All of lore.kernel.org
 help / color / mirror / Atom feed
* linux-next: build failure after merge of the final tree (staging related)
@ 2011-06-09  7:27 Stephen Rothwell
  2011-06-09 18:41 ` Greg KH
  0 siblings, 1 reply; 59+ messages in thread
From: Stephen Rothwell @ 2011-06-09  7:27 UTC (permalink / raw)
  To: Greg KH; +Cc: linux-next, linux-kernel, Linus

[-- Attachment #1: Type: text/plain, Size: 2561 bytes --]

Hi Greg,

After merging the final tree, today's linux-next build (powerpc allyesconfig)
failed like this:

drivers/staging/brcm80211/brcmsmac/ampdu.c: In function 'wlc_ampdu_dotxstatus':
drivers/staging/brcm80211/brcmsmac/ampdu.c:840:17: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
drivers/staging/brcm80211/brcmsmac/ampdu.c:840:17: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
drivers/staging/brcm80211/brcmsmac/ampdu.c:848:8: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
drivers/staging/brcm80211/brcmsmac/ampdu.c:848:8: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_bmac_update_slot_timing':
drivers/staging/brcm80211/brcmsmac/bmac.c:186:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
drivers/staging/brcm80211/brcmsmac/bmac.c:186:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
drivers/staging/brcm80211/brcmsmac/bmac.c:190:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
drivers/staging/brcm80211/brcmsmac/bmac.c:190:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_setband_inact':
drivers/staging/brcm80211/brcmsmac/bmac.c:234:2: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
drivers/staging/brcm80211/brcmsmac/bmac.c:234:2: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_dpc':
drivers/staging/brcm80211/brcmsmac/bmac.c:311:6: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')

(and lots more)

Also in several other files in drivers/staging/brcm80211/

Also:

drivers/staging/comedi/drivers.c: In function 'comedi_buf_alloc':
drivers/staging/comedi/drivers.c:505:37: error: 'PAGE_KERNEL_NOCACHE' undeclared (first use in this function)
In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'

(Also several other occurrences of that one)

I left this build broken, but these should be fixed if you are going to
remove STAGING_EXCLUDE_BUILD.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-09  7:27 linux-next: build failure after merge of the final tree (staging related) Stephen Rothwell
@ 2011-06-09 18:41 ` Greg KH
  2011-06-09 19:22   ` Greg KH
  2011-06-09 19:52   ` linux-next: build failure after merge of the final tree (staging related) Henry Ptasinski
  0 siblings, 2 replies; 59+ messages in thread
From: Greg KH @ 2011-06-09 18:41 UTC (permalink / raw)
  To: Stephen Rothwell, brudley, henryp, rvossen
  Cc: linux-next, linux-kernel, Linus

On Thu, Jun 09, 2011 at 05:27:45PM +1000, Stephen Rothwell wrote:
> Hi Greg,
> 
> After merging the final tree, today's linux-next build (powerpc allyesconfig)
> failed like this:
> 
> drivers/staging/brcm80211/brcmsmac/ampdu.c: In function 'wlc_ampdu_dotxstatus':
> drivers/staging/brcm80211/brcmsmac/ampdu.c:840:17: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/ampdu.c:840:17: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/ampdu.c:848:8: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/ampdu.c:848:8: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_bmac_update_slot_timing':
> drivers/staging/brcm80211/brcmsmac/bmac.c:186:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/bmac.c:186:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/bmac.c:190:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/bmac.c:190:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_setband_inact':
> drivers/staging/brcm80211/brcmsmac/bmac.c:234:2: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/bmac.c:234:2: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_dpc':
> drivers/staging/brcm80211/brcmsmac/bmac.c:311:6: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> 
> (and lots more)

Fun :(

This looks messy.  It's a macro that is trying to be cute by doing:
#define R_REG(r) \
        ({ \
                __typeof(*(r)) __osl_v; \
                __asm__ __volatile__("sync"); \
                __osl_v = bcmsdh_reg_read(NULL, (unsigned long)(r),\
                                          sizeof(*(r))); \
                __asm__ __volatile__("sync"); \
                __osl_v; \
        })

on big-endian, non-mips platforms.  Which I really doubt has ever
been tested before.

Roland, Brett, any thoughts?

Should I just disable this module from being build on PPC as it doesn't
look like its ever been tested or run on that platform before.

> Also in several other files in drivers/staging/brcm80211/
> 
> Also:
> 
> drivers/staging/comedi/drivers.c: In function 'comedi_buf_alloc':
> drivers/staging/comedi/drivers.c:505:37: error: 'PAGE_KERNEL_NOCACHE' undeclared (first use in this function)
> In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> 
> (Also several other occurrences of that one)

I'll fix this up, it looks just like a #include that needs to be added.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-09 18:41 ` Greg KH
@ 2011-06-09 19:22   ` Greg KH
  2011-06-10  6:05     ` Stephen Rothwell
  2011-06-09 19:52   ` linux-next: build failure after merge of the final tree (staging related) Henry Ptasinski
  1 sibling, 1 reply; 59+ messages in thread
From: Greg KH @ 2011-06-09 19:22 UTC (permalink / raw)
  To: Stephen Rothwell, brudley, henryp, rvossen
  Cc: linux-next, linux-kernel, Linus

On Thu, Jun 09, 2011 at 11:41:27AM -0700, Greg KH wrote:
> > Also in several other files in drivers/staging/brcm80211/
> > 
> > Also:
> > 
> > drivers/staging/comedi/drivers.c: In function 'comedi_buf_alloc':
> > drivers/staging/comedi/drivers.c:505:37: error: 'PAGE_KERNEL_NOCACHE' undeclared (first use in this function)
> > In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> > drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> > drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> > 
> > (Also several other occurrences of that one)
> 
> I'll fix this up, it looks just like a #include that needs to be added.

I've fixed all of these up, thanks for reporting them.

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-09 18:41 ` Greg KH
  2011-06-09 19:22   ` Greg KH
@ 2011-06-09 19:52   ` Henry Ptasinski
  2011-06-09 20:19     ` Greg KH
  1 sibling, 1 reply; 59+ messages in thread
From: Henry Ptasinski @ 2011-06-09 19:52 UTC (permalink / raw)
  To: Greg KH
  Cc: Stephen Rothwell, Brett Rudley, Roland Vossen, linux-next,
	linux-kernel, Linus, Henry Ptasinski

On Thu, Jun 09, 2011 at 11:41:27AM -0700, Greg KH wrote:
> On Thu, Jun 09, 2011 at 05:27:45PM +1000, Stephen Rothwell wrote:
> > Hi Greg,
> > 
> > After merging the final tree, today's linux-next build (powerpc allyesconfig)
> > failed like this:
> > 
> > drivers/staging/brcm80211/brcmsmac/ampdu.c: In function 'wlc_ampdu_dotxstatus':
> > drivers/staging/brcm80211/brcmsmac/ampdu.c:840:17: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/ampdu.c:840:17: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/ampdu.c:848:8: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/ampdu.c:848:8: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_bmac_update_slot_timing':
> > drivers/staging/brcm80211/brcmsmac/bmac.c:186:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/bmac.c:186:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/bmac.c:190:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/bmac.c:190:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_setband_inact':
> > drivers/staging/brcm80211/brcmsmac/bmac.c:234:2: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/bmac.c:234:2: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_dpc':
> > drivers/staging/brcm80211/brcmsmac/bmac.c:311:6: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > 
> > (and lots more)
> 
> Fun :(
> 
> This looks messy.  It's a macro that is trying to be cute by doing:
> #define R_REG(r) \
>         ({ \
>                 __typeof(*(r)) __osl_v; \
>                 __asm__ __volatile__("sync"); \
>                 __osl_v = bcmsdh_reg_read(NULL, (unsigned long)(r),\
>                                           sizeof(*(r))); \
>                 __asm__ __volatile__("sync"); \
>                 __osl_v; \
>         })
> 
> on big-endian, non-mips platforms.  Which I really doubt has ever
> been tested before.

I think it was used on PPC once upon a time, but likely in a very different
incarnation.

> Roland, Brett, any thoughts?
> 
> Should I just disable this module from being build on PPC as it doesn't
> look like its ever been tested or run on that platform before.

Disabling the build on PPC for now sounds ok.  We'll work on cleaning up the
macros and try to get some more platform test coverage.

- Henry



^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-09 19:52   ` linux-next: build failure after merge of the final tree (staging related) Henry Ptasinski
@ 2011-06-09 20:19     ` Greg KH
  0 siblings, 0 replies; 59+ messages in thread
From: Greg KH @ 2011-06-09 20:19 UTC (permalink / raw)
  To: Henry Ptasinski
  Cc: Stephen Rothwell, Brett Rudley, Roland Vossen, linux-next,
	linux-kernel, Linus

On Thu, Jun 09, 2011 at 12:52:12PM -0700, Henry Ptasinski wrote:
> On Thu, Jun 09, 2011 at 11:41:27AM -0700, Greg KH wrote:
> > On Thu, Jun 09, 2011 at 05:27:45PM +1000, Stephen Rothwell wrote:
> > > Hi Greg,
> > > 
> > > After merging the final tree, today's linux-next build (powerpc allyesconfig)
> > > failed like this:
> > > 
> > > drivers/staging/brcm80211/brcmsmac/ampdu.c: In function 'wlc_ampdu_dotxstatus':
> > > drivers/staging/brcm80211/brcmsmac/ampdu.c:840:17: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/ampdu.c:840:17: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/ampdu.c:848:8: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/ampdu.c:848:8: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_bmac_update_slot_timing':
> > > drivers/staging/brcm80211/brcmsmac/bmac.c:186:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/bmac.c:186:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/bmac.c:190:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/bmac.c:190:3: error: invalid operands to binary ^ (have 'volatile u16 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_setband_inact':
> > > drivers/staging/brcm80211/brcmsmac/bmac.c:234:2: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/bmac.c:234:2: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > > drivers/staging/brcm80211/brcmsmac/bmac.c: In function 'wlc_dpc':
> > > drivers/staging/brcm80211/brcmsmac/bmac.c:311:6: error: invalid operands to binary ^ (have 'volatile u32 *' and 'int')
> > > 
> > > (and lots more)
> > 
> > Fun :(
> > 
> > This looks messy.  It's a macro that is trying to be cute by doing:
> > #define R_REG(r) \
> >         ({ \
> >                 __typeof(*(r)) __osl_v; \
> >                 __asm__ __volatile__("sync"); \
> >                 __osl_v = bcmsdh_reg_read(NULL, (unsigned long)(r),\
> >                                           sizeof(*(r))); \
> >                 __asm__ __volatile__("sync"); \
> >                 __osl_v; \
> >         })
> > 
> > on big-endian, non-mips platforms.  Which I really doubt has ever
> > been tested before.
> 
> I think it was used on PPC once upon a time, but likely in a very different
> incarnation.
> 
> > Roland, Brett, any thoughts?
> > 
> > Should I just disable this module from being build on PPC as it doesn't
> > look like its ever been tested or run on that platform before.
> 
> Disabling the build on PPC for now sounds ok.  We'll work on cleaning up the
> macros and try to get some more platform test coverage.

Ok, I've done that now and pushed it to the staging-next tree.

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-09 19:22   ` Greg KH
@ 2011-06-10  6:05     ` Stephen Rothwell
  2011-06-10  6:09       ` Stephen Rothwell
                         ` (3 more replies)
  0 siblings, 4 replies; 59+ messages in thread
From: Stephen Rothwell @ 2011-06-10  6:05 UTC (permalink / raw)
  To: Greg KH; +Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

[-- Attachment #1: Type: text/plain, Size: 1766 bytes --]

Hi Greg,

On Thu, 9 Jun 2011 12:22:43 -0700 Greg KH <greg@kroah.com> wrote:
>
> On Thu, Jun 09, 2011 at 11:41:27AM -0700, Greg KH wrote:
> > > Also in several other files in drivers/staging/brcm80211/
> > > 
> > > Also:
> > > 
> > > drivers/staging/comedi/drivers.c: In function 'comedi_buf_alloc':
> > > drivers/staging/comedi/drivers.c:505:37: error: 'PAGE_KERNEL_NOCACHE' undeclared (first use in this function)
> > > In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> > > drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> > > drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> > > 
> > > (Also several other occurrences of that one)
> > 
> > I'll fix this up, it looks just like a #include that needs to be added.
> 
> I've fixed all of these up, thanks for reporting them.

No, I still get these:

In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'

virt_to_bus is only defined for 32 bit powerpc (not 64 bit) (and maybe
not at all on some architectures e.g. sparc).

From Documentation/DMA-API-HOWTO.txt:
"All drivers should be using these interfaces with no exceptions.  It
is planned to completely remove virt_to_bus() and bus_to_virt() as
they are entirely deprecated.  Some ports already do not provide these
as it is impossible to correctly support them."

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-10  6:05     ` Stephen Rothwell
@ 2011-06-10  6:09       ` Stephen Rothwell
  2011-06-10 22:34         ` Greg KH
  2011-06-15 12:05         ` Geert Uytterhoeven
                         ` (2 subsequent siblings)
  3 siblings, 1 reply; 59+ messages in thread
From: Stephen Rothwell @ 2011-06-10  6:09 UTC (permalink / raw)
  To: Greg KH; +Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

[-- Attachment #1: Type: text/plain, Size: 1032 bytes --]

Hi Greg,

On Fri, 10 Jun 2011 16:05:48 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> No, I still get these:
> 
> In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> 
> virt_to_bus is only defined for 32 bit powerpc (not 64 bit) (and maybe
> not at all on some architectures e.g. sparc).
> 
> From Documentation/DMA-API-HOWTO.txt:
> "All drivers should be using these interfaces with no exceptions.  It
> is planned to completely remove virt_to_bus() and bus_to_virt() as
> they are entirely deprecated.  Some ports already do not provide these
> as it is impossible to correctly support them."

Drivers that use virt_to_bus should Kconfig depend on VIRT_TO_BUS.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-10  6:09       ` Stephen Rothwell
@ 2011-06-10 22:34         ` Greg KH
  2011-06-15  4:21           ` Stephen Rothwell
  0 siblings, 1 reply; 59+ messages in thread
From: Greg KH @ 2011-06-10 22:34 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

On Fri, Jun 10, 2011 at 04:09:38PM +1000, Stephen Rothwell wrote:
> Hi Greg,
> 
> On Fri, 10 Jun 2011 16:05:48 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> >
> > No, I still get these:
> > 
> > In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> > drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> > drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> > 
> > virt_to_bus is only defined for 32 bit powerpc (not 64 bit) (and maybe
> > not at all on some architectures e.g. sparc).
> > 
> > From Documentation/DMA-API-HOWTO.txt:
> > "All drivers should be using these interfaces with no exceptions.  It
> > is planned to completely remove virt_to_bus() and bus_to_virt() as
> > they are entirely deprecated.  Some ports already do not provide these
> > as it is impossible to correctly support them."
> 
> Drivers that use virt_to_bus should Kconfig depend on VIRT_TO_BUS.

Ah, I missed that, sorry.  I'll go make that change as well.

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-10 22:34         ` Greg KH
@ 2011-06-15  4:21           ` Stephen Rothwell
  2011-06-16 19:14             ` Greg KH
  0 siblings, 1 reply; 59+ messages in thread
From: Stephen Rothwell @ 2011-06-15  4:21 UTC (permalink / raw)
  To: Greg KH; +Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

[-- Attachment #1: Type: text/plain, Size: 1327 bytes --]

Hi Greg,

On Fri, 10 Jun 2011 15:34:23 -0700 Greg KH <greg@kroah.com> wrote:
>
> On Fri, Jun 10, 2011 at 04:09:38PM +1000, Stephen Rothwell wrote:
> > 
> > On Fri, 10 Jun 2011 16:05:48 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > >
> > > No, I still get these:
> > > 
> > > In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> > > drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> > > drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> > > 
> > > virt_to_bus is only defined for 32 bit powerpc (not 64 bit) (and maybe
> > > not at all on some architectures e.g. sparc).
> > > 
> > > From Documentation/DMA-API-HOWTO.txt:
> > > "All drivers should be using these interfaces with no exceptions.  It
> > > is planned to completely remove virt_to_bus() and bus_to_virt() as
> > > they are entirely deprecated.  Some ports already do not provide these
> > > as it is impossible to correctly support them."
> > 
> > Drivers that use virt_to_bus should Kconfig depend on VIRT_TO_BUS.
> 
> Ah, I missed that, sorry.  I'll go make that change as well.

Ping?

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-10  6:05     ` Stephen Rothwell
@ 2011-06-15 12:05         ` Geert Uytterhoeven
  2011-06-15 12:05         ` Geert Uytterhoeven
                           ` (2 subsequent siblings)
  3 siblings, 0 replies; 59+ messages in thread
From: Geert Uytterhoeven @ 2011-06-15 12:05 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Greg KH, brudley, henryp, rvossen, linux-next, linux-kernel,
	Linus, sparclinux, Linux-Arch

On Fri, Jun 10, 2011 at 08:05, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> On Thu, 9 Jun 2011 12:22:43 -0700 Greg KH <greg@kroah.com> wrote:
>> On Thu, Jun 09, 2011 at 11:41:27AM -0700, Greg KH wrote:
>> > > Also in several other files in drivers/staging/brcm80211/
>> > >
>> > > Also:
>> > >
>> > > drivers/staging/comedi/drivers.c: In function 'comedi_buf_alloc':
>> > > drivers/staging/comedi/drivers.c:505:37: error: 'PAGE_KERNEL_NOCACHE' undeclared (first use in this function)

I have my doubts

#ifdef PAGE_KERNEL_NOCACHE
                            vmap(pages, n_pages, VM_MAP, PAGE_KERNEL_NOCACHE);
#else
                            vmap(pages, n_pages, VM_MAP, PAGE_KERNEL);
#endif

is the right "fix" for this...

BTW, PAGE_KERNEL_NOCACHE is defined on frv, m32r, mn10300, sh, and x86 only.

Strangely, both sparc and tile have

/*
 * Some hardware wants to get fixmapped without caching.
 */
#define set_fixmap_nocache(idx, phys) \
                __set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)

in their <asm/fixmap.h>, without having PAGE_KERNEL_NOCACHE...

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
@ 2011-06-15 12:05         ` Geert Uytterhoeven
  0 siblings, 0 replies; 59+ messages in thread
From: Geert Uytterhoeven @ 2011-06-15 12:05 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Greg KH, brudley, henryp, rvossen, linux-next, linux-kernel,
	Linus, sparclinux, Linux-Arch

On Fri, Jun 10, 2011 at 08:05, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> On Thu, 9 Jun 2011 12:22:43 -0700 Greg KH <greg@kroah.com> wrote:
>> On Thu, Jun 09, 2011 at 11:41:27AM -0700, Greg KH wrote:
>> > > Also in several other files in drivers/staging/brcm80211/
>> > >
>> > > Also:
>> > >
>> > > drivers/staging/comedi/drivers.c: In function 'comedi_buf_alloc':
>> > > drivers/staging/comedi/drivers.c:505:37: error: 'PAGE_KERNEL_NOCACHE' undeclared (first use in this function)

I have my doubts

#ifdef PAGE_KERNEL_NOCACHE
                            vmap(pages, n_pages, VM_MAP, PAGE_KERNEL_NOCACHE);
#else
                            vmap(pages, n_pages, VM_MAP, PAGE_KERNEL);
#endif

is the right "fix" for this...

BTW, PAGE_KERNEL_NOCACHE is defined on frv, m32r, mn10300, sh, and x86 only.

Strangely, both sparc and tile have

/*
 * Some hardware wants to get fixmapped without caching.
 */
#define set_fixmap_nocache(idx, phys) \
                __set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)

in their <asm/fixmap.h>, without having PAGE_KERNEL_NOCACHE...

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 59+ messages in thread

* [PATCH] arch/tile: remove useless set_fixmap_nocache() macro
  2011-06-10  6:05     ` Stephen Rothwell
  2011-06-10  6:09       ` Stephen Rothwell
  2011-06-15 12:05         ` Geert Uytterhoeven
@ 2011-06-15 14:35         ` Chris Metcalf
  2011-06-15 14:35         ` Chris Metcalf
  3 siblings, 0 replies; 59+ messages in thread
From: Chris Metcalf @ 2011-06-15 14:35 UTC (permalink / raw)
  To: Geert Uytterhoeven, Stephen Rothwell, Greg KH, brudley, henryp,
	rvossen, linux-next, linux-kernel, Linus, sparclinux, Linux-Arch

TILE doesn't support PAGE_KERNEL_NOCACHE so the macro isn't useful;
it's a copy-and-paste from the first version of this header in 2007.

Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
---
 arch/tile/include/asm/fixmap.h |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/arch/tile/include/asm/fixmap.h b/arch/tile/include/asm/fixmap.h
index 51537ff..c66f793 100644
--- a/arch/tile/include/asm/fixmap.h
+++ b/arch/tile/include/asm/fixmap.h
@@ -75,12 +75,6 @@ extern void __set_fixmap(enum fixed_addresses idx,
 
 #define set_fixmap(idx, phys) \
 		__set_fixmap(idx, phys, PAGE_KERNEL)
-/*
- * Some hardware wants to get fixmapped without caching.
- */
-#define set_fixmap_nocache(idx, phys) \
-		__set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)
-
 #define clear_fixmap(idx) \
 		__set_fixmap(idx, 0, __pgprot(0))
 
-- 
1.6.5.2


^ permalink raw reply related	[flat|nested] 59+ messages in thread

* [PATCH] arch/tile: remove useless set_fixmap_nocache() macro
  2011-06-10  6:05     ` Stephen Rothwell
  2011-06-10  6:09       ` Stephen Rothwell
  2011-06-15 12:05         ` Geert Uytterhoeven
@ 2011-06-15 14:35       ` Chris Metcalf
  2011-06-15 14:35         ` Chris Metcalf
  3 siblings, 0 replies; 59+ messages in thread
From: Chris Metcalf @ 2011-06-15 14:35 UTC (permalink / raw)
  To: Geert Uytterhoeven, Stephen Rothwell, Greg KH, brudley, henryp, rvossen

TILE doesn't support PAGE_KERNEL_NOCACHE so the macro isn't useful;
it's a copy-and-paste from the first version of this header in 2007.

Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
---
 arch/tile/include/asm/fixmap.h |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/arch/tile/include/asm/fixmap.h b/arch/tile/include/asm/fixmap.h
index 51537ff..c66f793 100644
--- a/arch/tile/include/asm/fixmap.h
+++ b/arch/tile/include/asm/fixmap.h
@@ -75,12 +75,6 @@ extern void __set_fixmap(enum fixed_addresses idx,
 
 #define set_fixmap(idx, phys) \
 		__set_fixmap(idx, phys, PAGE_KERNEL)
-/*
- * Some hardware wants to get fixmapped without caching.
- */
-#define set_fixmap_nocache(idx, phys) \
-		__set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)
-
 #define clear_fixmap(idx) \
 		__set_fixmap(idx, 0, __pgprot(0))
 
-- 
1.6.5.2

^ permalink raw reply related	[flat|nested] 59+ messages in thread

* [PATCH] arch/tile: remove useless set_fixmap_nocache() macro
@ 2011-06-15 14:35         ` Chris Metcalf
  0 siblings, 0 replies; 59+ messages in thread
From: Chris Metcalf @ 2011-06-15 14:35 UTC (permalink / raw)
  To: Geert Uytterhoeven, Stephen Rothwell, Greg KH, brudley, henryp, rvossen

TILE doesn't support PAGE_KERNEL_NOCACHE so the macro isn't useful;
it's a copy-and-paste from the first version of this header in 2007.

Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
---
 arch/tile/include/asm/fixmap.h |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/arch/tile/include/asm/fixmap.h b/arch/tile/include/asm/fixmap.h
index 51537ff..c66f793 100644
--- a/arch/tile/include/asm/fixmap.h
+++ b/arch/tile/include/asm/fixmap.h
@@ -75,12 +75,6 @@ extern void __set_fixmap(enum fixed_addresses idx,
 
 #define set_fixmap(idx, phys) \
 		__set_fixmap(idx, phys, PAGE_KERNEL)
-/*
- * Some hardware wants to get fixmapped without caching.
- */
-#define set_fixmap_nocache(idx, phys) \
-		__set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)
-
 #define clear_fixmap(idx) \
 		__set_fixmap(idx, 0, __pgprot(0))
 
-- 
1.6.5.2

^ permalink raw reply related	[flat|nested] 59+ messages in thread

* [PATCH] arch/tile: remove useless set_fixmap_nocache() macro
@ 2011-06-15 14:35         ` Chris Metcalf
  0 siblings, 0 replies; 59+ messages in thread
From: Chris Metcalf @ 2011-06-15 14:35 UTC (permalink / raw)
  To: Geert Uytterhoeven, Stephen Rothwell, Greg KH, brudley, henryp,
	rvossen, linux-next, linux-kernel, Linus, sparclinux, Linux-Arch

TILE doesn't support PAGE_KERNEL_NOCACHE so the macro isn't useful;
it's a copy-and-paste from the first version of this header in 2007.

Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
---
 arch/tile/include/asm/fixmap.h |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/arch/tile/include/asm/fixmap.h b/arch/tile/include/asm/fixmap.h
index 51537ff..c66f793 100644
--- a/arch/tile/include/asm/fixmap.h
+++ b/arch/tile/include/asm/fixmap.h
@@ -75,12 +75,6 @@ extern void __set_fixmap(enum fixed_addresses idx,
 
 #define set_fixmap(idx, phys) \
 		__set_fixmap(idx, phys, PAGE_KERNEL)
-/*
- * Some hardware wants to get fixmapped without caching.
- */
-#define set_fixmap_nocache(idx, phys) \
-		__set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)
-
 #define clear_fixmap(idx) \
 		__set_fixmap(idx, 0, __pgprot(0))
 
-- 
1.6.5.2


^ permalink raw reply related	[flat|nested] 59+ messages in thread

* [PATCH] arch/tile: remove useless set_fixmap_nocache() macro
@ 2011-06-15 14:35         ` Chris Metcalf
  0 siblings, 0 replies; 59+ messages in thread
From: Chris Metcalf @ 2011-06-15 14:35 UTC (permalink / raw)
  To: Geert Uytterhoeven, Stephen Rothwell, Greg KH, brudley, henryp, rvossen

TILE doesn't support PAGE_KERNEL_NOCACHE so the macro isn't useful;
it's a copy-and-paste from the first version of this header in 2007.

Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
---
 arch/tile/include/asm/fixmap.h |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/arch/tile/include/asm/fixmap.h b/arch/tile/include/asm/fixmap.h
index 51537ff..c66f793 100644
--- a/arch/tile/include/asm/fixmap.h
+++ b/arch/tile/include/asm/fixmap.h
@@ -75,12 +75,6 @@ extern void __set_fixmap(enum fixed_addresses idx,
 
 #define set_fixmap(idx, phys) \
 		__set_fixmap(idx, phys, PAGE_KERNEL)
-/*
- * Some hardware wants to get fixmapped without caching.
- */
-#define set_fixmap_nocache(idx, phys) \
-		__set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)
-
 #define clear_fixmap(idx) \
 		__set_fixmap(idx, 0, __pgprot(0))
 
-- 
1.6.5.2


^ permalink raw reply related	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-15 12:05         ` Geert Uytterhoeven
@ 2011-06-15 15:47           ` Greg KH
  -1 siblings, 0 replies; 59+ messages in thread
From: Greg KH @ 2011-06-15 15:47 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Stephen Rothwell, brudley, henryp, rvossen, linux-next,
	linux-kernel, Linus, sparclinux, Linux-Arch

On Wed, Jun 15, 2011 at 02:05:29PM +0200, Geert Uytterhoeven wrote:
> On Fri, Jun 10, 2011 at 08:05, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > On Thu, 9 Jun 2011 12:22:43 -0700 Greg KH <greg@kroah.com> wrote:
> >> On Thu, Jun 09, 2011 at 11:41:27AM -0700, Greg KH wrote:
> >> > > Also in several other files in drivers/staging/brcm80211/
> >> > >
> >> > > Also:
> >> > >
> >> > > drivers/staging/comedi/drivers.c: In function 'comedi_buf_alloc':
> >> > > drivers/staging/comedi/drivers.c:505:37: error: 'PAGE_KERNEL_NOCACHE' undeclared (first use in this function)
> 
> I have my doubts
> 
> #ifdef PAGE_KERNEL_NOCACHE
>                             vmap(pages, n_pages, VM_MAP, PAGE_KERNEL_NOCACHE);
> #else
>                             vmap(pages, n_pages, VM_MAP, PAGE_KERNEL);
> #endif
> 
> is the right "fix" for this...
> 
> BTW, PAGE_KERNEL_NOCACHE is defined on frv, m32r, mn10300, sh, and x86 only.
> 
> Strangely, both sparc and tile have
> 
> /*
>  * Some hardware wants to get fixmapped without caching.
>  */
> #define set_fixmap_nocache(idx, phys) \
>                 __set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)
> 
> in their <asm/fixmap.h>, without having PAGE_KERNEL_NOCACHE...

So, what should the correct fix here be?

confused,

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging
@ 2011-06-15 15:47           ` Greg KH
  0 siblings, 0 replies; 59+ messages in thread
From: Greg KH @ 2011-06-15 15:47 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Stephen Rothwell, brudley, henryp, rvossen, linux-next,
	linux-kernel, Linus, sparclinux, Linux-Arch

On Wed, Jun 15, 2011 at 02:05:29PM +0200, Geert Uytterhoeven wrote:
> On Fri, Jun 10, 2011 at 08:05, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > On Thu, 9 Jun 2011 12:22:43 -0700 Greg KH <greg@kroah.com> wrote:
> >> On Thu, Jun 09, 2011 at 11:41:27AM -0700, Greg KH wrote:
> >> > > Also in several other files in drivers/staging/brcm80211/
> >> > >
> >> > > Also:
> >> > >
> >> > > drivers/staging/comedi/drivers.c: In function 'comedi_buf_alloc':
> >> > > drivers/staging/comedi/drivers.c:505:37: error: 'PAGE_KERNEL_NOCACHE' undeclared (first use in this function)
> 
> I have my doubts
> 
> #ifdef PAGE_KERNEL_NOCACHE
>                             vmap(pages, n_pages, VM_MAP, PAGE_KERNEL_NOCACHE);
> #else
>                             vmap(pages, n_pages, VM_MAP, PAGE_KERNEL);
> #endif
> 
> is the right "fix" for this...
> 
> BTW, PAGE_KERNEL_NOCACHE is defined on frv, m32r, mn10300, sh, and x86 only.
> 
> Strangely, both sparc and tile have
> 
> /*
>  * Some hardware wants to get fixmapped without caching.
>  */
> #define set_fixmap_nocache(idx, phys) \
>                 __set_fixmap(idx, phys, PAGE_KERNEL_NOCACHE)
> 
> in their <asm/fixmap.h>, without having PAGE_KERNEL_NOCACHE...

So, what should the correct fix here be?

confused,

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-15  4:21           ` Stephen Rothwell
@ 2011-06-16 19:14             ` Greg KH
  2011-06-23  0:35               ` Stephen Rothwell
  0 siblings, 1 reply; 59+ messages in thread
From: Greg KH @ 2011-06-16 19:14 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

On Wed, Jun 15, 2011 at 02:21:55PM +1000, Stephen Rothwell wrote:
> Hi Greg,
> 
> On Fri, 10 Jun 2011 15:34:23 -0700 Greg KH <greg@kroah.com> wrote:
> >
> > On Fri, Jun 10, 2011 at 04:09:38PM +1000, Stephen Rothwell wrote:
> > > 
> > > On Fri, 10 Jun 2011 16:05:48 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > > >
> > > > No, I still get these:
> > > > 
> > > > In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> > > > drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> > > > drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> > > > 
> > > > virt_to_bus is only defined for 32 bit powerpc (not 64 bit) (and maybe
> > > > not at all on some architectures e.g. sparc).
> > > > 
> > > > From Documentation/DMA-API-HOWTO.txt:
> > > > "All drivers should be using these interfaces with no exceptions.  It
> > > > is planned to completely remove virt_to_bus() and bus_to_virt() as
> > > > they are entirely deprecated.  Some ports already do not provide these
> > > > as it is impossible to correctly support them."
> > > 
> > > Drivers that use virt_to_bus should Kconfig depend on VIRT_TO_BUS.
> > 
> > Ah, I missed that, sorry.  I'll go make that change as well.
> 
> Ping?

Sorry, been swamped with other work, I'll get to this soon...

With a very relative value of soon.

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-16 19:14             ` Greg KH
@ 2011-06-23  0:35               ` Stephen Rothwell
  2011-06-23 21:51                 ` Greg KH
  0 siblings, 1 reply; 59+ messages in thread
From: Stephen Rothwell @ 2011-06-23  0:35 UTC (permalink / raw)
  To: Greg KH; +Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

[-- Attachment #1: Type: text/plain, Size: 1762 bytes --]

Hi Greg,

On Thu, 16 Jun 2011 12:14:48 -0700 Greg KH <greg@kroah.com> wrote:
>
> On Wed, Jun 15, 2011 at 02:21:55PM +1000, Stephen Rothwell wrote:
> > 
> > On Fri, 10 Jun 2011 15:34:23 -0700 Greg KH <greg@kroah.com> wrote:
> > >
> > > On Fri, Jun 10, 2011 at 04:09:38PM +1000, Stephen Rothwell wrote:
> > > > 
> > > > On Fri, 10 Jun 2011 16:05:48 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > > > >
> > > > > No, I still get these:
> > > > > 
> > > > > In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> > > > > drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> > > > > drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> > > > > 
> > > > > virt_to_bus is only defined for 32 bit powerpc (not 64 bit) (and maybe
> > > > > not at all on some architectures e.g. sparc).
> > > > > 
> > > > > From Documentation/DMA-API-HOWTO.txt:
> > > > > "All drivers should be using these interfaces with no exceptions.  It
> > > > > is planned to completely remove virt_to_bus() and bus_to_virt() as
> > > > > they are entirely deprecated.  Some ports already do not provide these
> > > > > as it is impossible to correctly support them."
> > > > 
> > > > Drivers that use virt_to_bus should Kconfig depend on VIRT_TO_BUS.
> > > 
> > > Ah, I missed that, sorry.  I'll go make that change as well.
> > 
> > Ping?
> 
> Sorry, been swamped with other work, I'll get to this soon...

ping?

> With a very relative value of soon.

Yeah, I understand busy ... but this is a simple patch, rigth?

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-23  0:35               ` Stephen Rothwell
@ 2011-06-23 21:51                 ` Greg KH
  2011-06-24  0:00                   ` Stephen Rothwell
  0 siblings, 1 reply; 59+ messages in thread
From: Greg KH @ 2011-06-23 21:51 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

On Thu, Jun 23, 2011 at 10:35:03AM +1000, Stephen Rothwell wrote:
> Hi Greg,
> 
> On Thu, 16 Jun 2011 12:14:48 -0700 Greg KH <greg@kroah.com> wrote:
> >
> > On Wed, Jun 15, 2011 at 02:21:55PM +1000, Stephen Rothwell wrote:
> > > 
> > > On Fri, 10 Jun 2011 15:34:23 -0700 Greg KH <greg@kroah.com> wrote:
> > > >
> > > > On Fri, Jun 10, 2011 at 04:09:38PM +1000, Stephen Rothwell wrote:
> > > > > 
> > > > > On Fri, 10 Jun 2011 16:05:48 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > > > > >
> > > > > > No, I still get these:
> > > > > > 
> > > > > > In file included from drivers/staging/comedi/drivers/addi_apci_035.c:7:0:
> > > > > > drivers/staging/comedi/drivers/addi-data/addi_common.c: In function 'i_ADDI_Attach':
> > > > > > drivers/staging/comedi/drivers/addi-data/addi_common.c:2765:7: error: implicit declaration of function 'virt_to_bus'
> > > > > > 
> > > > > > virt_to_bus is only defined for 32 bit powerpc (not 64 bit) (and maybe
> > > > > > not at all on some architectures e.g. sparc).
> > > > > > 
> > > > > > From Documentation/DMA-API-HOWTO.txt:
> > > > > > "All drivers should be using these interfaces with no exceptions.  It
> > > > > > is planned to completely remove virt_to_bus() and bus_to_virt() as
> > > > > > they are entirely deprecated.  Some ports already do not provide these
> > > > > > as it is impossible to correctly support them."
> > > > > 
> > > > > Drivers that use virt_to_bus should Kconfig depend on VIRT_TO_BUS.
> > > > 
> > > > Ah, I missed that, sorry.  I'll go make that change as well.
> > > 
> > > Ping?
> > 
> > Sorry, been swamped with other work, I'll get to this soon...
> 
> ping?
> 
> > With a very relative value of soon.
> 
> Yeah, I understand busy ... but this is a simple patch, rigth?

Sorry, I'm away from home, with a very spotty internet connection, on
vacation, so it's hard to get this done at the moment.  I'll get to it
on the 27th when I return.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-23 21:51                 ` Greg KH
@ 2011-06-24  0:00                   ` Stephen Rothwell
  2011-06-27 21:45                     ` Greg KH
  0 siblings, 1 reply; 59+ messages in thread
From: Stephen Rothwell @ 2011-06-24  0:00 UTC (permalink / raw)
  To: Greg KH; +Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

[-- Attachment #1: Type: text/plain, Size: 507 bytes --]

Hi Greg,

On Thu, 23 Jun 2011 14:51:15 -0700 Greg KH <greg@kroah.com> wrote:
>
> Sorry, I'm away from home, with a very spotty internet connection, on
> vacation, so it's hard to get this done at the moment.  I'll get to it
> on the 27th when I return.

I can understand vacation as well :-)

Thanks.  I will use Ralf's (arch restricting) patch until you come up
with something better.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-24  0:00                   ` Stephen Rothwell
@ 2011-06-27 21:45                     ` Greg KH
  2011-06-28  0:16                       ` Stephen Rothwell
  0 siblings, 1 reply; 59+ messages in thread
From: Greg KH @ 2011-06-27 21:45 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

On Fri, Jun 24, 2011 at 10:00:05AM +1000, Stephen Rothwell wrote:
> Hi Greg,
> 
> On Thu, 23 Jun 2011 14:51:15 -0700 Greg KH <greg@kroah.com> wrote:
> >
> > Sorry, I'm away from home, with a very spotty internet connection, on
> > vacation, so it's hard to get this done at the moment.  I'll get to it
> > on the 27th when I return.
> 
> I can understand vacation as well :-)
> 
> Thanks.  I will use Ralf's (arch restricting) patch until you come up
> with something better.

That's good, but it doesn't fix the root problem here.  I've now fixed
this up in the staging-linus branch.

You shouldn't have any more build breakages in the drivers/staging/*
tree now as I am pretty sure I've fixed all reported issues.  If not,
please let me know.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (staging related)
  2011-06-27 21:45                     ` Greg KH
@ 2011-06-28  0:16                       ` Stephen Rothwell
  0 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2011-06-28  0:16 UTC (permalink / raw)
  To: Greg KH; +Cc: brudley, henryp, rvossen, linux-next, linux-kernel, Linus

[-- Attachment #1: Type: text/plain, Size: 723 bytes --]

Hi Greg,

On Mon, 27 Jun 2011 14:45:47 -0700 Greg KH <greg@kroah.com> wrote:
>
> On Fri, Jun 24, 2011 at 10:00:05AM +1000, Stephen Rothwell wrote:
> > 
> > Thanks.  I will use Ralf's (arch restricting) patch until you come up
> > with something better.
> 
> That's good, but it doesn't fix the root problem here.  I've now fixed
> this up in the staging-linus branch.

OK, I have removed my copy of Ralf's patch.

> You shouldn't have any more build breakages in the drivers/staging/*
> tree now as I am pretty sure I've fixed all reported issues.  If not,
> please let me know.

Great, thanks.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* linux-next: build failure after merge of the final tree (pci tree related)
  2011-06-15 12:05         ` Geert Uytterhoeven
@ 2012-06-12  4:54 ` Stephen Rothwell
  -1 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2012-06-12  4:54 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

[-- Attachment #1: Type: text/plain, Size: 1375 bytes --]

Hi all,

After merging the final tree, today's linux-next build (sparc64 defconfig)
failed like this:

arch/sparc/kernel/pci.c: In function 'pci_scan_one_pbm':
arch/sparc/kernel/pci.c:689:21: error: 'struct pci_pbm_info' has no member named 'pci_last_busn'

Caused by commit 2c7f691b032b ("sparc/PCI: register busn_res for root buses").

I have added the following patch for today:

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Tue, 12 Jun 2012 14:48:39 +1000
Subject: [PATCH] sparc/PCI: fix typo

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 arch/sparc/kernel/pci.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c
index 74e4bf3..4f92a9a 100644
--- a/arch/sparc/kernel/pci.c
+++ b/arch/sparc/kernel/pci.c
@@ -686,7 +686,7 @@ struct pci_bus * __devinit pci_scan_one_pbm(struct pci_pbm_info *pbm,
 	pci_add_resource_offset(&resources, &pbm->mem_space,
 				pbm->mem_space.start);
 	pbm->busn.start = pbm->pci_first_busno;
-	pbm->busn.end	= pbm->pci_last_busn;
+	pbm->busn.end	= pbm->pci_last_busno;
 	pbm->busn.flags	= IORESOURCE_BUS;
 	pci_add_resource(&resources, &pbm->busn);
 	bus = pci_create_root_bus(parent, pbm->pci_first_busno, pbm->pci_ops,
-- 
1.7.10.280.gaa39

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply related	[flat|nested] 59+ messages in thread

* linux-next: build failure after merge of the final tree (pci tree related)
@ 2012-06-12  4:54 ` Stephen Rothwell
  0 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2012-06-12  4:54 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

[-- Attachment #1: Type: text/plain, Size: 1375 bytes --]

Hi all,

After merging the final tree, today's linux-next build (sparc64 defconfig)
failed like this:

arch/sparc/kernel/pci.c: In function 'pci_scan_one_pbm':
arch/sparc/kernel/pci.c:689:21: error: 'struct pci_pbm_info' has no member named 'pci_last_busn'

Caused by commit 2c7f691b032b ("sparc/PCI: register busn_res for root buses").

I have added the following patch for today:

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Tue, 12 Jun 2012 14:48:39 +1000
Subject: [PATCH] sparc/PCI: fix typo

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 arch/sparc/kernel/pci.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c
index 74e4bf3..4f92a9a 100644
--- a/arch/sparc/kernel/pci.c
+++ b/arch/sparc/kernel/pci.c
@@ -686,7 +686,7 @@ struct pci_bus * __devinit pci_scan_one_pbm(struct pci_pbm_info *pbm,
 	pci_add_resource_offset(&resources, &pbm->mem_space,
 				pbm->mem_space.start);
 	pbm->busn.start = pbm->pci_first_busno;
-	pbm->busn.end	= pbm->pci_last_busn;
+	pbm->busn.end	= pbm->pci_last_busno;
 	pbm->busn.flags	= IORESOURCE_BUS;
 	pci_add_resource(&resources, &pbm->busn);
 	bus = pci_create_root_bus(parent, pbm->pci_first_busno, pbm->pci_ops,
-- 
1.7.10.280.gaa39

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply related	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (pci tree related)
  2012-06-12  4:54 ` Stephen Rothwell
  (?)
@ 2012-06-12 15:31   ` Bjorn Helgaas
  -1 siblings, 0 replies; 59+ messages in thread
From: Bjorn Helgaas @ 2012-06-12 15:31 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

On Mon, Jun 11, 2012 at 10:54 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi all,
>
> After merging the final tree, today's linux-next build (sparc64 defconfig)
> failed like this:
>
> arch/sparc/kernel/pci.c: In function 'pci_scan_one_pbm':
> arch/sparc/kernel/pci.c:689:21: error: 'struct pci_pbm_info' has no member named 'pci_last_busn'
>
> Caused by commit 2c7f691b032b ("sparc/PCI: register busn_res for root buses").
>
> I have added the following patch for today:
>
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 12 Jun 2012 14:48:39 +1000
> Subject: [PATCH] sparc/PCI: fix typo
>
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/kernel/pci.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c
> index 74e4bf3..4f92a9a 100644
> --- a/arch/sparc/kernel/pci.c
> +++ b/arch/sparc/kernel/pci.c
> @@ -686,7 +686,7 @@ struct pci_bus * __devinit pci_scan_one_pbm(struct pci_pbm_info *pbm,
>        pci_add_resource_offset(&resources, &pbm->mem_space,
>                                pbm->mem_space.start);
>        pbm->busn.start = pbm->pci_first_busno;
> -       pbm->busn.end   = pbm->pci_last_busn;
> +       pbm->busn.end   = pbm->pci_last_busno;
>        pbm->busn.flags = IORESOURCE_BUS;
>        pci_add_resource(&resources, &pbm->busn);
>        bus = pci_create_root_bus(parent, pbm->pci_first_busno, pbm->pci_ops,

Thanks, I folded this typo fix into the relevant patch.  I'll rebase
"next" today.  Sorry for the trouble.

Bjorn

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (pci tree related)
@ 2012-06-12 15:31   ` Bjorn Helgaas
  0 siblings, 0 replies; 59+ messages in thread
From: Bjorn Helgaas @ 2012-06-12 15:31 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

On Mon, Jun 11, 2012 at 10:54 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi all,
>
> After merging the final tree, today's linux-next build (sparc64 defconfig)
> failed like this:
>
> arch/sparc/kernel/pci.c: In function 'pci_scan_one_pbm':
> arch/sparc/kernel/pci.c:689:21: error: 'struct pci_pbm_info' has no member named 'pci_last_busn'
>
> Caused by commit 2c7f691b032b ("sparc/PCI: register busn_res for root buses").
>
> I have added the following patch for today:
>
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 12 Jun 2012 14:48:39 +1000
> Subject: [PATCH] sparc/PCI: fix typo
>
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/kernel/pci.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c
> index 74e4bf3..4f92a9a 100644
> --- a/arch/sparc/kernel/pci.c
> +++ b/arch/sparc/kernel/pci.c
> @@ -686,7 +686,7 @@ struct pci_bus * __devinit pci_scan_one_pbm(struct pci_pbm_info *pbm,
>        pci_add_resource_offset(&resources, &pbm->mem_space,
>                                pbm->mem_space.start);
>        pbm->busn.start = pbm->pci_first_busno;
> -       pbm->busn.end   = pbm->pci_last_busn;
> +       pbm->busn.end   = pbm->pci_last_busno;
>        pbm->busn.flags = IORESOURCE_BUS;
>        pci_add_resource(&resources, &pbm->busn);
>        bus = pci_create_root_bus(parent, pbm->pci_first_busno, pbm->pci_ops,

Thanks, I folded this typo fix into the relevant patch.  I'll rebase
"next" today.  Sorry for the trouble.

Bjorn
--
To unsubscribe from this list: send the line "unsubscribe sparclinux" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (pci tree related)
@ 2012-06-12 15:31   ` Bjorn Helgaas
  0 siblings, 0 replies; 59+ messages in thread
From: Bjorn Helgaas @ 2012-06-12 15:31 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

On Mon, Jun 11, 2012 at 10:54 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi all,
>
> After merging the final tree, today's linux-next build (sparc64 defconfig)
> failed like this:
>
> arch/sparc/kernel/pci.c: In function 'pci_scan_one_pbm':
> arch/sparc/kernel/pci.c:689:21: error: 'struct pci_pbm_info' has no member named 'pci_last_busn'
>
> Caused by commit 2c7f691b032b ("sparc/PCI: register busn_res for root buses").
>
> I have added the following patch for today:
>
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 12 Jun 2012 14:48:39 +1000
> Subject: [PATCH] sparc/PCI: fix typo
>
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/kernel/pci.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c
> index 74e4bf3..4f92a9a 100644
> --- a/arch/sparc/kernel/pci.c
> +++ b/arch/sparc/kernel/pci.c
> @@ -686,7 +686,7 @@ struct pci_bus * __devinit pci_scan_one_pbm(struct pci_pbm_info *pbm,
>        pci_add_resource_offset(&resources, &pbm->mem_space,
>                                pbm->mem_space.start);
>        pbm->busn.start = pbm->pci_first_busno;
> -       pbm->busn.end   = pbm->pci_last_busn;
> +       pbm->busn.end   = pbm->pci_last_busno;
>        pbm->busn.flags = IORESOURCE_BUS;
>        pci_add_resource(&resources, &pbm->busn);
>        bus = pci_create_root_bus(parent, pbm->pci_first_busno, pbm->pci_ops,

Thanks, I folded this typo fix into the relevant patch.  I'll rebase
"next" today.  Sorry for the trouble.

Bjorn

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (pci tree related)
  2012-06-12 15:31   ` Bjorn Helgaas
@ 2012-06-13  0:50     ` Stephen Rothwell
  -1 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2012-06-13  0:50 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

[-- Attachment #1: Type: text/plain, Size: 443 bytes --]

Hi Bjorn,

On Tue, 12 Jun 2012 09:31:49 -0600 Bjorn Helgaas <bhelgaas@google.com> wrote:
>
> Thanks, I folded this typo fix into the relevant patch.  I'll rebase
> "next" today.  Sorry for the trouble.

I am not sure what you have done, but now you have a set of duplicated
commits in your tree including both versions of the one that caused the
build failure.
-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (pci tree related)
@ 2012-06-13  0:50     ` Stephen Rothwell
  0 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2012-06-13  0:50 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

[-- Attachment #1: Type: text/plain, Size: 443 bytes --]

Hi Bjorn,

On Tue, 12 Jun 2012 09:31:49 -0600 Bjorn Helgaas <bhelgaas@google.com> wrote:
>
> Thanks, I folded this typo fix into the relevant patch.  I'll rebase
> "next" today.  Sorry for the trouble.

I am not sure what you have done, but now you have a set of duplicated
commits in your tree including both versions of the one that caused the
build failure.
-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (pci tree related)
  2012-06-13  0:50     ` Stephen Rothwell
@ 2012-06-13 23:20       ` Bjorn Helgaas
  -1 siblings, 0 replies; 59+ messages in thread
From: Bjorn Helgaas @ 2012-06-13 23:20 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

On Tue, Jun 12, 2012 at 6:50 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi Bjorn,
>
> On Tue, 12 Jun 2012 09:31:49 -0600 Bjorn Helgaas <bhelgaas@google.com> wrote:
>>
>> Thanks, I folded this typo fix into the relevant patch.  I'll rebase
>> "next" today.  Sorry for the trouble.
>
> I am not sure what you have done, but now you have a set of duplicated
> commits in your tree including both versions of the one that caused the
> build failure.

This is because of my inept git usage.  I think my "next" branch ended
up with the right bits in it, but the history looked strange because I
fixed the typo in the Yinghai branch, but had a second branch that
depended on the original unfixed branch.

I rebuilt my "next" branch again and I think it's more
straightforward.  And I learned a tiny bit more about git, so thanks
for pointing this out.

Bjorn

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (pci tree related)
@ 2012-06-13 23:20       ` Bjorn Helgaas
  0 siblings, 0 replies; 59+ messages in thread
From: Bjorn Helgaas @ 2012-06-13 23:20 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: linux-next, linux-kernel, Yinghai Lu, David S. Miller, sparclinux

On Tue, Jun 12, 2012 at 6:50 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi Bjorn,
>
> On Tue, 12 Jun 2012 09:31:49 -0600 Bjorn Helgaas <bhelgaas@google.com> wrote:
>>
>> Thanks, I folded this typo fix into the relevant patch.  I'll rebase
>> "next" today.  Sorry for the trouble.
>
> I am not sure what you have done, but now you have a set of duplicated
> commits in your tree including both versions of the one that caused the
> build failure.

This is because of my inept git usage.  I think my "next" branch ended
up with the right bits in it, but the history looked strange because I
fixed the typo in the Yinghai branch, but had a second branch that
depended on the original unfixed branch.

I rebuilt my "next" branch again and I think it's more
straightforward.  And I learned a tiny bit more about git, so thanks
for pointing this out.

Bjorn

^ permalink raw reply	[flat|nested] 59+ messages in thread

* linux-next: build failure after merge of the final tree (acpi tree related)
  2011-06-15 12:05         ` Geert Uytterhoeven
@ 2013-02-11  7:34 ` Stephen Rothwell
  -1 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2013-02-11  7:34 UTC (permalink / raw)
  To: Len Brown; +Cc: linux-next, linux-kernel, David S. Miller, sparclinux

[-- Attachment #1: Type: text/plain, Size: 1131 bytes --]

Hi all,

After merging the final tree, today's linux-next build (sparc64 defconfig)
failed like this:

arch/sparc/include/asm/processor.h: Assembler messages:
arch/sparc/include/asm/processor.h:10: Error: Unknown opcode: `extern'

Caused by commit 3a242f58a5f4 ("sparc idle: rename pm_idle to
sparc_idle") from the acpi tree.

I have applied this patch for today:

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Mon, 11 Feb 2013 18:30:19 +1100
Subject: [PATCH] sparc idle: protect variable declarations against the assembler

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 arch/sparc/include/asm/processor.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
index 34baa35..622cfa5 100644
--- a/arch/sparc/include/asm/processor.h
+++ b/arch/sparc/include/asm/processor.h
@@ -7,6 +7,8 @@
 #endif
 
 #define nop() 		__asm__ __volatile__ ("nop")
+#ifndef __ASSEMBLY__
 extern void (*sparc_idle)(void);
+#endif
 
 #endif
-- 
1.8.1

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply related	[flat|nested] 59+ messages in thread

* linux-next: build failure after merge of the final tree (acpi tree related)
@ 2013-02-11  7:34 ` Stephen Rothwell
  0 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2013-02-11  7:34 UTC (permalink / raw)
  To: Len Brown; +Cc: linux-next, linux-kernel, David S. Miller, sparclinux

[-- Attachment #1: Type: text/plain, Size: 1131 bytes --]

Hi all,

After merging the final tree, today's linux-next build (sparc64 defconfig)
failed like this:

arch/sparc/include/asm/processor.h: Assembler messages:
arch/sparc/include/asm/processor.h:10: Error: Unknown opcode: `extern'

Caused by commit 3a242f58a5f4 ("sparc idle: rename pm_idle to
sparc_idle") from the acpi tree.

I have applied this patch for today:

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Mon, 11 Feb 2013 18:30:19 +1100
Subject: [PATCH] sparc idle: protect variable declarations against the assembler

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 arch/sparc/include/asm/processor.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
index 34baa35..622cfa5 100644
--- a/arch/sparc/include/asm/processor.h
+++ b/arch/sparc/include/asm/processor.h
@@ -7,6 +7,8 @@
 #endif
 
 #define nop() 		__asm__ __volatile__ ("nop")
+#ifndef __ASSEMBLY__
 extern void (*sparc_idle)(void);
+#endif
 
 #endif
-- 
1.8.1

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply related	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (acpi tree related)
  2013-02-11  7:34 ` Stephen Rothwell
@ 2013-02-11 18:22   ` Bjorn Helgaas
  -1 siblings, 0 replies; 59+ messages in thread
From: Bjorn Helgaas @ 2013-02-11 18:22 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Len Brown, linux-next, linux-kernel, David S. Miller, sparclinux,
	Rafael J. Wysocki

[+cc Rafael, since you mentioned the ACPI tree]

On Mon, Feb 11, 2013 at 12:34 AM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi all,
>
> After merging the final tree, today's linux-next build (sparc64 defconfig)
> failed like this:
>
> arch/sparc/include/asm/processor.h: Assembler messages:
> arch/sparc/include/asm/processor.h:10: Error: Unknown opcode: `extern'
>
> Caused by commit 3a242f58a5f4 ("sparc idle: rename pm_idle to
> sparc_idle") from the acpi tree.
>
> I have applied this patch for today:
>
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Mon, 11 Feb 2013 18:30:19 +1100
> Subject: [PATCH] sparc idle: protect variable declarations against the assembler
>
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/include/asm/processor.h | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
> index 34baa35..622cfa5 100644
> --- a/arch/sparc/include/asm/processor.h
> +++ b/arch/sparc/include/asm/processor.h
> @@ -7,6 +7,8 @@
>  #endif
>
>  #define nop()          __asm__ __volatile__ ("nop")
> +#ifndef __ASSEMBLY__
>  extern void (*sparc_idle)(void);
> +#endif
>
>  #endif
> --
> 1.8.1
>
> --
> Cheers,
> Stephen Rothwell                    sfr@canb.auug.org.au

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (acpi tree related)
@ 2013-02-11 18:22   ` Bjorn Helgaas
  0 siblings, 0 replies; 59+ messages in thread
From: Bjorn Helgaas @ 2013-02-11 18:22 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Len Brown, linux-next, linux-kernel, David S. Miller, sparclinux,
	Rafael J. Wysocki

[+cc Rafael, since you mentioned the ACPI tree]

On Mon, Feb 11, 2013 at 12:34 AM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi all,
>
> After merging the final tree, today's linux-next build (sparc64 defconfig)
> failed like this:
>
> arch/sparc/include/asm/processor.h: Assembler messages:
> arch/sparc/include/asm/processor.h:10: Error: Unknown opcode: `extern'
>
> Caused by commit 3a242f58a5f4 ("sparc idle: rename pm_idle to
> sparc_idle") from the acpi tree.
>
> I have applied this patch for today:
>
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Mon, 11 Feb 2013 18:30:19 +1100
> Subject: [PATCH] sparc idle: protect variable declarations against the assembler
>
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/include/asm/processor.h | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
> index 34baa35..622cfa5 100644
> --- a/arch/sparc/include/asm/processor.h
> +++ b/arch/sparc/include/asm/processor.h
> @@ -7,6 +7,8 @@
>  #endif
>
>  #define nop()          __asm__ __volatile__ ("nop")
> +#ifndef __ASSEMBLY__
>  extern void (*sparc_idle)(void);
> +#endif
>
>  #endif
> --
> 1.8.1
>
> --
> Cheers,
> Stephen Rothwell                    sfr@canb.auug.org.au

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (acpi tree related)
  2013-02-11  7:34 ` Stephen Rothwell
@ 2013-02-11 23:23   ` Len Brown
  -1 siblings, 0 replies; 59+ messages in thread
From: Len Brown @ 2013-02-11 23:23 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Len Brown, linux-next, linux-kernel, David S. Miller, sparclinux

On 02/11/2013 02:34 AM, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the final tree, today's linux-next build (sparc64 defconfig)
> failed like this:
> 
> arch/sparc/include/asm/processor.h: Assembler messages:
> arch/sparc/include/asm/processor.h:10: Error: Unknown opcode: `extern'
> 
> Caused by commit 3a242f58a5f4 ("sparc idle: rename pm_idle to
> sparc_idle") from the acpi tree.
> 
> I have applied this patch for today:
> 
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Mon, 11 Feb 2013 18:30:19 +1100
> Subject: [PATCH] sparc idle: protect variable declarations against the assembler
> 
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/include/asm/processor.h | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
> index 34baa35..622cfa5 100644
> --- a/arch/sparc/include/asm/processor.h
> +++ b/arch/sparc/include/asm/processor.h
> @@ -7,6 +7,8 @@
>  #endif
>  
>  #define nop() 		__asm__ __volatile__ ("nop")
> +#ifndef __ASSEMBLY__
>  extern void (*sparc_idle)(void);
> +#endif
>  
>  #endif
> 

Thank you Stephen!

The last time I compiled a sparc kernel was in 1993:-)

I've added your fix and Dave's Ack to this patch,
and updated it in my next branch.

Len Brown, Intel Open Source Technology Center



^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (acpi tree related)
@ 2013-02-11 23:23   ` Len Brown
  0 siblings, 0 replies; 59+ messages in thread
From: Len Brown @ 2013-02-11 23:23 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Len Brown, linux-next, linux-kernel, David S. Miller, sparclinux

On 02/11/2013 02:34 AM, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the final tree, today's linux-next build (sparc64 defconfig)
> failed like this:
> 
> arch/sparc/include/asm/processor.h: Assembler messages:
> arch/sparc/include/asm/processor.h:10: Error: Unknown opcode: `extern'
> 
> Caused by commit 3a242f58a5f4 ("sparc idle: rename pm_idle to
> sparc_idle") from the acpi tree.
> 
> I have applied this patch for today:
> 
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Mon, 11 Feb 2013 18:30:19 +1100
> Subject: [PATCH] sparc idle: protect variable declarations against the assembler
> 
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/include/asm/processor.h | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
> index 34baa35..622cfa5 100644
> --- a/arch/sparc/include/asm/processor.h
> +++ b/arch/sparc/include/asm/processor.h
> @@ -7,6 +7,8 @@
>  #endif
>  
>  #define nop() 		__asm__ __volatile__ ("nop")
> +#ifndef __ASSEMBLY__
>  extern void (*sparc_idle)(void);
> +#endif
>  
>  #endif
> 

Thank you Stephen!

The last time I compiled a sparc kernel was in 1993:-)

I've added your fix and Dave's Ack to this patch,
and updated it in my next branch.

Len Brown, Intel Open Source Technology Center



^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (acpi tree related)
  2013-02-11 23:23   ` Len Brown
@ 2013-02-12 17:35     ` Sam Ravnborg
  -1 siblings, 0 replies; 59+ messages in thread
From: Sam Ravnborg @ 2013-02-12 17:35 UTC (permalink / raw)
  To: Len Brown
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux

> > Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> > ---
> >  arch/sparc/include/asm/processor.h | 2 ++
> >  1 file changed, 2 insertions(+)
> > 
> > diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
> > index 34baa35..622cfa5 100644
> > --- a/arch/sparc/include/asm/processor.h
> > +++ b/arch/sparc/include/asm/processor.h
> > @@ -7,6 +7,8 @@
> >  #endif
> >  
> >  #define nop() 		__asm__ __volatile__ ("nop")
> > +#ifndef __ASSEMBLY__
> >  extern void (*sparc_idle)(void);
> > +#endif
> >  
> >  #endif
> > 
> 
> Thank you Stephen!
> 
> The last time I compiled a sparc kernel was in 1993:-)
> 
> I've added your fix and Dave's Ack to this patch,
> and updated it in my next branch.

Hi Len.

Can you please move the definition of sparc_idle to processor_32.h
It is sparc32 specific - and then we do not need the __ASSEMBLY__ guards
as the sparc32 variant are not used from assembler.

Do you btw. have any hints how I can convert to the cpu_idle thing you hinted?

	Sam

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the final tree (acpi tree related)
@ 2013-02-12 17:35     ` Sam Ravnborg
  0 siblings, 0 replies; 59+ messages in thread
From: Sam Ravnborg @ 2013-02-12 17:35 UTC (permalink / raw)
  To: Len Brown
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux

> > Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> > ---
> >  arch/sparc/include/asm/processor.h | 2 ++
> >  1 file changed, 2 insertions(+)
> > 
> > diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
> > index 34baa35..622cfa5 100644
> > --- a/arch/sparc/include/asm/processor.h
> > +++ b/arch/sparc/include/asm/processor.h
> > @@ -7,6 +7,8 @@
> >  #endif
> >  
> >  #define nop() 		__asm__ __volatile__ ("nop")
> > +#ifndef __ASSEMBLY__
> >  extern void (*sparc_idle)(void);
> > +#endif
> >  
> >  #endif
> > 
> 
> Thank you Stephen!
> 
> The last time I compiled a sparc kernel was in 1993:-)
> 
> I've added your fix and Dave's Ack to this patch,
> and updated it in my next branch.

Hi Len.

Can you please move the definition of sparc_idle to processor_32.h
It is sparc32 specific - and then we do not need the __ASSEMBLY__ guards
as the sparc32 variant are not used from assembler.

Do you btw. have any hints how I can convert to the cpu_idle thing you hinted?

	Sam

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tree related))
  2013-02-12 17:35     ` Sam Ravnborg
@ 2013-02-12 18:01       ` Len Brown
  -1 siblings, 0 replies; 59+ messages in thread
From: Len Brown @ 2013-02-12 18:01 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux, Linux PM list

On 02/12/2013 12:35 PM, Sam Ravnborg wrote:
>>> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
>>> ---
>>>  arch/sparc/include/asm/processor.h | 2 ++
>>>  1 file changed, 2 insertions(+)
>>>
>>> diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
>>> index 34baa35..622cfa5 100644
>>> --- a/arch/sparc/include/asm/processor.h
>>> +++ b/arch/sparc/include/asm/processor.h
>>> @@ -7,6 +7,8 @@
>>>  #endif
>>>  
>>>  #define nop() 		__asm__ __volatile__ ("nop")
>>> +#ifndef __ASSEMBLY__
>>>  extern void (*sparc_idle)(void);
>>> +#endif
>>>  
>>>  #endif
>>>
>>
>> Thank you Stephen!
>>
>> The last time I compiled a sparc kernel was in 1993:-)
>>
>> I've added your fix and Dave's Ack to this patch,
>> and updated it in my next branch.
> 
> Hi Len.
> 
> Can you please move the definition of sparc_idle to processor_32.h
> It is sparc32 specific - and then we do not need the __ASSEMBLY__ guards
> as the sparc32 variant are not used from assembler.

sure, let me know if attached works.

> Do you btw. have any hints how I can convert to the cpu_idle thing you hinted?

If you have exactly 1 idle state, then cpuidle isn't that interesting,
except, perhaps the standard residency counters.  If you have multiple
states to choose from, cpuidle becomes more valuable.

There are lots of cpuidle users now, including x86's intel_idle,
processor_idle, and the entire ARM tree.

In my tree right now is a patch to convert APM to cpuidle --
though as nobody has tested it yet I can't guarantee it is correct.

patches/issues related to idle should to to linux-pm@vger.kernel.org (on cc)

thanks,
-Len



^ permalink raw reply	[flat|nested] 59+ messages in thread

* Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tree r
@ 2013-02-12 18:01       ` Len Brown
  0 siblings, 0 replies; 59+ messages in thread
From: Len Brown @ 2013-02-12 18:01 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux, Linux PM list

On 02/12/2013 12:35 PM, Sam Ravnborg wrote:
>>> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
>>> ---
>>>  arch/sparc/include/asm/processor.h | 2 ++
>>>  1 file changed, 2 insertions(+)
>>>
>>> diff --git a/arch/sparc/include/asm/processor.h b/arch/sparc/include/asm/processor.h
>>> index 34baa35..622cfa5 100644
>>> --- a/arch/sparc/include/asm/processor.h
>>> +++ b/arch/sparc/include/asm/processor.h
>>> @@ -7,6 +7,8 @@
>>>  #endif
>>>  
>>>  #define nop() 		__asm__ __volatile__ ("nop")
>>> +#ifndef __ASSEMBLY__
>>>  extern void (*sparc_idle)(void);
>>> +#endif
>>>  
>>>  #endif
>>>
>>
>> Thank you Stephen!
>>
>> The last time I compiled a sparc kernel was in 1993:-)
>>
>> I've added your fix and Dave's Ack to this patch,
>> and updated it in my next branch.
> 
> Hi Len.
> 
> Can you please move the definition of sparc_idle to processor_32.h
> It is sparc32 specific - and then we do not need the __ASSEMBLY__ guards
> as the sparc32 variant are not used from assembler.

sure, let me know if attached works.

> Do you btw. have any hints how I can convert to the cpu_idle thing you hinted?

If you have exactly 1 idle state, then cpuidle isn't that interesting,
except, perhaps the standard residency counters.  If you have multiple
states to choose from, cpuidle becomes more valuable.

There are lots of cpuidle users now, including x86's intel_idle,
processor_idle, and the entire ARM tree.

In my tree right now is a patch to convert APM to cpuidle --
though as nobody has tested it yet I can't guarantee it is correct.

patches/issues related to idle should to to linux-pm@vger.kernel.org (on cc)

thanks,
-Len



^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: Should SPARC use cpuidle?
  2013-02-12 18:01       ` Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tree r Len Brown
@ 2013-02-12 18:03         ` Len Brown
  -1 siblings, 0 replies; 59+ messages in thread
From: Len Brown @ 2013-02-12 18:03 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux, Linux PM list

[-- Attachment #1: Type: text/plain, Size: 337 bytes --]


>> Can you please move the definition of sparc_idle to processor_32.h
>> It is sparc32 specific - and then we do not need the __ASSEMBLY__ guards
>> as the sparc32 variant are not used from assembler.
> 
> sure, let me know if attached works.

ugh, not accustomed to sending patches via thunderbird.
hopefully this attachment works...


[-- Attachment #2: 0001-sparc-idle-rename-pm_idle-to-sparc_idle.patch --]
[-- Type: text/x-patch, Size: 4055 bytes --]

>From 358ca5d7e02c4559ad3fbf8135421e4a3753e979 Mon Sep 17 00:00:00 2001
From: Len Brown <len.brown@intel.com>
Date: Sat, 9 Feb 2013 23:27:26 -0500
Subject: [PATCH] sparc idle: rename pm_idle to sparc_idle
Reply-To: Len Brown <lenb@kernel.org>
Organization: Intel Open Source Technology Center

(pm_idle)() is being removed from linux/pm.h
because Linux does not have such a cross-architecture concept.

sparc uses an idle function pointer in its architecture
specific code.  So we re-name sparc use of pm_idle to sparc_idle.

Maybe some day, SPARC will cut over to cpuidle...

Signed-off-by: Len Brown <len.brown@intel.com>
Acked-by: David S. Miller <davem@davemloft.net>
---
 arch/sparc/include/asm/processor_32.h | 1 +
 arch/sparc/kernel/apc.c               | 3 ++-
 arch/sparc/kernel/leon_pmc.c          | 5 +++--
 arch/sparc/kernel/pmc.c               | 3 ++-
 arch/sparc/kernel/process_32.c        | 7 +++----
 5 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/arch/sparc/include/asm/processor_32.h b/arch/sparc/include/asm/processor_32.h
index c1e0191..2c7baa4 100644
--- a/arch/sparc/include/asm/processor_32.h
+++ b/arch/sparc/include/asm/processor_32.h
@@ -118,6 +118,7 @@ extern unsigned long get_wchan(struct task_struct *);
 extern struct task_struct *last_task_used_math;
 
 #define cpu_relax()	barrier()
+extern void (*sparc_idle)(void);
 
 #endif
 
diff --git a/arch/sparc/kernel/apc.c b/arch/sparc/kernel/apc.c
index 348fa1a..eefda32 100644
--- a/arch/sparc/kernel/apc.c
+++ b/arch/sparc/kernel/apc.c
@@ -20,6 +20,7 @@
 #include <asm/uaccess.h>
 #include <asm/auxio.h>
 #include <asm/apc.h>
+#include <asm/processor.h>
 
 /* Debugging
  * 
@@ -158,7 +159,7 @@ static int apc_probe(struct platform_device *op)
 
 	/* Assign power management IDLE handler */
 	if (!apc_no_idle)
-		pm_idle = apc_swift_idle;	
+		sparc_idle = apc_swift_idle;
 
 	printk(KERN_INFO "%s: power management initialized%s\n", 
 	       APC_DEVNAME, apc_no_idle ? " (CPU idle disabled)" : "");
diff --git a/arch/sparc/kernel/leon_pmc.c b/arch/sparc/kernel/leon_pmc.c
index 4e17432..708bca4 100644
--- a/arch/sparc/kernel/leon_pmc.c
+++ b/arch/sparc/kernel/leon_pmc.c
@@ -9,6 +9,7 @@
 #include <asm/leon_amba.h>
 #include <asm/cpu_type.h>
 #include <asm/leon.h>
+#include <asm/processor.h>
 
 /* List of Systems that need fixup instructions around power-down instruction */
 unsigned int pmc_leon_fixup_ids[] = {
@@ -69,9 +70,9 @@ static int __init leon_pmc_install(void)
 	if (sparc_cpu_model == sparc_leon) {
 		/* Assign power management IDLE handler */
 		if (pmc_leon_need_fixup())
-			pm_idle = pmc_leon_idle_fixup;
+			sparc_idle = pmc_leon_idle_fixup;
 		else
-			pm_idle = pmc_leon_idle;
+			sparc_idle = pmc_leon_idle;
 
 		printk(KERN_INFO "leon: power management initialized\n");
 	}
diff --git a/arch/sparc/kernel/pmc.c b/arch/sparc/kernel/pmc.c
index dcbb62f..8b7297f 100644
--- a/arch/sparc/kernel/pmc.c
+++ b/arch/sparc/kernel/pmc.c
@@ -17,6 +17,7 @@
 #include <asm/oplib.h>
 #include <asm/uaccess.h>
 #include <asm/auxio.h>
+#include <asm/processor.h>
 
 /* Debug
  *
@@ -63,7 +64,7 @@ static int pmc_probe(struct platform_device *op)
 
 #ifndef PMC_NO_IDLE
 	/* Assign power management IDLE handler */
-	pm_idle = pmc_swift_idle;
+	sparc_idle = pmc_swift_idle;
 #endif
 
 	printk(KERN_INFO "%s: power management initialized\n", PMC_DEVNAME);
diff --git a/arch/sparc/kernel/process_32.c b/arch/sparc/kernel/process_32.c
index be8e862..62eede1 100644
--- a/arch/sparc/kernel/process_32.c
+++ b/arch/sparc/kernel/process_32.c
@@ -43,8 +43,7 @@
  * Power management idle function 
  * Set in pm platform drivers (apc.c and pmc.c)
  */
-void (*pm_idle)(void);
-EXPORT_SYMBOL(pm_idle);
+void (*sparc_idle)(void);
 
 /* 
  * Power-off handler instantiation for pm.h compliance
@@ -75,8 +74,8 @@ void cpu_idle(void)
 	/* endless idle loop with no priority at all */
 	for (;;) {
 		while (!need_resched()) {
-			if (pm_idle)
-				(*pm_idle)();
+			if (sparc_idle)
+				(*sparc_idle)();
 			else
 				cpu_relax();
 		}
-- 
1.8.1.3.535.ga923c31


^ permalink raw reply related	[flat|nested] 59+ messages in thread

* Re: Should SPARC use cpuidle?
@ 2013-02-12 18:03         ` Len Brown
  0 siblings, 0 replies; 59+ messages in thread
From: Len Brown @ 2013-02-12 18:03 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux, Linux PM list

[-- Attachment #1: Type: text/plain, Size: 337 bytes --]


>> Can you please move the definition of sparc_idle to processor_32.h
>> It is sparc32 specific - and then we do not need the __ASSEMBLY__ guards
>> as the sparc32 variant are not used from assembler.
> 
> sure, let me know if attached works.

ugh, not accustomed to sending patches via thunderbird.
hopefully this attachment works...


[-- Attachment #2: 0001-sparc-idle-rename-pm_idle-to-sparc_idle.patch --]
[-- Type: text/x-patch, Size: 4054 bytes --]

From 358ca5d7e02c4559ad3fbf8135421e4a3753e979 Mon Sep 17 00:00:00 2001
From: Len Brown <len.brown@intel.com>
Date: Sat, 9 Feb 2013 23:27:26 -0500
Subject: [PATCH] sparc idle: rename pm_idle to sparc_idle
Reply-To: Len Brown <lenb@kernel.org>
Organization: Intel Open Source Technology Center

(pm_idle)() is being removed from linux/pm.h
because Linux does not have such a cross-architecture concept.

sparc uses an idle function pointer in its architecture
specific code.  So we re-name sparc use of pm_idle to sparc_idle.

Maybe some day, SPARC will cut over to cpuidle...

Signed-off-by: Len Brown <len.brown@intel.com>
Acked-by: David S. Miller <davem@davemloft.net>
---
 arch/sparc/include/asm/processor_32.h | 1 +
 arch/sparc/kernel/apc.c               | 3 ++-
 arch/sparc/kernel/leon_pmc.c          | 5 +++--
 arch/sparc/kernel/pmc.c               | 3 ++-
 arch/sparc/kernel/process_32.c        | 7 +++----
 5 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/arch/sparc/include/asm/processor_32.h b/arch/sparc/include/asm/processor_32.h
index c1e0191..2c7baa4 100644
--- a/arch/sparc/include/asm/processor_32.h
+++ b/arch/sparc/include/asm/processor_32.h
@@ -118,6 +118,7 @@ extern unsigned long get_wchan(struct task_struct *);
 extern struct task_struct *last_task_used_math;
 
 #define cpu_relax()	barrier()
+extern void (*sparc_idle)(void);
 
 #endif
 
diff --git a/arch/sparc/kernel/apc.c b/arch/sparc/kernel/apc.c
index 348fa1a..eefda32 100644
--- a/arch/sparc/kernel/apc.c
+++ b/arch/sparc/kernel/apc.c
@@ -20,6 +20,7 @@
 #include <asm/uaccess.h>
 #include <asm/auxio.h>
 #include <asm/apc.h>
+#include <asm/processor.h>
 
 /* Debugging
  * 
@@ -158,7 +159,7 @@ static int apc_probe(struct platform_device *op)
 
 	/* Assign power management IDLE handler */
 	if (!apc_no_idle)
-		pm_idle = apc_swift_idle;	
+		sparc_idle = apc_swift_idle;
 
 	printk(KERN_INFO "%s: power management initialized%s\n", 
 	       APC_DEVNAME, apc_no_idle ? " (CPU idle disabled)" : "");
diff --git a/arch/sparc/kernel/leon_pmc.c b/arch/sparc/kernel/leon_pmc.c
index 4e17432..708bca4 100644
--- a/arch/sparc/kernel/leon_pmc.c
+++ b/arch/sparc/kernel/leon_pmc.c
@@ -9,6 +9,7 @@
 #include <asm/leon_amba.h>
 #include <asm/cpu_type.h>
 #include <asm/leon.h>
+#include <asm/processor.h>
 
 /* List of Systems that need fixup instructions around power-down instruction */
 unsigned int pmc_leon_fixup_ids[] = {
@@ -69,9 +70,9 @@ static int __init leon_pmc_install(void)
 	if (sparc_cpu_model == sparc_leon) {
 		/* Assign power management IDLE handler */
 		if (pmc_leon_need_fixup())
-			pm_idle = pmc_leon_idle_fixup;
+			sparc_idle = pmc_leon_idle_fixup;
 		else
-			pm_idle = pmc_leon_idle;
+			sparc_idle = pmc_leon_idle;
 
 		printk(KERN_INFO "leon: power management initialized\n");
 	}
diff --git a/arch/sparc/kernel/pmc.c b/arch/sparc/kernel/pmc.c
index dcbb62f..8b7297f 100644
--- a/arch/sparc/kernel/pmc.c
+++ b/arch/sparc/kernel/pmc.c
@@ -17,6 +17,7 @@
 #include <asm/oplib.h>
 #include <asm/uaccess.h>
 #include <asm/auxio.h>
+#include <asm/processor.h>
 
 /* Debug
  *
@@ -63,7 +64,7 @@ static int pmc_probe(struct platform_device *op)
 
 #ifndef PMC_NO_IDLE
 	/* Assign power management IDLE handler */
-	pm_idle = pmc_swift_idle;
+	sparc_idle = pmc_swift_idle;
 #endif
 
 	printk(KERN_INFO "%s: power management initialized\n", PMC_DEVNAME);
diff --git a/arch/sparc/kernel/process_32.c b/arch/sparc/kernel/process_32.c
index be8e862..62eede1 100644
--- a/arch/sparc/kernel/process_32.c
+++ b/arch/sparc/kernel/process_32.c
@@ -43,8 +43,7 @@
  * Power management idle function 
  * Set in pm platform drivers (apc.c and pmc.c)
  */
-void (*pm_idle)(void);
-EXPORT_SYMBOL(pm_idle);
+void (*sparc_idle)(void);
 
 /* 
  * Power-off handler instantiation for pm.h compliance
@@ -75,8 +74,8 @@ void cpu_idle(void)
 	/* endless idle loop with no priority at all */
 	for (;;) {
 		while (!need_resched()) {
-			if (pm_idle)
-				(*pm_idle)();
+			if (sparc_idle)
+				(*sparc_idle)();
 			else
 				cpu_relax();
 		}
-- 
1.8.1.3.535.ga923c31


^ permalink raw reply related	[flat|nested] 59+ messages in thread

* Re: Should SPARC use cpuidle?
  2013-02-12 18:03         ` Len Brown
@ 2013-02-12 19:36           ` Sam Ravnborg
  -1 siblings, 0 replies; 59+ messages in thread
From: Sam Ravnborg @ 2013-02-12 19:36 UTC (permalink / raw)
  To: Len Brown
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux, Linux PM list

On Tue, Feb 12, 2013 at 01:03:04PM -0500, Len Brown wrote:
> 
> >> Can you please move the definition of sparc_idle to processor_32.h
> >> It is sparc32 specific - and then we do not need the __ASSEMBLY__ guards
> >> as the sparc32 variant are not used from assembler.
> > 
> > sure, let me know if attached works.
> 
> ugh, not accustomed to sending patches via thunderbird.
> hopefully this attachment works...
> 

> >From 358ca5d7e02c4559ad3fbf8135421e4a3753e979 Mon Sep 17 00:00:00 2001
> From: Len Brown <len.brown@intel.com>
> Date: Sat, 9 Feb 2013 23:27:26 -0500
> Subject: [PATCH] sparc idle: rename pm_idle to sparc_idle
> Reply-To: Len Brown <lenb@kernel.org>
> Organization: Intel Open Source Technology Center
> 
> (pm_idle)() is being removed from linux/pm.h
> because Linux does not have such a cross-architecture concept.
> 
> sparc uses an idle function pointer in its architecture
> specific code.  So we re-name sparc use of pm_idle to sparc_idle.
> 
> Maybe some day, SPARC will cut over to cpuidle...
> 
> Signed-off-by: Len Brown <len.brown@intel.com>
> Acked-by: David S. Miller <davem@davemloft.net>
Build tested - OK.
Acked-by: Sam Ravnborg <sam@ravnborg.org>

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: Should SPARC use cpuidle?
@ 2013-02-12 19:36           ` Sam Ravnborg
  0 siblings, 0 replies; 59+ messages in thread
From: Sam Ravnborg @ 2013-02-12 19:36 UTC (permalink / raw)
  To: Len Brown
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux, Linux PM list

On Tue, Feb 12, 2013 at 01:03:04PM -0500, Len Brown wrote:
> 
> >> Can you please move the definition of sparc_idle to processor_32.h
> >> It is sparc32 specific - and then we do not need the __ASSEMBLY__ guards
> >> as the sparc32 variant are not used from assembler.
> > 
> > sure, let me know if attached works.
> 
> ugh, not accustomed to sending patches via thunderbird.
> hopefully this attachment works...
> 

> >From 358ca5d7e02c4559ad3fbf8135421e4a3753e979 Mon Sep 17 00:00:00 2001
> From: Len Brown <len.brown@intel.com>
> Date: Sat, 9 Feb 2013 23:27:26 -0500
> Subject: [PATCH] sparc idle: rename pm_idle to sparc_idle
> Reply-To: Len Brown <lenb@kernel.org>
> Organization: Intel Open Source Technology Center
> 
> (pm_idle)() is being removed from linux/pm.h
> because Linux does not have such a cross-architecture concept.
> 
> sparc uses an idle function pointer in its architecture
> specific code.  So we re-name sparc use of pm_idle to sparc_idle.
> 
> Maybe some day, SPARC will cut over to cpuidle...
> 
> Signed-off-by: Len Brown <len.brown@intel.com>
> Acked-by: David S. Miller <davem@davemloft.net>
Build tested - OK.
Acked-by: Sam Ravnborg <sam@ravnborg.org>

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tree related))
  2013-02-12 18:01       ` Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tree r Len Brown
@ 2013-02-12 19:42         ` Sam Ravnborg
  -1 siblings, 0 replies; 59+ messages in thread
From: Sam Ravnborg @ 2013-02-12 19:42 UTC (permalink / raw)
  To: Len Brown
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux, Linux PM list

> 
> > Do you btw. have any hints how I can convert to the cpu_idle thing you hinted?
> 
> If you have exactly 1 idle state, then cpuidle isn't that interesting,
> except, perhaps the standard residency counters.  If you have multiple
> states to choose from, cpuidle becomes more valuable.
> 
> There are lots of cpuidle users now, including x86's intel_idle,
> processor_idle, and the entire ARM tree.

I think LEON has only a single power-down state.
The APC stuff I know nothing about :-(

So for now I think I will let it be as it is then.

	Sam

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tr
@ 2013-02-12 19:42         ` Sam Ravnborg
  0 siblings, 0 replies; 59+ messages in thread
From: Sam Ravnborg @ 2013-02-12 19:42 UTC (permalink / raw)
  To: Len Brown
  Cc: Stephen Rothwell, Len Brown, linux-next, linux-kernel,
	David S. Miller, sparclinux, Linux PM list

> 
> > Do you btw. have any hints how I can convert to the cpu_idle thing you hinted?
> 
> If you have exactly 1 idle state, then cpuidle isn't that interesting,
> except, perhaps the standard residency counters.  If you have multiple
> states to choose from, cpuidle becomes more valuable.
> 
> There are lots of cpuidle users now, including x86's intel_idle,
> processor_idle, and the entire ARM tree.

I think LEON has only a single power-down state.
The APC stuff I know nothing about :-(

So for now I think I will let it be as it is then.

	Sam

^ permalink raw reply	[flat|nested] 59+ messages in thread

* linux-next: build failure after merge of the audit tree
  2011-06-15 12:05         ` Geert Uytterhoeven
@ 2014-04-22  6:22 ` Stephen Rothwell
  -1 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2014-04-22  6:22 UTC (permalink / raw)
  To: Eric Paris; +Cc: linux-next, linux-kernel, Richard Briggs, sparclinux

[-- Attachment #1: Type: text/plain, Size: 1602 bytes --]

Hi Eric,

After merging the audit tree, today's linux-next build (sparc defconfig)
failed like this:

In file included from include/linux/audit.h:29:0,
                 from mm/mmap.c:33:
arch/sparc/include/asm/syscall.h: In function 'syscall_get_arch':
arch/sparc/include/asm/syscall.h:131:9: error: 'TIF_32BIT' undeclared (first use in this function)
arch/sparc/include/asm/syscall.h:131:9: note: each undeclared identifier is reported only once for each function it appears in

And many more ...

Caused by commit 374c0c054122 ("ARCH: AUDIT: implement syscall_get_arch
for all arches").

I applied this patch for today:

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Tue, 22 Apr 2014 16:18:53 +1000
Subject: [PATCH] fix ARCH: AUDIT: implement syscall_get_arch for all arches

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 arch/sparc/include/asm/syscall.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
index fed3d511b108..a5a8153766b3 100644
--- a/arch/sparc/include/asm/syscall.h
+++ b/arch/sparc/include/asm/syscall.h
@@ -128,8 +128,12 @@ static inline void syscall_set_arguments(struct task_struct *task,
 
 static inline int syscall_get_arch(void)
 {
+#if defined(__sparc__) && defined(__arch64__)
 	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
 					   : AUDIT_ARCH_SPARC64;
+#else
+	return AUDIT_ARCH_SPARC;
+#endif
 }
 
 #endif /* __ASM_SPARC_SYSCALL_H */
-- 
1.9.2

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply related	[flat|nested] 59+ messages in thread

* linux-next: build failure after merge of the audit tree
@ 2014-04-22  6:22 ` Stephen Rothwell
  0 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2014-04-22  6:22 UTC (permalink / raw)
  To: Eric Paris; +Cc: linux-next, linux-kernel, Richard Briggs, sparclinux

[-- Attachment #1: Type: text/plain, Size: 1602 bytes --]

Hi Eric,

After merging the audit tree, today's linux-next build (sparc defconfig)
failed like this:

In file included from include/linux/audit.h:29:0,
                 from mm/mmap.c:33:
arch/sparc/include/asm/syscall.h: In function 'syscall_get_arch':
arch/sparc/include/asm/syscall.h:131:9: error: 'TIF_32BIT' undeclared (first use in this function)
arch/sparc/include/asm/syscall.h:131:9: note: each undeclared identifier is reported only once for each function it appears in

And many more ...

Caused by commit 374c0c054122 ("ARCH: AUDIT: implement syscall_get_arch
for all arches").

I applied this patch for today:

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Tue, 22 Apr 2014 16:18:53 +1000
Subject: [PATCH] fix ARCH: AUDIT: implement syscall_get_arch for all arches

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 arch/sparc/include/asm/syscall.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
index fed3d511b108..a5a8153766b3 100644
--- a/arch/sparc/include/asm/syscall.h
+++ b/arch/sparc/include/asm/syscall.h
@@ -128,8 +128,12 @@ static inline void syscall_set_arguments(struct task_struct *task,
 
 static inline int syscall_get_arch(void)
 {
+#if defined(__sparc__) && defined(__arch64__)
 	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
 					   : AUDIT_ARCH_SPARC64;
+#else
+	return AUDIT_ARCH_SPARC;
+#endif
 }
 
 #endif /* __ASM_SPARC_SYSCALL_H */
-- 
1.9.2

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply related	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the audit tree
  2014-04-22  6:22 ` Stephen Rothwell
@ 2014-04-22 15:56   ` Richard Guy Briggs
  -1 siblings, 0 replies; 59+ messages in thread
From: Richard Guy Briggs @ 2014-04-22 15:56 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: Eric Paris, linux-next, linux-kernel, sparclinux

On 14/04/22, Stephen Rothwell wrote:
> Hi Eric,
> 
> After merging the audit tree, today's linux-next build (sparc defconfig)
> failed like this:
> 
> In file included from include/linux/audit.h:29:0,
>                  from mm/mmap.c:33:
> arch/sparc/include/asm/syscall.h: In function 'syscall_get_arch':
> arch/sparc/include/asm/syscall.h:131:9: error: 'TIF_32BIT' undeclared (first use in this function)
> arch/sparc/include/asm/syscall.h:131:9: note: each undeclared identifier is reported only once for each function it appears in
> 
> And many more ...
> 
> Caused by commit 374c0c054122 ("ARCH: AUDIT: implement syscall_get_arch
> for all arches").
> 
> I applied this patch for today:
> 
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 22 Apr 2014 16:18:53 +1000
> Subject: [PATCH] fix ARCH: AUDIT: implement syscall_get_arch for all arches
> 
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>

Looks good to me.  Thanks.

Acked-by: Richard Guy Briggs <rgb@redhat.com>

> ---
>  arch/sparc/include/asm/syscall.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
> index fed3d511b108..a5a8153766b3 100644
> --- a/arch/sparc/include/asm/syscall.h
> +++ b/arch/sparc/include/asm/syscall.h
> @@ -128,8 +128,12 @@ static inline void syscall_set_arguments(struct task_struct *task,
>  
>  static inline int syscall_get_arch(void)
>  {
> +#if defined(__sparc__) && defined(__arch64__)
>  	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
>  					   : AUDIT_ARCH_SPARC64;
> +#else
> +	return AUDIT_ARCH_SPARC;
> +#endif
>  }
>  
>  #endif /* __ASM_SPARC_SYSCALL_H */
> -- 
> 1.9.2
> 
> -- 
> Cheers,
> Stephen Rothwell                    sfr@canb.auug.org.au



- RGB

--
Richard Guy Briggs <rbriggs@redhat.com>
Senior Software Engineer, Kernel Security, AMER ENG Base Operating Systems, Red Hat
Remote, Ottawa, Canada
Voice: +1.647.777.2635, Internal: (81) 32635, Alt: +1.613.693.0684x3545

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the audit tree
@ 2014-04-22 15:56   ` Richard Guy Briggs
  0 siblings, 0 replies; 59+ messages in thread
From: Richard Guy Briggs @ 2014-04-22 15:56 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: Eric Paris, linux-next, linux-kernel, sparclinux

On 14/04/22, Stephen Rothwell wrote:
> Hi Eric,
> 
> After merging the audit tree, today's linux-next build (sparc defconfig)
> failed like this:
> 
> In file included from include/linux/audit.h:29:0,
>                  from mm/mmap.c:33:
> arch/sparc/include/asm/syscall.h: In function 'syscall_get_arch':
> arch/sparc/include/asm/syscall.h:131:9: error: 'TIF_32BIT' undeclared (first use in this function)
> arch/sparc/include/asm/syscall.h:131:9: note: each undeclared identifier is reported only once for each function it appears in
> 
> And many more ...
> 
> Caused by commit 374c0c054122 ("ARCH: AUDIT: implement syscall_get_arch
> for all arches").
> 
> I applied this patch for today:
> 
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 22 Apr 2014 16:18:53 +1000
> Subject: [PATCH] fix ARCH: AUDIT: implement syscall_get_arch for all arches
> 
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>

Looks good to me.  Thanks.

Acked-by: Richard Guy Briggs <rgb@redhat.com>

> ---
>  arch/sparc/include/asm/syscall.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
> index fed3d511b108..a5a8153766b3 100644
> --- a/arch/sparc/include/asm/syscall.h
> +++ b/arch/sparc/include/asm/syscall.h
> @@ -128,8 +128,12 @@ static inline void syscall_set_arguments(struct task_struct *task,
>  
>  static inline int syscall_get_arch(void)
>  {
> +#if defined(__sparc__) && defined(__arch64__)
>  	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
>  					   : AUDIT_ARCH_SPARC64;
> +#else
> +	return AUDIT_ARCH_SPARC;
> +#endif
>  }
>  
>  #endif /* __ASM_SPARC_SYSCALL_H */
> -- 
> 1.9.2
> 
> -- 
> Cheers,
> Stephen Rothwell                    sfr@canb.auug.org.au



- RGB

--
Richard Guy Briggs <rbriggs@redhat.com>
Senior Software Engineer, Kernel Security, AMER ENG Base Operating Systems, Red Hat
Remote, Ottawa, Canada
Voice: +1.647.777.2635, Internal: (81) 32635, Alt: +1.613.693.0684x3545

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the audit tree
  2014-04-22  6:22 ` Stephen Rothwell
@ 2014-04-22 16:32   ` Eric Paris
  -1 siblings, 0 replies; 59+ messages in thread
From: Eric Paris @ 2014-04-22 16:32 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next, linux-kernel, Richard Briggs, sparclinux

On Tue, 2014-04-22 at 16:22 +1000, Stephen Rothwell wrote:
> Hi Eric,
> 
> After merging the audit tree, today's linux-next build (sparc defconfig)
> failed like this:
> 
> In file included from include/linux/audit.h:29:0,
>                  from mm/mmap.c:33:
> arch/sparc/include/asm/syscall.h: In function 'syscall_get_arch':
> arch/sparc/include/asm/syscall.h:131:9: error: 'TIF_32BIT' undeclared (first use in this function)
> arch/sparc/include/asm/syscall.h:131:9: note: each undeclared identifier is reported only once for each function it appears in
> 
> And many more ...
> 
> Caused by commit 374c0c054122 ("ARCH: AUDIT: implement syscall_get_arch
> for all arches").
> 
> I applied this patch for today:
> 
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 22 Apr 2014 16:18:53 +1000
> Subject: [PATCH] fix ARCH: AUDIT: implement syscall_get_arch for all arches
> 
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/include/asm/syscall.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
> index fed3d511b108..a5a8153766b3 100644
> --- a/arch/sparc/include/asm/syscall.h
> +++ b/arch/sparc/include/asm/syscall.h
> @@ -128,8 +128,12 @@ static inline void syscall_set_arguments(struct task_struct *task,
>  
>  static inline int syscall_get_arch(void)
>  {
> +#if defined(__sparc__) && defined(__arch64__)
>  	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
>  					   : AUDIT_ARCH_SPARC64;
> +#else
> +	return AUDIT_ARCH_SPARC;
> +#endif
>  }
>  
>  #endif /* __ASM_SPARC_SYSCALL_H */
> -- 

I swear I saw this and I fixed it.  Drat.  Do we want to do it this way?
Above in syscall_get_arguments() they use

#ifdef CONFIG_SPARC64
        if (test_tsk_thread_flag(task, TIF_32BIT))
                zero_extend = 1;
#endif

Is CONFIG_SPARC64 a better choice than:
   defined(__sparc__) && defined(__arch64__)

Maybe even better would be to copy what you suggested in powerpc:

---

diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
index fed3d51..49f71fd 100644
--- a/arch/sparc/include/asm/syscall.h
+++ b/arch/sparc/include/asm/syscall.h
@@ -128,8 +128,7 @@ static inline void syscall_set_arguments(struct task_struct *task,
 
 static inline int syscall_get_arch(void)
 {
-	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
-					   : AUDIT_ARCH_SPARC64;
+	return is_32bit_task() ? AUDIT_ARCH_SPARC : AUDIT_ARCH_SPARC64;
 }
 
 #endif /* __ASM_SPARC_SYSCALL_H */
diff --git a/arch/sparc/include/asm/thread_info_32.h b/arch/sparc/include/asm/thread_info_32.h
index 96efa7a..acd2be0 100644
--- a/arch/sparc/include/asm/thread_info_32.h
+++ b/arch/sparc/include/asm/thread_info_32.h
@@ -130,6 +130,8 @@ register struct thread_info *current_thread_info_reg asm("g6");
 #define _TIF_DO_NOTIFY_RESUME_MASK	(_TIF_NOTIFY_RESUME | \
 					 _TIF_SIGPENDING)
 
+#define is_32bit_task()	(0)
+
 #endif /* __KERNEL__ */
 
 #endif /* _ASM_THREAD_INFO_H */
diff --git a/arch/sparc/include/asm/thread_info_64.h b/arch/sparc/include/asm/thread_info_64.h
index a5f01ac..5a4f660 100644
--- a/arch/sparc/include/asm/thread_info_64.h
+++ b/arch/sparc/include/asm/thread_info_64.h
@@ -219,6 +219,8 @@ register struct thread_info *current_thread_info_reg asm("g6");
 				 _TIF_NEED_RESCHED)
 #define _TIF_DO_NOTIFY_RESUME_MASK	(_TIF_NOTIFY_RESUME | _TIF_SIGPENDING)
 
+#define is_32bit_task()	(test_thread_flag(TIF_32BIT))
+
 /*
  * Thread-synchronous status.
  *



^ permalink raw reply related	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the audit tree
@ 2014-04-22 16:32   ` Eric Paris
  0 siblings, 0 replies; 59+ messages in thread
From: Eric Paris @ 2014-04-22 16:32 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next, linux-kernel, Richard Briggs, sparclinux

On Tue, 2014-04-22 at 16:22 +1000, Stephen Rothwell wrote:
> Hi Eric,
> 
> After merging the audit tree, today's linux-next build (sparc defconfig)
> failed like this:
> 
> In file included from include/linux/audit.h:29:0,
>                  from mm/mmap.c:33:
> arch/sparc/include/asm/syscall.h: In function 'syscall_get_arch':
> arch/sparc/include/asm/syscall.h:131:9: error: 'TIF_32BIT' undeclared (first use in this function)
> arch/sparc/include/asm/syscall.h:131:9: note: each undeclared identifier is reported only once for each function it appears in
> 
> And many more ...
> 
> Caused by commit 374c0c054122 ("ARCH: AUDIT: implement syscall_get_arch
> for all arches").
> 
> I applied this patch for today:
> 
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 22 Apr 2014 16:18:53 +1000
> Subject: [PATCH] fix ARCH: AUDIT: implement syscall_get_arch for all arches
> 
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
>  arch/sparc/include/asm/syscall.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
> index fed3d511b108..a5a8153766b3 100644
> --- a/arch/sparc/include/asm/syscall.h
> +++ b/arch/sparc/include/asm/syscall.h
> @@ -128,8 +128,12 @@ static inline void syscall_set_arguments(struct task_struct *task,
>  
>  static inline int syscall_get_arch(void)
>  {
> +#if defined(__sparc__) && defined(__arch64__)
>  	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
>  					   : AUDIT_ARCH_SPARC64;
> +#else
> +	return AUDIT_ARCH_SPARC;
> +#endif
>  }
>  
>  #endif /* __ASM_SPARC_SYSCALL_H */
> -- 

I swear I saw this and I fixed it.  Drat.  Do we want to do it this way?
Above in syscall_get_arguments() they use

#ifdef CONFIG_SPARC64
        if (test_tsk_thread_flag(task, TIF_32BIT))
                zero_extend = 1;
#endif

Is CONFIG_SPARC64 a better choice than:
   defined(__sparc__) && defined(__arch64__)

Maybe even better would be to copy what you suggested in powerpc:

---

diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
index fed3d51..49f71fd 100644
--- a/arch/sparc/include/asm/syscall.h
+++ b/arch/sparc/include/asm/syscall.h
@@ -128,8 +128,7 @@ static inline void syscall_set_arguments(struct task_struct *task,
 
 static inline int syscall_get_arch(void)
 {
-	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
-					   : AUDIT_ARCH_SPARC64;
+	return is_32bit_task() ? AUDIT_ARCH_SPARC : AUDIT_ARCH_SPARC64;
 }
 
 #endif /* __ASM_SPARC_SYSCALL_H */
diff --git a/arch/sparc/include/asm/thread_info_32.h b/arch/sparc/include/asm/thread_info_32.h
index 96efa7a..acd2be0 100644
--- a/arch/sparc/include/asm/thread_info_32.h
+++ b/arch/sparc/include/asm/thread_info_32.h
@@ -130,6 +130,8 @@ register struct thread_info *current_thread_info_reg asm("g6");
 #define _TIF_DO_NOTIFY_RESUME_MASK	(_TIF_NOTIFY_RESUME | \
 					 _TIF_SIGPENDING)
 
+#define is_32bit_task()	(0)
+
 #endif /* __KERNEL__ */
 
 #endif /* _ASM_THREAD_INFO_H */
diff --git a/arch/sparc/include/asm/thread_info_64.h b/arch/sparc/include/asm/thread_info_64.h
index a5f01ac..5a4f660 100644
--- a/arch/sparc/include/asm/thread_info_64.h
+++ b/arch/sparc/include/asm/thread_info_64.h
@@ -219,6 +219,8 @@ register struct thread_info *current_thread_info_reg asm("g6");
 				 _TIF_NEED_RESCHED)
 #define _TIF_DO_NOTIFY_RESUME_MASK	(_TIF_NOTIFY_RESUME | _TIF_SIGPENDING)
 
+#define is_32bit_task()	(test_thread_flag(TIF_32BIT))
+
 /*
  * Thread-synchronous status.
  *



^ permalink raw reply related	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the audit tree
  2014-04-22 16:32   ` Eric Paris
@ 2014-04-22 21:27     ` Stephen Rothwell
  -1 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2014-04-22 21:27 UTC (permalink / raw)
  To: Eric Paris; +Cc: linux-next, linux-kernel, Richard Briggs, sparclinux

[-- Attachment #1: Type: text/plain, Size: 1708 bytes --]

Hi Eric,

On Tue, 22 Apr 2014 12:32:40 -0400 Eric Paris <eparis@redhat.com> wrote:
>
> I swear I saw this and I fixed it.  Drat.  Do we want to do it this way?
> Above in syscall_get_arguments() they use
> 
> #ifdef CONFIG_SPARC64
>         if (test_tsk_thread_flag(task, TIF_32BIT))
>                 zero_extend = 1;
> #endif
> 
> Is CONFIG_SPARC64 a better choice than:
>    defined(__sparc__) && defined(__arch64__)

I have no idea, I just copied the test from thread_info.h.

> Maybe even better would be to copy what you suggested in powerpc:

That would be better, except ...

> diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
> index fed3d51..49f71fd 100644
> --- a/arch/sparc/include/asm/syscall.h
> +++ b/arch/sparc/include/asm/syscall.h
> @@ -128,8 +128,7 @@ static inline void syscall_set_arguments(struct task_struct *task,
>  
>  static inline int syscall_get_arch(void)
>  {
> -	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
> -					   : AUDIT_ARCH_SPARC64;
> +	return is_32bit_task() ? AUDIT_ARCH_SPARC : AUDIT_ARCH_SPARC64;
>  }
>  
>  #endif /* __ASM_SPARC_SYSCALL_H */
> diff --git a/arch/sparc/include/asm/thread_info_32.h b/arch/sparc/include/asm/thread_info_32.h
> index 96efa7a..acd2be0 100644
> --- a/arch/sparc/include/asm/thread_info_32.h
> +++ b/arch/sparc/include/asm/thread_info_32.h
> @@ -130,6 +130,8 @@ register struct thread_info *current_thread_info_reg asm("g6");
>  #define _TIF_DO_NOTIFY_RESUME_MASK	(_TIF_NOTIFY_RESUME | \
>  					 _TIF_SIGPENDING)
>  
> +#define is_32bit_task()	(0)

Shouldn't that be (1) ?

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* Re: linux-next: build failure after merge of the audit tree
@ 2014-04-22 21:27     ` Stephen Rothwell
  0 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2014-04-22 21:27 UTC (permalink / raw)
  To: Eric Paris; +Cc: linux-next, linux-kernel, Richard Briggs, sparclinux

[-- Attachment #1: Type: text/plain, Size: 1708 bytes --]

Hi Eric,

On Tue, 22 Apr 2014 12:32:40 -0400 Eric Paris <eparis@redhat.com> wrote:
>
> I swear I saw this and I fixed it.  Drat.  Do we want to do it this way?
> Above in syscall_get_arguments() they use
> 
> #ifdef CONFIG_SPARC64
>         if (test_tsk_thread_flag(task, TIF_32BIT))
>                 zero_extend = 1;
> #endif
> 
> Is CONFIG_SPARC64 a better choice than:
>    defined(__sparc__) && defined(__arch64__)

I have no idea, I just copied the test from thread_info.h.

> Maybe even better would be to copy what you suggested in powerpc:

That would be better, except ...

> diff --git a/arch/sparc/include/asm/syscall.h b/arch/sparc/include/asm/syscall.h
> index fed3d51..49f71fd 100644
> --- a/arch/sparc/include/asm/syscall.h
> +++ b/arch/sparc/include/asm/syscall.h
> @@ -128,8 +128,7 @@ static inline void syscall_set_arguments(struct task_struct *task,
>  
>  static inline int syscall_get_arch(void)
>  {
> -	return test_thread_flag(TIF_32BIT) ? AUDIT_ARCH_SPARC
> -					   : AUDIT_ARCH_SPARC64;
> +	return is_32bit_task() ? AUDIT_ARCH_SPARC : AUDIT_ARCH_SPARC64;
>  }
>  
>  #endif /* __ASM_SPARC_SYSCALL_H */
> diff --git a/arch/sparc/include/asm/thread_info_32.h b/arch/sparc/include/asm/thread_info_32.h
> index 96efa7a..acd2be0 100644
> --- a/arch/sparc/include/asm/thread_info_32.h
> +++ b/arch/sparc/include/asm/thread_info_32.h
> @@ -130,6 +130,8 @@ register struct thread_info *current_thread_info_reg asm("g6");
>  #define _TIF_DO_NOTIFY_RESUME_MASK	(_TIF_NOTIFY_RESUME | \
>  					 _TIF_SIGPENDING)
>  
> +#define is_32bit_task()	(0)

Shouldn't that be (1) ?

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 59+ messages in thread

* linux-next: build failure after merge of the akpm-current tree
  2011-06-15 12:05         ` Geert Uytterhoeven
@ 2017-11-30  3:46 ` Stephen Rothwell
  -1 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2017-11-30  3:46 UTC (permalink / raw)
  To: Andrew Morton
  Cc: Linux-Next Mailing List, Linux Kernel Mailing List, Waiman Long,
	David S. Miller, sparclinux

Hi Andrew,

After merging the akpm-current tree, today's linux-next build (sparc
defconfig) failed like this:

mm/list_lru.c: In function 'list_lru_del':
mm/list_lru.c:141:2: error: implicit declaration of function 'prefetchw' [-Werror=implicit-function-declaration]
  prefetchw(item->prev);
  ^

Caused by commit

  9b4516980e87 ("mm/list_lru.c: prefetch neighboring list entries before acquiring lock")

Missing include of linux/prefetch.h?

I have reverted that commit for today.

-- 
Cheers,
Stephen Rothwell

^ permalink raw reply	[flat|nested] 59+ messages in thread

* linux-next: build failure after merge of the akpm-current tree
@ 2017-11-30  3:46 ` Stephen Rothwell
  0 siblings, 0 replies; 59+ messages in thread
From: Stephen Rothwell @ 2017-11-30  3:46 UTC (permalink / raw)
  To: Andrew Morton
  Cc: Linux-Next Mailing List, Linux Kernel Mailing List, Waiman Long,
	David S. Miller, sparclinux

Hi Andrew,

After merging the akpm-current tree, today's linux-next build (sparc
defconfig) failed like this:

mm/list_lru.c: In function 'list_lru_del':
mm/list_lru.c:141:2: error: implicit declaration of function 'prefetchw' [-Werror=implicit-function-declaration]
  prefetchw(item->prev);
  ^

Caused by commit

  9b4516980e87 ("mm/list_lru.c: prefetch neighboring list entries before acquiring lock")

Missing include of linux/prefetch.h?

I have reverted that commit for today.

-- 
Cheers,
Stephen Rothwell

^ permalink raw reply	[flat|nested] 59+ messages in thread

end of thread, other threads:[~2017-11-30  3:46 UTC | newest]

Thread overview: 59+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-09  7:27 linux-next: build failure after merge of the final tree (staging related) Stephen Rothwell
2011-06-09 18:41 ` Greg KH
2011-06-09 19:22   ` Greg KH
2011-06-10  6:05     ` Stephen Rothwell
2011-06-10  6:09       ` Stephen Rothwell
2011-06-10 22:34         ` Greg KH
2011-06-15  4:21           ` Stephen Rothwell
2011-06-16 19:14             ` Greg KH
2011-06-23  0:35               ` Stephen Rothwell
2011-06-23 21:51                 ` Greg KH
2011-06-24  0:00                   ` Stephen Rothwell
2011-06-27 21:45                     ` Greg KH
2011-06-28  0:16                       ` Stephen Rothwell
2011-06-15 12:05       ` Geert Uytterhoeven
2011-06-15 12:05         ` Geert Uytterhoeven
2011-06-15 15:47         ` Greg KH
2011-06-15 15:47           ` linux-next: build failure after merge of the final tree (staging Greg KH
2011-06-15 14:35       ` [PATCH] arch/tile: remove useless set_fixmap_nocache() macro Chris Metcalf
2011-06-15 14:35       ` Chris Metcalf
2011-06-15 14:35         ` Chris Metcalf
2011-06-15 14:35         ` Chris Metcalf
2011-06-15 14:35         ` Chris Metcalf
2011-06-09 19:52   ` linux-next: build failure after merge of the final tree (staging related) Henry Ptasinski
2011-06-09 20:19     ` Greg KH
2012-06-12  4:54 linux-next: build failure after merge of the final tree (pci tree related) Stephen Rothwell
2012-06-12  4:54 ` Stephen Rothwell
2012-06-12 15:31 ` Bjorn Helgaas
2012-06-12 15:31   ` Bjorn Helgaas
2012-06-12 15:31   ` Bjorn Helgaas
2012-06-13  0:50   ` Stephen Rothwell
2012-06-13  0:50     ` Stephen Rothwell
2012-06-13 23:20     ` Bjorn Helgaas
2012-06-13 23:20       ` Bjorn Helgaas
2013-02-11  7:34 linux-next: build failure after merge of the final tree (acpi " Stephen Rothwell
2013-02-11  7:34 ` Stephen Rothwell
2013-02-11 18:22 ` Bjorn Helgaas
2013-02-11 18:22   ` Bjorn Helgaas
2013-02-11 23:23 ` Len Brown
2013-02-11 23:23   ` Len Brown
2013-02-12 17:35   ` Sam Ravnborg
2013-02-12 17:35     ` Sam Ravnborg
2013-02-12 18:01     ` Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tree related)) Len Brown
2013-02-12 18:01       ` Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tree r Len Brown
2013-02-12 18:03       ` Should SPARC use cpuidle? Len Brown
2013-02-12 18:03         ` Len Brown
2013-02-12 19:36         ` Sam Ravnborg
2013-02-12 19:36           ` Sam Ravnborg
2013-02-12 19:42       ` Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tree related)) Sam Ravnborg
2013-02-12 19:42         ` Should SPARC use cpuidle? (was: linux-next: build failure after merge of the final tree (acpi tr Sam Ravnborg
2014-04-22  6:22 linux-next: build failure after merge of the audit tree Stephen Rothwell
2014-04-22  6:22 ` Stephen Rothwell
2014-04-22 15:56 ` Richard Guy Briggs
2014-04-22 15:56   ` Richard Guy Briggs
2014-04-22 16:32 ` Eric Paris
2014-04-22 16:32   ` Eric Paris
2014-04-22 21:27   ` Stephen Rothwell
2014-04-22 21:27     ` Stephen Rothwell
2017-11-30  3:46 linux-next: build failure after merge of the akpm-current tree Stephen Rothwell
2017-11-30  3:46 ` Stephen Rothwell

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.