2002-12-12 22:59:09

by Matt Reppert

[permalink] [raw]
Subject: [PATCH] "extern inline" to "static inline" allows compile

Hi,

I can't compile 2.5.51 on an EV56 without this. Tested, boots.
There are a bunch of symbols in core_cia.h that break the build if they're
extern inline because they're only defined in the header now. Make them
static inline instead. (Important, since they're #defined to things like
inb)

Comments?

Matt

diff -Nru a/include/asm-alpha/core_cia.h b/include/asm-alpha/core_cia.h
--- a/include/asm-alpha/core_cia.h Thu Dec 12 16:59:06 2002
+++ b/include/asm-alpha/core_cia.h Thu Dec 12 16:59:06 2002
@@ -293,7 +293,7 @@
#ifdef __KERNEL__

#ifndef __EXTERN_INLINE
-#define __EXTERN_INLINE extern inline
+#define __EXTERN_INLINE static inline
#define __IO_EXTERN_INLINE
#endif


2002-12-12 23:17:03

by Richard Henderson

[permalink] [raw]
Subject: Re: [PATCH] "extern inline" to "static inline" allows compile

On Thu, Dec 12, 2002 at 05:09:02PM -0600, Matt Reppert wrote:
> Comments?

Revert the asm/pci.h change instead.


r~

2002-12-12 23:36:35

by Steffen Persvold

[permalink] [raw]
Subject: Re: [PATCH] "extern inline" to "static inline" allows compile

On Thu, 12 Dec 2002, Richard Henderson wrote:

> On Thu, Dec 12, 2002 at 05:09:02PM -0600, Matt Reppert wrote:
> > Comments?
>
> Revert the asm/pci.h change instead.
>

Is there a reason for the 'extern inline', to me it seems more natural to
have 'static inline' ?

Regards,
--
Steffen Persvold | Scali AS
mailto:[email protected] | http://www.scali.com
Tel: (+47) 2262 8950 | Olaf Helsets vei 6
Fax: (+47) 2262 8951 | N0621 Oslo, NORWAY

2002-12-12 23:44:44

by Richard Henderson

[permalink] [raw]
Subject: Re: [PATCH] "extern inline" to "static inline" allows compile

On Fri, Dec 13, 2002 at 12:44:17AM +0100, Steffen Persvold wrote:
> Is there a reason for the 'extern inline', to me it seems more natural to
> have 'static inline' ?

Yes. Examine the entire __EXTERN_INLINE structure with
core_foo.[ch].


r~

2002-12-13 00:12:40

by Rusty Russell

[permalink] [raw]
Subject: Re: [PATCH] "extern inline" to "static inline" allows compile

In message <[email protected]> you write:
> Hi,
>
> I can't compile 2.5.51 on an EV56 without this. Tested, boots.
> There are a bunch of symbols in core_cia.h that break the build if they're
> extern inline because they're only defined in the header now. Make them
> static inline instead. (Important, since they're #defined to things like
> inb)
>
> Comments?

This patch is simple, but not trivial, and since RTH wrote this, I'm
assuming all those __EXTERN_INLINE's are defined and undefned in
multiple places for a reason.

Richard?
Rusty.
--
Anyone who quotes me in their sig is an idiot. -- Rusty Russell.

2002-12-13 09:16:53

by Richard Henderson

[permalink] [raw]
Subject: Re: [PATCH] "extern inline" to "static inline" allows compile

On Fri, Dec 13, 2002 at 11:18:57AM +1100, Rusty Russell wrote:
> This patch is simple, but not trivial, and since RTH wrote this, I'm
> assuming all those __EXTERN_INLINE's are defined and undefned in
> multiple places for a reason.

Indeed.

> Richard?

Fixed properly by reverting the asm-alpha/pci.h patch
and including asm/io.h in drivers/scsi/sr_ioctl.c.


r~