From: Meghana Madhyastha Date: Sat, 16 Sep 2017 08:12:16 +0000 (+0530) Subject: Staging: rtl8723bs/os_dep: Remove typecast in kfree X-Git-Tag: v4.15-rc1~142^2~308 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=c8d5fa75141bec422be82117c826e78e715a9007;p=linux.git Staging: rtl8723bs/os_dep: Remove typecast in kfree Remove typecast of pointer in kfree((u8 *)pdvobj) as it is not needed. Found using the following Coccinelle semantic patch: @@ identifier x; type t; @@ -kfree((t *)x) +kfree(x) Signed-off-by: Meghana Madhyastha Acked-by: Julia Lawall Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8723bs/os_dep/os_intfs.c b/drivers/staging/rtl8723bs/os_dep/os_intfs.c index f509713c9e68..51df42de9167 100644 --- a/drivers/staging/rtl8723bs/os_dep/os_intfs.c +++ b/drivers/staging/rtl8723bs/os_dep/os_intfs.c @@ -719,7 +719,7 @@ void devobj_deinit(struct dvobj_priv *pdvobj) mutex_destroy(&pdvobj->setch_mutex); mutex_destroy(&pdvobj->setbw_mutex); - kfree((u8 *)pdvobj); + kfree(pdvobj); } u8 rtw_reset_drv_sw(struct adapter *padapter)