Thread (11 messages) flat view 11 messages, 4 authors, 2002-12-08

Re: [RFC][PATCH] net drivers and cache alignment

From: Jeff Garzik <hidden>
Date: 2002-12-07 23:29:52
Also in: lkml

Andrew Morton wrote:
It needs padding _only_ on SMP.  ____cacheline_aligned_in_smp.
[...]
So your patch will do what you want it to do.  You should just tag the
first member of a group with ____cacheline_aligned_in_smp, and keep an
eye on things with offsetof().

thanks.

For this case, though, I want to align on cacheline bounaries even on 
UP, right?  That's why I picked ____cacheline_aligned.  It uses 
L1_CACHE_BYTES when !CONFIG_SMP.  Other uses of ____cacheline_aligned in 
the kernel seem to relate to irq matters, just like my groupings in tg3.h.

[obviously benchmarking can answer some of this, but I want to hammer 
out silliness first]

	Jeff
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help