# git rev-parse -q --verify 625d3449788f85569096780592549d0340e9c0c7^{commit} 625d3449788f85569096780592549d0340e9c0c7 already have revision, skipping fetch # git checkout -q -f -B kisskb 625d3449788f85569096780592549d0340e9c0c7 # git clean -qxdf # < git log -1 # commit 625d3449788f85569096780592549d0340e9c0c7 # Author: Jason A. Donenfeld # Date: Sun Jun 21 21:02:22 2020 -0600 # # Revert "kernel/printk: add kmsg SEEK_CUR handling" # # This reverts commit 8ece3b3eb576a78d2e67ad4c3a80a39fa6708809. # # This commit broke userspace. Bash uses ESPIPE to determine whether or # not the file should be read using "unbuffered I/O", which means reading # 1 byte at a time instead of 128 bytes at a time. I used to use bash to # read through kmsg in a really quite nasty way: # # while read -t 0.1 -r line 2>/dev/null || [[ $? -ne 142 ]]; do # echo "SARU $line" # done < /dev/kmsg # # This will show all lines that can fit into the 128 byte buffer, and skip # lines that don't. That's pretty awful, but at least it worked. # # With this change, bash now tries to do 1-byte reads, which means it # skips all the lines, which is worse than before. # # Now, I don't really care very much about this, and I'm already look for # a workaround. But I did just spend an hour trying to figure out why my # scripts were broken. Either way, it makes no difference to me personally # whether this is reverted, but it might be something to consider. If you # declare that "trying to read /dev/kmsg with bash is terminally stupid # anyway," I might be inclined to agree with you. But do note that bash # uses lseek(fd, 0, SEEK_CUR)==>ESPIPE to determine whether or not it's # reading from a pipe. # # Cc: Bruno Meneguele # Cc: Sergey Senozhatsky # Cc: Steven Rostedt # Cc: David Laight # Cc: Sergey Senozhatsky # Cc: Petr Mladek # Signed-off-by: Jason A. Donenfeld # Signed-off-by: Linus Torvalds # < /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/s390-linux/bin/s390-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/s390-linux/bin/s390-linux-ld --version # < git log --format=%s --max-count=1 625d3449788f85569096780592549d0340e9c0c7 # < make -s -j 48 ARCH=s390 O=/kisskb/build/linus_s390-allmodconfig_s390x-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/s390-linux/bin/s390-linux- allmodconfig # Added to kconfig CONFIG_BUILD_DOCSRC=n # Added to kconfig CONFIG_MODULE_SIG=n # Added to kconfig CONFIG_SAMPLES=n # < make -s -j 48 ARCH=s390 O=/kisskb/build/linus_s390-allmodconfig_s390x-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/s390-linux/bin/s390-linux- help # make -s -j 48 ARCH=s390 O=/kisskb/build/linus_s390-allmodconfig_s390x-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/s390-linux/bin/s390-linux- olddefconfig # make -s -j 48 ARCH=s390 O=/kisskb/build/linus_s390-allmodconfig_s390x-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/s390-linux/bin/s390-linux- /kisskb/src/lib/test_kasan.c: In function 'kasan_alloca_oob_left': /kisskb/src/lib/test_kasan.c:555:1: warning: 'kasan_alloca_oob_left' uses dynamic stack allocation } ^ /kisskb/src/lib/test_kasan.c: In function 'kasan_alloca_oob_right': /kisskb/src/lib/test_kasan.c:565:1: warning: 'kasan_alloca_oob_right' uses dynamic stack allocation } ^ /kisskb/src/drivers/input/joystick/analog.c:160:2: warning: #warning Precise timer not defined for this architecture. [-Wcpp] #warning Precise timer not defined for this architecture. ^~~~~~~ /kisskb/src/drivers/mailbox/imx-mailbox.c:638:12: warning: 'imx_mu_runtime_resume' defined but not used [-Wunused-function] static int imx_mu_runtime_resume(struct device *dev) ^~~~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/mailbox/imx-mailbox.c:629:12: warning: 'imx_mu_runtime_suspend' defined but not used [-Wunused-function] static int imx_mu_runtime_suspend(struct device *dev) ^~~~~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/mailbox/imx-mailbox.c:611:12: warning: 'imx_mu_resume_noirq' defined but not used [-Wunused-function] static int imx_mu_resume_noirq(struct device *dev) ^~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/mailbox/imx-mailbox.c:601:12: warning: 'imx_mu_suspend_noirq' defined but not used [-Wunused-function] static int imx_mu_suspend_noirq(struct device *dev) ^~~~~~~~~~~~~~~~~~~~ In file included from /kisskb/src/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c:40: /kisskb/src/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c: In function 'mvpp2_setup_bm_pool': /kisskb/src/drivers/net/ethernet/marvell/mvpp2/mvpp2.h:634:2: warning: overflow in conversion from 'long unsigned int' to 'int' changes value from '18446744073709551584' to '-32' [-Woverflow] ((total_size) - NET_SKB_PAD - MVPP2_SKB_SHINFO_SIZE) ^ /kisskb/src/drivers/net/ethernet/marvell/mvpp2/mvpp2.h:699:33: note: in expansion of macro 'MVPP2_RX_MAX_PKT_SIZE' #define MVPP2_BM_SHORT_PKT_SIZE MVPP2_RX_MAX_PKT_SIZE(MVPP2_BM_SHORT_FRAME_SIZE) ^~~~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c:580:41: note: in expansion of macro 'MVPP2_BM_SHORT_PKT_SIZE' mvpp2_pools[MVPP2_BM_SHORT].pkt_size = MVPP2_BM_SHORT_PKT_SIZE; ^~~~~~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/scsi/dc395x.c: In function '__dc395x_eh_bus_reset': /kisskb/src/drivers/scsi/dc395x.c:155:36: warning: value computed is not used [-Wunused-value] #define DC395x_read8(acb,address) (u8)(inb(acb->io_port_base + (address))) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/scsi/dc395x.c:1197:2: note: in expansion of macro 'DC395x_read8' DC395x_read8(acb, TRM_S1040_SCSI_INTSTATUS); ^~~~~~~~~~~~ /kisskb/src/drivers/scsi/dc395x.c: In function 'set_basic_config': /kisskb/src/drivers/scsi/dc395x.c:155:36: warning: value computed is not used [-Wunused-value] #define DC395x_read8(acb,address) (u8)(inb(acb->io_port_base + (address))) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/scsi/dc395x.c:3489:2: note: in expansion of macro 'DC395x_read8' DC395x_read8(acb, TRM_S1040_SCSI_INTSTATUS); ^~~~~~~~~~~~ /kisskb/src/drivers/scsi/dc395x.c: In function 'adapter_uninit_chip': /kisskb/src/drivers/scsi/dc395x.c:155:36: warning: value computed is not used [-Wunused-value] #define DC395x_read8(acb,address) (u8)(inb(acb->io_port_base + (address))) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/scsi/dc395x.c:4435:2: note: in expansion of macro 'DC395x_read8' DC395x_read8(acb, TRM_S1040_SCSI_INTSTATUS); ^~~~~~~~~~~~ In file included from ./arch/s390/include/generated/asm/cacheflush.h:1, from /kisskb/src/drivers/media/platform/omap3isp/isp.c:42: /kisskb/src/include/asm-generic/cacheflush.h:16:42: warning: 'struct mm_struct' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_cache_mm(struct mm_struct *mm) ^~~~~~~~~ /kisskb/src/include/asm-generic/cacheflush.h:22:46: warning: 'struct mm_struct' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_cache_dup_mm(struct mm_struct *mm) ^~~~~~~~~ /kisskb/src/include/asm-generic/cacheflush.h:28:45: warning: 'struct vm_area_struct' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_cache_range(struct vm_area_struct *vma, ^~~~~~~~~~~~~~ /kisskb/src/include/asm-generic/cacheflush.h:36:44: warning: 'struct vm_area_struct' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_cache_page(struct vm_area_struct *vma, ^~~~~~~~~~~~~~ /kisskb/src/include/asm-generic/cacheflush.h:44:45: warning: 'struct page' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_dcache_page(struct page *page) ^~~~ /kisskb/src/include/asm-generic/cacheflush.h:52:50: warning: 'struct address_space' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_dcache_mmap_lock(struct address_space *mapping) ^~~~~~~~~~~~~ /kisskb/src/include/asm-generic/cacheflush.h:58:52: warning: 'struct address_space' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_dcache_mmap_unlock(struct address_space *mapping) ^~~~~~~~~~~~~ /kisskb/src/include/asm-generic/cacheflush.h:75:17: warning: 'struct page' declared inside parameter list will not be visible outside of this definition or declaration struct page *page) ^~~~ /kisskb/src/include/asm-generic/cacheflush.h:74:45: warning: 'struct vm_area_struct' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_icache_page(struct vm_area_struct *vma, ^~~~~~~~~~~~~~ /kisskb/src/include/asm-generic/cacheflush.h:82:16: warning: 'struct page' declared inside parameter list will not be visible outside of this definition or declaration struct page *page, ^~~~ /kisskb/src/include/asm-generic/cacheflush.h:81:50: warning: 'struct vm_area_struct' declared inside parameter list will not be visible outside of this definition or declaration static inline void flush_icache_user_page(struct vm_area_struct *vma, ^~~~~~~~~~~~~~ Completed OK # rm -rf /kisskb/build/linus_s390-allmodconfig_s390x-gcc8 # Build took: 0:19:44.185548