# git rev-parse -q --verify 06af8679449d4ed282df13191fc52d5ba28ec536^{commit} 06af8679449d4ed282df13191fc52d5ba28ec536 already have revision, skipping fetch # git checkout -q -f -B kisskb 06af8679449d4ed282df13191fc52d5ba28ec536 # git clean -qxdf # < git log -1 # commit 06af8679449d4ed282df13191fc52d5ba28ec536 # Author: Eric W. Biederman # Date: Thu Jun 10 15:11:11 2021 -0500 # # coredump: Limit what can interrupt coredumps # # Olivier Langlois has been struggling with coredumps being incompletely written in # processes using io_uring. # # Olivier Langlois writes: # > io_uring is a big user of task_work and any event that io_uring made a # > task waiting for that occurs during the core dump generation will # > generate a TIF_NOTIFY_SIGNAL. # > # > Here are the detailed steps of the problem: # > 1. io_uring calls vfs_poll() to install a task to a file wait queue # > with io_async_wake() as the wakeup function cb from io_arm_poll_handler() # > 2. wakeup function ends up calling task_work_add() with TWA_SIGNAL # > 3. task_work_add() sets the TIF_NOTIFY_SIGNAL bit by calling # > set_notify_signal() # # The coredump code deliberately supports being interrupted by SIGKILL, # and depends upon prepare_signal to filter out all other signals. Now # that signal_pending includes wake ups for TIF_NOTIFY_SIGNAL this hack # in dump_emitted by the coredump code no longer works. # # Make the coredump code more robust by explicitly testing for all of # the wakeup conditions the coredump code supports. This prevents # new wakeup conditions from breaking the coredump code, as well # as fixing the current issue. # # The filesystem code that the coredump code uses already limits # itself to only aborting on fatal_signal_pending. So it should # not develop surprising wake-up reasons either. # # v2: Don't remove the now unnecessary code in prepare_signal. # # Cc: stable@vger.kernel.org # Fixes: 12db8b690010 ("entry: Add support for TIF_NOTIFY_SIGNAL") # Reported-by: Olivier Langlois # Signed-off-by: "Eric W. Biederman" # Signed-off-by: Linus Torvalds # < /opt/cross/kisskb/korg/gcc-4.9.4-nolibc/powerpc64-linux/bin/powerpc64-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-4.9.4-nolibc/powerpc64-linux/bin/powerpc64-linux-ld --version # < git log --format=%s --max-count=1 06af8679449d4ed282df13191fc52d5ba28ec536 # < make -s -j 160 ARCH=powerpc O=/kisskb/build/linus_mpc85xx_defconfig_powerpc-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/powerpc64-linux/bin/powerpc64-linux- mpc85xx_defconfig # < make -s -j 160 ARCH=powerpc O=/kisskb/build/linus_mpc85xx_defconfig_powerpc-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/powerpc64-linux/bin/powerpc64-linux- help # make -s -j 160 ARCH=powerpc O=/kisskb/build/linus_mpc85xx_defconfig_powerpc-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/powerpc64-linux/bin/powerpc64-linux- olddefconfig # make -s -j 160 ARCH=powerpc O=/kisskb/build/linus_mpc85xx_defconfig_powerpc-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/powerpc64-linux/bin/powerpc64-linux- /kisskb/src/net/sched/sch_frag.c: In function 'sch_fragment': /kisskb/src/net/sched/sch_frag.c:93:10: warning: missing braces around initializer [-Wmissing-braces] struct rtable sch_frag_rt = { 0 }; ^ /kisskb/src/net/sched/sch_frag.c:93:10: warning: (near initialization for 'sch_frag_rt.dst') [-Wmissing-braces] In file included from /kisskb/src/include/linux/kernel.h:11:0, from /kisskb/src/include/linux/list.h:9, from /kisskb/src/include/linux/module.h:12, from /kisskb/src/drivers/net/ethernet/freescale/fs_enet/mac-scc.c:15: /kisskb/src/drivers/net/ethernet/freescale/fs_enet/mac-scc.c: In function 'allocate_bd': /kisskb/src/include/linux/err.h:22:49: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] #define IS_ERR_VALUE(x) unlikely((unsigned long)(void *)(x) >= (unsigned long)-MAX_ERRNO) ^ /kisskb/src/include/linux/compiler.h:78:42: note: in definition of macro 'unlikely' # define unlikely(x) __builtin_expect(!!(x), 0) ^ /kisskb/src/drivers/net/ethernet/freescale/fs_enet/mac-scc.c:139:6: note: in expansion of macro 'IS_ERR_VALUE' if (IS_ERR_VALUE(fep->ring_mem_addr)) ^ /kisskb/src/arch/powerpc/boot/dts/fsl/mpc8541cds.dts:330.3-21: Warning (pci_device_bus_num): /pci@e0008000/i8259@19000:bus-range: PCI bus number 1 out of range, expected (0 - 0) /kisskb/src/arch/powerpc/boot/dts/fsl/mpc8555cds.dts:330.3-21: Warning (pci_device_bus_num): /pci@e0008000/i8259@19000:bus-range: PCI bus number 1 out of range, expected (0 - 0) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd76ef0) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) INFO: Uncompressed kernel (size 0xd667c4) overlaps the address of the wrapper(0x400000) INFO: Fixing the link_address of wrapper to (0xe00000) Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:36 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6512239 Bytes = 6359.61 KiB = 6.21 MiB Load Address: 00000000 Entry Point: 00000000 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:38 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6544791 Bytes = 6391.40 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e00314 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:38 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6544693 Bytes = 6391.30 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6546909 Bytes = 6393.47 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6543835 Bytes = 6390.46 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e00314 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6543833 Bytes = 6390.46 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e00314 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6546949 Bytes = 6393.50 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6543770 Bytes = 6390.40 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6543841 Bytes = 6390.47 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6546593 Bytes = 6393.16 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6546157 Bytes = 6392.73 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6544763 Bytes = 6391.37 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6544741 Bytes = 6391.35 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6544734 Bytes = 6391.34 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e00314 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6544606 Bytes = 6391.22 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e00314 Image Name: Linux-5.13.0-rc5-g06af8679449d Created: Sat Jul 17 20:37:39 2021 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 6544780 Bytes = 6391.39 KiB = 6.24 MiB Load Address: 00e00000 Entry Point: 00e002a4 Completed OK # rm -rf /kisskb/build/linus_mpc85xx_defconfig_powerpc-gcc4.9 # Build took: 0:00:52.165698