Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-27 Thread Dave P. Martin
On Wed, Jan 26, 2011 at 04:06:40PM -0500, Nicolas Pitre wrote: > On Wed, 26 Jan 2011, Dave Martin wrote: > > > On Wed, Jan 26, 2011 at 3:52 PM, Russell King - ARM Linux > > wrote: > > > So I don't think weak symbols work like we want them to. > > > > > > > That was the conclusion I came to also

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-26 Thread Nicolas Pitre
On Wed, 26 Jan 2011, Dave Martin wrote: > On Wed, Jan 26, 2011 at 3:52 PM, Russell King - ARM Linux > wrote: > > So I don't think weak symbols work like we want them to. > > > > That was the conclusion I came to also ... the linker seems to resolve > references in each object before discarding s

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-26 Thread Dave Martin
On Wed, Jan 26, 2011 at 3:52 PM, Russell King - ARM Linux wrote: > On Wed, Jan 26, 2011 at 10:42:41AM -0500, Nicolas Pitre wrote: >> On Wed, 26 Jan 2011, Dave Martin wrote: >> > Alternatively, I wonder .alt.smp.init could make weak references >> > instead of normal references: then if the referenc

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-26 Thread Russell King - ARM Linux
On Wed, Jan 26, 2011 at 10:42:41AM -0500, Nicolas Pitre wrote: > On Wed, 26 Jan 2011, Dave Martin wrote: > > Alternatively, I wonder .alt.smp.init could make weak references > > instead of normal references: then if the referenced section is > > discarded, the reference will revert to 0 and the fix

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-26 Thread Nicolas Pitre
On Wed, 26 Jan 2011, Dave Martin wrote: > On Tue, Jan 25, 2011 at 9:21 PM, Nicolas Pitre > wrote: > > On Tue, 25 Jan 2011, Russell King - ARM Linux wrote: > > > >> Hmm, actually it looks like you can end up with configurations where the > >> spinlocks are inlined. > >> > >> That means we'll have

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-26 Thread Russell King - ARM Linux
On Wed, Jan 26, 2011 at 11:11:31AM +, Dave Martin wrote: > Do we need to consider any other discarded sections? In vmlinux.lds, I have: > > /* Default discards */ > /DISCARD/ : { *(.exit.text) *(.cpuexit.text) *(.memexit.text) > *(.exit.data) *(.cpuexit.data) *(.cpuexit.rodata) *(.memexit.d

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-26 Thread Dave Martin
On Tue, Jan 25, 2011 at 9:21 PM, Nicolas Pitre wrote: > On Tue, 25 Jan 2011, Russell King - ARM Linux wrote: > >> On Tue, Jan 25, 2011 at 05:33:14PM +, Dave Martin wrote: >> > On Tue, Jan 25, 2011 at 4:59 PM, Russell King - ARM Linux >> > wrote: >> > > On Tue, Jan 25, 2011 at 04:43:52PM +

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-25 Thread Nicolas Pitre
On Tue, 25 Jan 2011, Russell King - ARM Linux wrote: > On Tue, Jan 25, 2011 at 05:33:14PM +, Dave Martin wrote: > > On Tue, Jan 25, 2011 at 4:59 PM, Russell King - ARM Linux > > wrote: > > > On Tue, Jan 25, 2011 at 04:43:52PM +, Dave Martin wrote: > > >> A couple of questions on this: > >

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-25 Thread Russell King - ARM Linux
On Tue, Jan 25, 2011 at 05:33:14PM +, Dave Martin wrote: > On Tue, Jan 25, 2011 at 4:59 PM, Russell King - ARM Linux > wrote: > > On Tue, Jan 25, 2011 at 04:43:52PM +, Dave Martin wrote: > >> A couple of questions on this: > >> > >> 1) I notice these spinlock functions are generally marked

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-25 Thread Dave Martin
On Tue, Jan 25, 2011 at 4:59 PM, Russell King - ARM Linux wrote: > On Tue, Jan 25, 2011 at 04:43:52PM +, Dave Martin wrote: >> A couple of questions on this: >> >> 1) I notice these spinlock functions are generally marked inline. >> >> Is that likely to happen in modules?  If so, there would b

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-25 Thread Russell King - ARM Linux
On Tue, Jan 25, 2011 at 04:43:52PM +, Dave Martin wrote: > A couple of questions on this: > > 1) I notice these spinlock functions are generally marked inline. > > Is that likely to happen in modules? If so, there would be a need to > do SMP_ON_UP fixups at module load time -- I don't think

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-25 Thread Dave Martin
Hi there, On Mon, Jan 17, 2011 at 7:22 PM, Russell King - ARM Linux wrote: > SMP requires at least the ARMv6K extensions to be present, so if we're > running on SMP, the WFE and SEV instructions must be available. > > However, when we run on UP, the v6K extensions may not be available, > and so w

Re: [PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-17 Thread Tony Lindgren
* Russell King - ARM Linux [110117 11:21]: > SMP requires at least the ARMv6K extensions to be present, so if we're > running on SMP, the WFE and SEV instructions must be available. > > However, when we run on UP, the v6K extensions may not be available, > and so we don't want WFE/SEV to be in th

[PATCH 03/14] ARM: v6k: remove CPU_32v6K dependencies in asm/spinlock.h

2011-01-17 Thread Russell King - ARM Linux
SMP requires at least the ARMv6K extensions to be present, so if we're running on SMP, the WFE and SEV instructions must be available. However, when we run on UP, the v6K extensions may not be available, and so we don't want WFE/SEV to be in the instruction stream. Use the SMP alternatives infras