Even though it is declared in an include file, it is used only in rtw_cmd.c. There's even a preprocessor guard to make sure it is not visible in other modules. It is now useless, so remove it. Signed-off-by: Luca Ceresoli <luca@xxxxxxxxxxxxxxxx> Cc: Larry Finger <Larry.Finger@xxxxxxxxxxxx> Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxx> --- drivers/staging/rtl8188eu/core/rtw_cmd.c | 23 +++++++++++++++++++++++ drivers/staging/rtl8188eu/include/rtw_cmd.h | 25 ------------------------- 2 files changed, 23 insertions(+), 25 deletions(-) diff --git a/drivers/staging/rtl8188eu/core/rtw_cmd.c b/drivers/staging/rtl8188eu/core/rtw_cmd.c index 700686ec8798..2b2bec3dbe4a 100644 --- a/drivers/staging/rtl8188eu/core/rtw_cmd.c +++ b/drivers/staging/rtl8188eu/core/rtw_cmd.c @@ -211,6 +211,29 @@ exit: } +struct _cmd_callback { + u32 cmd_code; + void (*callback)(struct adapter *padapter, struct cmd_obj *cmd); +}; + +static struct _cmd_callback rtw_cmd_callback[] = { + {GEN_CMD_CODE(_JoinBss), &rtw_joinbss_cmd_callback}, + {GEN_CMD_CODE(_DisConnect), &rtw_disassoc_cmd_callback}, + {GEN_CMD_CODE(_CreateBss), &rtw_createbss_cmd_callback}, + {GEN_CMD_CODE(_SetOpMode), NULL}, + {GEN_CMD_CODE(_SiteSurvey), &rtw_survey_cmd_callback}, + {GEN_CMD_CODE(_SetAuth), NULL}, + {GEN_CMD_CODE(_SetKey), NULL}, + {GEN_CMD_CODE(_SetStaKey), &rtw_setstaKey_cmdrsp_callback}, + {GEN_CMD_CODE(_SetAssocSta), &rtw_setassocsta_cmdrsp_callback}, + {GEN_CMD_CODE(_AddBAReq), NULL}, + {GEN_CMD_CODE(_SetChannel), NULL}, + {GEN_CMD_CODE(_TX_Beacon), NULL}, + {GEN_CMD_CODE(_Set_MLME_EVT), NULL}, + {GEN_CMD_CODE(_Set_Drv_Extra), NULL}, + {GEN_CMD_CODE(_SetChannelPlan), NULL}, +}; + /* Caller and the rtw_cmd_thread can protect cmd_q by spin_lock. No irqsave is necessary. diff --git a/drivers/staging/rtl8188eu/include/rtw_cmd.h b/drivers/staging/rtl8188eu/include/rtw_cmd.h index 9e9f5f4af8f1..d10c93e2f6f6 100644 --- a/drivers/staging/rtl8188eu/include/rtw_cmd.h +++ b/drivers/staging/rtl8188eu/include/rtw_cmd.h @@ -375,11 +375,6 @@ void rtw_setstaKey_cmdrsp_callback(struct adapter *adapt, struct cmd_obj *cmd); void rtw_setassocsta_cmdrsp_callback(struct adapter *adapt, struct cmd_obj *cm); void rtw_getrttbl_cmdrsp_callback(struct adapter *adapt, struct cmd_obj *cmd); -struct _cmd_callback { - u32 cmd_code; - void (*callback)(struct adapter *padapter, struct cmd_obj *cmd); -}; - enum rtw_h2c_cmd { GEN_CMD_CODE(_JoinBss), GEN_CMD_CODE(_DisConnect), @@ -400,24 +395,4 @@ enum rtw_h2c_cmd { MAX_H2CCMD }; -#ifdef _RTW_CMD_C_ -static struct _cmd_callback rtw_cmd_callback[] = { - {GEN_CMD_CODE(_JoinBss), &rtw_joinbss_cmd_callback}, - {GEN_CMD_CODE(_DisConnect), &rtw_disassoc_cmd_callback}, - {GEN_CMD_CODE(_CreateBss), &rtw_createbss_cmd_callback}, - {GEN_CMD_CODE(_SetOpMode), NULL}, - {GEN_CMD_CODE(_SiteSurvey), &rtw_survey_cmd_callback}, - {GEN_CMD_CODE(_SetAuth), NULL}, - {GEN_CMD_CODE(_SetKey), NULL}, - {GEN_CMD_CODE(_SetStaKey), &rtw_setstaKey_cmdrsp_callback}, - {GEN_CMD_CODE(_SetAssocSta), &rtw_setassocsta_cmdrsp_callback}, - {GEN_CMD_CODE(_AddBAReq), NULL}, - {GEN_CMD_CODE(_SetChannel), NULL}, - {GEN_CMD_CODE(_TX_Beacon), NULL}, - {GEN_CMD_CODE(_Set_MLME_EVT), NULL}, - {GEN_CMD_CODE(_Set_Drv_Extra), NULL}, - {GEN_CMD_CODE(_SetChannelPlan), NULL}, -}; -#endif - #endif /* _CMD_H_ */ -- 1.9.1 _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel