diff options
| author | Chaehyun Lim <chaehyun.lim@gmail.com> | 2015-10-05 19:35:01 +0900 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-10-08 10:58:33 +0100 |
| commit | 754d8c9016e00fc34dc6460ec00db2544033a12b (patch) | |
| tree | 200814236a9820ecc5fcbba0338620524b694e44 | |
| parent | 9e5e8b44bc67d2d06f660b6f3e8270f862078011 (diff) | |
staging: wilc1000: remove pstrWFIDrv in host_int_remove_key
This patch remove pstrWFIDrv in host_int_remove_key. There is no need to
make another variable to check if first argument is NULL or not.
It is able to use wfi_drv directly that is first argument of this
function.
Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| -rw-r--r-- | drivers/staging/wilc1000/host_interface.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c index 7acd744efed6..1e465522d4e8 100644 --- a/drivers/staging/wilc1000/host_interface.c +++ b/drivers/staging/wilc1000/host_interface.c @@ -4191,11 +4191,10 @@ s32 host_int_remove_key(tstrWILC_WFIDrv *hWFIDrv, const u8 *pu8StaAddress) int host_int_remove_wep_key(tstrWILC_WFIDrv *wfi_drv, u8 index) { int result = 0; - tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)wfi_drv; struct host_if_msg msg; - if (pstrWFIDrv == NULL) { + if (wfi_drv == NULL) { result = -EFAULT; PRINT_ER("Failed to send setup multicast config packet\n"); return result; @@ -4219,7 +4218,7 @@ int host_int_remove_wep_key(tstrWILC_WFIDrv *wfi_drv, u8 index) result = wilc_mq_send(&gMsgQHostIF, &msg, sizeof(struct host_if_msg)); if (result) PRINT_ER("Error in sending message queue : Request to remove WEP key\n"); - down(&(pstrWFIDrv->hSemTestKeyBlock)); + down(&(wfi_drv->hSemTestKeyBlock)); return result; } |
