1. 29 Dec, 2023 2 commits
  2. 28 Dec, 2023 5 commits
  3. 27 Dec, 2023 1 commit
    • Kent Overstreet's avatar
      bcachefs: Fix promotes · 7b474c77
      Kent Overstreet authored
      The recent work to fix data moves w.r.t. durability broke promotes,
      because the caused us to bail out when the extent minus pointers being
      dropped still has enough pointers to satisfy the current number of
      replicas.
      
      Disable this check when we're adding cached replicas.
      Signed-off-by: default avatarKent Overstreet <kent.overstreet@linux.dev>
      7b474c77
  4. 26 Dec, 2023 2 commits
    • Edward Adam Davis's avatar
      keys, dns: Fix missing size check of V1 server-list header · 1997b3cb
      Edward Adam Davis authored
      The dns_resolver_preparse() function has a check on the size of the
      payload for the basic header of the binary-style payload, but is missing
      a check for the size of the V1 server-list payload header after
      determining that's what we've been given.
      
      Fix this by getting rid of the the pointer to the basic header and just
      assuming that we have a V1 server-list payload and moving the V1 server
      list pointer inside the if-statement.  Dealing with other types and
      versions can be left for when such have been defined.
      
      This can be tested by doing the following with KASAN enabled:
      
          echo -n -e '\x0\x0\x1\x2' | keyctl padd dns_resolver foo @p
      
      and produces an oops like the following:
      
          BUG: KASAN: slab-out-of-bounds in dns_resolver_preparse+0xc9f/0xd60 net/dns_resolver/dns_key.c:127
          Read of size 1 at addr ffff888028894084 by task syz-executor265/5069
          ...
          Call Trace:
            dns_resolver_preparse+0xc9f/0xd60 net/dns_resolver/dns_key.c:127
            __key_create_or_update+0x453/0xdf0 security/keys/key.c:842
            key_create_or_update+0x42/0x50 security/keys/key.c:1007
            __do_sys_add_key+0x29c/0x450 security/keys/keyctl.c:134
            do_syscall_x64 arch/x86/entry/common.c:52 [inline]
            do_syscall_64+0x40/0x110 arch/x86/entry/common.c:83
            entry_SYSCALL_64_after_hwframe+0x62/0x6a
      
      This patch was originally by Edward Adam Davis, but was modified by
      Linus.
      
      Fixes: b946001d3bb1 ("keys, dns: Allow key types (eg. DNS) to be reclaimed immediately on expiry")
      Reported-and-tested-by: syzbot+94bbb75204a05da3d89f@syzkaller.appspotmail.com
      Link: https://lore.kernel.org/r/0000000000009b39bc060c73e209@google.com/Suggested-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      Signed-off-by: default avatarEdward Adam Davis <eadavis@qq.com>
      Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
      Tested-by: default avatarDavid Howells <dhowells@redhat.com>
      Cc: Edward Adam Davis <eadavis@qq.com>
      Cc: Jarkko Sakkinen <jarkko@kernel.org>
      Cc: Jeffrey E Altman <jaltman@auristor.com>
      Cc: Wang Lei <wang840925@gmail.com>
      Cc: Jeff Layton <jlayton@redhat.com>
      Cc: Steve French <sfrench@us.ibm.com>
      Cc: Marc Dionne <marc.dionne@auristor.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Eric Dumazet <edumazet@google.com>
      Cc: Jakub Kicinski <kuba@kernel.org>
      Cc: Paolo Abeni <pabeni@redhat.com>
      Reviewed-by: default avatarSimon Horman <horms@kernel.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      1997b3cb
    • Christoph Hellwig's avatar
      block: renumber QUEUE_FLAG_HW_WC · 02d374f3
      Christoph Hellwig authored
      For the QUEUE_FLAG_HW_WC to actually work, it needs to have a separate
      number from QUEUE_FLAG_FUA, doh.
      
      Fixes: 43c9835b ("block: don't allow enabling a cache on devices that don't support it")
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Link: https://lore.kernel.org/r/20231226081524.180289-1-hch@lst.deSigned-off-by: default avatarJens Axboe <axboe@kernel.dk>
      02d374f3
  5. 25 Dec, 2023 1 commit
  6. 24 Dec, 2023 2 commits
  7. 23 Dec, 2023 12 commits
    • Linus Torvalds's avatar
      Merge tag 'x86-urgent-2023-12-23' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 3f82f1c3
      Linus Torvalds authored
      Pull x86 fixes from Ingo Molnar:
      
       - Fix a secondary CPUs enumeration regression caused by creative MADT
         APIC table entries on certain systems.
      
       - Fix a race in the NOP-patcher that can spuriously trigger crashes on
         bootup.
      
       - Fix a bootup failure regression caused by the parallel bringup code,
         caused by firmware inconsistency between the APIC initialization
         states of the boot and secondary CPUs, on certain systems.
      
      * tag 'x86-urgent-2023-12-23' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/acpi: Handle bogus MADT APIC tables gracefully
        x86/alternatives: Disable interrupts and sync when optimizing NOPs in place
        x86/alternatives: Sync core before enabling interrupts
        x86/smpboot/64: Handle X2APIC BIOS inconsistency gracefully
      3f82f1c3
    • Linus Torvalds's avatar
      Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · f969c914
      Linus Torvalds authored
      Pull SCSI fixes from James Bottomley:
       "Four small fixes, three in drivers with the core one adding a batch
        indicator (for drivers which use it) to the error handler"
      
      * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        scsi: ufs: core: Let the sq_lock protect sq_tail_slot access
        scsi: ufs: qcom: Return ufs_qcom_clk_scale_*() errors in ufs_qcom_clk_scale_notify()
        scsi: core: Always send batch on reset or error handling command
        scsi: bnx2fc: Fix skb double free in bnx2fc_rcv()
      f969c914
    • Linus Torvalds's avatar
      Merge tag 'usb-6.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb · 4b2ee6d2
      Linus Torvalds authored
      Pull USB / Thunderbolt fixes from Greg KH:
       "Here are some small bugfixes and new device ids for USB and
        Thunderbolt drivers for 6.7-rc7. Included in here are:
      
         - new usb-serial device ids
      
         - thunderbolt driver fixes
      
         - typec driver fix
      
         - usb-storage driver quirk added
      
         - fotg210 driver fix
      
        All of these have been in linux-next with no reported issues"
      
      * tag 'usb-6.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
        USB: serial: option: add Quectel EG912Y module support
        USB: serial: ftdi_sio: update Actisense PIDs constant names
        usb: fotg210-hcd: delete an incorrect bounds test
        usb-storage: Add quirk for incorrect WP on Kingston DT Ultimate 3.0 G3
        usb: typec: ucsi: fix gpio-based orientation detection
        net: usb: ax88179_178a: avoid failed operations when device is disconnected
        USB: serial: option: add Quectel RM500Q R13 firmware support
        USB: serial: option: add Foxconn T99W265 with new baseline
        thunderbolt: Fix minimum allocated USB 3.x and PCIe bandwidth
        thunderbolt: Fix memory leak in margining_port_remove()
      4b2ee6d2
    • Linus Torvalds's avatar
      Merge tag 'char-misc-6.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc · a0652eb2
      Linus Torvalds authored
      Pull char / misc driver fixes from Greg KH:
       "Here are a small number of various driver fixes for 6.7-rc7 that
        normally come through the char-misc tree, and one debugfs fix as well.
      
        Included in here are:
      
         - iio and hid sensor driver fixes for a number of small things
      
         - interconnect driver fixes
      
         - brcm_nvmem driver fixes
      
         - debugfs fix for previous fix
      
         - guard() definition in device.h so that many subsystems can start
           using it for 6.8-rc1 (requested by Dan Williams to make future
           merges easier)
      
        All of these have been in linux-next for a while with no reported
        issues"
      
      * tag 'char-misc-6.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (21 commits)
        debugfs: initialize cancellations earlier
        Revert "iio: hid-sensor-als: Add light color temperature support"
        Revert "iio: hid-sensor-als: Add light chromaticity support"
        nvmem: brcm_nvram: store a copy of NVRAM content
        dt-bindings: nvmem: mxs-ocotp: Document fsl,ocotp
        driver core: Add a guard() definition for the device_lock()
        interconnect: qcom: icc-rpm: Fix peak rate calculation
        iio: adc: MCP3564: fix hardware identification logic
        iio: adc: MCP3564: fix calib_bias and calib_scale range checks
        iio: adc: meson: add separate config for axg SoC family
        iio: adc: imx93: add four channels for imx93 adc
        iio: adc: ti_am335x_adc: Fix return value check of tiadc_request_dma()
        interconnect: qcom: sm8250: Enable sync_state
        iio: triggered-buffer: prevent possible freeing of wrong buffer
        iio: imu: inv_mpu6050: fix an error code problem in inv_mpu6050_read_raw
        iio: imu: adis16475: use bit numbers in assign_bit()
        iio: imu: adis16475: add spi_device_id table
        iio: tmag5273: fix temperature offset
        interconnect: Treat xlate() returning NULL node as an error
        iio: common: ms_sensors: ms_sensors_i2c: fix humidity conversion time table
        ...
      a0652eb2
    • Linus Torvalds's avatar
      Merge tag 'input-for-v6.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input · fa655abe
      Linus Torvalds authored
      Pull input updates from Dmitry Torokhov:
      
       - a quirk to AT keyboard driver to skip issuing "GET ID" command when
         8042 is in translated mode and the device is a laptop/portable,
         because the "GET ID" command makes a bunch of recent laptops unhappy
      
       - a quirk to i8042 to disable multiplexed mode on Acer P459-G2-M which
         causes issues on resume
      
       - psmouse will activate native RMI4 protocol support for touchpad on
         ThinkPad L14 G1
      
       - addition of Razer Wolverine V2 ID to xpad gamepad driver
      
       - mapping for airplane mode button in soc_button_array driver for
         TUXEDO laptops
      
       - improved error handling in ipaq-micro-keys driver
      
       - amimouse being prepared for platform remove callback returning void
      
      * tag 'input-for-v6.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
        Input: soc_button_array - add mapping for airplane mode button
        Input: xpad - add Razer Wolverine V2 support
        Input: ipaq-micro-keys - add error handling for devm_kmemdup
        Input: amimouse - convert to platform remove callback returning void
        Input: i8042 - add nomux quirk for Acer P459-G2-M
        Input: atkbd - skip ATKBD_CMD_GETID in translated mode
        Input: psmouse - enable Synaptics InterTouch for ThinkPad L14 G1
      fa655abe
    • Masahiro Yamada's avatar
      kbuild: fix build ID symlinks to installed debug VDSO files · c1a86271
      Masahiro Yamada authored
      Commit 56769ba4 ("kbuild: unify vdso_install rules") accidentally
      dropped the '.debug' suffix from the build ID symlinks.
      
      Fixes: 56769ba4 ("kbuild: unify vdso_install rules")
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      c1a86271
    • Jialu Xu's avatar
      gen_compile_commands.py: fix path resolve with symlinks in it · 88094615
      Jialu Xu authored
      When a path contains relative symbolic links, os.path.abspath() might
      not follow the symlinks and instead return the absolute path with just
      the relative paths resolved, resulting in an incorrect path.
      
      1. Say "drivers/hdf/" has some symlinks:
      
          # ls -l drivers/hdf/
          total 364
          drwxrwxr-x 2 ...   4096 ... evdev
          lrwxrwxrwx 1 ...     44 ... framework -> ../../../../../../drivers/hdf_core/framework
          -rw-rw-r-- 1 ... 359010 ... hdf_macro_test.h
          lrwxrwxrwx 1 ...     55 ... inner_api -> ../../../../../../drivers/hdf_core/interfaces/inner_api
          lrwxrwxrwx 1 ...     53 ... khdf -> ../../../../../../drivers/hdf_core/adapter/khdf/linux
          -rw-r--r-- 1 ...     74 ... Makefile
          drwxrwxr-x 3 ...   4096 ... wifi
      
      2. One .cmd file records that:
      
          # head -1 ./framework/core/manager/src/.devmgr_service.o.cmd
          cmd_drivers/hdf/khdf/manager/../../../../framework/core/manager/src/devmgr_service.o := ... \
          /path/to/src/drivers/hdf/khdf/manager/../../../../framework/core/manager/src/devmgr_service.c
      
      3. os.path.abspath returns "/path/to/src/framework/core/manager/src/devmgr_service.c", not correct:
      
          # ./scripts/clang-tools/gen_compile_commands.py
          INFO: Could not add line from ./framework/core/manager/src/.devmgr_service.o.cmd: File \
              /path/to/src/framework/core/manager/src/devmgr_service.c not found
      
      Use os.path.realpath(), which resolves the symlinks and normalizes the paths correctly.
      
          # cat compile_commands.json
          ...
          {
            "command": ...
            "directory": ...
            "file": "/path/to/bla/drivers/hdf_core/framework/core/manager/src/devmgr_service.c"
          },
          ...
      
      Also fix it in parse_arguments().
      Signed-off-by: default avatarJialu Xu <xujialu@vimux.org>
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      88094615
    • Nathan Chancellor's avatar
      MAINTAINERS: Add scripts/clang-tools to Kbuild section · c134abc9
      Nathan Chancellor authored
      Masahiro has always applied scripts/clang-tools patches but it is not
      included in the Kbuild section, so neither he nor linux-kbuild get cc'd
      on patches that touch those files.
      Signed-off-by: default avatarNathan Chancellor <nathan@kernel.org>
      Acked-by: default avatarNicolas Schier <nicolas@fjasle.eu>
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      c134abc9
    • Helge Deller's avatar
      linux/export: Fix alignment for 64-bit ksymtab entries · f6847807
      Helge Deller authored
      An alignment of 4 bytes is wrong for 64-bit platforms which don't define
      CONFIG_HAVE_ARCH_PREL32_RELOCATIONS (which then store 64-bit pointers).
      Fix their alignment to 8 bytes.
      
      Fixes: ddb5cdba ("kbuild: generate KSYMTAB entries by modpost")
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      f6847807
    • Christoffer Sandberg's avatar
      Input: soc_button_array - add mapping for airplane mode button · ea371594
      Christoffer Sandberg authored
      This add a mapping for the airplane mode button on the TUXEDO Pulse Gen3.
      
      While it is physically a key it behaves more like a switch, sending a key
      down on first press and a key up on 2nd press. Therefor the switch event
      is used here. Besides this behaviour it uses the HID usage-id 0xc6
      (Wireless Radio Button) and not 0xc8 (Wireless Radio Slider Switch), but
      since neither 0xc6 nor 0xc8 are currently implemented at all in
      soc_button_array this not to standard behaviour is not put behind a quirk
      for the moment.
      Signed-off-by: default avatarChristoffer Sandberg <cs@tuxedo.de>
      Signed-off-by: default avatarWerner Sembach <wse@tuxedocomputers.com>
      Link: https://lore.kernel.org/r/20231215171718.80229-1-wse@tuxedocomputers.com
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
      ea371594
    • Linus Torvalds's avatar
      Merge tag 'block-6.7-2023-12-22' of git://git.kernel.dk/linux · 5254c0cb
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
       "Just an NVMe pull request this time, with a fix for bad sleeping
        context, and a revert of a patch that caused some trouble"
      
      * tag 'block-6.7-2023-12-22' of git://git.kernel.dk/linux:
        nvme-pci: fix sleeping function called from interrupt context
        Revert "nvme-fc: fix race between error recovery and creating association"
      5254c0cb
    • Linus Torvalds's avatar
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm · 867583b3
      Linus Torvalds authored
      Pull kvm fixes from Paolo Bonzini:
      "RISC-V:
      
         - Fix a race condition in updating external interrupt for
           trap-n-emulated IMSIC swfile
      
         - Fix print_reg defaults in get-reg-list selftest
      
        ARM:
      
         - Ensure a vCPU's redistributor is unregistered from the MMIO bus if
           vCPU creation fails
      
         - Fix building KVM selftests for arm64 from the top-level Makefile
      
        x86:
      
         - Fix breakage for SEV-ES guests that use XSAVES
      
        Selftests:
      
         - Fix bad use of strcat(), by not using strcat() at all"
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
        KVM: SEV: Do not intercept accesses to MSR_IA32_XSS for SEV-ES guests
        KVM: selftests: Fix dynamic generation of configuration names
        RISCV: KVM: update external interrupt atomically for IMSIC swfile
        KVM: riscv: selftests: Fix get-reg-list print_reg defaults
        KVM: selftests: Ensure sysreg-defs.h is generated at the expected path
        KVM: Convert comment into an assertion in kvm_io_bus_register_dev()
        KVM: arm64: vgic: Ensure that slots_lock is held in vgic_register_all_redist_iodevs()
        KVM: arm64: vgic: Force vcpu vgic teardown on vcpu destroy
        KVM: arm64: vgic: Add a non-locking primitive for kvm_vgic_vcpu_destroy()
        KVM: arm64: vgic: Simplify kvm_vgic_destroy()
      867583b3
  8. 22 Dec, 2023 15 commits