It's an upstream bug - i can reproduce it on lundmark (thunderx) with 4.14.26 (latest 4.14 stable release) using the artful .config (make oldconfig and accept all defaults values - i'll attach the config below). It appears it only shows up on ThunderX SOCs (the same test on a hisilicon d05 worked fine), and the toolchain doesn't matter, it shows up when the kernel was compiled with the artful or xenial toolchain, no matter what. I'm reducing the scope before reporting it upstream. ubuntu@lundmark:~$ uname -a Linux lundmark 4.14.26+ #3 SMP Mon Mar 12 15:48:47 UTC 2018 aarch64 aarch64 aarch64 GNU/Linux ubuntu@lundmark:~$ sudo ./zram_smoke_test.sh PASSED: zram module loaded PASSED: got 48 compression streams PASSED: got lzo lz4 deflate lz4hc 842 compression algorithmns PASSED: mkfs.ext4 on ZRAM successful PASSED: ext4 on ZRAM (lzo), memory used: 41945534 4497 PASSED: mkfs.ext4 on ZRAM successful PASSED: ext4 on ZRAM (lz4), memory used: 41945256 4006 [from the serial console] dmesg: ... [ 289.708789] zram: Added device: zram0 [ 291.743271] zram0: detected capacity change from 0 to 134217728 [ 291.909193] EXT4-fs (zram0): mounted filesystem with ordered data mode. Opts: (null) [ 295.177609] zram0: detected capacity change from 134217728 to 0 [ 296.291895] zram0: detected capacity change from 0 to 134217728 [ 296.394257] EXT4-fs (zram0): mounted filesystem with ordered data mode. Opts: (null) [ 299.602110] zram0: detected capacity change from 134217728 to 0 [ 300.606078] zram0: detected capacity change from 0 to 134217728 [ 327.694207] watchdog: BUG: soft lockup - CPU#25 stuck for 23s! [mkfs.ext4:2016] [ 327.701593] Modules linked in: lz4 lz4_compress zram nicvf nicpf nls_iso8859_1 ast ttm thunder_bgx drm_kms_helper thunder_xcv thunderx_mmc mdio_thund er mdio_cavium drm fb_sys_fops syscopyarea sysfillrect sysimgblt i2c_thunderx i2c_smbus i2c_algo_bit thunderx_edac thunderx_zip cavium_rng_vf shpchp cav ium_rng aes_ce_blk crypto_simd cryptd aes_ce_cipher crc32_ce crct10dif_ce ghash_ce ipmi_ssif aes_arm64 ipmi_devintf gpio_keys sha2_ce sha256_arm64 sha1_ ce ipmi_msghandler uio_pdrv_genirq uio ib_iser rdma_cm iw_cm ib_cm ib_core iscsi_tcp libiscsi_tcp libiscsi scsi_transport_iscsi ip_tables x_tables autof s4 [ 327.701693] CPU: 25 PID: 2016 Comm: mkfs.ext4 Not tainted 4.14.26+ #3 [ 327.701695] Hardware name: Cavium ThunderX CRB/To be filled by O.E.M., BIOS 5.11 12/12/2012 [ 327.701698] task: ffff801f56dc0f00 task.stack: ffff000012768000 [ 327.701711] PC is at zip_deflate+0x180/0x2e8 [thunderx_zip] [ 327.701717] LR is at zip_deflate+0x17c/0x2e8 [thunderx_zip] [ 327.701720] pc : [] lr : [] pstate: 20400145 [ 327.701721] sp : ffff00001276b570 [ 327.701723] x29: ffff00001276b570 x28: 0000000000000000 [ 327.701728] x27: ffff801f27f2ec00 x26: 0000000000000000 [ 327.701733] x25: ffff801f58b5c000 x24: ffff801f6f72ac18 [ 327.701738] x23: 0000000000001000 x22: ffff00001276b678 [ 327.701743] x21: ffff801f59214880 x20: ffff801f6f72ac18 [ 327.701748] x19: ffff00001276b5f8 x18: 0000000000000000 [ 327.701752] x17: 0000000000000001 x16: 0000000000000000 [ 327.701757] x15: 0000aaab222018db x14: 00000000fb570000 [ 327.701762] x13: 0000100000000000 x12: 00000000fb560000 [ 327.701766] x11: 0000000000000000 x10: 0000000000000000 [ 327.701771] x9 : 0000000000000000 x8 : 0000000000000000 [ 327.701775] x7 : 0000000000000000 x6 : ffff8000101d8080 [ 327.701780] x5 : ffff000002031058 x4 : 0000000000000008 [ 327.701785] x3 : 0000000000000000 x2 : 0000000000000001 [ 327.701789] x1 : ffff801f6f72ae08 x0 : 0000000000000000 [ 327.701794] Call trace: [ 327.701798] Exception stack(0xffff00001276b430 to 0xffff00001276b570) [151/9460] [ 327.701801] b420: 0000000000000000 ffff801f6f72ae08 [ 327.701805] b440: 0000000000000001 0000000000000000 0000000000000008 ffff000002031058 [ 327.701809] b460: ffff8000101d8080 0000000000000000 0000000000000000 0000000000000000 [ 327.701812] b480: 0000000000000000 0000000000000000 00000000fb560000 0000100000000000 [ 327.701816] b4a0: 00000000fb570000 0000aaab222018db 0000000000000000 0000000000000001 [ 327.701820] b4c0: 0000000000000000 ffff00001276b5f8 ffff801f6f72ac18 ffff801f59214880 [ 327.701823] b4e0: ffff00001276b678 0000000000001000 ffff801f6f72ac18 ffff801f58b5c000 [ 327.701827] b500: 0000000000000000 ffff801f27f2ec00 0000000000000000 ffff00001276b570 [ 327.701831] b520: ffff000002031614 ffff00001276b570 ffff000002031618 0000000020400145 [ 327.701834] b540: ffff801f59214880 ffff00001276b678 0000ffffffffffff ffff801f6f72ac18 [ 327.701837] b560: ffff00001276b570 ffff000002031618 [ 327.701844] [] zip_deflate+0x180/0x2e8 [thunderx_zip] [ 327.701850] [] zip_compress+0xd8/0x158 [thunderx_zip] [ 327.701856] [] zip_comp_compress+0x48/0x60 [thunderx_zip] [ 327.701863] [] crypto_compress+0x50/0x68 [ 327.701874] [] zcomp_compress+0x48/0x58 [zram] [ 327.701880] [] zram_bvec_rw.isra.22+0x1d8/0x618 [zram] [ 327.701887] [] zram_make_request+0x13c/0x358 [zram] [ 327.701893] [] generic_make_request+0xf4/0x288 [ 327.701896] [] submit_bio+0x5c/0x198 [ 327.701901] [] submit_bh_wbc+0x17c/0x1d0 [ 327.701904] [] __block_write_full_page+0x22c/0x3d0 [ 327.701907] [] block_write_full_page+0x10c/0x120 [ 327.701910] [] blkdev_writepage+0x30/0x40 [ 327.701915] [] __writepage+0x38/0x88 [ 327.701918] [] write_cache_pages+0x1f4/0x4d0 [ 327.701921] [] generic_writepages+0x64/0xa0 [ 327.701924] [] blkdev_writepages+0x38/0x60 [ 327.701927] [] do_writepages+0x5c/0x108 [ 327.701933] [] __filemap_fdatawrite_range+0xec/0x128 [ 327.701936] [] file_write_and_wait_range+0x74/0xd8 [ 327.701939] [] blkdev_fsync+0x3c/0x70 [ 327.701945] [] vfs_fsync_range+0x64/0xc0 [ 327.701948] [] do_fsync+0x48/0x78 [ 327.701951] [] SyS_fsync+0x24/0x38 [ 327.701954] Exception stack(0xffff00001276bec0 to 0xffff00001276c000) [ 327.701957] bec0: 0000000000000003 0000000000000000 0000000000001000 0000000000001000 [ 327.701961] bee0: 0000000000000000 0000aaab222018d4 0000000000000000 0000000067645f80 [ 327.701964] bf00: 0000000000000052 00000000000003f8 0000000000000400 0000000000000800 [ 327.701968] bf20: 0000000000000c00 0000000000001000 0000000000001c00 0000aaab222018db [ 327.701972] bf40: 0000ffff870b5c98 0000ffff86f40b58 0000000000000000 0000000000000000 [ 327.701975] bf60: 0000aaab221fd1d0 0000000000000000 0000000000000000 0000aaab22200f70 [ 327.701979] bf80: 0000ffffc2be70a0 0000aaab222014e0 0000aaab22200f70 0000000000000000 [ 327.701982] bfa0: 0000aaab22200f70 0000ffffc2be6e90 0000ffff8709b0a4 0000ffffc2be6e90 [ 327.701986] bfc0: 0000ffff86f40b7c 0000000060000000 0000000000000003 0000000000000052 [ 327.701990] bfe0: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 [ 327.701994] [] el0_svc_naked+0x34/0x38 [ 355.685032] watchdog: BUG: soft lockup - CPU#8 stuck for 23s! [kworker/u96:3:411] [ 355.692587] Modules linked in: lz4 lz4_compress zram nicvf nicpf nls_iso8859_1 ast ttm thunder_bgx drm_kms_helper thunder_xcv thunderx_mmc mdio_thund er mdio_cavium drm fb_sys_fops syscopyarea sysfillrect sysimgblt i2c_thunderx i2c_smbus i2c_algo_bit thunderx_edac thunderx_zip cavium_rng_vf shpchp cav ium_rng aes_ce_blk crypto_simd cryptd aes_ce_cipher crc32_ce crct10dif_ce ghash_ce ipmi_ssif aes_arm64 ipmi_devintf gpio_keys sha2_ce sha256_arm64 sha1_ ce ipmi_msghandler uio_pdrv_genirq uio ib_iser rdma_cm iw_cm ib_cm ib_core iscsi_tcp libiscsi_tcp libiscsi scsi_transport_iscsi ip_tables x_tables autof s4 [ 355.692678] CPU: 8 PID: 411 Comm: kworker/u96:3 Tainted: G L 4.14.26+ #3 [ 355.692680] Hardware name: Cavium ThunderX CRB/To be filled by O.E.M., BIOS 5.11 12/12/2012 [ 355.692687] Workqueue: writeback wb_workfn (flush-252:0) [ 355.692693] task: ffff801f27cf0000 task.stack: ffff000012268000 [ 355.692701] PC is at zip_deflate+0x180/0x2e8 [thunderx_zip] [ 355.692706] LR is at zip_deflate+0x17c/0x2e8 [thunderx_zip] [ 355.692709] pc : [] lr : [] pstate: 20400145 [ 355.692711] sp : ffff00001226b320 [ 355.692713] x29: ffff00001226b320 x28: 0000000000000000 [89/9460] [ 355.692718] x27: ffff801f27f2ec00 x26: 0000000000000000 [ 355.692723] x25: ffff801f576c2000 x24: ffff801f6f72ac18 [ 355.692728] x23: 0000000000001000 x22: ffff00001226b428 [ 355.692733] x21: ffff801f71861c80 x20: ffff801f6f72ac18 [ 355.692737] x19: ffff00001226b3a8 x18: 0000000000000140 [ 355.692742] x17: 0000000000000002 x16: 0000000000000000 [ 355.692747] x15: 0000000000000012 x14: 00000000fb930000 [ 355.692752] x13: 0000100000000000 x12: 00000000fb920000 [ 355.692757] x11: 0000000000000000 x10: 0000000000000000 [ 355.692762] x9 : 0000000000000000 x8 : 0000000000000000 [ 355.692766] x7 : 0000000000000000 x6 : ffff8000101d6080 [ 355.692771] x5 : ffff000002031058 x4 : 0000000000000008 [ 355.692776] x3 : 0000000000000000 x2 : 0000000000000000 [ 355.692781] x1 : ffff801f6f72ae08 x0 : 0000000000000000 [ 355.692786] Call trace: [ 355.692789] Exception stack(0xffff00001226b1e0 to 0xffff00001226b320) [ 355.692793] b1e0: 0000000000000000 ffff801f6f72ae08 0000000000000000 0000000000000000 [ 355.692796] b200: 0000000000000008 ffff000002031058 ffff8000101d6080 0000000000000000 [ 355.692800] b220: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 [ 355.692803] b240: 00000000fb920000 0000100000000000 00000000fb930000 0000000000000012 [ 355.692807] b260: 0000000000000000 0000000000000002 0000000000000140 ffff00001226b3a8 [ 355.692811] b280: ffff801f6f72ac18 ffff801f71861c80 ffff00001226b428 0000000000001000 [ 355.692814] b2a0: ffff801f6f72ac18 ffff801f576c2000 0000000000000000 ffff801f27f2ec00 [ 355.692818] b2c0: 0000000000000000 ffff00001226b320 ffff000002031614 ffff00001226b320 [ 355.692822] b2e0: ffff000002031618 0000000020400145 ffff801f71861c80 ffff00001226b428 [ 355.692825] b300: ffffffffffffffff ffff801f6f72ac18 ffff00001226b320 ffff000002031618 [ 355.692832] [] zip_deflate+0x180/0x2e8 [thunderx_zip] [62/9460] [ 355.692838] [] zip_compress+0xd8/0x158 [thunderx_zip] [ 355.692844] [] zip_comp_compress+0x48/0x60 [thunderx_zip] [ 355.692847] [] crypto_compress+0x50/0x68 [ 355.692855] [] zcomp_compress+0x48/0x58 [zram] [ 355.692861] [] zram_bvec_rw.isra.22+0x1d8/0x618 [zram] [ 355.692867] [] zram_make_request+0x13c/0x358 [zram] [ 355.692871] [] generic_make_request+0xf4/0x288 [ 355.692874] [] submit_bio+0x5c/0x198 [ 355.692878] [] submit_bh_wbc+0x17c/0x1d0 [ 355.692881] [] __block_write_full_page+0x22c/0x3d0 [ 355.692884] [] block_write_full_page+0x10c/0x120 [ 355.692887] [] blkdev_writepage+0x30/0x40 [ 355.692890] [] __writepage+0x38/0x88 [ 355.692894] [] write_cache_pages+0x1f4/0x4d0 [ 355.692897] [] generic_writepages+0x64/0xa0 [ 355.692900] [] blkdev_writepages+0x38/0x60 [ 355.692903] [] do_writepages+0x5c/0x108 [ 355.692906] [] __writeback_single_inode+0x48/0x3f8 [ 355.692909] [] writeback_sb_inodes+0x1c0/0x460 [ 355.692912] [] __writeback_inodes_wb+0x78/0xc8 [ 355.692916] [] wb_writeback+0x224/0x350 [ 355.692919] [] wb_workfn+0x1c4/0x400 [ 355.692924] [] process_one_work+0x1e0/0x420 [ 355.692927] [] worker_thread+0x4c/0x478 [ 355.692931] [] kthread+0x138/0x140 [ 355.692935] [] ret_from_fork+0x10/0x1c [ 360.624822] INFO: rcu_sched self-detected stall on CPU [ 360.628822] INFO: rcu_sched detected stalls on CPUs/tasks: [ 360.628830] 25-...: (14999 ticks this GP) idle=ef2/140000000000001/0 softirq=921/921 fqs=6941 [ 360.628832] (detected by 17, t=15002 jiffies, g=2154, c=2153, q=5028) [ 360.628840] Task dump for CPU 25: [ 360.628843] mkfs.ext4 R running task 0 2016 1930 0x00000022 [ 360.628847] Call trace: [ 360.628853] [] __switch_to+0x94/0xd8 [28/9460] [ 360.628855] [] 0xffff801f269d7950 [ 360.650900] 25-...: (14999 ticks this GP) idle=ef2/140000000000001/0 softirq=921/921 fqs=6945 [ 360.659675] (t=15009 jiffies g=2154 c=2153 q=5028) [ 360.664687] Task dump for CPU 25: [ 360.664689] mkfs.ext4 R running task 0 2016 1930 0x00000022 [ 360.664694] Call trace: [ 360.664700] [] dump_backtrace+0x0/0x238 [ 360.664704] [] show_stack+0x24/0x30 [ 360.664709] [] sched_show_task+0x134/0x158 [ 360.664713] [] dump_cpu_task+0x48/0x58 [ 360.664717] [] rcu_dump_cpu_stacks+0x9c/0xdc [ 360.664720] [] rcu_check_callbacks+0x680/0x8a8 [ 360.664725] [] update_process_times+0x34/0x60 [ 360.664729] [] tick_sched_handle.isra.5+0x34/0x70 [ 360.664732] [] tick_sched_timer+0x48/0x98 [ 360.664735] [] __hrtimer_run_queues+0xe4/0x2c0 [ 360.664739] [] hrtimer_interrupt+0xa8/0x230 [ 360.664743] [] arch_timer_handler_phys+0x38/0x58 [ 360.664749] [] handle_percpu_devid_irq+0x90/0x260 [ 360.664752] [] generic_handle_irq+0x34/0x50 [ 360.664755] [] __handle_domain_irq+0x68/0xc0 [ 360.664758] [] gic_handle_irq+0x84/0x188 [ 360.664760] Exception stack(0xffff00001276b430 to 0xffff00001276b570) [ 360.664763] b420: 0000000000000000 ffff801f6f72ae08 [ 360.664767] b440: 0000000000000001 0000000000000000 0000000000000008 ffff000002031058 [ 360.664770] b460: ffff8000101d8080 0000000000000000 0000000000000000 0000000000000000 [ 360.664774] b480: 0000000000000000 0000000000000000 00000000fb560000 0000100000000000 [ 360.664778] b4a0: 00000000fb570000 0000aaab222018db 0000000000000000 0000000000000001 [ 360.664781] b4c0: 0000000000000000 ffff00001276b5f8 ffff801f6f72ac18 ffff801f59214880 [ 360.664785] b4e0: ffff00001276b678 0000000000001000 ffff801f6f72ac18 ffff801f58b5c000 [ 360.664789] b500: 0000000000000000 ffff801f27f2ec00 0000000000000000 ffff00001276b570 [ 360.664792] b520: ffff000002031614 ffff00001276b570 ffff00000203161c 0000000020400145 [ 360.664796] b540: ffff801f59214880 ffff00001276b678 0000ffffffffffff ffff801f6f72ac18 [ 360.664799] b560: ffff00001276b570 ffff00000203161c [ 360.664802] [] el1_irq+0xe8/0x180 [ 360.664809] [] zip_deflate+0x184/0x2e8 [thunderx_zip] [ 360.664815] [] zip_compress+0xd8/0x158 [thunderx_zip] [ 360.664821] [] zip_comp_compress+0x48/0x60 [thunderx_zip] [ 360.664824] [] crypto_compress+0x50/0x68 [ 360.664832] [] zcomp_compress+0x48/0x58 [zram] [ 360.664838] [] zram_bvec_rw.isra.22+0x1d8/0x618 [zram] [ 360.664844] [] zram_make_request+0x13c/0x358 [zram] [ 360.664848] [] generic_make_request+0xf4/0x288 [ 360.664851] [] submit_bio+0x5c/0x198 [ 360.664854] [] submit_bh_wbc+0x17c/0x1d0 [ 360.664857] [] __block_write_full_page+0x22c/0x3d0 [ 360.664860] [] block_write_full_page+0x10c/0x120 [ 360.664863] [] blkdev_writepage+0x30/0x40 [ 360.664867] [] __writepage+0x38/0x88 [ 360.664870] [] write_cache_pages+0x1f4/0x4d0 [ 360.664873] [] generic_writepages+0x64/0xa0 [ 360.664876] [] blkdev_writepages+0x38/0x60 [ 360.664879] [] do_writepages+0x5c/0x108 [ 360.664882] [] __filemap_fdatawrite_range+0xec/0x128 [ 360.664886] [] file_write_and_wait_range+0x74/0xd8 [ 360.664889] [] blkdev_fsync+0x3c/0x70 [ 360.664892] [] vfs_fsync_range+0x64/0xc0 [ 360.664895] [] do_fsync+0x48/0x78 [ 360.664898] [] SyS_fsync+0x24/0x38 [ 360.664901] Exception stack(0xffff00001276bec0 to 0xffff00001276c000) [ 360.664904] bec0: 0000000000000003 0000000000000000 0000000000001000 0000000000001000 [ 360.664908] bee0: 0000000000000000 0000aaab222018d4 0000000000000000 0000000067645f80 [ 360.664911] bf00: 0000000000000052 00000000000003f8 0000000000000400 0000000000000800 [ 360.664915] bf20: 0000000000000c00 0000000000001000 0000000000001c00 0000aaab222018db [ 360.664919] bf40: 0000ffff870b5c98 0000ffff86f40b58 0000000000000000 0000000000000000 [ 360.664922] bf60: 0000aaab221fd1d0 0000000000000000 0000000000000000 0000aaab22200f70 [ 360.664926] bf80: 0000ffffc2be70a0 0000aaab222014e0 0000aaab22200f70 0000000000000000 [ 360.664929] bfa0: 0000aaab22200f70 0000ffffc2be6e90 0000ffff8709b0a4 0000ffffc2be6e90 [ 360.664933] bfc0: 0000ffff86f40b7c 0000000060000000 0000000000000003 0000000000000052 [ 360.664936] bfe0: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 [ 360.664940] [] el0_svc_naked+0x34/0x38