|To:||Andrew Morton <akpm@xxxxxxxxx>|
|Subject:||Re: [RFC][PATCH] net drivers and cache alignment|
|From:||Jeff Garzik <jgarzik@xxxxxxxxx>|
|Date:||Sat, 07 Dec 2002 18:36:48 -0500|
|Cc:||"David S. Miller" <davem@xxxxxxxxxx>, linux-kernel@xxxxxxxxxxxxxxx, netdev@xxxxxxxxxxx|
|References:||<3DF2781D.3030209@xxxxxxxxx> <20021207.144004.45605764.davem@xxxxxxxxxx> <3DF27EE7.4010508@xxxxxxxxx> <3DF2844C.F9216283@xxxxxxxxx>|
|User-agent:||Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2) Gecko/20021202|
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]
|<Prev in Thread]||Current Thread||[Next in Thread>|
|Previous by Date:||Re: [RFC][PATCH] net drivers and cache alignment, David S. Miller|
|Next by Date:||Re: [RFC][PATCH] net drivers and cache alignment, J.A. Magallon|
|Previous by Thread:||Re: [RFC][PATCH] net drivers and cache alignment, David S. Miller|
|Next by Thread:||Re: [RFC][PATCH] net drivers and cache alignment, J.A. Magallon|
|Indexes:||[Date] [Thread] [Top] [All Lists]|