~vicamo/+git/ubuntu-kernel:bug-2032157/RTL8851BE-pid-collision/oem-6.5

Last commit made on 2023-08-24
Get this branch:
git clone -b bug-2032157/RTL8851BE-pid-collision/oem-6.5 https://git.launchpad.net/~vicamo/+git/ubuntu-kernel
Only You-Sheng Yang can upload to this branch. If you are You-Sheng Yang please log in for upload directions.

Branch merges

Branch information

Name:
bug-2032157/RTL8851BE-pid-collision/oem-6.5
Repository:
lp:~vicamo/+git/ubuntu-kernel

Recent commits

17de43f... by You-Sheng Yang

Bug 2032157: SAUCE: net: usb: rtl8150: avoid PID collision with RTL8851BE

Signed-off-by: You-Sheng Yang <email address hidden>

dbee473... by You-Sheng Yang

net: usb: rtl8150: avoid PID collision with RTL8851BE

BugLink: https://bugs.launchpad.net/somerville/+bug/2032157

Within newly launched Realtek RTL8851BE WiFi 6 802.11ax PCIe Adapter,
0x8150 is chosen as usb idProduct, which is already registered for
RTL8150 Fast Ethernet Adapter. The rtl8150 driver may be loaded before
rtw89 does, trying to initialize a RTL8851BE as a RTL8150.

  Bus 001 Device 002: ID 0bda:8150 Realtek Semiconductor Corp. RTL8150
  Fast Ethernet Adapter
  Device Descriptor:
    bDeviceClass 0 (Defined at Interface level)
    bDeviceSubClass 0
    bDeviceProtocol 0
    idVendor 0x0bda Realtek Semiconductor Corp.
    idProduct 0x8150 RTL8150 Fast Ethernet Adapter
    bcdDevice 1.00
    ...
      Interface Descriptor:
        bInterfaceClass 255 Vendor Specific Class
        bInterfaceSubClass 0
        bInterfaceProtocol 255

  Bus 001 Device 005: ID 0bda:8150 Realtek Semiconductor Corp. RTL8150
  Fast Ethernet Adapter
  Device Descriptor:
    bDeviceClass 224 Wireless
    bDeviceSubClass 1 Radio Frequency
    bDeviceProtocol 1 Bluetooth
    idVendor 0x0bda Realtek Semiconductor Corp.
    idProduct 0x8150 RTL8150 Fast Ethernet Adapter
    bcdDevice 0.00
    ...
      Interface Descriptor:
        bInterfaceClass 224 Wireless
        bInterfaceSubClass 1 Radio Frequency
        bInterfaceProtocol 1 Bluetooth

This change adds an additional match for RTL8150, so that it won't match
RTL8851BE anymore.

Signed-off-by: You-Sheng Yang <email address hidden>

4a30b7f... by You-Sheng Yang

Experimental linux-oem-6.5/jammy changes

71fc266... by You-Sheng Yang

UBUNTU: debian/dkms-versions -- add Intel USBIO Bridge drivers

BugLink: https://bugs.launchpad.net/bugs/2031412
Signed-off-by: You-Sheng Yang <email address hidden>

f39bb2f... by You-Sheng Yang

UBUNTU: debian/dkms-versions -- use ipu6/ivsc from ppa

BugLink: https://bugs.launchpad.net/bugs/2031412
Signed-off-by: You-Sheng Yang <email address hidden>

0f91270... by You-Sheng Yang

UBUNTU: debian/dkms-versions -- disable zfs for now

BugLink: https://bugs.launchpad.net/bugs/1786013
Signed-off-by: You-Sheng Yang <email address hidden>

4da0245... by You-Sheng Yang

UBUNTU: debian/dkms-versions -- update from kernel-versions (main/d2023.07.26)

BugLink: https://bugs.launchpad.net/bugs/1786013
Signed-off-by: You-Sheng Yang <email address hidden>

8556337... by Stefan Binding <email address hidden>

ALSA: hda/cs8409: Support new Dell Dolphin Variants

BugLink: https://bugs.launchpad.net/bugs/2031407

Add 4 new Dell Dolphin Systems, same configuration as older systems.

Signed-off-by: Stefan Binding <email address hidden>
Link: https://<email address hidden>
Signed-off-by: Takashi Iwai <email address hidden>
(cherry picked from commit 7c761166399bedfc89c928bef8015546d85a9099 linux-next)
Signed-off-by: You-Sheng Yang <email address hidden>

8f69ccc... by Igor

PCI: acpiphp: Use pci_assign_unassigned_bridge_resources() only for non-root bus

BugLink: https://bugs.launchpad.net/bugs/2031408

40613da52b13 ("PCI: acpiphp: Reassign resources on bridge if necessary")
changed acpiphp hotplug to use pci_assign_unassigned_bridge_resources()
which depends on bridge being available, however enable_slot() can be
called without bridge associated:

  1. Legitimate case of hotplug on root bus (widely used in virt world)

  2. A (misbehaving) firmware, that sends ACPI Bus Check notifications to
     non existing root ports (Dell Inspiron 7352/0W6WV0), which end up at
     enable_slot(..., bridge = 0) where bus has no bridge assigned to it.
     acpihp doesn't know that it's a bridge, and bus specific 'PCI
     subsystem' can't augment ACPI context with bridge information since
     the PCI device to get this data from is/was not available.

Issue is easy to reproduce with QEMU's 'pc' machine, which supports PCI
hotplug on hostbridge slots. To reproduce, boot kernel at commit
40613da52b13 in VM started with following CLI (assuming guest root fs is
installed on sda1 partition):

  # qemu-system-x86_64 -M pc -m 1G -enable-kvm -cpu host \
        -monitor stdio -serial file:serial.log \
        -kernel arch/x86/boot/bzImage \
        -append "root=/dev/sda1 console=ttyS0" \
        guest_disk.img

Once guest OS is fully booted at qemu prompt:

  (qemu) device_add e1000

(check serial.log) it will cause NULL pointer dereference at:

  void pci_assign_unassigned_bridge_resources(struct pci_dev *bridge)
  {
    struct pci_bus *parent = bridge->subordinate;

  BUG: kernel NULL pointer dereference, address: 0000000000000018

   ? pci_assign_unassigned_bridge_resources+0x1f/0x260
   enable_slot+0x21f/0x3e0
   acpiphp_hotplug_notify+0x13d/0x260
   acpi_device_hotplug+0xbc/0x540
   acpi_hotplug_work_fn+0x15/0x20
   process_one_work+0x1f7/0x370
   worker_thread+0x45/0x3b0

The issue was discovered on Dell Inspiron 7352/0W6WV0 laptop with following
sequence:

  1. Suspend to RAM
  2. Wake up with the same backtrace being observed:
  3. 2nd suspend to RAM attempt makes laptop freeze

Fix it by using __pci_bus_assign_resources() instead of
pci_assign_unassigned_bridge_resources() as we used to do, but only in case
when bus doesn't have a bridge associated (to cover for the case of ACPI
event on hostbridge or non existing root port).

That lets us keep hotplug on root bus working like it used to and at the
same time keeps resource reassignment usable on root ports (and other 1st
level bridges) that was fixed by 40613da52b13.

Fixes: 40613da52b13 ("PCI: acpiphp: Reassign resources on bridge if necessary")
Link: https://<email address hidden>
Reported-by: Woody Suwalski <email address hidden>
Tested-by: Woody Suwalski <email address hidden>
Tested-by: Michal Koutný <email address hidden>
Link: https://<email address hidden>
Signed-off-by: Igor Mammedov <email address hidden>
Signed-off-by: Bjorn Helgaas <email address hidden>
Acked-by: Rafael J. Wysocki <email address hidden>
Acked-by: Michael S. Tsirkin <email address hidden>
(cherry picked from commit cc22522fd55e257c86d340ae9aedc122e705a435)
Signed-off-by: You-Sheng Yang <email address hidden>

a1dcc5c... by Max Chou

UBUNTU: SAUCE: Bluetooth: btrtl: Load FW v2 otherwise FW v1 for RTL8852C

BugLink: https://bugs.launchpad.net/bugs/2025672

In the commit of linux-firmware project, rtl8852cu_fw.bin is updated as
FW v2 format[1]. Consider the case that if driver did not be updated for
FW v2 supported[2], it can not use FW v2.
By Canonical's suggestion, older driver should be able to load FW v1,
so rtl8852cu_fw.bin will be revert to the previous commit as FW v1 and
add rtl8852cu_fw_v2.bin as FW v2. This item will be started on
linux-firmware project.

In this commit, the driver prefers to load FW v2 if available. Fallback to
FW v1 otherwise.

Note that the driver has supported to extract the data for v1 and v2
since the commit[1].
The previous FW format of RTL8852C is v1. After the commit[2], the FW format
was changed to v2. Only RTL8852C suffered the different FW formats, so
we will use rtl8852cu_fw.bin for the original commit as FW v1 and
rtl8852cu_fw_v2.bin for the future maintained as FW v2. Other Realtek chips
will not been impacted by this patch.

To do on linux-firmware project after this commit.
1. revert '55e7448533e7 ("rtl_bt: Update RTL8852C BT USB firmware
   to 0x040D_7225")'
   => rtl_bt/rtl8852cu_fw.bin: FW v1 (stay at ver. 0xD7B8_FABF)
2. Add a new commit for rtl8852cu_fw_v2.bin
   =>rtl_bt/rtl8852cu_fw_v2.bin: FW v2 (to be maintained)

Reference:
[1]'9a24ce5e29b1 ("Bluetooth: btrtl: Firmware format v2 support")'
[2]'55e7448533e7 ("rtl_bt: Update RTL8852C BT USB firmware
    to 0x040D_7225")'

Fixes: 9a24ce5e29b ("Bluetooth: btrtl: Firmware format v2 support")
Suggested-by: Juerg Haefliger <email address hidden>
Tested-by: Hilda Wu <email address hidden>
Signed-off-by: Max Chou <email address hidden>
(cherry-picked from https://patchwork.kernel<email address hidden>/)
Signed-off-by: You-Sheng Yang <email address hidden>