1. 01 Jul, 2021 3 commits
    • Stephen Brennan's avatar
      ext4: use ext4_grp_locked_error in mb_find_extent · cd84bbba
      Stephen Brennan authored
      Commit 5d1b1b3f ("ext4: fix BUG when calling ext4_error with locked
      block group") introduces ext4_grp_locked_error to handle unlocking a
      group in error cases. Otherwise, there is a possibility of a sleep while
      atomic. However, since 43c73221 ("ext4: replace BUG_ON with WARN_ON
      in mb_find_extent()"), mb_find_extent() has contained a ext4_error()
      call while a group spinlock is held. Replace this with
      ext4_grp_locked_error.
      
      Fixes: 43c73221 ("ext4: replace BUG_ON with WARN_ON in mb_find_extent()")
      Cc: <stable@vger.kernel.org> # 4.14+
      Signed-off-by: default avatarStephen Brennan <stephen.s.brennan@oracle.com>
      Reviewed-by: default avatarLukas Czerner <lczerner@redhat.com>
      Reviewed-by: default avatarJunxiao Bi <junxiao.bi@oracle.com>
      Link: https://lore.kernel.org/r/20210623232114.34457-1-stephen.s.brennan@oracle.comSigned-off-by: default avatarTheodore Ts'o <tytso@mit.edu>
      cd84bbba
    • Ye Bin's avatar
      ext4: fix WARN_ON_ONCE(!buffer_uptodate) after an error writing the superblock · 558d6450
      Ye Bin authored
      If a writeback of the superblock fails with an I/O error, the buffer
      is marked not uptodate.  However, this can cause a WARN_ON to trigger
      when we attempt to write superblock a second time.  (Which might
      succeed this time, for cerrtain types of block devices such as iSCSI
      devices over a flaky network.)
      
      Try to detect this case in flush_stashed_error_work(), and also change
      __ext4_handle_dirty_metadata() so we always set the uptodate flag, not
      just in the nojournal case.
      
      Before this commit, this problem can be repliciated via:
      
      1. dmsetup  create dust1 --table  '0 2097152 dust /dev/sdc 0 4096'
      2. mount  /dev/mapper/dust1  /home/test
      3. dmsetup message dust1 0 addbadblock 0 10
      4. cd /home/test
      5. echo "XXXXXXX" > t
      
      After a few seconds, we got following warning:
      
      [   80.654487] end_buffer_async_write: bh=0xffff88842f18bdd0
      [   80.656134] Buffer I/O error on dev dm-0, logical block 0, lost async page write
      [   85.774450] EXT4-fs error (device dm-0): ext4_check_bdev_write_error:193: comm kworker/u16:8: Error while async write back metadata
      [   91.415513] mark_buffer_dirty: bh=0xffff88842f18bdd0
      [   91.417038] ------------[ cut here ]------------
      [   91.418450] WARNING: CPU: 1 PID: 1944 at fs/buffer.c:1092 mark_buffer_dirty.cold+0x1c/0x5e
      [   91.440322] Call Trace:
      [   91.440652]  __jbd2_journal_temp_unlink_buffer+0x135/0x220
      [   91.441354]  __jbd2_journal_unfile_buffer+0x24/0x90
      [   91.441981]  __jbd2_journal_refile_buffer+0x134/0x1d0
      [   91.442628]  jbd2_journal_commit_transaction+0x249a/0x3240
      [   91.443336]  ? put_prev_entity+0x2a/0x200
      [   91.443856]  ? kjournald2+0x12e/0x510
      [   91.444324]  kjournald2+0x12e/0x510
      [   91.444773]  ? woken_wake_function+0x30/0x30
      [   91.445326]  kthread+0x150/0x1b0
      [   91.445739]  ? commit_timeout+0x20/0x20
      [   91.446258]  ? kthread_flush_worker+0xb0/0xb0
      [   91.446818]  ret_from_fork+0x1f/0x30
      [   91.447293] ---[ end trace 66f0b6bf3d1abade ]---
      Signed-off-by: default avatarYe Bin <yebin10@huawei.com>
      Link: https://lore.kernel.org/r/20210615090537.3423231-1-yebin10@huawei.comSigned-off-by: default avatarTheodore Ts'o <tytso@mit.edu>
      558d6450
    • Theodore Ts'o's avatar
      Revert "ext4: consolidate checks for resize of bigalloc into ext4_resize_begin" · 8813587a
      Theodore Ts'o authored
      The function ext4_resize_begin() gets called from three different
      places, and online resize for bigalloc file systems is disallowed from
      the old-style online resize (EXT4_IOC_GROUP_ADD and
      EXT4_IOC_GROUP_EXTEND), but it *is* supposed to be allowed via
      EXT4_IOC_RESIZE_FS.
      
      This reverts commit e9f9f61d.
      8813587a
  2. 30 Jun, 2021 2 commits
  3. 24 Jun, 2021 15 commits
  4. 23 Jun, 2021 7 commits
  5. 22 Jun, 2021 1 commit
  6. 17 Jun, 2021 7 commits
  7. 06 Jun, 2021 5 commits
    • Linus Torvalds's avatar
      Linux 5.13-rc5 · 614124be
      Linus Torvalds authored
      614124be
    • Linus Torvalds's avatar
      Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · 90d56a3d
      Linus Torvalds authored
      Pull SCSI fixes from James Bottomley:
       "Five small and fairly minor fixes, all in drivers"
      
      * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        scsi: scsi_devinfo: Add blacklist entry for HPE OPEN-V
        scsi: ufs: ufs-mediatek: Fix HCI version in some platforms
        scsi: qedf: Do not put host in qedf_vport_create() unconditionally
        scsi: lpfc: Fix failure to transmit ABTS on FC link
        scsi: target: core: Fix warning on realtime kernels
      90d56a3d
    • Linus Torvalds's avatar
      Merge tag 'ext4_for_linus_stable' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 · 20e41d9b
      Linus Torvalds authored
      Pull ext4 fixes from Ted Ts'o:
       "Miscellaneous ext4 bug fixes"
      
      * tag 'ext4_for_linus_stable' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4:
        ext4: Only advertise encrypted_casefold when encryption and unicode are enabled
        ext4: fix no-key deletion for encrypt+casefold
        ext4: fix memory leak in ext4_fill_super
        ext4: fix fast commit alignment issues
        ext4: fix bug on in ext4_es_cache_extent as ext4_split_extent_at failed
        ext4: fix accessing uninit percpu counter variable with fast_commit
        ext4: fix memory leak in ext4_mb_init_backend on error path.
      20e41d9b
    • Linus Torvalds's avatar
      Merge tag 'arm-soc-fixes-v5.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc · decad3e1
      Linus Torvalds authored
      Pull ARM SoC fixes from Olof Johansson:
       "A set of fixes that have been coming in over the last few weeks, the
        usual mix of fixes:
      
         - DT fixups for TI K3
      
         - SATA drive detection fix for TI DRA7
      
         - Power management fixes and a few build warning removals for OMAP
      
         - OP-TEE fix to use standard API for UUID exporting
      
         - DT fixes for a handful of i.MX boards
      
        And a few other smaller items"
      
      * tag 'arm-soc-fixes-v5.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (29 commits)
        arm64: meson: select COMMON_CLK
        soc: amlogic: meson-clk-measure: remove redundant dev_err call in meson_msr_probe()
        ARM: OMAP1: ams-delta: remove unused function ams_delta_camera_power
        bus: ti-sysc: Fix flakey idling of uarts and stop using swsup_sidle_act
        ARM: dts: imx: emcon-avari: Fix nxp,pca8574 #gpio-cells
        ARM: dts: imx7d-pico: Fix the 'tuning-step' property
        ARM: dts: imx7d-meerkat96: Fix the 'tuning-step' property
        arm64: dts: freescale: sl28: var1: fix RGMII clock and voltage
        arm64: dts: freescale: sl28: var4: fix RGMII clock and voltage
        ARM: imx: pm-imx27: Include "common.h"
        arm64: dts: zii-ultra: fix 12V_MAIN voltage
        arm64: dts: zii-ultra: remove second GEN_3V3 regulator instance
        arm64: dts: ls1028a: fix memory node
        bus: ti-sysc: Fix am335x resume hang for usb otg module
        ARM: OMAP2+: Fix build warning when mmc_omap is not built
        ARM: OMAP1: isp1301-omap: Add missing gpiod_add_lookup_table function
        ARM: OMAP1: Fix use of possibly uninitialized irq variable
        optee: use export_uuid() to copy client UUID
        arm64: dts: ti: k3*: Introduce reg definition for interrupt routers
        arm64: dts: ti: k3-am65|j721e|am64: Map the dma / navigator subsystem via explicit ranges
        ...
      decad3e1
    • Linus Torvalds's avatar
      Merge tag 'powerpc-5.13-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux · bd7b12aa
      Linus Torvalds authored
      Pull powerpc fixes from Michael Ellerman:
       "Fix our KVM reverse map real-mode handling since we enabled huge
        vmalloc (in some configurations).
      
        Revert a recent change to our IOMMU code which broke some devices.
      
        Fix KVM handling of FSCR on P7/P8, which could have possibly let a
        guest crash it's Qemu.
      
        Fix kprobes validation of prefixed instructions across page boundary.
      
        Thanks to Alexey Kardashevskiy, Christophe Leroy, Fabiano Rosas,
        Frederic Barrat, Naveen N. Rao, and Nicholas Piggin"
      
      * tag 'powerpc-5.13-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
        Revert "powerpc/kernel/iommu: Align size for IOMMU_PAGE_SIZE() to save TCEs"
        KVM: PPC: Book3S HV: Save host FSCR in the P7/8 path
        powerpc: Fix reverse map real-mode address lookup with huge vmalloc
        powerpc/kprobes: Fix validation of prefixed instructions across page boundary
      bd7b12aa