Skip to content

Commit

Permalink
staging: rtl8723bs: remove typedefs in rtl8723b_hal.h
Browse files Browse the repository at this point in the history
This commit fixes the following checkpatch.pl warnings:

    WARNING: do not add new typedefs
    torvalds#173: FILE: include/rtl8723b_hal.h:173:
    +typedef enum _C2H_EVT {

    WARNING: do not add new typedefs
    torvalds#189: FILE: include/rtl8723b_hal.h:189:
    +typedef struct _C2H_EVT_HDR {

    WARNING: do not add new typedefs
    torvalds#195: FILE: include/rtl8723b_hal.h:195:
    +typedef enum tag_Package_Definition {

Signed-off-by: Marco Cesati <marco.cesati@gmail.com>
Link: https://lore.kernel.org/r/20210312082638.25512-23-marco.cesati@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Marco Cesati authored and gregkh committed Mar 12, 2021
1 parent f30c262 commit 23004f3
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -3706,7 +3706,7 @@ s32 c2h_handler_8723b(struct adapter *padapter, u8 *buf)
return ret;
}

static void process_c2h_event(struct adapter *padapter, PC2H_EVT_HDR pC2hEvent, u8 *c2hBuf)
static void process_c2h_event(struct adapter *padapter, struct C2H_EVT_HDR *pC2hEvent, u8 *c2hBuf)
{
u8 index = 0;

Expand Down Expand Up @@ -3750,7 +3750,7 @@ static void process_c2h_event(struct adapter *padapter, PC2H_EVT_HDR pC2hEvent,

void C2HPacketHandler_8723B(struct adapter *padapter, u8 *pbuffer, u16 length)
{
C2H_EVT_HDR C2hEvent;
struct C2H_EVT_HDR C2hEvent;
u8 *tmpBuf = NULL;
#ifdef CONFIG_WOWLAN
struct pwrctrl_priv *pwrpriv = adapter_to_pwrctl(padapter);
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/rtl8723bs/hal/rtl8723bs_recv.c
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ static void rtl8723bs_recv_tasklet(struct tasklet_struct *t)
RT_TRACE(_module_rtl871x_recv_c_, _drv_dump_, ("%s: rtw_recv_entry(precvframe) != _SUCCESS\n", __func__));
}
} else if (pattrib->pkt_rpt_type == C2H_PACKET) {
C2H_EVT_HDR C2hEvent;
struct C2H_EVT_HDR C2hEvent;

u16 len_c2h = pattrib->pkt_len;
u8 *pbuf_c2h = precvframe->u.hdr.rx_data;
Expand Down
12 changes: 6 additions & 6 deletions drivers/staging/rtl8723bs/include/rtl8723b_hal.h
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ struct rt_firmware_hdr {
/* Description: Determine the types of C2H events that are the same in driver
* and FW; First constructed by tynli. 2009.10.09.
*/
typedef enum _C2H_EVT {
enum C2H_EVT {
C2H_DBG = 0,
C2H_TSF = 1,
C2H_AP_RPT_RSP = 2,
Expand All @@ -184,21 +184,21 @@ typedef enum _C2H_EVT {
C2H_HW_INFO_EXCH = 10,
C2H_8723B_BT_MP_INFO = 11,
MAX_C2HEVENT
} C2H_EVT;
};

typedef struct _C2H_EVT_HDR {
struct C2H_EVT_HDR {
u8 CmdID;
u8 CmdLen;
u8 CmdSeq;
} __attribute__((__packed__)) C2H_EVT_HDR, *PC2H_EVT_HDR;
} __attribute__((__packed__));

typedef enum tag_Package_Definition {
enum PACKAGE_TYPE_E { /* tag_Package_Definition */
PACKAGE_DEFAULT,
PACKAGE_QFN68,
PACKAGE_TFBGA90,
PACKAGE_TFBGA80,
PACKAGE_TFBGA79
} PACKAGE_TYPE_E;
};

#define INCLUDE_MULTI_FUNC_BT(_Adapter) \
(GET_HAL_DATA(_Adapter)->MultiFunc & RT_MULTI_FUNC_BT)
Expand Down

0 comments on commit 23004f3

Please sign in to comment.