Skip to content

Commit c8708d7

Browse files
committed
parisc: Prevent hung tasks when printing inventory on serial console
Printing the inventory on a serial console can be quite slow and thus may trigger the hung task detector (CONFIG_DETECT_HUNG_TASK=y) and possibly reboot the machine. Adding a cond_resched() prevents this. Signed-off-by: Helge Deller <[email protected]> Cc: <[email protected]> # v6.0+
1 parent b9402e3 commit c8708d7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

arch/parisc/kernel/drivers.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1004,6 +1004,9 @@ static __init int qemu_print_iodc_data(struct device *lin_dev, void *data)
10041004

10051005
pr_info("\n");
10061006

1007+
/* Prevent hung task messages when printing on serial console */
1008+
cond_resched();
1009+
10071010
pr_info("#define HPA_%08lx_DESCRIPTION \"%s\"\n",
10081011
hpa, parisc_hardware_description(&dev->id));
10091012

0 commit comments

Comments
 (0)