FYI, we noticed the following commit: commit: 7361ce7529bd0a6525d088a0def0f392d98f00d3 ("Make LSM Writable Hooks a command line option") url: https://github.com/0day-ci/linux/commits/Igor-Stoppa/ro-protection-for-dynamic-data/20170627-103230 base: git://git.cmpxchg.org/linux-mmotm.git master in testcase: trinity with following parameters: runtime: 300s test-description: Trinity is a linux system call fuzz tester. test-url: http://codemonkey.org.uk/projects/trinity/ on test machine: qemu-system-x86_64 -enable-kvm -m 420M caused below changes (please refer to attached dmesg/kmsg for entire log/backtrace): +----------------------------------------------------------------+------------+------------+ | | 2131b0bc3a | 7361ce7529 | +----------------------------------------------------------------+------------+------------+ | boot_successes | 12 | 0 | | boot_failures | 0 | 66 | | BUG:sleeping_function_called_from_invalid_context_at_mm/slab.h | 0 | 66 | | INFO:lockdep_is_turned_off | 0 | 66 | | BUG:key_not_in.data | 0 | 66 | +----------------------------------------------------------------+------------+------------+ [ 8.693078] BUG: sleeping function called from invalid context at mm/slab.h:416 [ 8.694030] in_atomic(): 1, irqs_disabled(): 1, pid: 1, name: swapper/0 [ 8.694651] INFO: lockdep is turned off. [ 8.695074] irq event stamp: 1559917 [ 8.695493] hardirqs last enabled at (1559917): [] _raw_spin_unlock_irqrestore+0x46/0x5a [ 8.696443] hardirqs last disabled at (1559916): [] _raw_spin_lock_irqsave+0x23/0x84 [ 8.697373] softirqs last enabled at (1559890): [] bnx2fc_mod_init+0x1f6/0x319 [ 8.698238] softirqs last disabled at (1559888): [] bnx2fc_mod_init+0x1e3/0x319 [ 8.699097] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.12.0-rc5-mm1-00320-g7361ce75 #22 [ 8.699904] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.9.3-20161025_171302-gandalf 04/01/2014 [ 8.700864] Call Trace: [ 8.701187] dump_stack+0x82/0xb8 [ 8.701566] ___might_sleep+0x1bc/0x1cf [ 8.701985] __might_sleep+0x6d/0x74 [ 8.702413] slab_pre_alloc_hook+0x32/0x3f [ 8.702868] __kmalloc+0x52/0x148 [ 8.703244] ? ___cache_free+0x176/0x3e2 [ 8.703667] ? kzalloc+0xe/0x10 [ 8.704152] ? __pmalloc_connect+0x4d/0x4d [ 8.704585] ? gen_pool_destroy+0xb1/0xb1 [ 8.705010] kzalloc+0xe/0x10 [ 8.705462] device_private_init+0x17/0x64 [ 8.705891] device_add+0x5e/0x509 [ 8.706276] ? lock_acquired+0xcd/0x2bc [ 8.706684] ? devres_for_each_res+0x46/0xc2 [ 8.707129] ? __pmalloc_connect+0x4d/0x4d [ 8.707564] ? gen_pool_destroy+0xb1/0xb1 [ 8.708020] __pmalloc_connect+0x1b/0x4d [ 8.708439] __pmalloc_late_add+0x23/0x25 [ 8.708865] devres_for_each_res+0x82/0xc2 [ 8.709304] ? sparse_mem_maps_populate_node+0x13a/0x13a [ 8.709843] ? set_debug_rodata+0x17/0x17 [ 8.710266] pmalloc_late_init+0x4b/0x50 [ 8.710681] do_one_initcall+0x90/0x138 [ 8.711094] ? set_debug_rodata+0x17/0x17 [ 8.711514] kernel_init_freeable+0x1c6/0x24e [ 8.711964] ? rest_init+0xd8/0xd8 [ 8.712346] kernel_init+0xe/0xfa [ 8.712735] ret_from_fork+0x2a/0x40 [ 8.713173] BUG: key ffff9356f80c24e0 not in .data! [ 8.713682] BUG: key ffff9356f80c2510 not in .data! [ 8.714264] BUG: key ffff9356f80c2540 not in .data! [ 8.715020] kAFS: Red Hat AFS client v0.1 registering. [ 8.715591] random: generate_random_uuid+0x12/0x2d get_random_bytes called with crng_init=0 [ 8.716473] FS-Cache: Netfs 'afs' registered for caching [ 8.718480] Btrfs loaded, crc32c=crc32c-generic [ 8.718999] random: key_alloc+0x25a/0x3ce get_random_bytes called with crng_init=0 [ 8.719815] random: prandom_seed_full_state+0x43/0x9c get_random_bytes called with crng_init=0 [ 8.721515] console [netcon0] enabled [ 8.721940] netconsole: network logging started [ 8.722500] rtc_cmos 00:00: setting system clock to 2017-06-27 11:19:14 UTC (1498562354) [ 8.723373] BIOS EDD facility v0.16 2004-Jun-25, 0 devices found [ 8.724025] EDD information not available. [ 8.724952] IPv6: ADDRCONF(NETDEV_UP): bond0: link is not ready [ 8.725577] 8021q: adding VLAN 0 to HW filter on device bond0 [ 8.726198] random: ip_auto_config+0x269/0xeaa get_random_bytes called with crng_init=0 [ 8.727514] IP-Config: Failed to open ipddp0 [ 8.729906] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready [ 8.730943] 8021q: adding VLAN 0 to HW filter on device eth0 [ 8.731579] IP-Config: Failed to open plip0 [ 8.732056] ieee80211 phy0: mac80211_hwsim_start [ 8.732558] ieee80211 phy0: mac80211_hwsim_add_interface (type=2 mac_addr=02:00:00:00:00:00) [ 8.733424] ieee80211 phy0: mac80211_hwsim_bss_info_changed(changed=0xe vif->addr=02:00:00:00:00:00) [ 8.734421] ieee80211 phy0: ERP_CTS_PROT: 0 [ 8.734901] ieee80211 phy0: ERP_PREAMBLE: 0 [ 8.735373] ieee80211 phy0: ERP_SLOT: 0 [ 8.735810] ieee80211 phy0: mac80211_hwsim_conf_tx (queue=0 txop=0 cw_min=15 cw_max=1023 aifs=2) [ 8.737179] ieee80211 phy0: mac80211_hwsim_conf_tx (queue=1 txop=0 cw_min=15 cw_max=1023 aifs=2) [ 8.738083] ieee80211 phy0: mac80211_hwsim_conf_tx (queue=2 txop=0 cw_min=15 cw_max=1023 aifs=2) [ 8.738978] ieee80211 phy0: mac80211_hwsim_conf_tx (queue=3 txop=0 cw_min=15 cw_max=1023 aifs=2) [ 8.739886] ieee80211 phy0: mac80211_hwsim_bss_info_changed(changed=0x2000 vif->addr=02:00:00:00:00:00) [ 8.741218] e1000: eth0 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX [ 8.742321] ieee80211 phy0: mac80211_hwsim_config (freq=2412(2412 - 0)/noht idle=1 ps=0 smps=static) [ 8.743244] ieee80211 phy0: mac80211_hwsim_configure_filter [ 8.743846] ieee80211 phy0: mac80211_hwsim_configure_filter [ 8.744631] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready [ 8.745260] ieee80211 phy0: mac80211_hwsim_configure_filter [ 8.745847] ieee80211 phy1: mac80211_hwsim_start [ 8.746336] ieee80211 phy1: mac80211_hwsim_add_interface (type=2 mac_addr=02:00:00:00:01:00) [ 8.747198] ieee80211 phy1: mac80211_hwsim_bss_info_changed(changed=0xe vif->addr=02:00:00:00:01:00) [ 8.748125] ieee80211 phy1: ERP_CTS_PROT: 0 [ 8.748580] ieee80211 phy1: ERP_PREAMBLE: 0 [ 8.749037] ieee80211 phy1: ERP_SLOT: 0 [ 8.749468] ieee80211 phy1: mac80211_hwsim_conf_tx (queue=0 txop=0 cw_min=15 cw_max=1023 aifs=2) [ 8.750358] ieee80211 phy1: mac80211_hwsim_conf_tx (queue=1 txop=0 cw_min=15 cw_max=1023 aifs=2) [ 8.751244] ieee80211 phy1: mac80211_hwsim_conf_tx (queue=2 txop=0 cw_min=15 cw_max=1023 aifs=2) [ 8.752122] ieee80211 phy1: mac80211_hwsim_conf_tx (queue=3 txop=0 cw_min=15 cw_max=1023 aifs=2) [ 8.753012] ieee80211 phy1: mac80211_hwsim_bss_info_changed(changed=0x2000 vif->addr=02:00:00:00:01:00) [ 8.754011] ieee80211 phy1: mac80211_hwsim_config (freq=2412(2412 - 0)/noht idle=1 ps=0 smps=static) [ 8.754931] ieee80211 phy1: mac80211_hwsim_configure_filter [ 8.755556] ieee80211 phy1: mac80211_hwsim_configure_filter [ 8.756353] IPv6: ADDRCONF(NETDEV_UP): wlan1: link is not ready [ 8.756973] ieee80211 phy1: mac80211_hwsim_configure_filter [ 8.757604] IP-Config: Failed to open gretap0 [ 8.758097] IP-Config: Failed to open irlan0 [ 8.758631] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready [ 8.759805] random: addrconf_dad_kick+0x9f/0xa8 get_random_bytes called with crng_init=0 [ 8.776028] Sending DHCP requests . [ 8.776034] random: ip_auto_config+0x4ad/0xeaa get_random_bytes called with crng_init=0 [ 8.777423] random: hash_conntrack_raw+0x42/0x13b get_random_bytes called with crng_init=0 [ 8.778372] , OK [ 8.778726] IP-Config: Got DHCP answer from 10.0.2.2, my address is 10.0.2.15 [ 8.779436] IP-Config: Complete: [ 8.779835] device=eth0, hwaddr=52:54:00:12:34:56, ipaddr=10.0.2.15, mask=255.255.255.0, gw=10.0.2.2 [ 8.780769] host=vm-lkp-hsw01-openwrt-ia32-18, domain=, nis-domain=(none) [ 8.781543] bootserver=10.0.2.2, rootserver=10.0.2.2, rootpath= nameserver0=10.0.2.3 [ 8.782856] ieee80211 phy0: mac80211_hwsim_configure_filter [ 8.783444] ieee80211 phy0: mac80211_hwsim_remove_interface (type=2 mac_addr=02:00:00:00:00:00) [ 8.784381] ieee80211 phy0: mac80211_hwsim_stop [ 8.784907] ieee80211 phy1: mac80211_hwsim_configure_filter [ 8.785519] ieee80211 phy1: mac80211_hwsim_remove_interface (type=2 mac_addr=02:00:00:00:01:00) [ 8.786422] ieee80211 phy1: mac80211_hwsim_stop [ 8.787006] PM: Hibernation image not present or could not be loaded. [ 8.787655] ALSA device list: [ 8.788042] #0: Dummy 1 [ 8.788383] #1: Loopback 1 [ 8.788749] #2: Virtual MIDI Card 1 [ 8.796051] Freeing unused kernel memory: 4788K [ 8.796586] Write protecting the kernel read-only data: 49152k [ 8.797768] Freeing unused kernel memory: 40K [ 8.803432] Freeing unused kernel memory: 1596K [ 8.803954] rodata_test: all tests were successful [ 8.804563] random: arch_pick_mmap_layout+0x3a/0xf8 get_random_u64 called with crng_init=0 [ 8.805439] random: arch_pick_mmap_layout+0x9b/0xf8 get_random_u64 called with crng_init=0 [ 8.806298] random: load_elf_binary+0x32a/0xe32 get_random_u64 called with crng_init=0 [ 8.807107] random: arch_align_stack+0x2d/0x3f get_random_u32 called with crng_init=0 [ 8.807984] random: create_elf_tables+0xae/0x53c get_random_bytes called with crng_init=0 [ 8.808815] random: randomize_page+0x4e/0x62 get_random_u64 called with crng_init=0 [ 8.828632] init: Console is alive [ 8.829143] init: - watchdog - [ 8.829818] random: arch_pick_mmap_layout+0x3a/0xf8 get_random_u64 called with crng_init=0 [ 8.830677] random: arch_pick_mmap_layout+0x9b/0xf8 get_random_u64 called with crng_init=0 [ 8.831515] random: load_elf_binary+0x32a/0xe32 get_random_u64 called with crng_init=0 [ 8.832538] random: randomize_page+0x4e/0x62 get_random_u64 called with crng_init=0 [ 9.830020] init: - preinit - [ 9.831539] random: arch_pick_mmap_layout+0x3a/0xf8 get_random_u64 called with crng_init=0 [ 9.833342] random: arch_pick_mmap_layout+0x3a/0xf8 get_random_u64 called with crng_init=0 [ 9.833347] random: arch_pick_mmap_layout+0x9b/0xf8 get_random_u64 called with crng_init=0 [ 9.833356] random: load_elf_binary+0x32a/0xe32 get_random_u64 called with crng_init=0 [ 9.833419] random: randomize_page+0x4e/0x62 get_random_u64 called with crng_init=0 [ 9.840254] random: arch_pick_mmap_layout+0x9b/0xf8 get_random_u64 called with crng_init=0 [ 9.841701] random: load_elf_binary+0x32a/0xe32 get_random_u64 called with crng_init=0 To reproduce: git clone https://github.com/01org/lkp-tests.git cd lkp-tests bin/lkp qemu -k job-script # job-script is attached in this email Thanks, Kernel Test Robot