linux/drivers
Yang Yingliang 36225a7c72 w1: fix WARNING after calling w1_process()
I got the following WARNING message while removing driver(ds2482):

------------[ cut here ]------------
do not call blocking ops when !TASK_RUNNING; state=1 set at [<000000002d50bfb6>] w1_process+0x9e/0x1d0 [wire]
WARNING: CPU: 0 PID: 262 at kernel/sched/core.c:9817 __might_sleep+0x98/0xa0
CPU: 0 PID: 262 Comm: w1_bus_master1 Tainted: G                 N 6.1.0-rc3+ #307
RIP: 0010:__might_sleep+0x98/0xa0
Call Trace:
 exit_signals+0x6c/0x550
 do_exit+0x2b4/0x17e0
 kthread_exit+0x52/0x60
 kthread+0x16d/0x1e0
 ret_from_fork+0x1f/0x30

The state of task is set to TASK_INTERRUPTIBLE in loop in w1_process(),
set it to TASK_RUNNING when it breaks out of the loop to avoid the
warning.

Fixes: 3c52e4e627 ("W1: w1_process, block or sleep")
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Link: https://lore.kernel.org/r/20221205101558.3599162-1-yangyingliang@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-19 17:26:33 +01:00
..
accel Fix mismerge due to devnode now taking a 'const *' device 2022-12-16 13:04:15 -06:00
accessibility
acpi Merge branches 'acpi-resource' and 'acpi-video' 2023-01-13 11:11:05 +01:00
amba ARM updates for 6.2 2022-12-13 15:22:14 -08:00
android
ata ata: pata_cs5535: Don't build on UML 2023-01-14 07:38:48 +09:00
atm treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
auxdisplay
base Kbuild updates for v6.2 2022-12-19 12:33:32 -06:00
bcma
block xen: branch for v6.2-rc4 2023-01-12 17:02:20 -06:00
bluetooth treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
bus Char/Misc driver changes for 6.2-rc1 2022-12-16 03:49:24 -08:00
cdrom
char xen: branch for v6.2-rc4 2023-01-12 17:02:20 -06:00
clk A pile of clk driver updates with a small tracepoint patch to the clk core this 2022-12-13 13:46:07 -08:00
clocksource Updates for timers, timekeeping and drivers: 2022-12-12 12:52:02 -08:00
comedi comedi: adv_pci1760: Fix PWM instruction handling 2023-01-19 17:24:47 +01:00
connector
counter
cpufreq cpufreq: amd-pstate: fix kernel hang issue while amd-pstate unregistering 2023-01-10 20:31:08 +01:00
cpuidle powerpc updates for 6.2 2022-12-19 07:13:33 -06:00
crypto MTD changes: 2023-01-12 05:56:06 -06:00
cxl cxl/region: Fix memdev reuse check 2022-12-08 13:03:47 -08:00
dax
dca
devfreq PM / devfreq: event: use devm_platform_get_and_ioremap_resource() 2022-12-05 21:57:20 +09:00
dio
dma dmaengine updates for v6.2 2022-12-19 08:54:17 -06:00
dma-buf Merge drm/drm-fixes into drm-misc-fixes 2023-01-03 08:32:12 +01:00
edac EDAC/highbank: Fix memory leak in highbank_mc_probe() 2023-01-03 17:03:57 +01:00
eisa
extcon Char/Misc driver changes for 6.2-rc1 2022-12-16 03:49:24 -08:00
firewire
firmware kernel hardening fixes for v6.2-rc4 2023-01-14 10:04:00 -06:00
fpga Char/Misc driver changes for 6.2-rc1 2022-12-16 03:49:24 -08:00
fsi
gnss
gpio gpio: sifive: Fix refcount leak in sifive_gpio_probe 2023-01-02 13:01:14 +01:00
gpu drm fixes for 6.2-rc4 2023-01-13 07:18:59 -06:00
greybus
hid treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
hsi
hte
hv Networking changes for 6.2. 2022-12-13 15:47:48 -08:00
hwmon hwmon updates for v6.2 merge window 2022-12-13 13:09:38 -08:00
hwspinlock
hwtracing
i2c Core got a new helper 'i2c_client_get_device_id', designware got some 2022-12-15 14:47:10 -08:00
i3c i3c: export SETDASA method 2022-12-11 21:25:58 +01:00
idle
iio Char/Misc driver changes for 6.2-rc1 2022-12-16 03:49:24 -08:00
infiniband RDMA/mlx5: Fix validation of max_rd_atomic caps for DC 2023-01-01 09:40:35 +02:00
input xen: branch for v6.2-rc4 2023-01-12 17:02:20 -06:00
interconnect
iommu iommu/mediatek-v1: Fix an error handling path in mtk_iommu_v1_probe() 2023-01-13 13:46:32 +01:00
ipack
irqchip RISC-V Patches for the 6.2 Merge Window, Part 1 2022-12-14 15:23:49 -08:00
isdn treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
leds treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
macintosh
mailbox - qcom: enable sc8280xp, sm8550 and sm4250 support 2022-12-21 09:31:18 -08:00
mcb
md block: handle bio_split_to_limits() NULL return 2023-01-04 09:05:23 -07:00
media treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
memory ARM updates for 6.2 2022-12-13 15:22:14 -08:00
memstick memstick/mspro_block: Convert to use sysfs_emit()/sysfs_emit_at() APIs 2022-12-09 10:29:58 +01:00
message
mfd - New Drivers 2022-12-21 09:19:24 -08:00
misc kernel hardening fixes for v6.2-rc1 2022-12-23 12:00:24 -08:00
mmc MMC core: 2022-12-13 13:41:26 -08:00
most
mtd mtd: cfi: allow building spi-intel standalone 2023-01-02 12:08:53 +01:00
mux
net Including fixes from rxrpc. 2023-01-12 18:20:44 -06:00
nfc nfc: pn533: Wait for out_urb's completion in pn533_usb_send_frame() 2023-01-09 07:34:13 +00:00
ntb
nubus
nvdimm nvdimm/region: Move cache management to the region driver 2022-12-02 23:52:32 -08:00
nvme block-6.2-2023-01-13 2023-01-13 17:41:19 -06:00
nvmem Char/Misc driver changes for 6.2-rc1 2022-12-16 03:49:24 -08:00
of of: fdt: Honor CONFIG_CMDLINE* even without /chosen node, take 2 2023-01-04 21:31:59 -06:00
opp
parisc parisc: led: Fix potential null-ptr-deref in start_task() 2022-12-17 23:19:38 +01:00
parport
pci pci-v6.2-fixes-1 2023-01-13 17:32:22 -06:00
pcmcia treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
peci
perf RISC-V Patches for the 6.2 Merge Window, Part 1 2022-12-14 15:23:49 -08:00
phy phy-for-6.2 2022-12-19 08:40:58 -06:00
pinctrl Pin control changes for the v6.2 kernel cycle: 2022-12-13 13:03:06 -08:00
platform platform/x86: thinkpad_acpi: Fix profile mode display in AMT mode 2023-01-13 11:40:30 +01:00
pnp
power power supply and reset changes for the v6.2 series 2022-12-17 08:39:31 -06:00
powercap
pps
ps3
ptp Networking changes for 6.2. 2022-12-13 15:47:48 -08:00
pwm pwm: Changes for v6.2-rc1 2022-12-21 09:41:28 -08:00
rapidio rapidio: devices: fix missing put_device in mport_cdev_open 2022-12-11 19:30:20 -08:00
ras
regulator regulator: qcom-rpmh: PM8550 ldo11 regulator is an nldo 2023-01-03 15:54:38 +00:00
remoteproc remoteproc: core: Do pm_relax when in RPROC_OFFLINE state 2022-12-07 11:20:55 -07:00
reset
rpmsg
rtc - New Drivers 2022-12-21 09:19:24 -08:00
s390 block-2023-01-06 2023-01-06 13:12:42 -08:00
sbus
scsi SCSI fixes on 20230114 2023-01-14 07:57:25 -06:00
sh
siox
slimbus
soc ARM: SoC fixes for 6.2 2022-12-19 16:07:59 -06:00
soundwire soundwire updates for 6.2 2022-12-19 08:47:33 -06:00
spi spi: Merge rename of spi-cs-setup-ns DT property 2023-01-11 14:15:22 +00:00
spmi
ssb
staging treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
target SCSI misc on 20221213 2022-12-14 08:58:51 -08:00
tc
tee SoC driver updates for 6.2 2022-12-12 10:17:08 -08:00
thermal thermal: int340x: Add missing attribute for data rate base 2022-12-30 19:48:37 +01:00
thunderbolt
tty xen: branch for v6.2-rc4 2023-01-12 17:02:20 -06:00
ufs Merge branch '6.2/scsi-queue' into 6.2/scsi-fixes 2022-12-30 16:29:34 +00:00
uio
usb xen: branch for v6.2-rc4 2023-01-12 17:02:20 -06:00
vdpa vdpa_sim_net: should not drop the multicast/broadcast packet 2022-12-28 05:28:11 -05:00
vfio Driver Core changes for 6.2-rc1 2022-12-16 03:54:54 -08:00
vhost vhost_vdpa: fix the crash in unmap a large memory 2022-12-28 05:28:11 -05:00
video xen: branch for v6.2-rc4 2023-01-12 17:02:20 -06:00
virt Char/Misc driver changes for 6.2-rc1 2022-12-16 03:49:24 -08:00
virtio virtio: Implementing attribute show with sysfs_emit 2022-12-28 05:28:11 -05:00
vlynq
w1 w1: fix WARNING after calling w1_process() 2023-01-19 17:26:33 +01:00
watchdog linux-watchdog 6.2-rc1 tag 2022-12-17 08:34:01 -06:00
xen xen: branch for v6.2-rc4 2023-01-12 17:02:20 -06:00
zorro
Kconfig
Makefile