LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 12-31-2011, 01:30 AM   #1
mah454
Member
 
Registered: Oct 2009
Location: Iran
Distribution: Debian , Ubuntu , RHEL , CentOS , NetBill
Posts: 134

Rep: Reputation: 15
compile compat-wireless


Hello ...
I use kernel 3.1.4 . and download compat-wireless-3.1.1-1 .
i extract and this package and use channel-negative-one-maxim.patch
Code:
patch -p1 < ../channel-negative-one-maxim.patch
patch success .
but in compile receive this message :

Code:
root@skynet:/data2/compat-wireless-3.1.1-1# make
make -C /lib/modules/3.1.4/build M=/data2/compat-wireless-3.1.1-1 modules
make[1]: Entering directory `/usr/src/linux-3.1.4'
  CC [M]  /data2/compat-wireless-3.1.1-1/net/wireless/util.o
/data2/compat-wireless-3.1.1-1/net/wireless/util.c: In function ‘cfg80211_change_iface’:
/data2/compat-wireless-3.1.1-1/net/wireless/util.c:804: error: implicit declaration of function ‘br_port_exists’
make[3]: *** [/data2/compat-wireless-3.1.1-1/net/wireless/util.o] Error 1
make[2]: *** [/data2/compat-wireless-3.1.1-1/net/wireless] Error 2
make[1]: *** [_module_/data2/compat-wireless-3.1.1-1] Error 2
make[1]: Leaving directory `/usr/src/linux-3.1.4'
make: *** [modules] Error 2
i search in internet but can not find any way for fix this problem !
 
Old 12-31-2011, 07:43 AM   #2
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
The error implicit declaration of function means that a function is referenced (used) before its declaration or when the function prototype is missing. Looking at the source code of compat-wireless-3.1.1-1 it seems the prototype of function br_port_exists is in the header linux/compat-3.1.h but this header is not included in util.c. I would try to add the proper include line (see text in bold) among the others in net/wireless/util.c:
Code:
#include <linux/bitops.h>
#include <linux/etherdevice.h>
#include <linux/slab.h>
#include <linux/compat-3.1.h>
#include <net/cfg80211.h>
#include <net/ip.h>
#include "core.h"
If this solves the issue, you may consider to submit a bug report to the developers of compat-wireless.

Moved: This thread is more suitable in Programming and has been moved accordingly to help your thread/question get the exposure it deserves.

Last edited by colucix; 12-31-2011 at 07:44 AM.
 
Old 01-01-2012, 12:29 AM   #3
mah454
Member
 
Registered: Oct 2009
Location: Iran
Distribution: Debian , Ubuntu , RHEL , CentOS , NetBill
Posts: 134

Original Poster
Rep: Reputation: 15
i have not this file !
Code:
/usr/include/linux/compat-3.1.h
 
Old 01-01-2012, 04:45 AM   #4
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
It's not a system file. The path is relative to the compat-wireless installation directory, that one you extracted from the downloaded tar.gz. If you look at the other include statements, you can see they refer to:
Code:

<path-with-extracted-tarball>/compat-wireless-3.1.1-1/include/linux/bitops.h
<path-with-extracted-tarball>/compat-wireless-3.1.1-1/include/linux/etherdevice.h
<path-with-extracted-tarball>/compat-wireless-3.1.1-1/include/linux/slab.h
<path-with-extracted-tarball>/compat-wireless-3.1.1-1/include/linux/compat-3.1.h
 
Old 01-01-2012, 06:02 AM   #5
mah454
Member
 
Registered: Oct 2009
Location: Iran
Distribution: Debian , Ubuntu , RHEL , CentOS , NetBill
Posts: 134

Original Poster
Rep: Reputation: 15
opss !
sorry ..
I do this ! but not work !
 
Old 01-01-2012, 09:51 AM   #6
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
Is it exactly the same error message?
 
Old 01-01-2012, 11:22 PM   #7
mah454
Member
 
Registered: Oct 2009
Location: Iran
Distribution: Debian , Ubuntu , RHEL , CentOS , NetBill
Posts: 134

Original Poster
Rep: Reputation: 15
Error replayed ... !

Code:
  CC [M]  /data2/compat-wireless-3.1.1-1/net/mac80211/mesh_hwmp.o
  CC [M]  /data2/compat-wireless-3.1.1-1/net/mac80211/pm.o
  CC [M]  /data2/compat-wireless-3.1.1-1/net/mac80211/rc80211_pid_algo.o
  CC [M]  /data2/compat-wireless-3.1.1-1/net/mac80211/rc80211_minstrel.o
  CC [M]  /data2/compat-wireless-3.1.1-1/net/mac80211/rc80211_minstrel_ht.o
  LD [M]  /data2/compat-wireless-3.1.1-1/net/mac80211/mac80211.o
  LD      /data2/compat-wireless-3.1.1-1/net/rfkill/built-in.o
  LD      /data2/compat-wireless-3.1.1-1/net/wireless/built-in.o
  CC [M]  /data2/compat-wireless-3.1.1-1/net/wireless/core.o
/data2/compat-wireless-3.1.1-1/net/wireless/core.c:7:1: warning: "pr_fmt" redefined
In file included from /data2/compat-wireless-3.1.1-1/include/linux/printk.h:7,
                 from include/linux/kernel.h:20,
                 from include/linux/skbuff.h:17,
                 from include/linux/if_ether.h:131,
                 from include/linux/netdevice.h:29,
                 from /data2/compat-wireless-3.1.1-1/include/linux/compat-2.6.29.h:5,
                 from /data2/compat-wireless-3.1.1-1/include/linux/compat-2.6.h:24,
                 from <command-line>:0:
include/linux/printk.h:152:1: warning: this is the location of the previous definition
/data2/compat-wireless-3.1.1-1/net/wireless/core.c:7:1: warning: "pr_fmt" redefined
In file included from /data2/compat-wireless-3.1.1-1/include/linux/printk.h:7,
                 from include/linux/kernel.h:20,
                 from include/linux/skbuff.h:17,
                 from include/linux/if_ether.h:131,
                 from include/linux/netdevice.h:29,
                 from /data2/compat-wireless-3.1.1-1/include/linux/compat-2.6.29.h:5,
                 from /data2/compat-wireless-3.1.1-1/include/linux/compat-2.6.h:24,
                 from <command-line>:0:
include/linux/printk.h:152:1: warning: this is the location of the previous definition
  CC [M]  /data2/compat-wireless-3.1.1-1/net/wireless/sysfs.o
  CC [M]  /data2/compat-wireless-3.1.1-1/net/wireless/radiotap.o
  CC [M]  /data2/compat-wireless-3.1.1-1/net/wireless/util.o
/data2/compat-wireless-3.1.1-1/net/wireless/util.c: In function ‘cfg80211_change_iface’:
/data2/compat-wireless-3.1.1-1/net/wireless/util.c:805: error: implicit declaration of function ‘br_port_exists’
make[3]: *** [/data2/compat-wireless-3.1.1-1/net/wireless/util.o] Error 1
make[2]: *** [/data2/compat-wireless-3.1.1-1/net/wireless] Error 2
make[1]: *** [_module_/data2/compat-wireless-3.1.1-1] Error 2
make[1]: Leaving directory `/usr/src/linux-3.1.4'
make: *** [modules] Error 2
 
Old 01-01-2012, 11:43 PM   #8
mah454
Member
 
Registered: Oct 2009
Location: Iran
Distribution: Debian , Ubuntu , RHEL , CentOS , NetBill
Posts: 134

Original Poster
Rep: Reputation: 15
Fixed ... !
I patch this files :
mac80211.compat08082009.wl_frag+ack_v1.patch
channel-negative-one-maxim.patch

comment lines from : compat-wireless-3.1.1-1/net/wireless/nl80211.c
Code:
if (!use_4addr) {
     if (netdev && br_port_exists(netdev))
       return -EBUSY;
     return 0;
}
and this file : compat-wireless-3.1.1-1/net/wireless/util.c
Code:
if (br_port_exists(dev) &&
       (ntype == NL80211_IFTYPE_ADHOC ||
        ntype == NL80211_IFTYPE_STATION ||
        ntype == NL80211_IFTYPE_P2P_CLIENT))
     return -EBUSY;
compile and worked ... !
 
Old 01-02-2012, 02:19 AM   #9
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
Well done!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] compat-wireless compile error kaz2100 Linux - Software 1 10-24-2010 08:36 AM
Compile Compat-wireless mah454 Linux - Networking 2 09-25-2010 10:55 AM
compat-wireless driver wont compile for my rtl8187 wlan chipset fakie_flip Linux - Hardware 1 10-01-2009 09:24 PM
COMPAT-WIRELESS location? lxquestions000019 Linux - Newbie 0 08-24-2009 05:31 PM
compat-wireless error... ott0disk Linux - Wireless Networking 5 12-30-2008 01:38 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 12:56 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration