Thread (20 messages) 20 messages, 5 authors, 2005-05-27

Re: A new driver for Broadcom bcm5706

From: "David S. Miller" <davem@davemloft.net>
Date: 2005-05-21 04:36:56

From: "Michael Chan" <mchan@broadcom.com>
Date: Fri, 20 May 2005 16:04:21 -0700
On Fri, 2005-05-20 at 15:28 -0700, David S.Miller wrote:
quoted
From: Jeff Garzik <redacted>
Date: Fri, 20 May 2005 15:42:20 -0400
quoted
9) [additional review]  DaveM, others: is this correct for all arches?

+       if (unlikely((align = (unsigned long) skb->data & 0x7))) {
+               skb_reserve(skb, 8 - align);
+       }
It's probably not even necessary.  dev_alloc_skb() should be returning
an SKB with skb->data at least cache_line_size() aligned (see mm/slab.c)
unless the platform defines an ARCH_KMALLOC_MINALIGN override.
If I remember correctly, I was seeing some SKB with skb->data that is 4-
byte aligned on some Fedora kernels. I don't remember which kernel. This
device has an alignment requirement of at least 8-bytes for the receive
buffers.
Just keep it in for now then.  I wouldn't be surprised if some 2.4.x
kernels let this happen.
Yes, but in this case, cksum is the checksum calculated over the entire
TCP/UDP packet including the pseudo IP header. Jeff is right, it should
always be 0xffff when the checksum is correct. Checking for zero is a
bug.
Ok, thanks for verifying.
Originally, the driver pulse interval was set at 250 msec, but it's been
extended to a few seconds. So the driver currently will write the pulse
every second and do the serdes related checking at the same time.
I think the current timer stuff is fine, at least for now.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help