Skip to content
  1. Apr 27, 2024
    • Mathieu Desnoyers's avatar
      sched: Add missing memory barrier in switch_mm_cid · 7fce9f0f
      Mathieu Desnoyers authored
      commit fe90f396 upstream.
      
      Many architectures' switch_mm() (e.g. arm64) do not have an smp_mb()
      which the core scheduler code has depended upon since commit:
      
          commit 223baf9d ("sched: Fix performance regression introduced by mm_cid")
      
      If switch_mm() doesn't call smp_mb(), sched_mm_cid_remote_clear() can
      unset the actively used cid when it fails to observe active task after it
      sets lazy_put.
      
      There *is* a memory barrier between storing to rq->curr and _return to
      userspace_ (as required by membarrier), but the rseq mm_cid has stricter
      requirements: the barrier needs to be issued between store to rq->curr
      and switch_mm_cid(), which happens earlier than:
      
        - spin_unlock(),
        - switch_to().
      
      So it's fine when the architecture switch_mm() happens to have that
      barrier already, but less so when the architecture only provides the
      full barrier in switch_to() or spin_unlock().
      
      It is a bug in the rseq switch_mm_cid() implementation. All architectures
      that don't have memory barriers in switch_mm(), but rather have the full
      barrier either in finish_lock_switch() or switch_to() have them too late
      for the needs of switch_mm_cid().
      
      Introduce a new smp_mb__after_switch_mm(), defined as smp_mb() in the
      generic barrier.h header, and use it in switch_mm_cid() for scheduler
      transitions where switch_mm() is expected to provide a memory barrier.
      
      Architectures can override smp_mb__after_switch_mm() if their
      switch_mm() implementation provides an implicit memory barrier.
      Override it with a no-op on x86 which implicitly provide this memory
      barrier by writing to CR3.
      
      Fixes: 223baf9d
      
       ("sched: Fix performance regression introduced by mm_cid")
      Reported-by: default avatarlevi.yun <yeoreum.yun@arm.com>
      Signed-off-by: default avatarMathieu Desnoyers <mathieu.desnoyers@efficios.com>
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> # for arm64
      Acked-by: Dave Hansen <dave.hansen@linux.intel.com> # for x86
      Cc: <stable@vger.kernel.org> # 6.4.x
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Link: https://lore.kernel.org/r/20240415152114.59122-2-mathieu.desnoyers@efficios.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      7fce9f0f
    • Alan Stern's avatar
      fs: sysfs: Fix reference leak in sysfs_break_active_protection() · ac107356
      Alan Stern authored
      commit a90bca22
      
       upstream.
      
      The sysfs_break_active_protection() routine has an obvious reference
      leak in its error path.  If the call to kernfs_find_and_get() fails then
      kn will be NULL, so the companion sysfs_unbreak_active_protection()
      routine won't get called (and would only cause an access violation by
      trying to dereference kn->parent if it was called).  As a result, the
      reference to kobj acquired at the start of the function will never be
      released.
      
      Fix the leak by adding an explicit kobject_put() call when kn is NULL.
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Fixes: 2afc9166
      
       ("scsi: sysfs: Introduce sysfs_{un,}break_active_protection()")
      Cc: Bart Van Assche <bvanassche@acm.org>
      Cc: stable@vger.kernel.org
      Reviewed-by: default avatarBart Van Assche <bvanassche@acm.org>
      Acked-by: default avatarTejun Heo <tj@kernel.org>
      Link: https://lore.kernel.org/r/8a4d3f0f-c5e3-4b70-a188-0ca433f9e6f9@rowland.harvard.edu
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      ac107356
    • Samuel Thibault's avatar
      speakup: Avoid crash on very long word · 8defb1d2
      Samuel Thibault authored
      commit c8d2f34e
      
       upstream.
      
      In case a console is set up really large and contains a really long word
      (> 256 characters), we have to stop before the length of the word buffer.
      
      Signed-off-by: default avatarSamuel Thibault <samuel.thibault@ens-lyon.org>
      Fixes: c6e3fd22
      
       ("Staging: add speakup to the staging directory")
      Cc: stable@vger.kernel.org
      Link: https://lore.kernel.org/r/20240323164843.1426997-1-samuel.thibault@ens-lyon.org
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      8defb1d2
    • Alexander Usyskin's avatar
      mei: me: disable RPL-S on SPS and IGN firmwares · 2a19c2a5
      Alexander Usyskin authored
      commit 0dc04112 upstream.
      
      Extend the quirk to disable MEI interface on Intel PCH Ignition (IGN)
      and SPS firmwares for RPL-S devices. These firmwares do not support
      the MEI protocol.
      
      Fixes: 3ed8c7d3
      
       ("mei: me: add raptor lake point S DID")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarAlexander Usyskin <alexander.usyskin@intel.com>
      Signed-off-by: default avatarTomas Winkler <tomas.winkler@intel.com>
      Link: https://lore.kernel.org/r/20240312051958.118478-1-tomas.winkler@intel.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      2a19c2a5
    • Norihiko Hama's avatar
      usb: gadget: f_ncm: Fix UAF ncm object at re-bind after usb ep transport error · f356fd0c
      Norihiko Hama authored
      commit 6334b8e4
      
       upstream.
      
      When ncm function is working and then stop usb0 interface for link down,
      eth_stop() is called. At this piont, accidentally if usb transport error
      should happen in usb_ep_enable(), 'in_ep' and/or 'out_ep' may not be enabled.
      
      After that, ncm_disable() is called to disable for ncm unbind
      but gether_disconnect() is never called since 'in_ep' is not enabled.
      
      As the result, ncm object is released in ncm unbind
      but 'dev->port_usb' associated to 'ncm->port' is not NULL.
      
      And when ncm bind again to recover netdev, ncm object is reallocated
      but usb0 interface is already associated to previous released ncm object.
      
      Therefore, once usb0 interface is up and eth_start_xmit() is called,
      released ncm object is dereferrenced and it might cause use-after-free memory.
      
      [function unlink via configfs]
        usb0: eth_stop dev->port_usb=ffffff9b179c3200
        --> error happens in usb_ep_enable().
        NCM: ncm_disable: ncm=ffffff9b179c3200
        --> no gether_disconnect() since ncm->port.in_ep->enabled is false.
        NCM: ncm_unbind: ncm unbind ncm=ffffff9b179c3200
        NCM: ncm_free: ncm free ncm=ffffff9b179c3200   <-- released ncm
      
      [function link via configfs]
        NCM: ncm_alloc: ncm alloc ncm=ffffff9ac4f8a000
        NCM: ncm_bind: ncm bind ncm=ffffff9ac4f8a000
        NCM: ncm_set_alt: ncm=ffffff9ac4f8a000 alt=0
        usb0: eth_open dev->port_usb=ffffff9b179c3200  <-- previous released ncm
        usb0: eth_start dev->port_usb=ffffff9b179c3200 <--
        eth_start_xmit()
        --> dev->wrap()
        Unable to handle kernel paging request at virtual address dead00000000014f
      
      This patch addresses the issue by checking if 'ncm->netdev' is not NULL at
      ncm_disable() to call gether_disconnect() to deassociate 'dev->port_usb'.
      It's more reasonable to check 'ncm->netdev' to call gether_connect/disconnect
      rather than check 'ncm->port.in_ep->enabled' since it might not be enabled
      but the gether connection might be established.
      
      Signed-off-by: default avatarNorihiko Hama <Norihiko.Hama@alpsalpine.com>
      Cc: stable <stable@kernel.org>
      Link: https://lore.kernel.org/r/20240327023550.51214-1-Norihiko.Hama@alpsalpine.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      f356fd0c
    • Kai-Heng Feng's avatar
      usb: Disable USB3 LPM at shutdown · aa61f87f
      Kai-Heng Feng authored
      commit d920a2ed
      
       upstream.
      
      SanDisks USB3 storage may disapper after system reboot:
      
      usb usb2-port3: link state change
      xhci_hcd 0000:00:14.0: clear port3 link state change, portsc: 0x2c0
      usb usb2-port3: do warm reset, port only
      xhci_hcd 0000:00:14.0: xhci_hub_status_data: stopping usb2 port polling
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x2b0, return 0x2b0
      usb usb2-port3: not warm reset yet, waiting 50ms
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x2f0, return 0x2f0
      usb usb2-port3: not warm reset yet, waiting 200ms
      ...
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x6802c0, return 0x7002c0
      usb usb2-port3: not warm reset yet, waiting 200ms
      xhci_hcd 0000:00:14.0: clear port3 reset change, portsc: 0x4802c0
      xhci_hcd 0000:00:14.0: clear port3 warm(BH) reset change, portsc: 0x4002c0
      xhci_hcd 0000:00:14.0: clear port3 link state change, portsc: 0x2c0
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x2c0, return 0x2c0
      usb usb2-port3: not enabled, trying warm reset again...
      
      This is due to the USB device still cause port change event after xHCI is
      shuted down:
      
      xhci_hcd 0000:38:00.0: // Setting command ring address to 0xffffe001
      xhci_hcd 0000:38:00.0: xhci_resume: starting usb3 port polling.
      xhci_hcd 0000:38:00.0: xhci_hub_status_data: stopping usb4 port polling
      xhci_hcd 0000:38:00.0: xhci_hub_status_data: stopping usb3 port polling
      xhci_hcd 0000:38:00.0: hcd_pci_runtime_resume: 0
      xhci_hcd 0000:38:00.0: xhci_shutdown: stopping usb3 port polling.
      xhci_hcd 0000:38:00.0: // Halt the HC
      xhci_hcd 0000:38:00.0: xhci_shutdown completed - status = 1
      xhci_hcd 0000:00:14.0: xhci_shutdown: stopping usb1 port polling.
      xhci_hcd 0000:00:14.0: // Halt the HC
      xhci_hcd 0000:00:14.0: xhci_shutdown completed - status = 1
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x1203, return 0x203
      xhci_hcd 0000:00:14.0: set port reset, actual port 2-3 status  = 0x1311
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x201203, return 0x100203
      xhci_hcd 0000:00:14.0: clear port3 reset change, portsc: 0x1203
      xhci_hcd 0000:00:14.0: clear port3 warm(BH) reset change, portsc: 0x1203
      xhci_hcd 0000:00:14.0: clear port3 link state change, portsc: 0x1203
      xhci_hcd 0000:00:14.0: clear port3 connect change, portsc: 0x1203
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x1203, return 0x203
      usb 2-3: device not accepting address 2, error -108
      xhci_hcd 0000:00:14.0: xHCI dying or halted, can't queue_command
      xhci_hcd 0000:00:14.0: Set port 2-3 link state, portsc: 0x1203, write 0x11261
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x1263, return 0x263
      xhci_hcd 0000:00:14.0: set port reset, actual port 2-3 status  = 0x1271
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x12b1, return 0x2b1
      usb usb2-port3: not reset yet, waiting 60ms
      ACPI: PM: Preparing to enter system sleep state S5
      xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x12f1, return 0x2f1
      usb usb2-port3: not reset yet, waiting 200ms
      reboot: Restarting system
      
      The port change event is caused by LPM transition, so disabling LPM at shutdown
      to make sure the device is in U0 for warmboot.
      
      Signed-off-by: default avatarKai-Heng Feng <kai.heng.feng@canonical.com>
      Cc: stable <stable@kernel.org>
      Link: https://lore.kernel.org/r/20240305065140.66801-1-kai.heng.feng@canonical.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      aa61f87f
    • Minas Harutyunyan's avatar
      usb: dwc2: host: Fix dereference issue in DDMA completion flow. · 8a139fa4
      Minas Harutyunyan authored
      commit eed04fa9 upstream.
      
      Fixed variable dereference issue in DDMA completion flow.
      
      Fixes: b258e426
      
       ("usb: dwc2: host: Fix ISOC flow in DDMA mode")
      CC: stable@vger.kernel.org
      Reported-by: default avatarDan Carpenter <dan.carpenter@linaro.org>
      Closes: https://lore.kernel.org/linux-usb/2024040834-ethically-rumble-701f@gregkh/T/#m4c4b83bef0ebb4b67fe2e0a7d6466cbb6f416e39
      Signed-off-by: default avatarMinas Harutyunyan <Minas.Harutyunyan@synopsys.com>
      Link: https://lore.kernel.org/r/cc826d3ef53c934d8e6d98870f17f3cdc3d2755d.1712665387.git.Minas.Harutyunyan@synopsys.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      8a139fa4
    • Greg Kroah-Hartman's avatar
      Revert "usb: cdc-wdm: close race between read and workqueue" · 2ff436b6
      Greg Kroah-Hartman authored
      commit 1607830d upstream.
      
      This reverts commit 339f8361
      
      .
      
      It has been found to cause problems in a number of Chromebook devices,
      so revert the change until it can be brought back in a safe way.
      
      Link: https://lore.kernel.org/r/385a3519-b45d-48c5-a6fd-a3fdb6bec92f@chromium.org
      Reported-by: default avatar: Aleksander Morgado <aleksandermj@chromium.org>
      Fixes: 339f8361
      
       ("usb: cdc-wdm: close race between read and workqueue")
      Cc: stable <stable@kernel.org>
      Cc: Oliver Neukum <oneukum@suse.com>
      Cc: Bjørn Mork <bjorn@mork.no>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      2ff436b6
    • Daniele Palmas's avatar
      USB: serial: option: add Telit FN920C04 rmnet compositions · d841a93b
      Daniele Palmas authored
      commit 582ee2f9
      
       upstream.
      
      Add the following Telit FN920C04 compositions:
      
      0x10a0: rmnet + tty (AT/NMEA) + tty (AT) + tty (diag)
      T:  Bus=03 Lev=01 Prnt=03 Port=06 Cnt=01 Dev#=  5 Spd=480  MxCh= 0
      D:  Ver= 2.01 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=1bc7 ProdID=10a0 Rev=05.15
      S:  Manufacturer=Telit Cinterion
      S:  Product=FN920
      S:  SerialNumber=92c4c4d8
      C:  #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=50 Driver=qmi_wwan
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=82(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
      I:  If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=60 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=86(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=87(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      0x10a4: rmnet + tty (AT) + tty (AT) + tty (diag)
      T:  Bus=03 Lev=01 Prnt=03 Port=06 Cnt=01 Dev#=  8 Spd=480  MxCh= 0
      D:  Ver= 2.01 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=1bc7 ProdID=10a4 Rev=05.15
      S:  Manufacturer=Telit Cinterion
      S:  Product=FN920
      S:  SerialNumber=92c4c4d8
      C:  #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=50 Driver=qmi_wwan
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=82(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
      I:  If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=86(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=87(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      0x10a9: rmnet + tty (AT) + tty (diag) + DPL (data packet logging) + adb
      T:  Bus=03 Lev=01 Prnt=03 Port=06 Cnt=01 Dev#=  9 Spd=480  MxCh= 0
      D:  Ver= 2.01 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=1bc7 ProdID=10a9 Rev=05.15
      S:  Manufacturer=Telit Cinterion
      S:  Product=FN920
      S:  SerialNumber=92c4c4d8
      C:  #Ifs= 5 Cfg#= 1 Atr=e0 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=50 Driver=qmi_wwan
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=82(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
      I:  If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 3 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=80 Driver=(none)
      E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=42 Prot=01 Driver=(none)
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=87(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      Signed-off-by: default avatarDaniele Palmas <dnlplm@gmail.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      d841a93b
    • Vanillan Wang's avatar
      USB: serial: option: add Rolling RW101-GL and RW135-GL support · 0772a609
      Vanillan Wang authored
      commit 311f97a4
      
       upstream.
      
      Update the USB serial option driver support for the Rolling
      LTE modules.
      
      - VID:PID 33f8:01a2, RW101-GL for laptop debug M.2 cards(with MBIM
      interface for /Linux/Chrome OS)
      0x01a2: mbim, diag, at, pipe
      - VID:PID 33f8:01a3, RW101-GL for laptop debug M.2 cards(with MBIM
      interface for /Linux/Chrome OS)
      0x01a3: mbim, pipe
      - VID:PID 33f8:01a4, RW101-GL for laptop debug M.2 cards(with MBIM
      interface for /Linux/Chrome OS)
      0x01a4: mbim, diag, at, pipe
      - VID:PID 33f8:0104, RW101-GL for laptop debug M.2 cards(with RMNET
      interface for /Linux/Chrome OS)
      0x0104: RMNET, diag, at, pipe
      - VID:PID 33f8:0115, RW135-GL for laptop debug M.2 cards(with MBIM
      interface for /Linux/Chrome OS)
      0x0115: MBIM, diag, at, pipe
      
      Here are the outputs of usb-devices:
      T:  Bus=01 Lev=01 Prnt=01 Port=02 Cnt=01 Dev#=  5 Spd=480 MxCh= 0
      D:  Ver= 2.01 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=33f8 ProdID=01a2 Rev=05.15
      S:  Manufacturer=Rolling Wireless S.a.r.l.
      S:  Product=Rolling Module
      S:  SerialNumber=12345678
      C:  #Ifs= 5 Cfg#= 1 Atr=a0 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=0e Prot=00 Driver=cdc_mbim
      E:  Ad=82(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=02 Driver=cdc_mbim
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      T:  Bus=01 Lev=01 Prnt=01 Port=02 Cnt=01 Dev#=  8 Spd=480 MxCh= 0
      D:  Ver= 2.01 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=33f8 ProdID=01a3 Rev=05.15
      S:  Manufacturer=Rolling Wireless S.a.r.l.
      S:  Product=Rolling Module
      S:  SerialNumber=12345678
      C:  #Ifs= 3 Cfg#= 1 Atr=a0 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=0e Prot=00 Driver=cdc_mbim
      E:  Ad=82(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=02 Driver=cdc_mbim
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      T:  Bus=01 Lev=01 Prnt=01 Port=02 Cnt=01 Dev#= 17 Spd=480 MxCh= 0
      D:  Ver= 2.01 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=33f8 ProdID=01a4 Rev=05.15
      S:  Manufacturer=Rolling Wireless S.a.r.l.
      S:  Product=Rolling Module
      S:  SerialNumber=12345678
      C:  #Ifs= 6 Cfg#= 1 Atr=a0 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=0e Prot=00 Driver=cdc_mbim
      E:  Ad=82(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=02 Driver=cdc_mbim
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=42 Prot=01 Driver=usbfs
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=05(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=87(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      T:  Bus=04 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  2 Spd=5000 MxCh= 0
      D:  Ver= 3.20 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 9 #Cfgs=  1
      P:  Vendor=33f8 ProdID=0104 Rev=05.04
      S:  Manufacturer=Rolling Wireless S.a.r.l.
      S:  Product=Rolling Module
      S:  SerialNumber=ba2eb033
      C:  #Ifs= 6 Cfg#= 1 Atr=a0 MxPwr=896mA
      I:  If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=01(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=82(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=83(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=85(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=40 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=87(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=50 Driver=qmi_wwan
      E:  Ad=0f(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=88(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
      E:  Ad=8e(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=42 Prot=01 Driver=usbfs
      E:  Ad=05(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=89(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      
      T:  Bus=01 Lev=01 Prnt=01 Port=02 Cnt=01 Dev#= 16 Spd=480 MxCh= 0
      D:  Ver= 2.01 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=33f8 ProdID=0115 Rev=05.15
      S:  Manufacturer=Rolling Wireless S.a.r.l.
      S:  Product=Rolling Module
      S:  SerialNumber=12345678
      C:  #Ifs= 6 Cfg#= 1 Atr=a0 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=0e Prot=00 Driver=cdc_mbim
      E:  Ad=82(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=02 Driver=cdc_mbim
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=42 Prot=01 Driver=usbfs
      E:  Ad=05(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=87(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      Signed-off-by: default avatarVanillan Wang <vanillanwang@163.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      0772a609
    • Jerry Meng's avatar
      USB: serial: option: support Quectel EM060K sub-models · b39ecc8c
      Jerry Meng authored
      commit c840244a
      
       upstream.
      
      EM060K_129, EM060K_12a, EM060K_12b and EM0060K_12c are EM060K's sub-models,
      having the same name "Quectel EM060K-GL" and the same interface layout.
      
      MBIM + GNSS + DIAG + NMEA + AT + QDSS + DPL
      
      T:  Bus=03 Lev=01 Prnt=01 Port=01 Cnt=02 Dev#=  8 Spd=480  MxCh= 0
      D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=2c7c ProdID=0129 Rev= 5.04
      S:  Manufacturer=Quectel
      S:  Product=Quectel EM060K-GL
      S:  SerialNumber=f6fa08b6
      C:* #Ifs= 8 Cfg#= 1 Atr=a0 MxPwr=500mA
      A:  FirstIf#= 0 IfCount= 2 Cls=02(comm.) Sub=0e Prot=00
      I:* If#= 0 Alt= 0 #EPs= 1 Cls=02(comm.) Sub=0e Prot=00 Driver=cdc_mbim
      E:  Ad=81(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
      I:  If#= 1 Alt= 0 #EPs= 0 Cls=0a(data ) Sub=00 Prot=02 Driver=cdc_mbim
      I:* If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=02 Driver=cdc_mbim
      E:  Ad=8e(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=0f(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:* If#= 2 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
      E:  Ad=82(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
      I:* If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:* If#= 4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=40 Driver=option
      E:  Ad=85(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:* If#= 5 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=87(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:* If#= 6 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=70 Driver=(none)
      E:  Ad=88(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:* If#= 7 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=80 Driver=(none)
      E:  Ad=8f(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      Signed-off-by: default avatarJerry Meng <jerry-meng@foxmail.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      b39ecc8c
    • Coia Prant's avatar
      USB: serial: option: add Lonsung U8300/U9300 product · aeb7de0a
      Coia Prant authored
      commit cf16ffa1
      
       upstream.
      
      Update the USB serial option driver to support Longsung U8300/U9300.
      
      For U8300
      
      Interface 4 is used by for QMI interface in stock firmware of U8300, the
      router which uses U8300 modem.
      Interface 5 is used by for ADB interface in stock firmware of U8300, the
      router which uses U8300 modem.
      
      Interface mapping is:
      0: unknown (Debug), 1: AT (Modem), 2: AT, 3: PPP (NDIS / Pipe), 4: QMI, 5: ADB
      
      T:  Bus=05 Lev=01 Prnt=03 Port=02 Cnt=01 Dev#=  4 Spd=480 MxCh= 0
      D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=1c9e ProdID=9b05 Rev=03.18
      S:  Manufacturer=Android
      S:  Product=Android
      C:  #Ifs= 6 Cfg#= 1 Atr=80 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=option
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=87(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=ff Driver=qmi_wwan
      E:  Ad=05(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=88(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=89(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
      I:  If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=42 Prot=01 Driver=(none)
      E:  Ad=06(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=8a(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      For U9300
      
      Interface 1 is used by for ADB interface in stock firmware of U9300, the
      router which uses U9300 modem.
      Interface 4 is used by for QMI interface in stock firmware of U9300, the
      router which uses U9300 modem.
      
      Interface mapping is:
      0: ADB, 1: AT (Modem), 2: AT, 3: PPP (NDIS / Pipe), 4: QMI
      
      Note: Interface 3 of some models of the U9300 series can send AT commands.
      
      T:  Bus=05 Lev=01 Prnt=05 Port=04 Cnt=01 Dev#=  6 Spd=480 MxCh= 0
      D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=1c9e ProdID=9b3c Rev=03.18
      S:  Manufacturer=Android
      S:  Product=Android
      C:  #Ifs= 5 Cfg#= 1 Atr=80 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=42 Prot=01 Driver=(none)
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=87(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=ff Driver=qmi_wwan
      E:  Ad=05(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=88(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=89(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
      
      Tested successfully using Modem Manager on U9300.
      Tested successfully AT commands using If=1, If=2 and If=3 on U9300.
      
      Signed-off-by: default avatarCoia Prant <coiaprant@gmail.com>
      Reviewed-by: default avatarLars Melin <larsm17@gmail.com>
      [ johan: drop product defines, trim commit message ]
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      aeb7de0a
    • Chuanhong Guo's avatar
      USB: serial: option: add support for Fibocom FM650/FG650 · f91606d7
      Chuanhong Guo authored
      commit fb1f4584
      
       upstream.
      
      Fibocom FM650/FG650 are 5G modems with ECM/NCM/RNDIS/MBIM modes.
      This patch adds support to all 4 modes.
      
      In all 4 modes, the first serial port is the AT console while the other
      3 appear to be diagnostic interfaces for dumping modem logs.
      
      usb-devices output for all modes:
      
      ECM:
      T:  Bus=04 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  5 Spd=5000 MxCh= 0
      D:  Ver= 3.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 9 #Cfgs=  1
      P:  Vendor=2cb7 ProdID=0a04 Rev=04.04
      S:  Manufacturer=Fibocom Wireless Inc.
      S:  Product=FG650 Module
      S:  SerialNumber=0123456789ABCDEF
      C:  #Ifs= 5 Cfg#= 1 Atr=c0 MxPwr=504mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=06 Prot=00 Driver=cdc_ether
      E:  Ad=82(I) Atr=03(Int.) MxPS=  16 Ivl=32ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=cdc_ether
      E:  Ad=01(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=85(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      
      NCM:
      T:  Bus=04 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  6 Spd=5000 MxCh= 0
      D:  Ver= 3.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 9 #Cfgs=  1
      P:  Vendor=2cb7 ProdID=0a05 Rev=04.04
      S:  Manufacturer=Fibocom Wireless Inc.
      S:  Product=FG650 Module
      S:  SerialNumber=0123456789ABCDEF
      C:  #Ifs= 6 Cfg#= 1 Atr=c0 MxPwr=504mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=0d Prot=00 Driver=cdc_ncm
      E:  Ad=82(I) Atr=03(Int.) MxPS=  16 Ivl=32ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=01 Driver=cdc_ncm
      E:  Ad=01(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=85(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=05(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      
      RNDIS:
      T:  Bus=04 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  4 Spd=5000 MxCh= 0
      D:  Ver= 3.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 9 #Cfgs=  1
      P:  Vendor=2cb7 ProdID=0a06 Rev=04.04
      S:  Manufacturer=Fibocom Wireless Inc.
      S:  Product=FG650 Module
      S:  SerialNumber=0123456789ABCDEF
      C:  #Ifs= 6 Cfg#= 1 Atr=c0 MxPwr=504mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=e0(wlcon) Sub=01 Prot=03 Driver=rndis_host
      E:  Ad=82(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
      I:  If#= 1 Alt= 0 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=rndis_host
      E:  Ad=01(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=85(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=05(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      
      MBIM:
      T:  Bus=04 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  7 Spd=5000 MxCh= 0
      D:  Ver= 3.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 9 #Cfgs=  1
      P:  Vendor=2cb7 ProdID=0a07 Rev=04.04
      S:  Manufacturer=Fibocom Wireless Inc.
      S:  Product=FG650 Module
      S:  SerialNumber=0123456789ABCDEF
      C:  #Ifs= 6 Cfg#= 1 Atr=c0 MxPwr=504mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=0e Prot=00 Driver=cdc_mbim
      E:  Ad=82(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=02 Driver=cdc_mbim
      E:  Ad=01(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=85(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      I:  If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=05(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
      
      Signed-off-by: default avatarChuanhong Guo <gch981213@gmail.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      f91606d7
    • bolan wang's avatar
      USB: serial: option: add Fibocom FM135-GL variants · 590d0e13
      bolan wang authored
      commit 356952b1
      
       upstream.
      
      Update the USB serial option driver support for the Fibocom
      FM135-GL LTE modules.
      - VID:PID 2cb7:0115, FM135-GL for laptop debug M.2 cards(with MBIM
      interface for /Linux/Chrome OS)
      
      0x0115: mbim, diag, at, pipe
      
      Here are the outputs of usb-devices:
      T:  Bus=01 Lev=01 Prnt=01 Port=02 Cnt=01 Dev#= 16 Spd=480 MxCh= 0
      D:  Ver= 2.01 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
      P:  Vendor=2cb7 ProdID=0115 Rev=05.15
      S:  Manufacturer=Fibocom Wireless Inc.
      S:  Product=Fibocom Module
      S:  SerialNumber=12345678
      C:  #Ifs= 6 Cfg#= 1 Atr=a0 MxPwr=500mA
      I:  If#= 0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=0e Prot=00 Driver=cdc_mbim
      E:  Ad=82(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=02 Driver=cdc_mbim
      E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
      E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=40 Driver=option
      E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=85(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
      I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
      E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      I:  If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=42 Prot=01 Driver=usbfs
      E:  Ad=05(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      E:  Ad=87(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
      
      Signed-off-by: default avatarbolan wang <bolan.wang@fibocom.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      590d0e13
    • Tony Lindgren's avatar
      serial: core: Fix missing shutdown and startup for serial base port · 83290f9f
      Tony Lindgren authored
      commit 1aa4ad4e upstream.
      
      We are seeing start_tx being called after port shutdown as noted by Jiri.
      This happens because we are missing the startup and shutdown related
      functions for the serial base port.
      
      Let's fix the issue by adding startup and shutdown functions for the
      serial base port to block tx flushing for the serial base port when the
      port is not in use.
      
      Fixes: 84a9582f
      
       ("serial: core: Start managing serial controllers to enable runtime PM")
      Cc: stable <stable@kernel.org>
      Reported-by: default avatarJiri Slaby <jirislaby@kernel.org>
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      Link: https://lore.kernel.org/r/20240411055848.38190-1-tony@atomide.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      83290f9f
    • Andy Shevchenko's avatar
      serial: core: Clearing the circular buffer before NULLifying it · 7ae7104d
      Andy Shevchenko authored
      commit 9cf7ea2e upstream.
      
      The circular buffer is NULLified in uart_tty_port_shutdown()
      under the spin lock. However, the PM or other timer based callbacks
      may still trigger after this event without knowning that buffer pointer
      is not valid. Since the serial code is a bit inconsistent in checking
      the buffer state (some rely on the head-tail positions, some on the
      buffer pointer), it's better to have both aligned, i.e. buffer pointer
      to be NULL and head-tail possitions to be the same, meaning it's empty.
      This will prevent asynchronous calls to dereference NULL pointer as
      reported recently in 8250 case:
      
        BUG: kernel NULL pointer dereference, address: 00000cf5
        Workqueue: pm pm_runtime_work
        EIP: serial8250_tx_chars (drivers/tty/serial/8250/8250_port.c:1809)
        ...
        ? serial8250_tx_chars (drivers/tty/serial/8250/8250_port.c:1809)
        __start_tx (drivers/tty/serial/8250/8250_port.c:1551)
        serial8250_start_tx (drivers/tty/serial/8250/8250_port.c:1654)
        serial_port_runtime_suspend (include/linux/serial_core.h:667 drivers/tty/serial/serial_port.c:63)
        __rpm_callback (drivers/base/power/runtime.c:393)
        ? serial_port_remove (drivers/tty/serial/serial_port.c:50)
        rpm_suspend (drivers/base/power/runtime.c:447)
      
      The proposed change will prevent ->start_tx() to be called during
      suspend on shut down port.
      
      Fixes: 43066e32
      
       ("serial: port: Don't suspend if the port is still busy")
      Cc: stable <stable@kernel.org>
      Reported-by: default avatarkernel test robot <oliver.sang@intel.com>
      Closes: https://lore.kernel.org/oe-lkp/202404031607.2e92eebe-lkp@intel.com
      Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
      Link: https://lore.kernel.org/r/20240404150034.41648-1-andriy.shevchenko@linux.intel.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      7ae7104d
    • Uwe Kleine-König's avatar
      serial: stm32: Reset .throttled state in .startup() · 12e9459d
      Uwe Kleine-König authored
      commit ea2624b5 upstream.
      
      When an UART is opened that still has .throttled set from a previous
      open, the RX interrupt is enabled but the irq handler doesn't consider
      it. This easily results in a stuck irq with the effect to occupy the CPU
      in a tight loop.
      
      So reset the throttle state in .startup() to ensure that RX irqs are
      handled.
      
      Fixes: d1ec8a2e
      
       ("serial: stm32: update throttle and unthrottle ops for dma mode")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
      Link: https://lore.kernel.org/r/a784f80d3414f7db723b2ec66efc56e1ad666cbf.1713344161.git.u.kleine-koenig@pengutronix.de
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      12e9459d
    • Uwe Kleine-König's avatar
      serial: stm32: Return IRQ_NONE in the ISR if no handling happend · 9f9be0ec
      Uwe Kleine-König authored
      commit 13c78532 upstream.
      
      If there is a stuck irq that the handler doesn't address, returning
      IRQ_HANDLED unconditionally makes it impossible for the irq core to
      detect the problem and disable the irq. So only return IRQ_HANDLED if
      an event was handled.
      
      A stuck irq is still problematic, but with this change at least it only
      makes the UART nonfunctional instead of occupying the (usually only) CPU
      by 100% and so stall the whole machine.
      
      Fixes: 48a6092f
      
       ("serial: stm32-usart: Add STM32 USART Driver")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
      Link: https://lore.kernel.org/r/5f92603d0dfd8a5b8014b2b10a902d91e0bb881f.1713344161.git.u.kleine-koenig@pengutronix.de
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      9f9be0ec
    • Finn Thain's avatar
      serial/pmac_zilog: Remove flawed mitigation for rx irq flood · 52aaf1ff
      Finn Thain authored
      commit 1be32264
      
       upstream.
      
      The mitigation was intended to stop the irq completely. That may be
      better than a hard lock-up but it turns out that you get a crash anyway
      if you're using pmac_zilog as a serial console:
      
      ttyPZ0: pmz: rx irq flood !
      BUG: spinlock recursion on CPU#0, swapper/0
      
      That's because the pr_err() call in pmz_receive_chars() results in
      pmz_console_write() attempting to lock a spinlock already locked in
      pmz_interrupt(). With CONFIG_DEBUG_SPINLOCK=y, this produces a fatal
      BUG splat. The spinlock in question is the one in struct uart_port.
      
      Even when it's not fatal, the serial port rx function ceases to work.
      Also, the iteration limit doesn't play nicely with QEMU, as can be
      seen in the bug report linked below.
      
      A web search for other reports of the error message "pmz: rx irq flood"
      didn't produce anything. So I don't think this code is needed any more.
      Remove it.
      
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Cc: Nicholas Piggin <npiggin@gmail.com>
      Cc: Christophe Leroy <christophe.leroy@csgroup.eu>
      Cc: Aneesh Kumar K.V <aneesh.kumar@kernel.org>
      Cc: Naveen N. Rao <naveen.n.rao@linux.ibm.com>
      Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
      Cc: stable@kernel.org
      Cc: linux-m68k@lists.linux-m68k.org
      Link: https://github.com/vivier/qemu-m68k/issues/44
      Link: https://lore.kernel.org/all/1078874617.9746.36.camel@gaston/
      Acked-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
      Fixes: 1da177e4
      
       ("Linux-2.6.12-rc2")
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarFinn Thain <fthain@linux-m68k.org>
      Link: https://lore.kernel.org/r/e853cf2c762f23101cd2ddec0cc0c2be0e72685f.1712568223.git.fthain@linux-m68k.org
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      52aaf1ff
    • Emil Kronborg's avatar
      serial: mxs-auart: add spinlock around changing cts state · 5f40fd6c
      Emil Kronborg authored
      commit 54c4ec5f upstream.
      
      The uart_handle_cts_change() function in serial_core expects the caller
      to hold uport->lock. For example, I have seen the below kernel splat,
      when the Bluetooth driver is loaded on an i.MX28 board.
      
          [   85.119255] ------------[ cut here ]------------
          [   85.124413] WARNING: CPU: 0 PID: 27 at /drivers/tty/serial/serial_core.c:3453 uart_handle_cts_change+0xb4/0xec
          [   85.134694] Modules linked in: hci_uart bluetooth ecdh_generic ecc wlcore_sdio configfs
          [   85.143314] CPU: 0 PID: 27 Comm: kworker/u3:0 Not tainted 6.6.3-00021-gd62a2f068f92 #1
          [   85.151396] Hardware name: Freescale MXS (Device Tree)
          [   85.156679] Workqueue: hci0 hci_power_on [bluetooth]
          (...)
          [   85.191765]  uart_handle_cts_change from mxs_auart_irq_handle+0x380/0x3f4
          [   85.198787]  mxs_auart_irq_handle from __handle_irq_event_percpu+0x88/0x210
          (...)
      
      Cc: stable@vger.kernel.org
      Fixes: 4d90bb14
      
       ("serial: core: Document and assert lock requirements for irq helpers")
      Reviewed-by: default avatarFrank Li <Frank.Li@nxp.com>
      Signed-off-by: default avatarEmil Kronborg <emil.kronborg@protonmail.com>
      Link: https://lore.kernel.org/r/20240320121530.11348-1-emil.kronborg@protonmail.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      5f40fd6c
    • Nikita Zhandarovich's avatar
      comedi: vmk80xx: fix incomplete endpoint checking · 59f33af9
      Nikita Zhandarovich authored
      commit d1718530
      
       upstream.
      
      While vmk80xx does have endpoint checking implemented, some things
      can fall through the cracks. Depending on the hardware model,
      URBs can have either bulk or interrupt type, and current version
      of vmk80xx_find_usb_endpoints() function does not take that fully
      into account. While this warning does not seem to be too harmful,
      at the very least it will crash systems with 'panic_on_warn' set on
      them.
      
      Fix the issue found by Syzkaller [1] by somewhat simplifying the
      endpoint checking process with usb_find_common_endpoints() and
      ensuring that only expected endpoint types are present.
      
      This patch has not been tested on real hardware.
      
      [1] Syzkaller report:
      usb 1-1: BOGUS urb xfer, pipe 1 != type 3
      WARNING: CPU: 0 PID: 781 at drivers/usb/core/urb.c:504 usb_submit_urb+0xc4e/0x18c0 drivers/usb/core/urb.c:503
      ...
      Call Trace:
       <TASK>
       usb_start_wait_urb+0x113/0x520 drivers/usb/core/message.c:59
       vmk80xx_reset_device drivers/comedi/drivers/vmk80xx.c:227 [inline]
       vmk80xx_auto_attach+0xa1c/0x1a40 drivers/comedi/drivers/vmk80xx.c:818
       comedi_auto_config+0x238/0x380 drivers/comedi/drivers.c:1067
       usb_probe_interface+0x5cd/0xb00 drivers/usb/core/driver.c:399
      ...
      
      Similar issue also found by Syzkaller:
      Link: https://syzkaller.appspot.com/bug?extid=5205eb2f17de3e01946e
      
      Reported-and-tested-by: default avatar <syzbot+5f29dc6a889fc42bd896@syzkaller.appspotmail.com>
      Cc: stable <stable@kernel.org>
      Fixes: 49253d54
      
       ("staging: comedi: vmk80xx: factor out usb endpoint detection")
      Reviewed-by: default avatarIan Abbott <abbotti@mev.co.uk>
      Signed-off-by: default avatarNikita Zhandarovich <n.zhandarovich@fintech.ru>
      Link: https://lore.kernel.org/r/20240408171633.31649-1-n.zhandarovich@fintech.ru
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      59f33af9
    • Gil Fine's avatar
      thunderbolt: Fix wake configurations after device unplug · 9954c514
      Gil Fine authored
      commit c38fa07d
      
       upstream.
      
      Currently we don't configure correctly the wake events after unplug of device
      router. What can happen is that the downstream ports of host router will be
      configured to wake on: USB4-wake and wake-on-disconnect, but not on
      wake-on-connect. This may cause the later plugged device not to wake the
      domain and fail in enumeration. Fix this by clearing downstream port's "USB4
      Port is Configured" bit, after unplug of a device router.
      
      Signed-off-by: default avatarGil Fine <gil.fine@linux.intel.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarMika Westerberg <mika.westerberg@linux.intel.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      9954c514
    • Gil Fine's avatar
      thunderbolt: Avoid notify PM core about runtime PM resume · 3238b23e
      Gil Fine authored
      commit dcd12aca
      
       upstream.
      
      Currently we notify PM core about occurred wakes after any resume. This
      is not actually needed after resume from runtime suspend. Hence, notify
      PM core about occurred wakes only after resume from system sleep. Also,
      if the wake occurred in USB4 router upstream port, we don't notify the
      PM core about it since it is not actually needed and can cause
      unexpected autowake (e.g. if /sys/power/wakeup_count is used).
      
      While there add the missing kernel-doc for tb_switch_resume().
      
      Signed-off-by: default avatarGil Fine <gil.fine@linux.intel.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarMika Westerberg <mika.westerberg@linux.intel.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      3238b23e
    • Carlos Llamas's avatar
      binder: check offset alignment in binder_get_object() · 1d7f1049
      Carlos Llamas authored
      commit aaef7382 upstream.
      
      Commit 6d98eb95 ("binder: avoid potential data leakage when copying
      txn") introduced changes to how binder objects are copied. In doing so,
      it unintentionally removed an offset alignment check done through calls
      to binder_alloc_copy_from_buffer() -> check_buffer().
      
      These calls were replaced in binder_get_object() with copy_from_user(),
      so now an explicit offset alignment check is needed here. This avoids
      later complications when unwinding the objects gets harder.
      
      It is worth noting this check existed prior to commit 7a67a393
      ("binder: add function to copy binder object from buffer"), likely
      removed due to redundancy at the time.
      
      Fixes: 6d98eb95
      
       ("binder: avoid potential data leakage when copying txn")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarCarlos Llamas <cmllamas@google.com>
      Acked-by: default avatarTodd Kjos <tkjos@google.com>
      Link: https://lore.kernel.org/r/20240330190115.1877819-1-cmllamas@google.com
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      1d7f1049
    • Ai Chao's avatar
      ALSA: hda/realtek - Enable audio jacks of Haier Boyue G42 with ALC269VC · ce2ec45c
      Ai Chao authored
      commit 7ee5faad
      
       upstream.
      
      The Haier Boyue G42 with ALC269VC cannot detect the MIC of headset,
      the line out and internal speaker until
      ALC269VC_FIXUP_ACER_VCOPPERBOX_PINS quirk applied.
      
      Signed-off-by: default avatarAi Chao <aichao@kylinos.cn>
      Cc: <stable@vger.kernel.org>
      Message-ID: <20240419082159.476879-1-aichao@kylinos.cn>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      ce2ec45c
    • Mauro Carvalho Chehab's avatar
      ALSA: hda/realtek: Add quirks for Huawei Matebook D14 NBLB-WAX9N · 90782cf1
      Mauro Carvalho Chehab authored
      commit 7caf3daa
      
       upstream.
      
      The headset mic requires a fixup to be properly detected/used.
      
      As a reference, this specific model from 2021 reports
      the following devices:
      	https://alsa-project.org/db/?f=1a5ddeb0b151db8fe051407f5bb1c075b7dd3e4a
      
      Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@kernel.org>
      Cc: <stable@vger.kernel.org>
      Message-ID: <b92a9e49fb504eec8416bcc6882a52de89450102.1713370457.git.mchehab@kernel.org>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      90782cf1
    • Shenghao Ding's avatar
      ALSA: hda/tas2781: Add new vendor_id and subsystem_id to support ThinkPad ICE-1 · 05e6bfd3
      Shenghao Ding authored
      commit f74ab0c5
      
       upstream.
      
      Add new vendor_id and subsystem_id to support new Lenovo laptop
      ThinkPad ICE-1
      
      Signed-off-by: default avatarShenghao Ding <shenghao-ding@ti.com>
      Cc: <stable@vger.kernel.org>
      Message-ID: <20240411091823.1644-1-shenghao-ding@ti.com>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      05e6bfd3
    • Shenghao Ding's avatar
      ALSA: hda/tas2781: correct the register for pow calibrated data · 1da8f46f
      Shenghao Ding authored
      commit 0b6f0ff0 upstream.
      
      Calibrated data was written into an incorrect register, which cause
      speaker protection sometimes malfuctions
      
      Fixes: 5be27f1e
      
       ("ALSA: hda/tas2781: Add tas2781 HDA driver")
      Signed-off-by: default avatarShenghao Ding <shenghao-ding@ti.com>
      Cc: <stable@vger.kernel.org>
      Message-ID: <20240406132010.341-1-shenghao-ding@ti.com>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      1da8f46f
    • Takashi Iwai's avatar
      ALSA: seq: ump: Fix conversion from MIDI2 to MIDI1 UMP messages · 02d32d5a
      Takashi Iwai authored
      commit f25f17dc upstream.
      
      The conversion from MIDI2 to MIDI1 UMP messages had a leftover
      artifact (superfluous bit shift), and this resulted in the bogus type
      check, leading to empty outputs.  Let's fix it.
      
      Fixes: e9e02819
      
       ("ALSA: seq: Automatic conversion of UMP events")
      Cc: <stable@vger.kernel.org>
      Link: https://github.com/alsa-project/alsa-utils/issues/262
      Message-ID: <20240419100442.14806-1-tiwai@suse.de>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      02d32d5a
    • Shay Drory's avatar
      net/mlx5: E-switch, store eswitch pointer before registering devlink_param · 388a7302
      Shay Drory authored
      [ Upstream commit 0553e753
      
       ]
      
      Next patch will move devlink register to be first. Therefore, whenever
      mlx5 will register a param, the user will be notified.
      In order to notify the user, devlink is using the get() callback of
      the param. Hence, resources that are being used by the get() callback
      must be set before the devlink param is registered.
      
      Therefore, store eswitch pointer inside mdev before registering the
      param.
      
      Signed-off-by: default avatarShay Drory <shayd@nvidia.com>
      Reviewed-by: default avatarMoshe Shemesh <moshe@nvidia.com>
      Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
      Signed-off-by: default avatarTariq Toukan <tariqt@nvidia.com>
      Link: https://lore.kernel.org/r/20240409190820.227554-2-tariqt@nvidia.com
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      388a7302
    • Eric Biggers's avatar
      x86/cpufeatures: Fix dependencies for GFNI, VAES, and VPCLMULQDQ · 00cf046a
      Eric Biggers authored
      [ Upstream commit 9543f6e2 ]
      
      Fix cpuid_deps[] to list the correct dependencies for GFNI, VAES, and
      VPCLMULQDQ.  These features don't depend on AVX512, and there exist CPUs
      that support these features but not AVX512.  GFNI actually doesn't even
      depend on AVX.
      
      This prevents GFNI from being unnecessarily disabled if AVX is disabled
      to mitigate the GDS vulnerability.
      
      This also prevents all three features from being unnecessarily disabled
      if AVX512VL (or its dependency AVX512F) were to be disabled, but it
      looks like there isn't any case where this happens anyway.
      
      Fixes: c128dbfa
      
       ("x86/cpufeatures: Enable new SSE/AVX/AVX512 CPU features")
      Signed-off-by: default avatarEric Biggers <ebiggers@google.com>
      Signed-off-by: default avatarBorislav Petkov (AMD) <bp@alien8.de>
      Acked-by: default avatarDave Hansen <dave.hansen@linux.intel.com>
      Link: https://lore.kernel.org/r/20240417060434.47101-1-ebiggers@kernel.org
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      00cf046a
    • Josh Poimboeuf's avatar
      x86/bugs: Fix BHI retpoline check · 5facc042
      Josh Poimboeuf authored
      [ Upstream commit 69129794 ]
      
      Confusingly, X86_FEATURE_RETPOLINE doesn't mean retpolines are enabled,
      as it also includes the original "AMD retpoline" which isn't a retpoline
      at all.
      
      Also replace cpu_feature_enabled() with boot_cpu_has() because this is
      before alternatives are patched and cpu_feature_enabled()'s fallback
      path is slower than plain old boot_cpu_has().
      
      Fixes: ec9404e4
      
       ("x86/bhi: Add BHI mitigation knob")
      Signed-off-by: default avatarJosh Poimboeuf <jpoimboe@kernel.org>
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      Reviewed-by: default avatarPawan Gupta <pawan.kumar.gupta@linux.intel.com>
      Cc: Borislav Petkov <bp@alien8.de>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Link: https://lore.kernel.org/r/ad3807424a3953f0323c011a643405619f2a4927.1712944776.git.jpoimboe@kernel.org
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      5facc042
    • Pin-yen Lin's avatar
      clk: mediatek: Do a runtime PM get on controllers during probe · c0dcd5c0
      Pin-yen Lin authored
      [ Upstream commit 2f7b1d8b ]
      
      mt8183-mfgcfg has a mutual dependency with genpd during the probing
      stage, which leads to a deadlock in the following call stack:
      
      CPU0:  genpd_lock --> clk_prepare_lock
      genpd_power_off_work_fn()
       genpd_lock()
       generic_pm_domain::power_off()
          clk_unprepare()
            clk_prepare_lock()
      
      CPU1: clk_prepare_lock --> genpd_lock
      clk_register()
        __clk_core_init()
          clk_prepare_lock()
          clk_pm_runtime_get()
            genpd_lock()
      
      Do a runtime PM get at the probe function to make sure clk_register()
      won't acquire the genpd lock. Instead of only modifying mt8183-mfgcfg,
      do this on all mediatek clock controller probings because we don't
      believe this would cause any regression.
      
      Verified on MT8183 and MT8192 Chromebooks.
      
      Fixes: acddfc2c
      
       ("clk: mediatek: Add MT8183 clock support")
      Signed-off-by: default avatarPin-yen Lin <treapking@chromium.org>
      
      Link: https://lore.kernel.org/r/20240312115249.3341654-1-treapking@chromium.org
      Reviewed-by: default avatarAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
      Tested-by: default avatarAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
      Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      c0dcd5c0
    • Stephen Boyd's avatar
      clk: Get runtime PM before walking tree for clk_summary · 2c077fdf
      Stephen Boyd authored
      [ Upstream commit 9d1e795f ]
      
      Similar to the previous commit, we should make sure that all devices are
      runtime resumed before printing the clk_summary through debugfs. Failure
      to do so would result in a deadlock if the thread is resuming a device
      to print clk state and that device is also runtime resuming in another
      thread, e.g the screen is turning on and the display driver is starting
      up. We remove the calls to clk_pm_runtime_{get,put}() in this path
      because they're superfluous now that we know the devices are runtime
      resumed. This also squashes a bug where the return value of
      clk_pm_runtime_get() wasn't checked, leading to an RPM count underflow
      on error paths.
      
      Fixes: 1bb294a7
      
       ("clk: Enable/Disable runtime PM for clk_summary")
      Cc: Taniya Das <quic_tdas@quicinc.com>
      Cc: Douglas Anderson <dianders@chromium.org>
      Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
      Link: https://lore.kernel.org/r/20240325184204.745706-6-sboyd@kernel.org
      Reviewed-by: default avatarDouglas Anderson <dianders@chromium.org>
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      2c077fdf
    • Vishal Badole's avatar
      clk: Show active consumers of clocks in debugfs · 888a44f2
      Vishal Badole authored
      [ Upstream commit dcce5cc7
      
       ]
      
      This feature lists the clock consumer's name and respective connection
      id. Using this feature user can easily check that which user has
      acquired and enabled a particular clock.
      
      Usage:
      >> cat /sys/kernel/debug/clk/clk_summary
                            enable  prepare  protect
                                                                                duty  hardware                            Connection
         clock               count    count    count    rate   accuracy phase  cycle    enable   consumer                         Id
      ------------------------------------------------------------------------------------------------------------------------------
       clk_mcasp0_fixed         0        0        0    24576000          0      0  50000     Y   deviceless                     of_clk_get_from_provider
                                                                                                 deviceless                     no_connection_id
          clk_mcasp0            0        0        0    24576000          0      0  50000     N      simple-audio-card,cpu           no_connection_id
                                                                                                    deviceless                      no_connection_id
      
      Co-developed-by: default avatarChinmoy Ghosh <chinmoyghosh2001@gmail.com>
      Signed-off-by: default avatarChinmoy Ghosh <chinmoyghosh2001@gmail.com>
      Co-developed-by: default avatarMintu Patel <mintupatel89@gmail.com>
      Signed-off-by: default avatarMintu Patel <mintupatel89@gmail.com>
      Co-developed-by: default avatarVimal Kumar <vimal.kumar32@gmail.com>
      Signed-off-by: default avatarVimal Kumar <vimal.kumar32@gmail.com>
      Signed-off-by: default avatarVishal Badole <badolevishal1116@gmail.com>
      Link: https://lore.kernel.org/r/1669569799-8526-1-git-send-email-badolevishal1116@gmail.com
      Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
      Stable-dep-of: 9d1e795f
      
       ("clk: Get runtime PM before walking tree for clk_summary")
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      888a44f2
    • Stephen Boyd's avatar
      clk: Get runtime PM before walking tree during disable_unused · 60ff482c
      Stephen Boyd authored
      [ Upstream commit e581cf5d
      
       ]
      
      Doug reported [1] the following hung task:
      
       INFO: task swapper/0:1 blocked for more than 122 seconds.
             Not tainted 5.15.149-21875-gf795ebc40eb8 #1
       "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
       task:swapper/0       state:D stack:    0 pid:    1 ppid:     0 flags:0x00000008
       Call trace:
        __switch_to+0xf4/0x1f4
        __schedule+0x418/0xb80
        schedule+0x5c/0x10c
        rpm_resume+0xe0/0x52c
        rpm_resume+0x178/0x52c
        __pm_runtime_resume+0x58/0x98
        clk_pm_runtime_get+0x30/0xb0
        clk_disable_unused_subtree+0x58/0x208
        clk_disable_unused_subtree+0x38/0x208
        clk_disable_unused_subtree+0x38/0x208
        clk_disable_unused_subtree+0x38/0x208
        clk_disable_unused_subtree+0x38/0x208
        clk_disable_unused+0x4c/0xe4
        do_one_initcall+0xcc/0x2d8
        do_initcall_level+0xa4/0x148
        do_initcalls+0x5c/0x9c
        do_basic_setup+0x24/0x30
        kernel_init_freeable+0xec/0x164
        kernel_init+0x28/0x120
        ret_from_fork+0x10/0x20
       INFO: task kworker/u16:0:9 blocked for more than 122 seconds.
             Not tainted 5.15.149-21875-gf795ebc40eb8 #1
       "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
       task:kworker/u16:0   state:D stack:    0 pid:    9 ppid:     2 flags:0x00000008
       Workqueue: events_unbound deferred_probe_work_func
       Call trace:
        __switch_to+0xf4/0x1f4
        __schedule+0x418/0xb80
        schedule+0x5c/0x10c
        schedule_preempt_disabled+0x2c/0x48
        __mutex_lock+0x238/0x488
        __mutex_lock_slowpath+0x1c/0x28
        mutex_lock+0x50/0x74
        clk_prepare_lock+0x7c/0x9c
        clk_core_prepare_lock+0x20/0x44
        clk_prepare+0x24/0x30
        clk_bulk_prepare+0x40/0xb0
        mdss_runtime_resume+0x54/0x1c8
        pm_generic_runtime_resume+0x30/0x44
        __genpd_runtime_resume+0x68/0x7c
        genpd_runtime_resume+0x108/0x1f4
        __rpm_callback+0x84/0x144
        rpm_callback+0x30/0x88
        rpm_resume+0x1f4/0x52c
        rpm_resume+0x178/0x52c
        __pm_runtime_resume+0x58/0x98
        __device_attach+0xe0/0x170
        device_initial_probe+0x1c/0x28
        bus_probe_device+0x3c/0x9c
        device_add+0x644/0x814
        mipi_dsi_device_register_full+0xe4/0x170
        devm_mipi_dsi_device_register_full+0x28/0x70
        ti_sn_bridge_probe+0x1dc/0x2c0
        auxiliary_bus_probe+0x4c/0x94
        really_probe+0xcc/0x2c8
        __driver_probe_device+0xa8/0x130
        driver_probe_device+0x48/0x110
        __device_attach_driver+0xa4/0xcc
        bus_for_each_drv+0x8c/0xd8
        __device_attach+0xf8/0x170
        device_initial_probe+0x1c/0x28
        bus_probe_device+0x3c/0x9c
        deferred_probe_work_func+0x9c/0xd8
        process_one_work+0x148/0x518
        worker_thread+0x138/0x350
        kthread+0x138/0x1e0
        ret_from_fork+0x10/0x20
      
      The first thread is walking the clk tree and calling
      clk_pm_runtime_get() to power on devices required to read the clk
      hardware via struct clk_ops::is_enabled(). This thread holds the clk
      prepare_lock, and is trying to runtime PM resume a device, when it finds
      that the device is in the process of resuming so the thread schedule()s
      away waiting for the device to finish resuming before continuing. The
      second thread is runtime PM resuming the same device, but the runtime
      resume callback is calling clk_prepare(), trying to grab the
      prepare_lock waiting on the first thread.
      
      This is a classic ABBA deadlock. To properly fix the deadlock, we must
      never runtime PM resume or suspend a device with the clk prepare_lock
      held. Actually doing that is near impossible today because the global
      prepare_lock would have to be dropped in the middle of the tree, the
      device runtime PM resumed/suspended, and then the prepare_lock grabbed
      again to ensure consistency of the clk tree topology. If anything
      changes with the clk tree in the meantime, we've lost and will need to
      start the operation all over again.
      
      Luckily, most of the time we're simply incrementing or decrementing the
      runtime PM count on an active device, so we don't have the chance to
      schedule away with the prepare_lock held. Let's fix this immediate
      problem that can be triggered more easily by simply booting on Qualcomm
      sc7180.
      
      Introduce a list of clk_core structures that have been registered, or
      are in the process of being registered, that require runtime PM to
      operate. Iterate this list and call clk_pm_runtime_get() on each of them
      without holding the prepare_lock during clk_disable_unused(). This way
      we can be certain that the runtime PM state of the devices will be
      active and resumed so we can't schedule away while walking the clk tree
      with the prepare_lock held. Similarly, call clk_pm_runtime_put() without
      the prepare_lock held to properly drop the runtime PM reference. We
      remove the calls to clk_pm_runtime_{get,put}() in this path because
      they're superfluous now that we know the devices are runtime resumed.
      
      Reported-by: default avatarDouglas Anderson <dianders@chromium.org>
      Closes: https://lore.kernel.org/all/20220922084322.RFC.2.I375b6b9e0a0a5348962f004beb3dafee6a12dfbb@changeid/ [1]
      Closes: https://issuetracker.google.com/328070191
      Cc: Marek Szyprowski <m.szyprowski@samsung.com>
      Cc: Ulf Hansson <ulf.hansson@linaro.org>
      Cc: Krzysztof Kozlowski <krzk@kernel.org>
      Fixes: 9a34b453
      
       ("clk: Add support for runtime PM")
      Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
      Link: https://lore.kernel.org/r/20240325184204.745706-5-sboyd@kernel.org
      Reviewed-by: default avatarDouglas Anderson <dianders@chromium.org>
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      60ff482c
    • Stephen Boyd's avatar
      clk: Initialize struct clk_core kref earlier · 731ffd8d
      Stephen Boyd authored
      [ Upstream commit 9d05ae53
      
       ]
      
      Initialize this kref once we allocate memory for the struct clk_core so
      that we can reuse the release function to free any memory associated
      with the structure. This mostly consolidates code, but also clarifies
      that the kref lifetime exists once the container structure (struct
      clk_core) is allocated instead of leaving it in a half-baked state for
      most of __clk_core_init().
      
      Reviewed-by: default avatarDouglas Anderson <dianders@chromium.org>
      Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
      Link: https://lore.kernel.org/r/20240325184204.745706-4-sboyd@kernel.org
      Stable-dep-of: e581cf5d
      
       ("clk: Get runtime PM before walking tree during disable_unused")
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      731ffd8d
    • Stephen Boyd's avatar
      clk: Remove prepare_lock hold assertion in __clk_release() · 02a516cb
      Stephen Boyd authored
      [ Upstream commit 8358a76c ]
      
      Removing this assertion lets us move the kref_put() call outside the
      prepare_lock section. We don't need to hold the prepare_lock here to
      free memory and destroy the clk_core structure. We've already unlinked
      the clk from the clk tree and by the time the release function runs
      nothing holds a reference to the clk_core anymore so anything with the
      pointer can't access the memory that's being freed anyway. Way back in
      commit 496eadf8 ("clk: Use lockdep asserts to find missing hold of
      prepare_lock") we didn't need to have this assertion either.
      
      Fixes: 496eadf8
      
       ("clk: Use lockdep asserts to find missing hold of prepare_lock")
      Cc: Krzysztof Kozlowski <krzk@kernel.org>
      Reviewed-by: default avatarDouglas Anderson <dianders@chromium.org>
      Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
      Link: https://lore.kernel.org/r/20240325184204.745706-2-sboyd@kernel.org
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      02a516cb
    • Mike Tipton's avatar
      interconnect: Don't access req_list while it's being manipulated · d0d04efa
      Mike Tipton authored
      [ Upstream commit de1bf25b ]
      
      The icc_lock mutex was split into separate icc_lock and icc_bw_lock
      mutexes in [1] to avoid lockdep splats. However, this didn't adequately
      protect access to icc_node::req_list.
      
      The icc_set_bw() function will eventually iterate over req_list while
      only holding icc_bw_lock, but req_list can be modified while only
      holding icc_lock. This causes races between icc_set_bw(), of_icc_get(),
      and icc_put().
      
      Example A:
      
        CPU0                               CPU1
        ----                               ----
        icc_set_bw(path_a)
          mutex_lock(&icc_bw_lock);
                                           icc_put(path_b)
                                             mutex_lock(&icc_lock);
          aggregate_requests()
            hlist_for_each_entry(r, ...
                                             hlist_del(...
              <r = invalid pointer>
      
      Example B:
      
        CPU0                               CPU1
        ----                               ----
        icc_set_bw(path_a)
          mutex_lock(&icc_bw_lock);
                                           path_b = of_icc_get()
                                             of_icc_get_by_index()
                                               mutex_lock(&icc_lock);
                                               path_find()
                                                 path_init()
          aggregate_requests()
            hlist_for_each_entry(r, ...
                                                   hlist_add_head(...
              <r = invalid pointer>
      
      Fix this by ensuring icc_bw_lock is always held before manipulating
      icc_node::req_list. The additional places icc_bw_lock is held don't
      perform any memory allocations, so we should still be safe from the
      original lockdep splats that motivated the separate locks.
      
      [1] commit af42269c
      
       ("interconnect: Fix locking for runpm vs reclaim")
      
      Signed-off-by: default avatarMike Tipton <quic_mdtipton@quicinc.com>
      Fixes: af42269c
      
       ("interconnect: Fix locking for runpm vs reclaim")
      Reviewed-by: default avatarRob Clark <robdclark@chromium.org>
      Link: https://lore.kernel.org/r/20240305225652.22872-1-quic_mdtipton@quicinc.com
      Signed-off-by: default avatarGeorgi Djakov <djakov@kernel.org>
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      d0d04efa
    • Mario Limonciello's avatar
      platform/x86/amd/pmc: Extend Framework 13 quirk to more BIOSes · d7cc1d72
      Mario Limonciello authored
      [ Upstream commit f609e7b1
      
       ]
      
      BIOS 03.05 still hasn't fixed the spurious IRQ1 issue.  As it's still
      being worked on there is still a possibility that it won't need to
      apply to future BIOS releases.
      
      Add a quirk for BIOS 03.05 as well.
      
      Signed-off-by: default avatarMario Limonciello <mario.limonciello@amd.com>
      Reviewed-by: default avatarHans de Goede <hdegoede@redhat.com>
      Link: https://lore.kernel.org/r/20240410141046.433-1-mario.limonciello@amd.com
      Reviewed-by: default avatarIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
      Signed-off-by: default avatarIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      d7cc1d72