staging: pi433: Return thread immediately when kthread_should_stop() call.
authorSidong Yang <realwakka@gmail.com>
Tue, 2 Apr 2019 12:14:31 +0000 (12:14 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 2 Apr 2019 17:58:04 +0000 (19:58 +0200)
commita35342d0f8b348fad38e6250f9b646b99aa210c7
tree6f5161d646722d99e725a34e1519ea4f2608c05c
parente7c3d05459673d21f62a3fd82fa3a1ee6ef8de55
staging: pi433: Return thread immediately when kthread_should_stop() call.

When kthread_stop() called by removing module, running thread should
return immediately. Otherwise, It is very dangerous that thread may access
any released data like struct pi433_device.

Signed-off-by: Sidong Yang <realwakka@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/pi433/pi433_if.c