From: Jeff Garzik <jgarzik@pobox.com>
To: "Feldman, Scott" <scott.feldman@intel.com>
Cc: netdev@oss.sgi.com
Subject: Re: e100 "Ferguson" release
Date: Tue, 05 Aug 2003 01:29:41 -0400 [thread overview]
Message-ID: <3F2F40C5.9070601@pobox.com> (raw)
In-Reply-To: <C6F5CF431189FA4CBAEC9E7DD5441E010222929E@orsmsx402.jf.intel.com>
Feldman, Scott wrote:
>>* (API) Does the out-of-tx-resources condition in
>>e100_xmit_frame ever really happen? I am under the
>>impression that returning non-zero in ->hard_start_xmit
>>results in the packet sometimes being requeued and
>>sometimes dropped. I prefer to guarantee a more-steady
>>state, by simply dropping the packet unconditionally,
>>when this uncommon condition occurs. So, I would
>>a) mark the failure condition with unlikely(), and
>>b) if the condition occurs, simply drop the packet
>>(tx_dropped++, kfree
>>skb), and return zero.
>
>
> Stop the queue also?
>
> if(unlikely(e100_exec_cb(nic, skb, e100_xmit_prepare) == -ENOMEM)) {
> netif_stop_queue(netdev);
> nic->net_stats.tx_dropped++;
> dev_kfree_skb(skb);
> return 0;
> }
Yes. I would also printk(KERN_ERR "we have a bug!") or somesuch, like
several other drivers do, too.
>>* IIRC Donald's MII phy scanning code scans MII phy ids like this:
>>1..31,0. Or maybe 1..31, and then 0 iff no MII phys were found. In
>>general I would prefer to follow his eepro100.c probe order.
>>Some phys need this because they will report on both phy id #0 (which
>>is magical) and phy id #(non-zero). Donald would know more than me,
>
> here.
>
> [kernel] eepro100 gets the ID from the eeprom, so no scanning there.
> Current e100 goes 1, 0..31, which is what we've always done, IIRC.
hmmm. I prefer the phy scanning to checking eeprom, since it reduces
the chance of eeprom screwups. However, I still think there's some
issue related to phy id #0. Oh well, fine for now, I guess.
>>* do we care about spinlocks around the update_stats and
>>get_stats code?
>
>
> Not sure. update_stats runs in a timer callback. Can get_stats jump
> in?
Well, the ->get_stats only returns a pointer to the stats, which are
then accessed in an unlocked manner. Since the net stats are unsigned
longs, asynchronously reading and updating them isn't a big deal in
practice.
>>* (minor) use a netif_msg_xxx wrapper/constant in
>>e100_init_module test?
>
>
> Can't - don't have nic->msg_enable allocated yet. :(
You could always use "(1 << debug) - 1"... :) I dunno if it's worth
worrying about.
Jeff
next prev parent reply other threads:[~2003-08-05 5:29 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-08-05 3:45 e100 "Ferguson" release Feldman, Scott
2003-08-05 5:29 ` Jeff Garzik [this message]
2003-08-05 7:16 ` David S. Miller
-- strict thread matches above, loose matches on Subject: below --
2003-08-05 15:19 Feldman, Scott
2003-08-05 15:24 ` Jeff Garzik
2003-08-10 9:00 ` Felix Radensky
2003-08-05 15:44 ` Felix Radensky
2003-08-05 14:28 Feldman, Scott
2003-08-03 4:34 Feldman, Scott
2003-08-03 6:06 ` Jeff Garzik
2003-08-03 6:12 ` Jeff Garzik
2003-08-03 7:32 ` Ben Greear
2003-08-03 7:32 ` David S. Miller
2003-08-04 3:09 ` David Brownell
2003-08-04 3:08 ` David S. Miller
2003-08-04 3:45 ` David Brownell
2003-08-04 3:46 ` David S. Miller
2003-08-04 4:08 ` David Brownell
2003-08-04 4:13 ` David S. Miller
2003-08-04 17:38 ` David Brownell
2003-08-05 8:23 ` Felix Radensky
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3F2F40C5.9070601@pobox.com \
--to=jgarzik@pobox.com \
--cc=netdev@oss.sgi.com \
--cc=scott.feldman@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).