1. Jan 06, 2024
  2. Jan 05, 2024
    • Dan Williams's avatar
      cxl/port: Fix missing target list lock · 5459e186
      Dan Williams authored
      cxl_port_setup_targets() modifies the ->targets[] array of a switch
      decoder. target_list_show() expects to be able to emit a coherent
      snapshot of that array by "holding" ->target_lock for read. The
      target_lock is held for write during initialization of the ->targets[]
      array, but it is not held for write during cxl_port_setup_targets().
      
      The ->target_lock() predates the introduction of @cxl_region_rwsem. That
      semaphore protects changes to host-physical-address (HPA) decode which
      is precisely what writes to a switch decoder's target list affects.
      
      Replace ->target_lock with @cxl_region_rwsem.
      
      Now the side-effect of snapshotting a unstable view of a decoder's
      target list is likely benign so the Fixes: tag is presumptive.
      
      Fixes: 27b3f8d1
      
       ("cxl/region: Program target lists")
      Reviewed-by: default avatarAlison Schofield <alison.schofield@intel.com>
      Reviewed-by: default avatarDave Jiang <dave.jiang@intel.com>
      Signed-off-by: default avatarDan Williams <dan.j.williams@intel.com>
      5459e186
    • Huang Ying's avatar
      cxl/port: Fix decoder initialization when nr_targets > interleave_ways · d6488fee
      Huang Ying authored
      The decoder_populate_targets() helper walks all of the targets in a port
      and makes sure they can be looked up in @target_map. Where @target_map
      is a lookup table from target position to target id (corresponding to a
      cxl_dport instance). However @target_map is only responsible for
      conveying the active dport instances as indicated by interleave_ways.
      
      When nr_targets > interleave_ways it results in
      decoder_populate_targets() walking off the end of the valid entries in
      @target_map. Given target_map is initialized to 0 it results in the
      dport lookup failing if position 0 is not mapped to a dport with an id
      of 0:
      
        cxl_port port3: Failed to populate active decoder targets
        cxl_port port3: Failed to add decoder
        cxl_port port3: Failed to add decoder3.0
        cxl_bus_probe: cxl_port port3: probe: -6
      
      This bug also highlights that when the decoder's ->targets[] array is
      written in cxl_port_setup_targets() it is missing a hold of the
      targets_lock to synchronize against sysfs readers of the target list. A
      fix for that is saved for a later patch.
      
      Fixes: a5c25802
      
       ("cxl/bus: Populate the target list at decoder create")
      Cc:  <stable@vger.kernel.org>
      Signed-off-by: default avatarHuang, Ying <ying.huang@intel.com>
      [djbw: rewrite the changelog, find the Fixes: tag]
      Co-developed-by: default avatarDan Williams <dan.j.williams@intel.com>
      Reviewed-by: default avatarAlison Schofield <alison.schofield@intel.com>
      Reviewed-by: default avatarDave Jiang <dave.jiang@intel.com>
      Signed-off-by: default avatarDan Williams <dan.j.williams@intel.com>
      d6488fee
  3. Jan 04, 2024
  4. Jan 03, 2024
    • Dan Williams's avatar
      Merge branch 'for-6.8/cxl-cdat' into for-6.8/cxl · 11c83932
      Dan Williams authored
      Pick up the CDAT parsing and QOS class infrastructure for v6.8.
      11c83932
    • Randy Dunlap's avatar
      cxl/region: use %pap format to print resource_size_t · 58f1e9d3
      Randy Dunlap authored
      Use "%pap" to print a resource_size_t (phys_addr_t derived type)
      to prevent build warnings on 32-bit arches (seen on i386 and
      riscv-32).
      
      ../drivers/cxl/core/region.c: In function 'alloc_hpa':
      ../drivers/cxl/core/region.c:556:25: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 5 has type 'resource_size_t' {aka 'unsigned int'} [-Wformat=]
        556 |                         "HPA allocation error (%ld) for size:%#llx in %s %pr\n",
      
      Fixes: 7984d22f
      
       ("cxl/region: Add dev_dbg() detail on failure to allocate HPA space")
      Signed-off-by: default avatarRandy Dunlap <rdunlap@infradead.org>
      Cc: Fan Ni <fan.ni@samsung.com>
      Cc: Davidlohr Bueso <dave@stgolabs.net>
      Cc: Jonathan Cameron <jonathan.cameron@huawei.com>
      Cc: Dave Jiang <dave.jiang@intel.com>
      Cc: Alison Schofield <alison.schofield@intel.com>
      Cc: Vishal Verma <vishal.l.verma@intel.com>
      Cc: Ira Weiny <ira.weiny@intel.com>
      Cc: Dan Williams <dan.j.williams@intel.com>
      Cc:  <linux-cxl@vger.kernel.org>
      Link: https://lore.kernel.org/r/20240102173917.19718-1-rdunlap@infradead.org
      
      
      Signed-off-by: default avatarDan Williams <dan.j.williams@intel.com>
      58f1e9d3
  5. Dec 25, 2023
  6. Dec 24, 2023
    • Linus Torvalds's avatar
      Linux 6.7-rc7 · 861deac3
      Linus Torvalds authored
      861deac3
    • 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 co...
      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
  7. Dec 23, 2023