Please note: This project is no longer active. The website is kept online for historic purposes only.
If you´re looking for a Linux driver for your Atheros WLAN device, you should continue here .

Ticket #1310 (closed defect: fixed)

Opened 12 years ago

Last modified 12 years ago

Unable to compile madwifi on sparc64

Reported by: Stijn Tintel <stijn at linux dash ipv6 dot be> Assigned to:
Priority: major Milestone: version 0.9.5
Component: madwifi: other Version: trunk
Keywords: Cc:
Patch is attached: 0 Pending:

Description

I am unable to compile madwifi trunk r2327 on Debian Etch for Sparc.

Compile output:

ultra5:~/madwifi/madwifi-svn# svn up
At revision 2327.
ultra5:~/madwifi/madwifi-svn# make
Checking requirements... ok.
Checking kernel configuration... ok.
make -C /lib/modules/2.6.18-4-sparc64/build SUBDIRS=/root/madwifi/madwifi-svn modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.18-4-sparc64'
  CC [M]  /root/madwifi/madwifi-svn/ath/if_ath.o
  CC [M]  /root/madwifi/madwifi-svn/ath/if_ath_pci.o
  LD [M]  /root/madwifi/madwifi-svn/ath/ath_pci.o
  CC [M]  /root/madwifi/madwifi-svn/ath_hal/ah_os.o
  HOSTCC  /root/madwifi/madwifi-svn/ath_hal/uudecode
  UUDECODE /root/madwifi/madwifi-svn/ath_hal/sparc64-be-elf.hal.o
  LD [M]  /root/madwifi/madwifi-svn/ath_hal/ath_hal.o
  CC [M]  /root/madwifi/madwifi-svn/ath_rate/amrr/amrr.o
  LD [M]  /root/madwifi/madwifi-svn/ath_rate/amrr/ath_rate_amrr.o
  CC [M]  /root/madwifi/madwifi-svn/ath_rate/minstrel/minstrel.o
cc1: warnings being treated as errors
/root/madwifi/madwifi-svn/ath_rate/minstrel/minstrel.c: In function 'ath_proc_read_nodes':
/root/madwifi/madwifi-svn/ath_rate/minstrel/minstrel.c:961: warning: format '%8llu' expects type 'long long unsigned int', but argument 11 has type 'long unsigned int'
/root/madwifi/madwifi-svn/ath_rate/minstrel/minstrel.c:961: warning: format '%8llu' expects type 'long long unsigned int', but argument 12 has type 'long unsigned int'
/root/madwifi/madwifi-svn/ath_rate/minstrel/minstrel.c:961: warning: format '%8llu' expects type 'long long unsigned int', but argument 11 has type 'long unsigned int'
/root/madwifi/madwifi-svn/ath_rate/minstrel/minstrel.c:961: warning: format '%8llu' expects type 'long long unsigned int', but argument 12 has type 'long unsigned int'
make[4]: *** [/root/madwifi/madwifi-svn/ath_rate/minstrel/minstrel.o] Error 1
make[3]: *** [/root/madwifi/madwifi-svn/ath_rate/minstrel] Error 2
make[2]: *** [/root/madwifi/madwifi-svn/ath_rate] Error 2
make[1]: *** [_module_/root/madwifi/madwifi-svn] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-2.6.18-4-sparc64'
make: *** [modules] Error 2

Kernel version:

ultra5:~/madwifi/madwifi-svn# uname -a
Linux ultra5 2.6.18-4-sparc64 #1 Wed Apr 25 18:47:43 UTC 2007 sparc64 GNU/Linux

FYI, 0.9.3 also doesn't compile, but there are other errors. If I should also attach the compile output for 0.9.3 to this ticket, please ask :-)

Change History

05/12/07 20:44:44 changed by Stijn Tintel <stijn at linux dash ipv6 dot be>

Ok, when I remove the "minstrel/" from ath_rate/Makefile, I'm seeing the same error as the one I'm seeing with 0.9.3, so I'll attach the compile output here anyway :-)

ultra5:~/madwifi/madwifi-svn# make
Checking requirements... ok.
Checking kernel configuration... ok.
make -C /lib/modules/2.6.18-4-sparc64/build SUBDIRS=/root/madwifi/madwifi-svn modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.18-4-sparc64'
  CC [M]  /root/madwifi/madwifi-svn/ath/if_ath.o
  CC [M]  /root/madwifi/madwifi-svn/ath/if_ath_pci.o
  LD [M]  /root/madwifi/madwifi-svn/ath/ath_pci.o
  CC [M]  /root/madwifi/madwifi-svn/ath_hal/ah_os.o
  HOSTCC  /root/madwifi/madwifi-svn/ath_hal/uudecode
  UUDECODE /root/madwifi/madwifi-svn/ath_hal/sparc64-be-elf.hal.o
  LD [M]  /root/madwifi/madwifi-svn/ath_hal/ath_hal.o
  CC [M]  /root/madwifi/madwifi-svn/ath_rate/amrr/amrr.o
  LD [M]  /root/madwifi/madwifi-svn/ath_rate/amrr/ath_rate_amrr.o
  CC [M]  /root/madwifi/madwifi-svn/ath_rate/onoe/onoe.o
  LD [M]  /root/madwifi/madwifi-svn/ath_rate/onoe/ath_rate_onoe.o
  CC [M]  /root/madwifi/madwifi-svn/ath_rate/sample/sample.o
  LD [M]  /root/madwifi/madwifi-svn/ath_rate/sample/ath_rate_sample.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/if_media.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_beacon.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_crypto.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_crypto_none.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_input.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_node.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_output.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_power.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_proto.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_scan.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_wireless.o
  CC [M]  /root/madwifi/madwifi-svn/net80211/ieee80211_linux.o
cc1: warnings being treated as errors
/root/madwifi/madwifi-svn/net80211/ieee80211_linux.c: In function 'ieee80211_notify_sta_stats':
/root/madwifi/madwifi-svn/net80211/ieee80211_linux.c:252: warning: format '%llu' expects type 'long long unsigned int', but argument 7 has type 'u_int64_t'
/root/madwifi/madwifi-svn/net80211/ieee80211_linux.c:252: warning: format '%llu' expects type 'long long unsigned int', but argument 9 has type 'u_int64_t'
/root/madwifi/madwifi-svn/net80211/ieee80211_linux.c:252: warning: format '%llu' expects type 'long long unsigned int', but argument 7 has type 'u_int64_t'
/root/madwifi/madwifi-svn/net80211/ieee80211_linux.c:252: warning: format '%llu' expects type 'long long unsigned int', but argument 9 has type 'u_int64_t'
make[3]: *** [/root/madwifi/madwifi-svn/net80211/ieee80211_linux.o] Error 1
make[2]: *** [/root/madwifi/madwifi-svn/net80211] Error 2
make[1]: *** [_module_/root/madwifi/madwifi-svn] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-2.6.18-4-sparc64'
make: *** [modules] Error 2

05/16/07 00:18:19 changed by anonymous

I get this same 2nd error on my alpha with 0.9.3

(follow-up: ↓ 5 ) 05/16/07 00:27:53 changed by strasak@bubakov.net

Quick workaround could be to comment out line #149 - in trunk, but probably the same in 0.9.3. The line - WARNINGS = -Werror - causes this behavior :

cc1: warnings being treated as errors

commenting it out should let you compile madwifi , but doesn't mean it would run flawlessly - try and you will see :)

05/16/07 03:18:24 changed by anonymous

What file specifically, sorry not sure what you mean. This is what I get on my alpha:

root@alpha:/usr/src/madwifi-0.9.3# uname -a
Linux alpha 2.6.21.1 #1 Fri May 11 13:43:09 PDT 2007 alpha GNU/Linux
root@alpha:/usr/src/madwifi-0.9.3# make
Checking requirements... ok.
Checking kernel configuration... ok.
make -C /lib/modules/2.6.21.1/build SUBDIRS=/usr/src/madwifi-0.9.3 modules
make[1]: Entering directory `/usr/src/linux-2.6.21.1'
  CC [M]  /usr/src/madwifi-0.9.3/ath/if_ath.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/ath/if_ath_pci.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  LD [M]  /usr/src/madwifi-0.9.3/ath/ath_pci.o
  CC [M]  /usr/src/madwifi-0.9.3/ath_hal/ah_os.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  HOSTCC  /usr/src/madwifi-0.9.3/ath_hal/uudecode
  UUDECODE /usr/src/madwifi-0.9.3/ath_hal/alpha-elf.hal.o
  LD [M]  /usr/src/madwifi-0.9.3/ath_hal/ath_hal.o
  CC [M]  /usr/src/madwifi-0.9.3/ath_rate/amrr/amrr.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  LD [M]  /usr/src/madwifi-0.9.3/ath_rate/amrr/ath_rate_amrr.o
  CC [M]  /usr/src/madwifi-0.9.3/ath_rate/onoe/onoe.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  LD [M]  /usr/src/madwifi-0.9.3/ath_rate/onoe/ath_rate_onoe.o
  CC [M]  /usr/src/madwifi-0.9.3/ath_rate/sample/sample.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  LD [M]  /usr/src/madwifi-0.9.3/ath_rate/sample/ath_rate_sample.o
  CC [M]  /usr/src/madwifi-0.9.3/net80211/if_media.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_beacon.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_crypto.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_crypto_none.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_input.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_node.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_output.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_power.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_proto.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_scan.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_wireless.o
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
  CC [M]  /usr/src/madwifi-0.9.3/net80211/ieee80211_linux.o
cc1: warnings being treated as errors
/usr/src/madwifi-0.9.3/net80211/ieee80211_linux.c: In function 'ieee80211_notify_sta_stats':
/usr/src/madwifi-0.9.3/net80211/ieee80211_linux.c:252: warning: format '%llu' expects type 'long long unsigned int', but argument 7 has type 'u_int64_t'
/usr/src/madwifi-0.9.3/net80211/ieee80211_linux.c:252: warning: format '%llu' expects type 'long long unsigned int', but argument 9 has type 'u_int64_t'
/usr/src/madwifi-0.9.3/net80211/ieee80211_linux.c:252: warning: format '%llu' expects type 'long long unsigned int', but argument 7 has type 'u_int64_t'
/usr/src/madwifi-0.9.3/net80211/ieee80211_linux.c:252: warning: format '%llu' expects type 'long long unsigned int', but argument 9 has type 'u_int64_t'
{standard input}: Assembler messages:
{standard input}:7: Warning: setting incorrect section attributes for .got
make[3]: *** [/usr/src/madwifi-0.9.3/net80211/ieee80211_linux.o] Error 1
make[2]: *** [/usr/src/madwifi-0.9.3/net80211] Error 2
make[1]: *** [_module_/usr/src/madwifi-0.9.3] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.21.1'
make: *** [modules] Error 2

(in reply to: ↑ 3 ) 05/16/07 06:47:17 changed by mrenzmann

Replying to strasak@bubakov.net:

Quick workaround could be to comment out line #149 - in trunk, but probably the same in 0.9.3. The line - WARNINGS = -Werror - causes this behavior :

Instead you could also run make WARNINGS=

05/16/07 13:50:04 changed by strasak@bubakov.net

sorry, forgot filename , it is Makefile.inc, mike's way is faster anyway so use that ->
make WARNINGS=

05/16/07 19:14:45 changed by Stijn Tintel <stijn at linux dash ipv6 dot be>

OK. With "make WARNINGS=", madwifi r2339 compiles fine. However, 'modprobe ath_pci' doesn't seem to be very happy:

ultra5:~/madwifi/madwifi-svn# modprobe ath_pci
Killed

And 'dmesg' shows me this:

ath_hal: module license 'Proprietary' taints kernel.
ath_hal: 0.9.18.0 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413, RF5413, REGOPS_FUNC)
wlan: 0.8.4.2 (svn r2339)
ath_pci: 0.9.4.5 (svn r2339)
Kernel unaligned access at TPC[629c18] wait_for_completion+0x68/0xc0
Unable to handle kernel NULL pointer dereference
tsk->{mm,active_mm}->context = 0000000000000f2f
tsk->{mm,active_mm}->pgd = fffff80010bb0000
              \|/ ____ \|/
              "@'/ .. \`@"
              /_| \__/ |_\
                 \__U_/
modprobe(3578): Oops [#1]
TSTATE: 0000000080f09605 TPC: 000000000041bb34 TNPC: 000000000041bb38 Y: 00000000    Tainted: P
TPC: <__do_int_store+0x30/0x90>
g0: 5f636f6d706c6574 g1: 0000000000000000 g2: 0000000000000000 g3: 0000000000000002
g4: fffff80011076e60 g5: fffff8001d3683c8 g6: fffff8001d8d4000 g7: 0000000000000000
o0: 0000000000000004 o1: 0000000000000008 o2: 0000000000000002 o3: 0000000000000080
o4: 0000000000000080 o5: fffff8001cbadfc0 sp: fffff8001d8d6511 ret_pc: 0000000000421bf0
RPC: <kernel_unaligned_trap+0x4f0/0x548>
l0: 0000000000000080 l1: 0000000000000002 l2: 0000000000000008 l3: 0000000000000062
l4: 0000000000000001 l5: 0000000000000080 l6: 0000000000000004 l7: 000000000000001b
i0: fffff8001d8d7000 i1: 0000000000000002 i2: fffff80011076e60 i3: 0000000000000000
i4: 0000000000000000 i5: fffff8001cbae0d0 i6: fffff8001d8d65e1 i7: 000000000041ae18
I7: <mem_address_unaligned+0x70/0xa8>
Caller[000000000041ae18]: mem_address_unaligned+0x70/0xa8
Caller[0000000000406688]: do_mna+0x44/0x4c
Caller[0000000000629bd4]: wait_for_completion+0x24/0xc0
Caller[0000000000456c40]: call_usermodehelper_keys+0xb0/0xbc
Caller[0000000000456ef0]: request_module+0x104/0x11c
Caller[00000000101b80a8]: ieee80211_load_module+0xc/0x3c [wlan]
Caller[00000000101b9a30]: ieee80211_rate_attach+0x84/0xe8 [wlan]
Caller[00000000101dce3c]: ath_attach+0xb74/0x1800 [ath_pci]
Caller[00000000101e22dc]: ath_pci_probe+0x2c8/0x380 [ath_pci]
Caller[0000000000522758]: pci_device_probe+0x5c/0x8c
Caller[0000000000578930]: driver_probe_device+0x54/0xc4
Caller[00000000005789e4]: __driver_attach+0x44/0x68
Caller[0000000000578428]: bus_for_each_dev+0x38/0x6c
Caller[0000000000577f4c]: bus_add_driver+0x70/0x134
Caller[00000000005228bc]: __pci_register_driver+0x40/0x6c
Caller[00000000101ee02c]: init_ath_pci+0x34/0x68 [ath_pci]
Caller[0000000000462e7c]: sys_init_module+0x13e4/0x154c
Caller[00000000004069d4]: linux_sparc_syscall32+0x3c/0x40
Caller[00000000000133b4]: 0x133bc
Instruction DUMP: 8530f018  8330f038  8f30f030 <c2aa2000> 8330f028  ceaa2001  8f30f020  c2aa2002  ceaa2003
ath_rate_sample: 1.2 (svn r2339)
Kernel unaligned access at TPC[444f40] try_to_wake_up+0x18/0x110
Unable to handle kernel NULL pointer dereference
tsk->{mm,active_mm}->context = 0000000000000f32
tsk->{mm,active_mm}->pgd = fffff8001143e000
              \|/ ____ \|/
              "@'/ .. \`@"
              /_| \__/ |_\
                 \__U_/
khelper(3581): Oops [#2]
TSTATE: 0000000080f09606 TPC: 000000000041bc0c TNPC: 000000000041bc10 Y: 00000000    Tainted: P
TPC: <do_int_load+0x78/0xf0>
g0: 616b655f75700000 g1: 0000000000000010 g2: 0000000000000400 g3: 0000000000000002
g4: fffff800110d7200 g5: 0000002e33004700 g6: fffff800114bc000 g7: fffff800114bfac0
o0: fffff800114bfad0 o1: 0000000000000008 o2: 0000000000000004 o3: 0000000000400000
o4: 0000000000000080 o5: 0000000000000080 sp: fffff800114befd1 ret_pc: 000000000042192c
RPC: <kernel_unaligned_trap+0x22c/0x548>
l0: 0000000000000080 l1: fffff800114bfad0 l2: 0000000000000008 l3: 0000000000000062
l4: 0000000000000000 l5: 0000000000000080 l6: 0000000000000004 l7: 00000000004306c0
i0: fffff800114bfac0 i1: 00000000c45e0000 i2: fffff800110d7200 i3: 000000000000000a
i4: 000000000000000f i5: 0000000000007fff i6: fffff800114bf0a1 i7: 000000000041ae18
I7: <mem_address_unaligned+0x70/0xa8>
Caller[000000000041ae18]: mem_address_unaligned+0x70/0xa8
Caller[0000000000406688]: do_mna+0x44/0x4c
Caller[0000000000444f38]: try_to_wake_up+0x10/0x110
Caller[0000000000443b70]: __wake_up_common+0x24/0x68
Caller[0000000000443c2c]: complete+0x30/0x3c
Caller[0000000000456de4]: wait_for_helper+0x7c/0x84
Caller[0000000000417978]: kernel_thread+0x38/0x48
Caller[0000000000456c8c]: __call_usermodehelper+0x40/0x74
Instruction DUMP: 8538a000  1068001f  c4720000 <c48aa000> c68aa001  8528b038  ce8aa002  8728f030  c28aa003

05/16/07 19:57:49 changed by tim@elementhost.com

Yep, alpha guy here still. It compiled, modprobe killed my box, it won't boot up now once it loads the module. So same boat as Stijn Tintel.

05/17/07 00:13:54 changed by mentor

Try r2344

05/17/07 10:16:47 changed by anonymous

Neat I'll give this a shot, thanks a lot :).

05/18/07 00:14:51 changed by Stijn Tintel <stijn at linux dash ipv6 dot be>

With madwifi r2347, I still have the compile error I initially reported in this ticket (during compile of minstrel rate module).

When I remove "minstrel/" from the Makefile in the ath_rate dir, madwifi compiles fine. Unfortunately, when I modprobe ath_pci, I'm still having a kernel oops. It looks the same as the one I posted in #comment:7.

05/18/07 00:31:52 changed by strasak@bubakov.net

maybe you should try branch with newer HAL as last resort, but it could be that sparc is broken, take a look at ticket #493

05/18/07 11:44:04 changed by mentor

  • status changed from new to closed.
  • resolution set to fixed.
  • milestone set to version 0.9.4.

r2349.

I believe the compiling problem is fixed and that the other problem is #493. Hence, I am closing htis ticket.

05/18/07 12:28:04 changed by Stijn Tintel <stijn at linux dash ipv6 dot be>

Madwifi r2350 seems to compile fine without any workaround. Thanks!

For the kernel oops, I'll take a look at ticket #493, and attach other info there.

02/11/08 06:18:17 changed by mrenzmann

  • milestone changed from version 0.9.4 to version 0.9.5.