[PATCH 46/49] drivers/staging/vt6655: Convert printks to pr_<level>
Joe Perches
joe at perches.com
Thu Oct 15 01:54:30 UTC 2009
Signed-off-by: Joe Perches <joe at perches.com>
---
drivers/staging/vt6655/bssdb.c | 4 +-
drivers/staging/vt6655/device_cfg.h | 4 +-
drivers/staging/vt6655/device_main.c | 175 +++++++++++++++++++---------------
3 files changed, 104 insertions(+), 79 deletions(-)
diff --git a/drivers/staging/vt6655/bssdb.c b/drivers/staging/vt6655/bssdb.c
index 9535d44..b3498cd 100644
--- a/drivers/staging/vt6655/bssdb.c
+++ b/drivers/staging/vt6655/bssdb.c
@@ -934,11 +934,11 @@ BSSvUpdateAPNode(
pMgmt->sNodeDBTable[0].bShortPreamble = WLAN_GET_CAP_INFO_SHORTPREAMBLE(*pwCapInfo);
pMgmt->sNodeDBTable[0].uRatePollTimeout = FALLBACK_POLL_SECOND;
#ifdef PLICE_DEBUG
- printk("BSSvUpdateAPNode:MaxSuppRate is %d\n",pMgmt->sNodeDBTable[0].wMaxSuppRate);
+ printk("%s:MaxSuppRate is %d\n", __func__, pMgmt->sNodeDBTable[0].wMaxSuppRate);
#endif
// Auto rate fallback function initiation.
// RATEbInit(pDevice);
- DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"pMgmt->sNodeDBTable[0].wTxDataRate = %d \n", pMgmt->sNodeDBTable[0].wTxDataRate);
+ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "pMgmt->sNodeDBTable[0].wTxDataRate = %d \n", pMgmt->sNodeDBTable[0].wTxDataRate);
};
diff --git a/drivers/staging/vt6655/device_cfg.h b/drivers/staging/vt6655/device_cfg.h
index d1e9c19..8665997 100644
--- a/drivers/staging/vt6655/device_cfg.h
+++ b/drivers/staging/vt6655/device_cfg.h
@@ -93,8 +93,8 @@ typedef enum _chip_type{
#ifdef VIAWET_DEBUG
#define ASSERT(x) { \
if (!(x)) { \
- printk(KERN_ERR "assertion %s failed: file %s line %d\n", #x,\
- __FUNCTION__, __LINE__);\
+ pr_err("assertion %s failed: file %s line %d\n", #x, \
+ __FUNCTION__, __LINE__); \
*(int*) 0=0;\
}\
}
diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c
index 53450b4..d0e0939 100644
--- a/drivers/staging/vt6655/device_main.c
+++ b/drivers/staging/vt6655/device_main.c
@@ -58,6 +58,9 @@
*
* Revision History:
*/
+
+#define pr_fmt(fmt) "vt6655: " fmt
+
#undef __NO_VERSION__
#include "device.h"
@@ -573,14 +576,19 @@ static void device_init_registers(PSDevice pDevice, DEVICE_INIT_TYPE InitType)
else
pDevice->bTxRxAntInv = FALSE;
#ifdef PLICE_DEBUG
- //printk("init_register:TxRxAntInv is %d,byValue is %d\n",pDevice->bTxRxAntInv,byValue);
+#if 0
+ pr_info("%s():TxRxAntInv is %d,byValue is %d\n",
+ __func__, pDevice->bTxRxAntInv, byValue);
+#endif
#endif
byValue &= (EEP_ANTENNA_AUX | EEP_ANTENNA_MAIN);
if (byValue == 0) // if not set default is All
byValue = (EEP_ANTENNA_AUX | EEP_ANTENNA_MAIN);
#ifdef PLICE_DEBUG
- //printk("init_register:byValue is %d\n",byValue);
+#if 0
+ pr_info("%s():byValue is %d\n", __func__, byValue);
+#endif
#endif
pDevice->ulDiversityNValue = 100*260;//100*SROMbyReadEmbedded(pDevice->PortOffset, 0x51);
pDevice->ulDiversityMValue = 100*16;//SROMbyReadEmbedded(pDevice->PortOffset, 0x52);
@@ -606,7 +614,10 @@ byValue1 = SROMbyReadEmbedded(pDevice->PortOffset, EEP_OFS_ANTENNA);
else
pDevice->bDiversityEnable = TRUE;
#ifdef PLICE_DEBUG
- //printk("aux |main antenna: RxAntennaMode is %d\n",pDevice->byRxAntennaMode);
+#if 0
+ pr_info("aux |main antenna: RxAntennaMode is %d\n",
+ pDevice->byRxAntennaMode);
+#endif
#endif
} else {
pDevice->bDiversityEnable = FALSE;
@@ -628,7 +639,10 @@ byValue1 = SROMbyReadEmbedded(pDevice->PortOffset, EEP_OFS_ANTENNA);
}
}
#ifdef PLICE_DEBUG
- //printk("init registers: TxAntennaMode is %d\n",pDevice->byTxAntennaMode);
+#if 0
+ pr_info("%s(): TxAntennaMode is %d\n",
+ __func__, pDevice->byTxAntennaMode);
+#endif
#endif
DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "bDiversityEnable=[%d],NValue=[%d],MValue=[%d],TMax=[%d],TMax2=[%d]\n",
pDevice->bDiversityEnable,(int)pDevice->ulDiversityNValue,(int)pDevice->ulDiversityMValue,pDevice->byTMax,pDevice->byTMax2);
@@ -659,13 +673,16 @@ byValue1 = SROMbyReadEmbedded(pDevice->PortOffset, EEP_OFS_ANTENNA);
else
{
if(zonetype!=pDevice->abyEEPROM[EEP_OFS_ZONETYPE])
- printk("zonetype in file[%02x] mismatch with in EEPROM[%02x]\n",zonetype,pDevice->abyEEPROM[EEP_OFS_ZONETYPE]);
+ pr_info("zonetype in file[%02x] mismatch with in EEPROM[%02x]\n",
+ zonetype,pDevice->abyEEPROM[EEP_OFS_ZONETYPE]);
else
- printk("Read Zonetype file sucess,use default zonetype setting[%02x]\n",zonetype);
+ pr_info("Read Zonetype file sucess,use default zonetype setting[%02x]\n",
+ zonetype);
}
}
else
- printk("Read Zonetype file fail,use default zonetype setting[%02x]\n",SROMbyReadEmbedded(pDevice->PortOffset, EEP_OFS_ZONETYPE));
+ pr_info("Read Zonetype file fail,use default zonetype setting[%02x]\n",
+ SROMbyReadEmbedded(pDevice->PortOffset, EEP_OFS_ZONETYPE));
// Get RFType
pDevice->byRFType = SROMbyReadEmbedded(pDevice->PortOffset, EEP_OFS_RFTYPE);
@@ -693,8 +710,8 @@ else
//byCCKPwrdBm = SROMbyReadEmbedded(pDevice->PortOffset, EEP_OFS_CCK_PWR_dBm);
//byOFDMPwrdBm = SROMbyReadEmbedded(pDevice->PortOffset, EEP_OFS_OFDM_PWR_dBm);
-//printk("CCKPwrdBm is 0x%x,byOFDMPwrdBm is 0x%x\n",byCCKPwrdBm,byOFDMPwrdBm);
- // Load power Table
+ //pr_info("CCKPwrdBm is 0x%x,byOFDMPwrdBm is 0x%x\n",byCCKPwrdBm,byOFDMPwrdBm);
+ // Load power Table
for (ii=0;ii<CB_MAX_CHANNEL_24G;ii++) {
@@ -758,7 +775,10 @@ else
BBvSetVGAGainOffset(pDevice, pDevice->abyBBVGA[0]);
}
#ifdef PLICE_DEBUG
- //printk("init registers:RxAntennaMode is %x,TxAntennaMode is %x\n",pDevice->byRxAntennaMode,pDevice->byTxAntennaMode);
+#if 0
+ pr_info("%s():RxAntennaMode is %x,TxAntennaMode is %x\n",
+ __func__, pDevice->byRxAntennaMode, pDevice->byTxAntennaMode);
+#endif
#endif
BBvSetRxAntennaMode(pDevice->PortOffset, pDevice->byRxAntennaMode);
BBvSetTxAntennaMode(pDevice->PortOffset, pDevice->byTxAntennaMode);
@@ -920,8 +940,8 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
PCHIP_INFO pChip_info = (PCHIP_INFO)ent->driver_data;
PSDevice pDevice;
int rc;
- if (device_nics ++>= MAX_UINTS) {
- printk(KERN_NOTICE DEVICE_NAME ": already found %d NICs\n", device_nics);
+ if (device_nics++ >= MAX_UINTS) {
+ pr_notice("already found %d NICs\n", device_nics);
return -ENODEV;
}
@@ -931,7 +951,7 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
pDevice = (PSDevice) netdev_priv(dev);
if (dev == NULL) {
- printk(KERN_ERR DEVICE_NAME ": allocate net device failed \n");
+ pr_err("allocate net device failed \n");
return -ENODEV;
}
@@ -940,8 +960,8 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
SET_NETDEV_DEV(dev, &pcid->dev);
if (bFirst) {
- printk(KERN_NOTICE "%s Ver. %s\n",DEVICE_FULL_DRV_NAM, DEVICE_VERSION);
- printk(KERN_NOTICE "Copyright (c) 2003 VIA Networking Technologies, Inc.\n");
+ pr_notice("%s Ver. %s\n",DEVICE_FULL_DRV_NAM, DEVICE_VERSION);
+ pr_notice("Copyright (c) 2003 VIA Networking Technologies, Inc.\n");
bFirst=FALSE;
}
@@ -958,10 +978,10 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
return -ENODEV;
}
#ifdef DEBUG
- printk("Before get pci_info memaddr is %x\n",pDevice->memaddr);
+ pr_info("Before get pci_info memaddr is %x\n", pDevice->memaddr);
#endif
if (device_get_pci_info(pDevice,pcid) == FALSE) {
- printk(KERN_ERR DEVICE_NAME ": Failed to find PCI device.\n");
+ pr_err("Failed to find PCI device.\n");
device_free_info(pDevice);
return -ENODEV;
}
@@ -971,7 +991,8 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
#ifdef DEBUG
//pci_read_config_byte(pcid, PCI_BASE_ADDRESS_0, &pDevice->byRevId);
- printk("after get pci_info memaddr is %x, io addr is %x,io_size is %d\n",pDevice->memaddr,pDevice->ioaddr,pDevice->io_size);
+ pr_info("after get pci_info memaddr is %x, io addr is %x,io_size is %d\n",
+ pDevice->memaddr, pDevice->ioaddr, pDevice->io_size);
{
int i;
U32 bar,len;
@@ -987,10 +1008,10 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
{
//pci_write_config_dword(pcid,address[i], 0xFFFFFFFF);
pci_read_config_dword(pcid, address[i], &bar);
- printk("bar %d is %x\n",i,bar);
+ pr_info("bar %d is %x\n", i, bar);
if (!bar)
{
- printk("bar %d not implemented\n",i);
+ pr_info("bar %d not implemented\n", i);
continue;
}
if (bar & PCI_BASE_ADDRESS_SPACE_IO) {
@@ -999,14 +1020,14 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
len = bar & (PCI_BASE_ADDRESS_IO_MASK & 0xFFFF);
len = len & ~(len - 1);
- printk("IO space: len in IO %x, BAR %d\n", len, i);
+ pr_info("IO space: len in IO %x, BAR %d\n", len, i);
}
else
{
len = bar & 0xFFFFFFF0;
len = ~len + 1;
- printk("len in MEM %x, BAR %d\n", len, i);
+ pr_info("len in MEM %x, BAR %d\n", len, i);
}
}
}
@@ -1022,7 +1043,7 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
//pDevice->PortOffset = (DWORD)ioremap(pDevice->ioaddr & PCI_BASE_ADDRESS_IO_MASK, pDevice->io_size);
if(pDevice->PortOffset == 0) {
- printk(KERN_ERR DEVICE_NAME ": Failed to IO remapping ..\n");
+ pr_err("Failed to IO remapping ..\n");
device_free_info(pDevice);
return -ENODEV;
}
@@ -1032,7 +1053,7 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
rc = pci_request_regions(pcid, DEVICE_NAME);
if (rc) {
- printk(KERN_ERR DEVICE_NAME ": Failed to find PCI device\n");
+ pr_err("Failed to find PCI device\n");
device_free_info(pDevice);
return -ENODEV;
}
@@ -1042,11 +1063,11 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
BYTE value;
VNSvInPortB(pDevice->PortOffset+0x4F, &value);
- printk("Before write: value is %x\n",value);
+ pr_info("Before write: value is %x\n",value);
//VNSvInPortB(pDevice->PortOffset+0x3F, 0x00);
VNSvOutPortB(pDevice->PortOffset,value);
VNSvInPortB(pDevice->PortOffset+0x4F, &value);
- printk("After write: value is %x\n",value);
+ pr_info("After write: value is %x\n",value);
#endif
@@ -1056,7 +1077,7 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
#endif
// do reset
if (!MACbSoftwareReset(pDevice->PortOffset)) {
- printk(KERN_ERR DEVICE_NAME ": Failed to access MAC hardware..\n");
+ pr_err("Failed to access MAC hardware..\n");
device_free_info(pDevice);
return -ENODEV;
}
@@ -1080,17 +1101,16 @@ device_found1(struct pci_dev *pcid, const struct pci_device_id *ent)
dev->wireless_handlers = (struct iw_handler_def *)&iwctl_handler_def;
- rc = register_netdev(dev);
- if (rc)
- {
- printk(KERN_ERR DEVICE_NAME " Failed to register netdev\n");
- device_free_info(pDevice);
- return -ENODEV;
- }
+ rc = register_netdev(dev);
+ if (rc) {
+ pr_err("Failed to register netdev\n");
+ device_free_info(pDevice);
+ return -ENODEV;
+ }
//2008-07-21-01<Add>by MikeLiu
//register wpadev
if(wpa_set_wpadev(pDevice, 1)!=0) {
- printk("Fail to Register WPADEV?\n");
+ pr_info("Fail to Register WPADEV?\n");
unregister_netdev(pDevice->dev);
free_netdev(dev);
}
@@ -1184,13 +1204,13 @@ static BOOL device_get_pci_info(PSDevice pDevice, struct pci_dev* pcid) {
#ifdef PLICE_DEBUG
//pci_read_config_word(pcid,PCI_MAX_LAT,&max_lat);
- //printk("max lat is %x,SubSystemID is %x\n",max_lat,pDevice->SubSystemID);
+ //pr_info("max lat is %x,SubSystemID is %x\n",max_lat,pDevice->SubSystemID);
//for (ii=0;ii<0xFF;ii++)
//pci_read_config_word(pcid,PCI_MAX_LAT,&max_lat);
//max_lat = 0x20;
//pci_write_config_word(pcid,PCI_MAX_LAT,max_lat);
//pci_read_config_word(pcid,PCI_MAX_LAT,&max_lat);
- //printk("max lat is %x\n",max_lat);
+ //pr_info("max lat is %x\n",max_lat);
for (ii=0;ii<0xFF;ii++)
{
@@ -1199,14 +1219,14 @@ static BOOL device_get_pci_info(PSDevice pDevice, struct pci_dev* pcid) {
}
for (ii=0,j=1;ii<0x100;ii++,j++)
{
- if (j %16 == 0)
+ if (j % 16 == 0)
{
- printk("%x:",pci_config[ii]);
- printk("\n");
+ pr_cont("%x:",pci_config[ii]);
+ pr_cont("\n");
}
else
{
- printk("%x:",pci_config[ii]);
+ pr_cont("%x:",pci_config[ii]);
}
}
#endif
@@ -1224,7 +1244,7 @@ device_release_WPADEV(pDevice);
//2008-07-21-01<Add>by MikeLiu
//unregister wpadev
if(wpa_set_wpadev(pDevice, 0)!=0)
- printk("unregister wpadev fail?\n");
+ pr_info("unregister wpadev fail?\n");
if (pDevice_Infos==NULL)
return;
@@ -1627,7 +1647,9 @@ static BOOL device_alloc_rx_buf(PSDevice pDevice, PSRxDesc pRD) {
pRDInfo->skb = dev_alloc_skb((int)pDevice->rx_buf_sz);
#ifdef PLICE_DEBUG
- //printk("device_alloc_rx_buf:skb is %x\n",pRDInfo->skb);
+#if 0
+ pr_info("%s():skb is %x\n", __func__, pRDInfo->skb);
+#endif
#endif
if (pRDInfo->skb==NULL)
return FALSE;
@@ -1850,15 +1872,15 @@ INT MlmeThread(
PSRxMgmtPacket pRxMgmtPacket;
// int i ;
//complete(&pDevice->notify);
-//printk("Enter MngWorkItem,Queue packet num is %d\n",pDevice->rxManeQueue.packet_num);
+//pr_info("Enter MngWorkItem,Queue packet num is %d\n",pDevice->rxManeQueue.packet_num);
- //printk("Enter MlmeThread,packet _num is %d\n",pDevice->rxManeQueue.packet_num);
+ //pr_info("Enter MlmeThread,packet _num is %d\n",pDevice->rxManeQueue.packet_num);
//i = 0;
#if 1
while (1)
{
- //printk("DDDD\n");
+ //pr_info("DDDD\n");
//down(&pDevice->mlme_semaphore);
// pRxMgmtPacket = DeQueue(pDevice);
#if 1
@@ -1869,7 +1891,7 @@ INT MlmeThread(
//pDevice;
//DequeueManageObject(pDevice->FirstRecvMngList, pDevice->LastRecvMngList);
vMgrRxManagePacket(pDevice, pDevice->pMgmt, pRxMgmtPacket);
- //printk("packet_num is %d\n",pDevice->rxManeQueue.packet_num);
+ //pr_info("packet_num is %d\n",pDevice->rxManeQueue.packet_num);
}
spin_unlock_irq(&pDevice->lock);
@@ -1877,7 +1899,7 @@ INT MlmeThread(
break;
//udelay(200);
#endif
- //printk("Before schedule thread jiffies is %x\n",jiffies);
+ //pr_info("Before schedule thread jiffies is %x\n",jiffies);
schedule();
//printk("after schedule thread jiffies is %x\n",jiffies);
if (mlme_kill == 0)
@@ -1940,7 +1962,7 @@ device_init_rd0_ring(pDevice);
mlme_kill = 0;
mlme_task = kthread_run(MlmeThread,(void *) pDevice, "MLME");
if (IS_ERR(mlme_task)) {
- printk("thread create fail\n");
+ pr_info("thread create fail\n");
return -1;
}
@@ -1953,13 +1975,13 @@ device_init_rd0_ring(pDevice);
pDevice->MLMEThr_pid = kernel_thread(MlmeThread, pDevice, CLONE_VM);
if (pDevice->MLMEThr_pid <0 )
{
- printk("unable start thread MlmeThread\n");
+ pr_info("unable start thread MlmeThread\n");
return -1;
}
#endif
- //printk("thread id is %d\n",pDevice->MLMEThr_pid);
- //printk("Create thread time is %x\n",jiffies);
+ //pr_info("thread id is %d\n",pDevice->MLMEThr_pid);
+ //pr_info("Create thread time is %x\n",jiffies);
//wait_for_completion(&pDevice->notify);
@@ -2003,7 +2025,7 @@ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "call device_init_registers\n");
pDevice->eEncryptionStatus = Ndis802_11Encryption1Enabled;
}
-//printk("DEBUG2\n");
+//pr_info("DEBUG2\n");
DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "call MACvIntEnable\n");
@@ -2446,7 +2468,8 @@ static int device_xmit(struct sk_buff *skb, struct net_device *dev) {
if (pDevice->bFixRate) {
#ifdef PLICE_DEBUG
- printk("Fix Rate: PhyType is %d,ConnectionRate is %d\n",pDevice->eCurrentPHYType,pDevice->uConnectionRate);
+ pr_info("Fix Rate: PhyType is %d,ConnectionRate is %d\n",
+ pDevice->eCurrentPHYType, pDevice->uConnectionRate);
#endif
if (pDevice->eCurrentPHYType == PHY_TYPE_11B) {
@@ -2495,7 +2518,7 @@ static int device_xmit(struct sk_buff *skb, struct net_device *dev) {
&(pDevice->byTopOFDMBasicRate));
#if 0
-printk("auto rate:Rate : %d,AckRate:%d,TopCCKRate:%d,TopOFDMRate:%d\n",
+pr_info("auto rate:Rate : %d,AckRate:%d,TopCCKRate:%d,TopOFDMRate:%d\n",
pDevice->wCurrentRate,pDevice->byACKRate,
pDevice->byTopCCKBasicRate,pDevice->byTopOFDMBasicRate);
@@ -2528,24 +2551,24 @@ pDevice->byTopCCKBasicRate,pDevice->byTopOFDMBasicRate);
}
//#ifdef PLICE_DEBUG
-// printk("FIX RATE:CurrentRate is %d");
+// pr_info("FIX RATE:CurrentRate is %d");
//#endif
if (bNeedEncryption == TRUE) {
- DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"ntohs Pkt Type=%04x\n", ntohs(pDevice->sTxEthHeader.wType));
+ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "ntohs Pkt Type=%04x\n", ntohs(pDevice->sTxEthHeader.wType));
if ((pDevice->sTxEthHeader.wType) == TYPE_PKT_802_1x) {
bNeedEncryption = FALSE;
- DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"Pkt Type=%04x\n", (pDevice->sTxEthHeader.wType));
+ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "Pkt Type=%04x\n", (pDevice->sTxEthHeader.wType));
if ((pDevice->pMgmt->eCurrMode == WMAC_MODE_ESS_STA) && (pDevice->pMgmt->eCurrState == WMAC_STATE_ASSOC)) {
if (pTransmitKey == NULL) {
- DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"Don't Find TX KEY\n");
+ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "Don't Find TX KEY\n");
}
else {
if (bTKIP_UseGTK == TRUE) {
- DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"error: KEY is GTK!!~~\n");
+ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "error: KEY is GTK!!~~\n");
}
else {
- DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"Find PTK [%lX]\n", pTransmitKey->dwKeyIndex);
+ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "Find PTK [%lX]\n", pTransmitKey->dwKeyIndex);
bNeedEncryption = TRUE;
}
}
@@ -2566,7 +2589,7 @@ pDevice->byTopCCKBasicRate,pDevice->byTopOFDMBasicRate);
}
else {
if (pTransmitKey == NULL) {
- DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"return no tx key\n");
+ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "return no tx key\n");
dev_kfree_skb_irq(skb);
spin_unlock_irq(&pDevice->lock);
return 0;
@@ -2578,7 +2601,7 @@ pDevice->byTopCCKBasicRate,pDevice->byTopOFDMBasicRate);
#ifdef PLICE_DEBUG
//if (skb->len == 98)
//{
- // printk("ping:len is %d\n");
+ // pr_info("ping:len is %d\n");
//}
#endif
vGenerateFIFOHeader(pDevice, byPktType, pDevice->pbyTmpBuff, bNeedEncryption,
@@ -2621,11 +2644,13 @@ pDevice->byTopCCKBasicRate,pDevice->byTopOFDMBasicRate);
//#ifdef PLICE_DEBUG
if (pDevice->bFixRate)
{
- printk("FixRate:Rate is %d,TxPower is %d\n",pDevice->wCurrentRate,pDevice->byCurPwr);
+ pr_info("FixRate:Rate is %d,TxPower is %d\n",
+ pDevice->wCurrentRate, pDevice->byCurPwr);
}
else
{
- //printk("Auto Rate:Rate is %d,TxPower is %d\n",pDevice->wCurrentRate,pDevice->byCurPwr);
+// pr_info("Auto Rate:Rate is %d,TxPower is %d\n",
+// pDevice->wCurrentRate,pDevice->byCurPwr);
}
//#endif
@@ -2648,10 +2673,10 @@ BOOL bTxeapol_key = FALSE;
(Key_info & BIT8) && (Key_info & BIT9)) { //send 2/2 key
pDevice->fWPA_Authened = TRUE;
if(Descriptor_type==254)
- printk("WPA ");
+ pr_info("WPA ");
else
- printk("WPA2 ");
- printk("Authentication completed!!\n");
+ pr_info("WPA2 ");
+ pr_cont("Authentication completed!!\n");
}
}
}
@@ -3013,32 +3038,32 @@ int Config_FileOperation(PSDevice pDevice,BOOL fwrite,unsigned char *Parameter)
//open file
filp = filp_open(config_path, O_RDWR, 0);
if (IS_ERR(filp)) {
- printk("Config_FileOperation:open file fail?\n");
+ pr_info("Config_FileOperation:open file fail?\n");
result=-1;
goto error2;
}
if(!(filp->f_op) || !(filp->f_op->read) ||!(filp->f_op->write)) {
- printk("file %s cann't readable or writable?\n",config_path);
+ pr_info("file %s cann't readable or writable?\n",config_path);
result = -1;
goto error1;
}
buffer = (UCHAR *)kmalloc(1024, GFP_KERNEL);
if(buffer==NULL) {
- printk("alllocate mem for file fail?\n");
+ pr_info("alllocate mem for file fail?\n");
result = -1;
goto error1;
}
if(filp->f_op->read(filp, buffer, 1024, &filp->f_pos)<0) {
- printk("read file error?\n");
+ pr_info("read file error?\n");
result = -1;
goto error1;
}
if(Config_FileGetParameter("ZONETYPE",tmpbuffer,buffer)!=TRUE) {
- printk("get parameter error?\n");
+ pr_info("get parameter error?\n");
result = -1;
goto error1;
}
@@ -3054,7 +3079,7 @@ else if(memcmp(tmpbuffer,"EUROPE",5)==0) {
}
else {
result = -1;
- printk("Unknown Zonetype[%s]?\n",tmpbuffer);
+ pr_info("Unknown Zonetype[%s]?\n",tmpbuffer);
}
error1:
@@ -3062,7 +3087,7 @@ error1:
kfree(buffer);
if(filp_close(filp,NULL))
- printk("Config_FileOperation:close file fail\n");
+ pr_info("Config_FileOperation:close file fail\n");
error2:
set_fs (old_fs);
--
1.6.5.rc3.dirty
More information about the devel
mailing list