Next-in-Thread Next Message

Question spinlock compile problem on ppc 

Forum: Non-x86 PCMCIA Issues
Date: 1999, Nov 08
From: Michael Baer baerm


I recently had a problem compiling pcmcia-cs-3.1.3, the following message describes it almost perfectly, I assume Tsuneya had a slightly different version of pcmcia-cs as my line numbers were slightly different. I'm using linuxppc (approx RH6) on a Wallstreet Powerbook. I maybe missing something completly obvious, but looking at the code, the structure socket_info_t defined in cs_internal.h is defined without the member 'spinlock_t lock' if USE_SPIN_LOCKS isn't defined (and it probably shouldn't be). It is then referenced in cs.c in several places where a variable of type socket_info_t is used to access 'lock'. whether or not USE_SPIN_LOCKS is defined (as far as I can tell). Compilalition then fails. This all seems internal to pcmcia-cs. I don't see how it is caused by the kernel spinlock header. Anyway, apologize for any boneheadness on my part in advance...

Mike Baer

>Hi all,

>Previously I posted the question below without getting any >answer
>on this list. I tried the same question in >comp.os.linux.portable
>and David Hinds, the author of pcmcia-cs, kindly pointed out >that
>the error message below is a bug in the kernel spinlock >header for
>ppc. According to him, the spin lock macros should not >reference
>the lock variable for non-SMP kernels. He also wrote that he >was
>surprised that this made it into the 2.2.13 final release.

>Can anyone point out how I can modify related headers to >avoid
>this spinlock problem to build pcmcia-cs under kernel 2.2.13?


> **
> In article <> for
> comp.os.linux.portable, Tsuneya Watabe ( > > wrote:

> I've just built kernel 2.2.13 from which basically works fine
> on both PCI9500 and PB2400. However, trying to compile pcmcia-cs-3.1.2
> for PB2400 always results in failure like below:

> cc -fno-builtin -msoft-float -ffixed-r2  -MD -O3 -Wall
> -Wstrict-prototypes
> -pipe  -D__KERNEL__ -DMODULE -I../include -I/usr/src/linux/include -c
> cs.c
> cs.c: In function `parse_events':
> cs.c:646: structure has no member named `lock'
> cs.c: In function `deregister_client':
> cs.c:955: structure has no member named `lock'
> cs.c: In function `cs_request_irq':
> cs.c:1781: warning: unused variable `mask'
> cs.c:1780: warning: unused variable `try'
> cs.c: In function `eject_card':
> cs.c:2031: structure has no member named `lock'
> cs.c: In function `insert_card':
> cs.c:2053: structure has no member named `lock'
> make[1]: *** [cs.o] Error 1

>Tsuneya Watab

Next-in-Thread Next Message

Messages Inline: 1 All Outline: 1 2 All

1. Ok Untitled by Tsuneya Watabe, 1999, Nov 27

Add Message to: "spinlock compile problem on ppc"

Members Subscribe Admin Mode Show Frames Help for HyperNews at 1.10