文档库

最新最全的文档下载
当前位置:文档库 > S3C6410 无线网卡移植 VT5565和ZyDAS

S3C6410 无线网卡移植 VT5565和ZyDAS

VT5565型号无限网卡移植

基于2.6.38内核

1下载驱动代码

从http://www.wendangku.net/doc/f2d2d7ea0975f46527d3e14b.html /Driver/VT6656_linux_src_v1.20.03_x86.rar 下载VNT6656驱动源代码并解压缩.(在Linux下你需要安装"unrar");

2修改配置文件drivers/main_usb.c

在drivers/main_usb.c中加入头文件(139行附近)(在下载的代码内部)

//============yaoyafei===================

#include

//=====================================

替换如下代码,注释掉的被替换为黄色背景的(2067行附近):

static void device_set_multi(struct net_device *dev) {

PSDevice pDevice = (PSDevice)VNT_NETDEV_GET_PRIV(dev);

PSMgmtObject pMgmt = &(pDevice->sMgmtObj);

u32 mc_filter[2];

int ii;

//===================yaoyafei==========

// struct dev_mc_list *mclist;

struct netdev_hw_addr *ha;

//=================================

替换如下代码,注释掉的被替换为黄色背景的(2088行附近):

if (dev->flags & IFF_PROMISC) { // Set promiscuous.

DBG_PRT(MSG_LEVEL_ERR,KERN_NOTICE "%s: Promiscuous mode enabled.\n", dev->name);

// Unconditionally log net taps.

pDevice->byRxMode |= (RCR_MULTICAST|RCR_BROADCAST|RCR_UNICAST);

}

//================== yaoyafei ======================

// else if ((dev->mc_count > pDevice->multicast_limit) || (dev->flags & IFF_ALLMULTI))

{

else if ((netdev_mc_count(dev) > pDevice->multicast_limit) || (dev->flags &

IFF_ALLMULTI)) {

//===============================

注释掉如下代码(灰色背景部分),替换为黄色背景部分(2095行附近):

CONTROLnsRequestOut(pDevice,

MESSAGE_TYPE_WRITE,

MAC_REG_MAR0,

MESSAGE_REQUEST_MACREG,

8,

pbyData

);

pDevice->byRxMode |= (RCR_MULTICAST|RCR_BROADCAST);

免费下载Word文档免费下载: S3C6410 无线网卡移植 VT5565和ZyDAS

(共9页)