Chris,

This is caused by a change to the mac80211 Makefile in
https://dev.openwrt.org/changeset/30742/trunk/package/mac80211 (make all ->
make modules) which causes the compat.ko module to get built a second time
from the kernel tree with an invalid configuration.

Its fixed with the latest compat-wireless update in r31322.

Tim

On Tue, Apr 10, 2012 at 9:56 AM, Christian Gagneraud <[email protected]>wrote:

> Hi,
>
> I'm still fighting with this problem, Here is what I found so far by
> tracking the make calls hierarchy when compiling compat-wireless:
>
> trunk> make package/mac80211/compile V=99 > |tee mac80211.log
> trunk> grep ^make mac80211.log
> make[1]: Entering directory `.../openwrt/trunk'
> make[2]: Entering directory `.../openwrt/trunk/package/**libnl-tiny'
> make[2]: Leaving directory `.../openwrt/trunk/package/**libnl-tiny'
> make[2]: Entering directory `.../openwrt/trunk/package/**crda'
> make[2]: Leaving directory `.../openwrt/trunk/package/**crda'
> make[2]: Entering directory `.../openwrt/trunk/package/iw'
> make[2]: Leaving directory `.../openwrt/trunk/package/iw'
> make[2]: Entering directory `.../openwrt/trunk/package/**wireless-tools'
> make[2]: Leaving directory `.../openwrt/trunk/package/**wireless-tools'
> make[2]: Entering directory `.../openwrt/trunk/package/**mac80211'
> make  -j1 -C 
> ".../openwrt/trunk/build_dir/**linux-at91_tmbbv3/compat-**wireless-2012-02-27"
> [snipped long argument list]
> make[3]: Entering directory `.../openwrt/trunk/build_dir/**
> linux-at91_tmbbv3/compat-**wireless-2012-02-27'
>
> Here i get a warning:
> WARNING: CONFIG_CFG80211_WEXT will be deactivated or not working because
> kernel was compiled with CONFIG_WIRELESS_EXT=n. Tools using wext
> interface like iwconfig will not work. To activate it build your kernel
> e.g. with CONFIG_LIBIPW=m.
>
> my target's .config has CONFIG_WIRELESS_EXT=y, but the kernel .config in
> the build dir don't ...
> and CONFIG_LIBIPW seems to be realated to Intel PCI wireless cards...
>
> make -C 
> .../openwrt/trunk/build_dir/**linux-at91_tmbbv3/compat-**wireless-2012-02-27
> modules
> make[4]: Entering directory `.../openwrt/trunk/build_dir/**
> linux-at91_tmbbv3/compat-**wireless-2012-02-27'
> make -C .../openwrt/trunk/build_dir/**linux-at91_tmbbv3/linux-2.6.**38.8
> M=.../openwrt/trunk/build_dir/**linux-at91_tmbbv3/compat-**wireless-2012-02-27
> modules V=1
> make[5]: Entering directory `.../openwrt/trunk/build_dir/**
> linux-at91_tmbbv3/linux-2.6.**38.8'
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/compat
>
> Here the compat.o get built with main.o, compat-2.6.39.o, kstrtox.o,
> compat-3.0.o and compat-3.2.o. At this stage the compat.o should have the
> kstrtou8_from_user
>
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/drivers/**misc/eeprom
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/drivers/**net/usb
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/drivers/**net/wireless
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/drivers/**
> net/wireless/rt2x00
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/net/**mac80211
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/net/**wireless
> make -f .../openwrt/trunk/build_dir/**linux-at91_tmbbv3/linux-2.6.**
> 38.8/scripts/Makefile.modpost
>
> Here compat.ko is created
>
> make[5]: Leaving directory `.../openwrt/trunk/build_dir/**
> linux-at91_tmbbv3/linux-2.6.**38.8'
> make[4]: Leaving directory `.../openwrt/trunk/build_dir/**
> linux-at91_tmbbv3/compat-**wireless-2012-02-27'
> make -C .../openwrt/trunk/build_dir/**linux-at91_tmbbv3/linux-2.6.**38.8
> M=.../openwrt/trunk/build_dir/**linux-at91_tmbbv3/compat-**wireless-2012-02-27
> modules V=1
> make[4]: Entering directory `.../openwrt/trunk/build_dir/**
> linux-at91_tmbbv3/linux-2.6.**38.8'
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/compat
>
> Now, here is the interesting stuff:
> The compat.o get built again but this time with only compat.o and
> main.o, does it mean that the build scripts think they build against a
> 3.2 kernel? Or maybe my kernel config has changed since then?
>
> And strangely, the following make calls won't cause any objects to be
> rebuilt (apart for compat.ko in modpost)
>
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/drivers/**misc/eeprom
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/drivers/**net/usb
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/drivers/**net/wireless
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/drivers/**
> net/wireless/rt2x00
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/net/**mac80211
> make -f scripts/Makefile.build obj=.../openwrt/trunk/build_**
> dir/linux-at91_tmbbv3/compat-**wireless-2012-02-27/net/**wireless
> make -f .../openwrt/trunk/build_dir/**linux-at91_tmbbv3/linux-2.6.**
> 38.8/scripts/Makefile.modpost
> make[4]: Leaving directory `.../openwrt/trunk/build_dir/**
> linux-at91_tmbbv3/linux-2.6.**38.8'
> make[3]: Leaving directory `.../openwrt/trunk/build_dir/**
> linux-at91_tmbbv3/compat-**wireless-2012-02-27'
> make V=99  -j1 clean-staging
> make[3]: Entering directory `.../openwrt/trunk/package/**mac80211'
> make[3]: Leaving directory `.../openwrt/trunk/package/**mac80211'
> make[2]: Leaving directory `.../openwrt/trunk/package/**mac80211'
> make[1]: Leaving directory `.../openwrt/trunk'
>
>
> /me keep digging....
>
> Chris
>
>
>
>
> On 06/04/12 21:06, Christian Gagneraud wrote:
>
>> Hi,
>>
>> I manage to dig a bit deeper, so actually the missing functions are in
>> compat-3.0.{c,h} from compat-wireless
>>
>> The file compat-3.0.c is build into a .o, but for some reason compat.ko
>> links only to main.o.
>>
>> So my .config in compat-wireless/ looks like:
>> export
>> CONFIG_COMPAT_KERNEL_2_6_39=y
>> CONFIG_COMPAT_KERNEL_3_0=y
>> CONFIG_COMPAT_KERNEL_3_1=y
>> CONFIG_COMPAT_KERNEL_3_2=y
>> CONFIG_COMPAT_KERNEL_3_3=y
>>
>> But the .tmp_versions/compat.mod only reference main.o:
>> [...]/openwrt/trunk/build_dir/**linux-at91_tmbbv3/compat-**
>> wireless-2012-02-27/compat/**compat.ko
>>
>> [...]/openwrt/trunk/build_dir/**linux-at91_tmbbv3/compat-**
>> wireless-2012-02-27/compat/**main.o
>>
>>
>> weird ....
>>
>> Chris
>>
>>
>>
>> On 06/04/12 20:00, Christian Gagneraud wrote:
>>
>>> Hi there,
>>>
>>> I'm fighting with a problem of missing kernel symbol.
>>> Basically kstrtou8_from_user is missing, as a consequence mac80211.ko
>>> can't be loaded, and then all the rest of the 802.11 stack and my wifi
>>> drivers.
>>>
>>> At some point I manage to get it loading, but i don't know how I did,
>>> and I can't reproduce it (reproducing the missing symbol situation is
>>> way easier)
>>> I'm not sure, but it seems to me that in my case using the 802.11 code
>>> from the kernel works but using the modules from
>>> compat-wireless-2012-02-27 doesn't...
>>>
>>> After checking on the linux cross-reference, i found that this symbol
>>> have been added to linux-3.0, and I'm running 2.6.38.8 ...
>>> (see 
>>> http://lxr.free-electrons.com/**source/lib/kstrtox.c?v=3.0#**L249<http://lxr.free-electrons.com/source/lib/kstrtox.c?v=3.0#L249>
>>> )
>>>
>>> My wifi device is a WPER-150gn (miniPCIe, Ralink RT3070 chipset on the
>>> USB lane), the kernel module i need seems to be rt2800usb.ko
>>> This module is selected from my subtarget's target.mk.
>>>
>>> I'm using OpenWrt trunk, updated a couple of days ago (the problem was
>>> already there before the last update I think).
>>>
>>> To give u an insight on my configuration here are some traces when I
>>> grep around for 80211 and kstrtou8_from_user:
>>> http://pastebin.com/gAY5d99M
>>>
>>> Could someone shed some light on how to fix this problem? Is it related
>>> with compat-wireless or maybe it's because of my target or configuration?
>>>
>>> Any help greatly appreciated.
>>>
>>> Cheers,
>>> Chris
>>>
>>>
>>>
>>>
>>
> --
> Christian Gagneraud,
> Embedded systems engineer.
> Techworks Marine
> 1 Harbour road
> Dun Laoghaire
> Co. Dublin
> Ireland
> Tel: + 353 (0) 1 236 5990
> Web: http://www.techworks.ie/
> ______________________________**_________________
> openwrt-devel mailing list
> [email protected].**org <[email protected]>
> https://lists.openwrt.org/**mailman/listinfo/openwrt-devel<https://lists.openwrt.org/mailman/listinfo/openwrt-devel>
>
_______________________________________________
openwrt-devel mailing list
[email protected]
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to