Commit 6df9f669 authored by Xenia Ragiadakou's avatar Xenia Ragiadakou Committed by Greg Kroah-Hartman

staging: rtl8192u: fix comments in r819xU_cmdpkt.c

This patches fixes comments by:
- replacing // comments with /**/ comments
- removing unnecessary comments (trailing comments
  with the function name, comments stating date/author
  when they are placed inside the function definition)
- fixing internal alignment
Signed-off-by: default avatarXenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent fa6b108b
/****************************************************************************** /******************************************************************************
*
(c) Copyright 2008, RealTEK Technologies Inc. All Rights Reserved. * (c) Copyright 2008, RealTEK Technologies Inc. All Rights Reserved.
*
Module: r819xusb_cmdpkt.c (RTL8190 TX/RX command packet handler Source C File) * Module: r819xusb_cmdpkt.c
* (RTL8190 TX/RX command packet handler Source C File)
Note: The module is responsible for handling TX and RX command packet. *
1. TX : Send set and query configuration command packet. * Note: The module is responsible for handling TX and RX command packet.
2. RX : Receive tx feedback, beacon state, query configuration * 1. TX : Send set and query configuration command packet.
command packet. * 2. RX : Receive tx feedback, beacon state, query configuration
* command packet.
Function: *
* Function:
Export: *
* Export:
Abbrev: *
* Abbrev:
History: *
Data Who Remark * History:
*
05/06/2008 amy Create initial version porting from windows driver. * Date Who Remark
* 05/06/2008 amy Create initial version porting from
******************************************************************************/ * windows driver.
*
******************************************************************************/
#include "r8192U.h" #include "r8192U.h"
#include "r819xU_cmdpkt.h" #include "r819xU_cmdpkt.h"
/*---------------------------Define Local Constant---------------------------*/
/* Debug constant*/ /* Debug constant */
#define CMPK_DEBOUNCE_CNT 1 #define CMPK_DEBOUNCE_CNT 1
/* 2007/10/24 MH Add for printing a range of data. */ /* Add for printing a range of data. */
#define CMPK_PRINT(Address)\ #define CMPK_PRINT(Address)\
{\ {\
unsigned char i;\ unsigned char i;\
...@@ -36,7 +38,6 @@ ...@@ -36,7 +38,6 @@
for (i = 0; i < 40; i += 4)\ for (i = 0; i < 40; i += 4)\
printk("\r\n %08x", temp[i]);\ printk("\r\n %08x", temp[i]);\
}\ }\
/*---------------------------Define functions---------------------------------*/
rt_status SendTxCommandPacket(struct net_device *dev, void *pData, u32 DataLen) rt_status SendTxCommandPacket(struct net_device *dev, void *pData, u32 DataLen)
{ {
...@@ -46,7 +47,8 @@ rt_status SendTxCommandPacket(struct net_device *dev, void *pData, u32 DataLen) ...@@ -46,7 +47,8 @@ rt_status SendTxCommandPacket(struct net_device *dev, void *pData, u32 DataLen)
cb_desc *tcb_desc; cb_desc *tcb_desc;
unsigned char *ptr_buf; unsigned char *ptr_buf;
//Get TCB and local buffer from common pool. (It is shared by CmdQ, MgntQ, and USB coalesce DataQ) /* Get TCB and local buffer from common pool.
(It is shared by CmdQ, MgntQ, and USB coalesce DataQ) */
skb = dev_alloc_skb(USB_HWDESC_HEADER_LEN + DataLen + 4); skb = dev_alloc_skb(USB_HWDESC_HEADER_LEN + DataLen + 4);
memcpy((unsigned char *)(skb->cb), &dev, sizeof(dev)); memcpy((unsigned char *)(skb->cb), &dev, sizeof(dev));
tcb_desc = (cb_desc *)(skb->cb + MAX_DEV_ADDR_SIZE); tcb_desc = (cb_desc *)(skb->cb + MAX_DEV_ADDR_SIZE);
...@@ -110,7 +112,7 @@ extern rt_status cmpk_message_handle_tx(struct net_device *dev, ...@@ -110,7 +112,7 @@ extern rt_status cmpk_message_handle_tx(struct net_device *dev,
u8 bLastIniPkt; u8 bLastIniPkt;
firmware_init_param(dev); firmware_init_param(dev);
//Fragmentation might be required /* Fragmentation might be required */
frag_threshold = pfirmware->cmdpacket_frag_thresold; frag_threshold = pfirmware->cmdpacket_frag_thresold;
do { do {
if ((buffer_len - frag_offset) > frag_threshold) { if ((buffer_len - frag_offset) > frag_threshold) {
...@@ -123,9 +125,8 @@ extern rt_status cmpk_message_handle_tx(struct net_device *dev, ...@@ -123,9 +125,8 @@ extern rt_status cmpk_message_handle_tx(struct net_device *dev,
} }
/* Allocate skb buffer to contain firmware info and tx descriptor info /* Allocate skb buffer to contain firmware info and tx
* add 4 to avoid packet appending overflow. descriptor info add 4 to avoid packet appending overflow. */
* */
#ifdef RTL8192U #ifdef RTL8192U
skb = dev_alloc_skb(USB_HWDESC_HEADER_LEN + frag_length + 4); skb = dev_alloc_skb(USB_HWDESC_HEADER_LEN + frag_length + 4);
#else #else
...@@ -168,15 +169,15 @@ extern rt_status cmpk_message_handle_tx(struct net_device *dev, ...@@ -168,15 +169,15 @@ extern rt_status cmpk_message_handle_tx(struct net_device *dev,
#endif #endif
} /* CMPK_Message_Handle_Tx */ }
/*----------------------------------------------------------------------------- /*-----------------------------------------------------------------------------
* Function: cmpk_counttxstatistic() * Function: cmpk_counttxstatistic()
* *
* Overview: * Overview:
* *
* Input: PADAPTER pAdapter - . * Input: PADAPTER pAdapter
* CMPK_TXFB_T *psTx_FB - . * CMPK_TXFB_T *psTx_FB
* *
* Output: NONE * Output: NONE
* *
...@@ -195,9 +196,9 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb) ...@@ -195,9 +196,9 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb)
pAdapter->HalFunc.GetHwRegHandler(pAdapter, HW_VAR_RF_STATE, (pu1Byte)(&rtState)); pAdapter->HalFunc.GetHwRegHandler(pAdapter, HW_VAR_RF_STATE, (pu1Byte)(&rtState));
// When RF is off, we should not count the packet for hw/sw synchronize /* When RF is off, we should not count the packet for hw/sw synchronize
// reason, ie. there may be a duration while sw switch is changed and hw reason, ie. there may be a duration while sw switch is changed and
// switch is being changed. 2006.12.04, by shien chang. hw switch is being changed. */
if (rtState == eRfOff) if (rtState == eRfOff)
return; return;
#endif #endif
...@@ -206,9 +207,9 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb) ...@@ -206,9 +207,9 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb)
if (pAdapter->bInHctTest) if (pAdapter->bInHctTest)
return; return;
#endif #endif
/* We can not know the packet length and transmit type: broadcast or uni /* We can not know the packet length and transmit type:
or multicast. So the relative statistics must be collected in tx broadcast or uni or multicast. So the relative statistics
feedback info. */ must be collected in tx feedback info. */
if (pstx_fb->tok) { if (pstx_fb->tok) {
priv->stats.txfeedbackok++; priv->stats.txfeedbackok++;
priv->stats.txoktotal++; priv->stats.txoktotal++;
...@@ -243,7 +244,7 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb) ...@@ -243,7 +244,7 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb)
priv->stats.txretrycount += pstx_fb->retry_cnt; priv->stats.txretrycount += pstx_fb->retry_cnt;
priv->stats.txfeedbackretry += pstx_fb->retry_cnt; priv->stats.txfeedbackretry += pstx_fb->retry_cnt;
} /* cmpk_CountTxStatistic */ }
...@@ -252,12 +253,12 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb) ...@@ -252,12 +253,12 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb)
* *
* Overview: The function is responsible for extract the message inside TX * Overview: The function is responsible for extract the message inside TX
* feedbck message from firmware. It will contain dedicated info in * feedbck message from firmware. It will contain dedicated info in
* ws-06-0063-rtl8190-command-packet-specification. Please * ws-06-0063-rtl8190-command-packet-specification.
* refer to chapter "TX Feedback Element". We have to read 20 bytes * Please refer to chapter "TX Feedback Element".
* in the command packet. * We have to read 20 bytes in the command packet.
* *
* Input: struct net_device * dev * Input: struct net_device *dev
* u8 * pmsg - Msg Ptr of the command packet. * u8 *pmsg - Msg Ptr of the command packet.
* *
* Output: NONE * Output: NONE
* *
...@@ -271,7 +272,7 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb) ...@@ -271,7 +272,7 @@ static void cmpk_count_txstatistic(struct net_device *dev, cmpk_txfb_t *pstx_fb)
static void cmpk_handle_tx_feedback(struct net_device *dev, u8 *pmsg) static void cmpk_handle_tx_feedback(struct net_device *dev, u8 *pmsg)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
cmpk_txfb_t rx_tx_fb; /* */ cmpk_txfb_t rx_tx_fb;
priv->stats.txfeedback++; priv->stats.txfeedback++;
...@@ -279,24 +280,22 @@ static void cmpk_handle_tx_feedback(struct net_device *dev, u8 *pmsg) ...@@ -279,24 +280,22 @@ static void cmpk_handle_tx_feedback(struct net_device *dev, u8 *pmsg)
/* It seems that FW use big endian(MIPS) and DRV use little endian in /* It seems that FW use big endian(MIPS) and DRV use little endian in
windows OS. So we have to read the content byte by byte or transfer windows OS. So we have to read the content byte by byte or transfer
endian type before copy the message copy. */ endian type before copy the message copy. */
/* 2007/07/05 MH Use pointer to transfer structure memory. */ /* Use pointer to transfer structure memory. */
memcpy((u8 *)&rx_tx_fb, pmsg, sizeof(cmpk_txfb_t)); memcpy((u8 *)&rx_tx_fb, pmsg, sizeof(cmpk_txfb_t));
/* 2. Use tx feedback info to count TX statistics. */ /* 2. Use tx feedback info to count TX statistics. */
cmpk_count_txstatistic(dev, &rx_tx_fb); cmpk_count_txstatistic(dev, &rx_tx_fb);
/* 2007/01/17 MH Comment previous method for TX statistic function. */ /* Comment previous method for TX statistic function. */
/* Collect info TX feedback packet to fill TCB. */ /* Collect info TX feedback packet to fill TCB. */
/* We can not know the packet length and transmit type: broadcast or uni /* We can not know the packet length and transmit type: broadcast or uni
or multicast. */ or multicast. */
} /* cmpk_Handle_Tx_Feedback */ }
void cmdpkt_beacontimerinterrupt_819xusb(struct net_device *dev) void cmdpkt_beacontimerinterrupt_819xusb(struct net_device *dev)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
u16 tx_rate; u16 tx_rate;
// /* 87B have to S/W beacon for DTM encryption_cmn. */
// 070117, rcnjko: 87B have to S/W beacon for DTM encryption_cmn.
//
if (priv->ieee80211->current_network.mode == IEEE_A || if (priv->ieee80211->current_network.mode == IEEE_A ||
priv->ieee80211->current_network.mode == IEEE_N_5G || priv->ieee80211->current_network.mode == IEEE_N_5G ||
(priv->ieee80211->current_network.mode == IEEE_N_24G && (!priv->ieee80211->pHTInfo->bCurSuppCCK))) { (priv->ieee80211->current_network.mode == IEEE_N_24G && (!priv->ieee80211->pHTInfo->bCurSuppCCK))) {
...@@ -307,7 +306,7 @@ void cmdpkt_beacontimerinterrupt_819xusb(struct net_device *dev) ...@@ -307,7 +306,7 @@ void cmdpkt_beacontimerinterrupt_819xusb(struct net_device *dev)
DMESG("send beacon frame tx rate is 1Mbpm\n"); DMESG("send beacon frame tx rate is 1Mbpm\n");
} }
rtl819xusb_beacon_tx(dev, tx_rate); // HW Beacon rtl819xusb_beacon_tx(dev, tx_rate); /* HW Beacon */
} }
...@@ -323,8 +322,8 @@ void cmdpkt_beacontimerinterrupt_819xusb(struct net_device *dev) ...@@ -323,8 +322,8 @@ void cmdpkt_beacontimerinterrupt_819xusb(struct net_device *dev)
* ws-07-0063-v06-rtl819x-command-packet-specification-070315.doc. * ws-07-0063-v06-rtl819x-command-packet-specification-070315.doc.
* Please refer to chapter "Interrupt Status Element". * Please refer to chapter "Interrupt Status Element".
* *
* Input: struct net_device *dev, * Input: struct net_device *dev
* u8* pmsg - Message Pointer of the command packet. * u8 *pmsg - Message Pointer of the command packet.
* *
* Output: NONE * Output: NONE
* *
...@@ -353,9 +352,9 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg) ...@@ -353,9 +352,9 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg)
} }
// Statistics of beacon for ad-hoc mode. /* Statistics of beacon for ad-hoc mode. */
if (priv->ieee80211->iw_mode == IW_MODE_ADHOC) { if (priv->ieee80211->iw_mode == IW_MODE_ADHOC) {
//2 maybe need endian transform? /* 2 maybe need endian transform? */
rx_intr_status.interrupt_status = *((u32 *)(pmsg + 4)); rx_intr_status.interrupt_status = *((u32 *)(pmsg + 4));
DMESG("interrupt status = 0x%x\n", rx_intr_status.interrupt_status); DMESG("interrupt status = 0x%x\n", rx_intr_status.interrupt_status);
...@@ -373,12 +372,12 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg) ...@@ -373,12 +372,12 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg)
} }
// Other informations in interrupt status we need? /* Other informations in interrupt status we need? */
DMESG("<---- cmpk_handle_interrupt_status()\n"); DMESG("<---- cmpk_handle_interrupt_status()\n");
} /* cmpk_handle_interrupt_status */ }
/*----------------------------------------------------------------------------- /*-----------------------------------------------------------------------------
...@@ -389,7 +388,7 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg) ...@@ -389,7 +388,7 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg)
* ws-06-0063-rtl8190-command-packet-specification. Please * ws-06-0063-rtl8190-command-packet-specification. Please
* refer to chapter "Beacon State Element". * refer to chapter "Beacon State Element".
* *
* Input: u8 * pmsg - Message Pointer of the command packet. * Input: u8 *pmsg - Message Pointer of the command packet.
* *
* Output: NONE * Output: NONE
* *
...@@ -402,7 +401,7 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg) ...@@ -402,7 +401,7 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg)
*---------------------------------------------------------------------------*/ *---------------------------------------------------------------------------*/
static void cmpk_handle_query_config_rx(struct net_device *dev, u8 *pmsg) static void cmpk_handle_query_config_rx(struct net_device *dev, u8 *pmsg)
{ {
cmpk_query_cfg_t rx_query_cfg; /* */ cmpk_query_cfg_t rx_query_cfg;
/* 1. Extract TX feedback info from RFD to temp structure buffer. */ /* 1. Extract TX feedback info from RFD to temp structure buffer. */
...@@ -419,7 +418,7 @@ static void cmpk_handle_query_config_rx(struct net_device *dev, u8 *pmsg) ...@@ -419,7 +418,7 @@ static void cmpk_handle_query_config_rx(struct net_device *dev, u8 *pmsg)
rx_query_cfg.mask = (pmsg[12] << 24) | (pmsg[13] << 16) | rx_query_cfg.mask = (pmsg[12] << 24) | (pmsg[13] << 16) |
(pmsg[14] << 8) | (pmsg[15] << 0); (pmsg[14] << 8) | (pmsg[15] << 0);
} /* cmpk_Handle_Query_Config_Rx */ }
/*----------------------------------------------------------------------------- /*-----------------------------------------------------------------------------
...@@ -450,9 +449,9 @@ static void cmpk_count_tx_status(struct net_device *dev, ...@@ -450,9 +449,9 @@ static void cmpk_count_tx_status(struct net_device *dev,
pAdapter->HalFunc.GetHwRegHandler(pAdapter, HW_VAR_RF_STATE, (pu1Byte)(&rtState)); pAdapter->HalFunc.GetHwRegHandler(pAdapter, HW_VAR_RF_STATE, (pu1Byte)(&rtState));
// When RF is off, we should not count the packet for hw/sw synchronize /* When RF is off, we should not count the packet for hw/sw synchronize
// reason, ie. there may be a duration while sw switch is changed and hw reason, ie. there may be a duration while sw switch is changed and
// switch is being changed. 2006.12.04, by shien chang. hw switch is being changed. */
if (rtState == eRfOff) if (rtState == eRfOff)
return; return;
#endif #endif
...@@ -480,7 +479,7 @@ static void cmpk_count_tx_status(struct net_device *dev, ...@@ -480,7 +479,7 @@ static void cmpk_count_tx_status(struct net_device *dev,
priv->stats.txbytesunicast += pstx_status->txuclength; priv->stats.txbytesunicast += pstx_status->txuclength;
priv->stats.last_packet_rate = pstx_status->rate; priv->stats.last_packet_rate = pstx_status->rate;
} /* cmpk_CountTxStatus */ }
...@@ -503,13 +502,13 @@ static void cmpk_count_tx_status(struct net_device *dev, ...@@ -503,13 +502,13 @@ static void cmpk_count_tx_status(struct net_device *dev,
*---------------------------------------------------------------------------*/ *---------------------------------------------------------------------------*/
static void cmpk_handle_tx_status(struct net_device *dev, u8 *pmsg) static void cmpk_handle_tx_status(struct net_device *dev, u8 *pmsg)
{ {
cmpk_tx_status_t rx_tx_sts; /* */ cmpk_tx_status_t rx_tx_sts;
memcpy((void *)&rx_tx_sts, (void *)pmsg, sizeof(cmpk_tx_status_t)); memcpy((void *)&rx_tx_sts, (void *)pmsg, sizeof(cmpk_tx_status_t));
/* 2. Use tx feedback info to count TX statistics. */ /* 2. Use tx feedback info to count TX statistics. */
cmpk_count_tx_status(dev, &rx_tx_sts); cmpk_count_tx_status(dev, &rx_tx_sts);
} /* cmpk_Handle_Tx_Status */ }
/*----------------------------------------------------------------------------- /*-----------------------------------------------------------------------------
...@@ -540,19 +539,17 @@ static void cmpk_handle_tx_rate_history(struct net_device *dev, u8 *pmsg) ...@@ -540,19 +539,17 @@ static void cmpk_handle_tx_rate_history(struct net_device *dev, u8 *pmsg)
#ifdef ENABLE_PS #ifdef ENABLE_PS
pAdapter->HalFunc.GetHwRegHandler(pAdapter, HW_VAR_RF_STATE, (pu1Byte)(&rtState)); pAdapter->HalFunc.GetHwRegHandler(pAdapter, HW_VAR_RF_STATE, (pu1Byte)(&rtState));
// When RF is off, we should not count the packet for hw/sw synchronize /* When RF is off, we should not count the packet for hw/sw synchronize
// reason, ie. there may be a duration while sw switch is changed and hw reason, ie. there may be a duration while sw switch is changed and
// switch is being changed. 2006.12.04, by shien chang. hw switch is being changed. */
if (rtState == eRfOff) if (rtState == eRfOff)
return; return;
#endif #endif
ptemp = (u32 *)pmsg; ptemp = (u32 *)pmsg;
// /* Do endian transfer to word alignment(16 bits) for windows system.
// Do endian transfer to word alignment(16 bits) for windows system. You must do different endian transfer for linux and MAC OS */
// You must do different endian transfer for linux and MAC OS
//
for (i = 0; i < (length/4); i++) { for (i = 0; i < (length/4); i++) {
u16 temp1, temp2; u16 temp1, temp2;
...@@ -567,11 +564,11 @@ static void cmpk_handle_tx_rate_history(struct net_device *dev, u8 *pmsg) ...@@ -567,11 +564,11 @@ static void cmpk_handle_tx_rate_history(struct net_device *dev, u8 *pmsg)
return; return;
for (i = 0; i < 16; i++) { for (i = 0; i < 16; i++) {
// Collect CCK rate packet num /* Collect CCK rate packet num */
if (i < 4) if (i < 4)
priv->stats.txrate.cck[i] += ptxrate->cck[i]; priv->stats.txrate.cck[i] += ptxrate->cck[i];
// Collect OFDM rate packet num /* Collect OFDM rate packet num */
if (i < 8) if (i < 8)
priv->stats.txrate.ofdm[i] += ptxrate->ofdm[i]; priv->stats.txrate.ofdm[i] += ptxrate->ofdm[i];
...@@ -579,7 +576,7 @@ static void cmpk_handle_tx_rate_history(struct net_device *dev, u8 *pmsg) ...@@ -579,7 +576,7 @@ static void cmpk_handle_tx_rate_history(struct net_device *dev, u8 *pmsg)
priv->stats.txrate.ht_mcs[j][i] += ptxrate->ht_mcs[j][i]; priv->stats.txrate.ht_mcs[j][i] += ptxrate->ht_mcs[j][i];
} }
} /* cmpk_Handle_Tx_Rate_History */ }
/*----------------------------------------------------------------------------- /*-----------------------------------------------------------------------------
...@@ -610,8 +607,8 @@ extern u32 cmpk_message_handle_rx(struct net_device *dev, ...@@ -610,8 +607,8 @@ extern u32 cmpk_message_handle_rx(struct net_device *dev,
u8 element_id; u8 element_id;
u8 *pcmd_buff; u8 *pcmd_buff;
/* 0. Check inpt arguments. If is is a command queue message or pointer is /* 0. Check inpt arguments. If is is a command queue message or
null. */ pointer is null. */
if (pstats == NULL) if (pstats == NULL)
return 0; /* This is not a command packet. */ return 0; /* This is not a command packet. */
...@@ -625,11 +622,12 @@ extern u32 cmpk_message_handle_rx(struct net_device *dev, ...@@ -625,11 +622,12 @@ extern u32 cmpk_message_handle_rx(struct net_device *dev,
element_id = pcmd_buff[0]; element_id = pcmd_buff[0];
/* 4. Check every received command packet content according to different /* 4. Check every received command packet content according to different
element type. Because FW may aggregate RX command packet to minimize element type. Because FW may aggregate RX command packet to
transmit time between DRV and FW.*/ minimize transmit time between DRV and FW.*/
// Add a counter to prevent the lock in the loop from being held too long /* Add a counter to prevent the lock in the loop from being held too
long */
while (total_length > 0 && exe_cnt++ < 100) { while (total_length > 0 && exe_cnt++ < 100) {
/* 2007/01/17 MH We support aggregation of different cmd in the same packet. */ /* We support aggregation of different cmd in the same packet */
element_id = pcmd_buff[0]; element_id = pcmd_buff[0];
switch (element_id) { switch (element_id) {
...@@ -654,8 +652,8 @@ extern u32 cmpk_message_handle_rx(struct net_device *dev, ...@@ -654,8 +652,8 @@ extern u32 cmpk_message_handle_rx(struct net_device *dev,
break; break;
case RX_TX_PER_PKT_FEEDBACK: case RX_TX_PER_PKT_FEEDBACK:
// You must at lease add a switch case element here, /* You must at lease add a switch case element here,
// Otherwise, we will jump to default case. Otherwise, we will jump to default case. */
cmd_length = CMPK_RX_TX_FB_SIZE; cmd_length = CMPK_RX_TX_FB_SIZE;
break; break;
...@@ -675,4 +673,4 @@ extern u32 cmpk_message_handle_rx(struct net_device *dev, ...@@ -675,4 +673,4 @@ extern u32 cmpk_message_handle_rx(struct net_device *dev,
} }
return 1; /* This is a command packet. */ return 1; /* This is a command packet. */
} /* CMPK_Message_Handle_Rx */ }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment