Skip to content

Commit 501c887

Browse files
committed
exit/rtl8723bs: Replace the macro thread_exit with a simple return 0
Every place thread_exit is called is at the end of a function started with kthread_run. The code in kthread_run has arranged things so a kernel thread can just return and do_exit will be called. So just have the threads return instead of calling complete_and_exit. Link: https://lkml.kernel.org/r/[email protected] Signed-off-by: Eric W. Biederman <[email protected]>
1 parent 695dd0d commit 501c887

File tree

4 files changed

+3
-5
lines changed

4 files changed

+3
-5
lines changed

drivers/staging/rtl8723bs/core/rtw_cmd.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -524,7 +524,7 @@ int rtw_cmd_thread(void *context)
524524
complete(&pcmdpriv->terminate_cmdthread_comp);
525525
atomic_set(&(pcmdpriv->cmdthd_running), false);
526526

527-
thread_exit();
527+
return 0;
528528
}
529529

530530
/*

drivers/staging/rtl8723bs/core/rtw_xmit.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2491,7 +2491,7 @@ int rtw_xmit_thread(void *context)
24912491

24922492
complete(&padapter->xmitpriv.terminate_xmitthread_comp);
24932493

2494-
thread_exit();
2494+
return 0;
24952495
}
24962496

24972497
void rtw_sctx_init(struct submit_ctx *sctx, int timeout_ms)

drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -435,7 +435,7 @@ int rtl8723bs_xmit_thread(void *context)
435435

436436
complete(&pxmitpriv->SdioXmitTerminate);
437437

438-
thread_exit();
438+
return 0;
439439
}
440440

441441
s32 rtl8723bs_mgnt_xmit(

drivers/staging/rtl8723bs/include/osdep_service_linux.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,6 @@
4545
spinlock_t lock;
4646
};
4747

48-
#define thread_exit() complete_and_exit(NULL, 0)
49-
5048
static inline struct list_head *get_next(struct list_head *list)
5149
{
5250
return list->next;

0 commit comments

Comments
 (0)