码迷,mamicode.com
首页 > Web开发 > 详细

acer(宏基) Aspire E1-472G ubuntu-12.04下安装无线网卡驱动

时间:2015-03-01 18:30:00      阅读:328      评论:0      收藏:0      [点我收藏+]

标签:

本人前阶段时间买了个比较实惠的笔记本电脑acer(宏基) Aspire E1-472G,自带linux操作系统,由于工作需要便把操作系统换成了ubuntu12.04,但一直苦于没有无线网卡驱动。今天终于把这个问题给解决了,方法如下:

1,查看无线网卡型号:

~$ lspci -vnn | grep Wireless

我的无线网卡是:

02:00.0 Network controller [0280]: Qualcomm Atheros QCA9565 / AR9565 Wireless Network Adapter [168c:0036] (rev 01)

2.安装linux-headers-genericbuild-essential

~$ sudo apt-get install linux-headers-generic build-essential

3.下载驱动文件并安装:

~$ sudo -i wget https://www.kernel.org/pub/linux/kernel/projects/backports/stable/v3.9-rc4/compat-drivers-3.9-rc4-2-s.tar.bz2
~$ tar xvf compat-drivers-3.9-rc4-2-s.tar.bz2
~$ cd compat-drivers-3.9-rc4-2-s/
~$ ./scripts/driver-select ath9k
~$ make
然后发现报错了:
./scripts/gen-compat-autoconf.sh /home/renjie/Downloads/compat-drivers-3.9-rc4-2-s/.config /home/renjie/Downloads/compat-drivers-3.9-rc4-2-s/config.mk > include/linux/compat_autoconf.h
make -C /lib/modules/3.2.0-77-generic/build M=/home/renjie/Downloads/compat-drivers-3.9-rc4-2-s modules
make[1]: 正在进入目录 `/usr/src/linux-headers-3.2.0-77-generic‘
  CC [M]  /home/renjie/Downloads/compat-drivers-3.9-rc4-2-s/compat/main.o
In file included from /home/renjie/Downloads/compat-drivers-3.9-rc4-2-s/include/linux/compat-2.6.h:71:0,
                 from <命令行>:0:
/home/renjie/Downloads/compat-drivers-3.9-rc4-2-s/include/linux/compat-3.8.h:49:32: 错误: ‘kref_get_unless_zero’重定义
include/linux/kref.h:47:32: 附注: ‘kref_get_unless_zero’的上一个定义在此
make[3]: *** [/home/renjie/Downloads/compat-drivers-3.9-rc4-2-s/compat/main.o] 错误 1
make[2]: *** [/home/renjie/Downloads/compat-drivers-3.9-rc4-2-s/compat] 错误 2
make[1]: *** [_module_/home/renjie/Downloads/compat-drivers-3.9-rc4-2-s] 错误 2
make[1]:正在离开目录 `/usr/src/linux-headers-3.2.0-77-generic‘
make: *** [modules] 错误 2

错误解决:
打开
include/linux/compat-3.8.h,找到第49行:
static inline int __must_check kref_get_unless_zero(struct kref *kref)      
{
     return atomic_add_unless(&kref->refcount, 1, 0);
}
注释掉这个函数:
/*
static inline int __must_check kref_get_unless_zero(struct kref *kref)      
{
     return atomic_add_unless(&kref->refcount, 1, 0);
}
*/
接下来继续,

~$ make
~$ make install
~$ modprobe ath9k
然后你就会发现无线网卡可以用了(如果不行重启机器试试)。
详情可参考:http://askubuntu.com/questions/215498/how-to-install-qualcomm-atheros-ar9565-wireless-drivers 





acer(宏基) Aspire E1-472G ubuntu-12.04下安装无线网卡驱动

标签:

原文地址:http://blog.csdn.net/guan506713512/article/details/44003903

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!