1. 24 Apr, 2021 1 commit
  2. 23 Apr, 2021 1 commit
    • He Ying's avatar
      irqchip/gic-v3: Do not enable irqs when handling spurious interrups · a97709f5
      He Ying authored
      We triggered the following error while running our 4.19 kernel
      with the pseudo-NMI patches backported to it:
      
      [   14.816231] ------------[ cut here ]------------
      [   14.816231] kernel BUG at irq.c:99!
      [   14.816232] Internal error: Oops - BUG: 0 [#1] SMP
      [   14.816232] Process swapper/0 (pid: 0, stack limit = 0x(____ptrval____))
      [   14.816233] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G           O      4.19.95.aarch64 #14
      [   14.816233] Hardware name: evb (DT)
      [   14.816234] pstate: 80400085 (Nzcv daIf +PAN -UAO)
      [   14.816234] pc : asm_nmi_enter+0x94/0x98
      [   14.816235] lr : asm_nmi_enter+0x18/0x98
      [   14.816235] sp : ffff000008003c50
      [   14.816235] pmr_save: 00000070
      [   14.816237] x29: ffff000008003c50 x28: ffff0000095f56c0
      [   14.816238] x27: 0000000000000000 x26: ffff000008004000
      [   14.816239] x25: 00000000015e0000 x24: ffff8008fb916000
      [   14.816240] x23: 0000000020400005 x22: ffff0000080817cc
      [   14.816241] x21: ffff000008003da0 x20: 0000000000000060
      [   14.816242] x19: 00000000000003ff x18: ffffffffffffffff
      [   14.816243] x17: 0000000000000008 x16: 003d090000000000
      [   14.816244] x15: ffff0000095ea6c8 x14: ffff8008fff5ab40
      [   14.816244] x13: ffff8008fff58b9d x12: 0000000000000000
      [   14.816245] x11: ffff000008c8a200 x10: 000000008e31fca5
      [   14.816246] x9 : ffff000008c8a208 x8 : 000000000000000f
      [   14.816247] x7 : 0000000000000004 x6 : ffff8008fff58b9e
      [   14.816248] x5 : 0000000000000000 x4 : 0000000080000000
      [   14.816249] x3 : 0000000000000000 x2 : 0000000080000000
      [   14.816250] x1 : 0000000000120000 x0 : ffff0000095f56c0
      [   14.816251] Call trace:
      [   14.816251]  asm_nmi_enter+0x94/0x98
      [   14.816251]  el1_irq+0x8c/0x180                    (IRQ C)
      [   14.816252]  gic_handle_irq+0xbc/0x2e4
      [   14.816252]  el1_irq+0xcc/0x180                    (IRQ B)
      [   14.816253]  arch_timer_handler_virt+0x38/0x58
      [   14.816253]  handle_percpu_devid_irq+0x90/0x240
      [   14.816253]  generic_handle_irq+0x34/0x50
      [   14.816254]  __handle_domain_irq+0x68/0xc0
      [   14.816254]  gic_handle_irq+0xf8/0x2e4
      [   14.816255]  el1_irq+0xcc/0x180                    (IRQ A)
      [   14.816255]  arch_cpu_idle+0x34/0x1c8
      [   14.816255]  default_idle_call+0x24/0x44
      [   14.816256]  do_idle+0x1d0/0x2c8
      [   14.816256]  cpu_startup_entry+0x28/0x30
      [   14.816256]  rest_init+0xb8/0xc8
      [   14.816257]  start_kernel+0x4c8/0x4f4
      [   14.816257] Code: 940587f1 d5384100 b9401001 36a7fd01 (d4210000)
      [   14.816258] Modules linked in: start_dp(O) smeth(O)
      [   15.103092] ---[ end trace 701753956cb14aa8 ]---
      [   15.103093] Kernel panic - not syncing: Fatal exception in interrupt
      [   15.103099] SMP: stopping secondary CPUs
      [   15.103100] Kernel Offset: disabled
      [   15.103100] CPU features: 0x36,a2400218
      [   15.103100] Memory Limit: none
      
      which is cause by a 'BUG_ON(in_nmi())' in nmi_enter().
      
      From the call trace, we can find three interrupts (noted A, B, C above):
      interrupt (A) is preempted by (B), which is further interrupted by (C).
      
      Subsequent investigations show that (B) results in nmi_enter() being
      called, but that it actually is a spurious interrupt. Furthermore,
      interrupts are reenabled in the context of (B), and (C) fires with
      NMI priority. We end-up with a nested NMI situation, something
      we definitely do not want to (and cannot) handle.
      
      The bug here is that spurious interrupts should never result in any
      state change, and we should just return to the interrupted context.
      Moving the handling of spurious interrupts as early as possible in
      the GICv3 handler fixes this issue.
      
      Fixes: 3f1f3234 ("irqchip/gic-v3: Switch to PMR masking before calling IRQ handler")
      Acked-by: default avatarMark Rutland <mark.rutland@arm.com>
      Signed-off-by: default avatarHe Ying <heying24@huawei.com>
      [maz: rewrote commit message, corrected Fixes: tag]
      Signed-off-by: default avatarMarc Zyngier <maz@kernel.org>
      Link: https://lore.kernel.org/r/20210423083516.170111-1-heying24@huawei.com
      Cc: stable@vger.kernel.org
      a97709f5
  3. 22 Apr, 2021 8 commits
  4. 08 Apr, 2021 1 commit
  5. 07 Apr, 2021 11 commits
  6. 09 Mar, 2021 2 commits
  7. 08 Mar, 2021 3 commits
  8. 06 Mar, 2021 4 commits
  9. 05 Mar, 2021 9 commits
    • Linus Torvalds's avatar
      Merge tag 'for-5.12/dm-fixes' of... · 63dcd69d
      Linus Torvalds authored
      Merge tag 'for-5.12/dm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm
      
      Pull device mapper fixes from Mike Snitzer:
       "Fix DM verity target's optional Forward Error Correction (FEC) for
        Reed-Solomon roots that are unaligned to block size"
      
      * tag 'for-5.12/dm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm:
        dm verity: fix FEC for RS roots unaligned to block size
        dm bufio: subtract the number of initial sectors in dm_bufio_get_device_size
      63dcd69d
    • Linus Torvalds's avatar
      Merge tag 'block-5.12-2021-03-05' of git://git.kernel.dk/linux-block · 47454caf
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
      
       - NVMe fixes:
            - more device quirks (Julian Einwag, Zoltán Böszörményi, Pascal
              Terjan)
            - fix a hwmon error return (Daniel Wagner)
            - fix the keep alive timeout initialization (Martin George)
            - ensure the model_number can't be changed on a used subsystem
              (Max Gurtovoy)
      
       - rsxx missing -EFAULT on copy_to_user() failure (Dan)
      
       - rsxx remove unused linux.h include (Tian)
      
       - kill unused RQF_SORTED (Jean)
      
       - updated outdated BFQ comments (Joseph)
      
       - revert work-around commit for bd_size_lock, since we removed the
         offending user in this merge window (Damien)
      
      * tag 'block-5.12-2021-03-05' of git://git.kernel.dk/linux-block:
        nvmet: model_number must be immutable once set
        nvme-fabrics: fix kato initialization
        nvme-hwmon: Return error code when registration fails
        nvme-pci: add quirks for Lexar 256GB SSD
        nvme-pci: mark Kingston SKC2000 as not supporting the deepest power state
        nvme-pci: mark Seagate Nytro XM1440 as QUIRK_NO_NS_DESC_LIST.
        rsxx: Return -EFAULT if copy_to_user() fails
        block/bfq: update comments and default value in docs for fifo_expire
        rsxx: remove unused including <linux/version.h>
        block: Drop leftover references to RQF_SORTED
        block: revert "block: fix bd_size_lock use"
      47454caf
    • Linus Torvalds's avatar
      Merge tag 'io_uring-5.12-2021-03-05' of git://git.kernel.dk/linux-block · f292e873
      Linus Torvalds authored
      Pull io_uring fixes from Jens Axboe:
       "A bit of a mix between fallout from the worker change, cleanups and
        reductions now possible from that change, and fixes in general. In
        detail:
      
         - Fully serialize manager and worker creation, fixing races due to
           that.
      
         - Clean up some naming that had gone stale.
      
         - SQPOLL fixes.
      
         - Fix race condition around task_work rework that went into this
           merge window.
      
         - Implement unshare. Used for when the original task does unshare(2)
           or setuid/seteuid and friends, drops the original workers and forks
           new ones.
      
         - Drop the only remaining piece of state shuffling we had left, which
           was cred. Move it into issue instead, and we can drop all of that
           code too.
      
         - Kill f_op->flush() usage. That was such a nasty hack that we had
           out of necessity, we no longer need it.
      
         - Following from ->flush() removal, we can also drop various bits of
           ctx state related to SQPOLL and cancelations.
      
         - Fix an issue with IOPOLL retry, which originally was fallout from a
           filemap change (removing iov_iter_revert()), but uncovered an issue
           with iovec re-import too late.
      
         - Fix an issue with system suspend.
      
         - Use xchg() for fallback work, instead of cmpxchg().
      
         - Properly destroy io-wq on exec.
      
         - Add create_io_thread() core helper, and use that in io-wq and
           io_uring. This allows us to remove various silly completion events
           related to thread setup.
      
         - A few error handling fixes.
      
        This should be the grunt of fixes necessary for the new workers, next
        week should be quieter. We've got a pending series from Pavel on
        cancelations, and how tasks and rings are indexed. Outside of that,
        should just be minor fixes. Even with these fixes, we're still killing
        a net ~80 lines"
      
      * tag 'io_uring-5.12-2021-03-05' of git://git.kernel.dk/linux-block: (41 commits)
        io_uring: don't restrict issue_flags for io_openat
        io_uring: make SQPOLL thread parking saner
        io-wq: kill hashed waitqueue before manager exits
        io_uring: clear IOCB_WAITQ for non -EIOCBQUEUED return
        io_uring: don't keep looping for more events if we can't flush overflow
        io_uring: move to using create_io_thread()
        kernel: provide create_io_thread() helper
        io_uring: reliably cancel linked timeouts
        io_uring: cancel-match based on flags
        io-wq: ensure all pending work is canceled on exit
        io_uring: ensure that threads freeze on suspend
        io_uring: remove extra in_idle wake up
        io_uring: inline __io_queue_async_work()
        io_uring: inline io_req_clean_work()
        io_uring: choose right tctx->io_wq for try cancel
        io_uring: fix -EAGAIN retry with IOPOLL
        io-wq: fix error path leak of buffered write hash map
        io_uring: remove sqo_task
        io_uring: kill sqo_dead and sqo submission halting
        io_uring: ignore double poll add on the same waitqueue head
        ...
      f292e873
    • Linus Torvalds's avatar
      Merge tag 'pm-5.12-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 6d47254c
      Linus Torvalds authored
      Pull power management fixes from Rafael Wysocki:
       "These fix the usage of device links in the runtime PM core code and
        update the DTPM (Dynamic Thermal Power Management) feature added
        recently.
      
        Specifics:
      
         - Make the runtime PM core code avoid attempting to suspend supplier
           devices before updating the PM-runtime status of a consumer to
           'suspended' (Rafael Wysocki).
      
         - Fix DTPM (Dynamic Thermal Power Management) root node
           initialization and label that feature as EXPERIMENTAL in Kconfig
           (Daniel Lezcano)"
      
      * tag 'pm-5.12-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        powercap/drivers/dtpm: Add the experimental label to the option description
        powercap/drivers/dtpm: Fix root node initialization
        PM: runtime: Update device status before letting suppliers suspend
      6d47254c
    • Linus Torvalds's avatar
      Merge tag 'acpi-5.12-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · ea6be461
      Linus Torvalds authored
      Pull ACPI fix from Rafael Wysocki:
       "Make the empty stubs of some helper functions used when CONFIG_ACPI is
        not set actually match those functions (Andy Shevchenko)"
      
      * tag 'acpi-5.12-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        ACPI: bus: Constify is_acpi_node() and friends (part 2)
      ea6be461
    • Linus Torvalds's avatar
      Merge tag 'iommu-fixes-v5.12-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu · fc2c8d0a
      Linus Torvalds authored
      Pull iommu fixes from Joerg Roedel:
      
       - Fix a sleeping-while-atomic issue in the AMD IOMMU code
      
       - Disable lazy IOTLB flush for untrusted devices in the Intel VT-d
         driver
      
       - Fix status code definitions for Intel VT-d
      
       - Fix IO Page Fault issue in Tegra IOMMU driver
      
      * tag 'iommu-fixes-v5.12-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu:
        iommu/vt-d: Fix status code for Allocate/Free PASID command
        iommu: Don't use lazy flush for untrusted device
        iommu/tegra-smmu: Fix mc errors on tegra124-nyan
        iommu/amd: Fix sleeping in atomic in increase_address_space()
      fc2c8d0a
    • Linus Torvalds's avatar
      Merge tag 'for-5.12-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux · f09b04cc
      Linus Torvalds authored
      Pull btrfs fixes from David Sterba:
       "More regression fixes and stabilization.
      
        Regressions:
      
         - zoned mode
            - count zone sizes in wider int types
            - fix space accounting for read-only block groups
      
         - subpage: fix page tail zeroing
      
        Fixes:
      
         - fix spurious warning when remounting with free space tree
      
         - fix warning when creating a directory with smack enabled
      
         - ioctl checks for qgroup inheritance when creating a snapshot
      
         - qgroup
            - fix missing unlock on error path in zero range
            - fix amount of released reservation on error
            - fix flushing from unsafe context with open transaction,
              potentially deadlocking
      
         - minor build warning fixes"
      
      * tag 'for-5.12-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
        btrfs: zoned: do not account freed region of read-only block group as zone_unusable
        btrfs: zoned: use sector_t for zone sectors
        btrfs: subpage: fix the false data csum mismatch error
        btrfs: fix warning when creating a directory with smack enabled
        btrfs: don't flush from btrfs_delayed_inode_reserve_metadata
        btrfs: export and rename qgroup_reserve_meta
        btrfs: free correct amount of space in btrfs_delayed_inode_reserve_metadata
        btrfs: fix spurious free_space_tree remount warning
        btrfs: validate qgroup inherit for SNAP_CREATE_V2 ioctl
        btrfs: unlock extents in btrfs_zero_range in case of quota reservation errors
        btrfs: ref-verify: use 'inline void' keyword ordering
      f09b04cc
    • Linus Torvalds's avatar
      Merge tag 'devicetree-fixes-for-5.12-1' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux · 6bf331d5
      Linus Torvalds authored
      Pull devicetree fixes from Rob Herring:
      
       - Another batch of graph and video-interfaces schema conversions
      
       - Drop DT header symlink for dropped C6X arch
      
       - Fix bcm2711-hdmi schema error
      
      * tag 'devicetree-fixes-for-5.12-1' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux:
        dt-bindings: media: Use graph and video-interfaces schemas, round 2
        dts: drop dangling c6x symlink
        dt-bindings: bcm2711-hdmi: Fix broken schema
      6bf331d5
    • Linus Torvalds's avatar
      Merge tag 'trace-v5.12-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace · 54663cf3
      Linus Torvalds authored
      Pull tracing fixes from Steven Rostedt:
       "Functional fixes:
      
         - Fix big endian conversion for arm64 in recordmcount processing
      
         - Fix timestamp corruption in ring buffer on discarding events
      
         - Fix memory leak in __create_synth_event()
      
         - Skip selftests if tracing is disabled as it will cause them to
           fail.
      
        Non-functional fixes:
      
         - Fix help text in Kconfig
      
         - Remove duplicate prototype for trace_empty()
      
         - Fix stale comment about the trace_event_call flags.
      
        Self test update:
      
         - Add more information to the validation output of when a corrupt
           timestamp is found in the ring buffer, and also trigger a warning
           to make sure that tests catch it"
      
      * tag 'trace-v5.12-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace:
        tracing: Fix comment about the trace_event_call flags
        tracing: Skip selftests if tracing is disabled
        tracing: Fix memory leak in __create_synth_event()
        ring-buffer: Add a little more information and a WARN when time stamp going backwards is detected
        ring-buffer: Force before_stamp and write_stamp to be different on discard
        tracing: Fix help text of TRACEPOINT_BENCHMARK in Kconfig
        tracing: Remove duplicate declaration from trace.h
        ftrace: Have recordmcount use w8 to read relp->r_info in arm64_is_fake_mcount
      54663cf3