sgi-gru: grukservices: remove unnecessary (void*) conversions
authorLi kunyu <kunyu@nfschina.com>
Fri, 16 Dec 2022 05:59:10 +0000 (13:59 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 20 Jan 2023 12:06:54 +0000 (13:06 +0100)
void * pointer cb, no cast type assignment required.

Signed-off-by: Li kunyu <kunyu@nfschina.com>
Link: https://lore.kernel.org/r/20221216055910.3559-1-kunyu@nfschina.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/misc/sgi-gru/grukservices.c

index fa1f5a6..37e804b 100644 (file)
@@ -425,7 +425,7 @@ int gru_get_cb_exception_detail(void *cb,
 static char *gru_get_cb_exception_detail_str(int ret, void *cb,
                                             char *buf, int size)
 {
-       struct gru_control_block_status *gen = (void *)cb;
+       struct gru_control_block_status *gen = cb;
        struct control_block_extended_exc_detail excdet;
 
        if (ret > 0 && gen->istatus == CBS_EXCEPTION) {
@@ -452,7 +452,7 @@ static int gru_wait_idle_or_exception(struct gru_control_block_status *gen)
 
 static int gru_retry_exception(void *cb)
 {
-       struct gru_control_block_status *gen = (void *)cb;
+       struct gru_control_block_status *gen = cb;
        struct control_block_extended_exc_detail excdet;
        int retry = EXCEPTION_RETRY_LIMIT;
 
@@ -475,7 +475,7 @@ static int gru_retry_exception(void *cb)
 
 int gru_check_status_proc(void *cb)
 {
-       struct gru_control_block_status *gen = (void *)cb;
+       struct gru_control_block_status *gen = cb;
        int ret;
 
        ret = gen->istatus;
@@ -488,7 +488,7 @@ int gru_check_status_proc(void *cb)
 
 int gru_wait_proc(void *cb)
 {
-       struct gru_control_block_status *gen = (void *)cb;
+       struct gru_control_block_status *gen = cb;
        int ret;
 
        ret = gru_wait_idle_or_exception(gen);