diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2024-04-23 10:33:59 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2024-04-23 10:33:59 -0700 |
commit | 9eb5d99f4e4abaab8f4f3910ae1b484c7f7e0877 (patch) | |
tree | 3b5afba3c15b685981dcee360f01b0788dfdc21d | |
parent | facaf323ce6566067e1ccb0f3be74a10d2abf9d9 (diff) |
drop some 6.1 unneeded patches
-rw-r--r-- | queue-6.1/pci-add-pci_header_type_mfd-definition.patch | 38 | ||||
-rw-r--r-- | queue-6.1/pci-dpc-use-field_get.patch | 21 | ||||
-rw-r--r-- | queue-6.1/pci-use-pci_header_type_-instead-of-literals.patch | 323 | ||||
-rw-r--r-- | queue-6.1/series | 2 |
4 files changed, 6 insertions, 378 deletions
diff --git a/queue-6.1/pci-add-pci_header_type_mfd-definition.patch b/queue-6.1/pci-add-pci_header_type_mfd-definition.patch deleted file mode 100644 index fd6d3bb9e7..0000000000 --- a/queue-6.1/pci-add-pci_header_type_mfd-definition.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 17343c644f8dc296e6d6d6e7a87c036bf6fe0558 Mon Sep 17 00:00:00 2001 -From: Sasha Levin <sashal@kernel.org> -Date: Tue, 3 Oct 2023 15:52:59 +0300 -Subject: PCI: Add PCI_HEADER_TYPE_MFD definition -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -From: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> - -[ Upstream commit bdca03a271f2de2c24ea56756fd9bbcff35173fb ] - -Add PCI_HEADER_TYPE_MFD so we can replace literals in the code. - -Link: https://lore.kernel.org/r/20231003125300.5541-3-ilpo.jarvinen@linux.intel.com -Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> -Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> -Stable-dep-of: 83c088148c8e ("PCI: Use PCI_HEADER_TYPE_* instead of literals") -Signed-off-by: Sasha Levin <sashal@kernel.org> ---- - include/uapi/linux/pci_regs.h | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/include/uapi/linux/pci_regs.h b/include/uapi/linux/pci_regs.h -index 57b8e2ffb1dd3..2052d0bb363d7 100644 ---- a/include/uapi/linux/pci_regs.h -+++ b/include/uapi/linux/pci_regs.h -@@ -80,6 +80,7 @@ - #define PCI_HEADER_TYPE_NORMAL 0 - #define PCI_HEADER_TYPE_BRIDGE 1 - #define PCI_HEADER_TYPE_CARDBUS 2 -+#define PCI_HEADER_TYPE_MFD 0x80 /* Multi-Function Device (possible) */ - - #define PCI_BIST 0x0f /* 8 bits */ - #define PCI_BIST_CODE_MASK 0x0f /* Return result */ --- -2.43.0 - diff --git a/queue-6.1/pci-dpc-use-field_get.patch b/queue-6.1/pci-dpc-use-field_get.patch index 7fa8bc5dcc..aec821b278 100644 --- a/queue-6.1/pci-dpc-use-field_get.patch +++ b/queue-6.1/pci-dpc-use-field_get.patch @@ -18,13 +18,11 @@ Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Signed-off-by: Sasha Levin <sashal@kernel.org> --- - drivers/pci/pcie/dpc.c | 5 +++-- - drivers/pci/quirks.c | 2 +- - include/uapi/linux/pci_regs.h | 1 + + drivers/pci/pcie/dpc.c | 5 +++-- + drivers/pci/quirks.c | 2 +- + include/uapi/linux/pci_regs.h | 1 + 3 files changed, 5 insertions(+), 3 deletions(-) -diff --git a/drivers/pci/pcie/dpc.c b/drivers/pci/pcie/dpc.c -index 08800282825e1..acdbf9e770a8a 100644 --- a/drivers/pci/pcie/dpc.c +++ b/drivers/pci/pcie/dpc.c @@ -9,6 +9,7 @@ @@ -35,7 +33,7 @@ index 08800282825e1..acdbf9e770a8a 100644 #include <linux/delay.h> #include <linux/interrupt.h> #include <linux/init.h> -@@ -203,7 +204,7 @@ static void dpc_process_rp_pio_error(struct pci_dev *pdev) +@@ -203,7 +204,7 @@ static void dpc_process_rp_pio_error(str /* Get First Error Pointer */ pci_read_config_word(pdev, cap + PCI_EXP_DPC_STATUS, &dpc_status); @@ -53,11 +51,9 @@ index 08800282825e1..acdbf9e770a8a 100644 if (pdev->dpc_rp_log_size < 4 || pdev->dpc_rp_log_size > 9) { pci_err(pdev, "RP PIO log size %u is invalid\n", pdev->dpc_rp_log_size); -diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c -index 85088d1fff619..e4951b30b923b 100644 --- a/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c -@@ -6105,7 +6105,7 @@ static void dpc_log_size(struct pci_dev *dev) +@@ -6105,7 +6105,7 @@ static void dpc_log_size(struct pci_dev if (!(val & PCI_EXP_DPC_CAP_RP_EXT)) return; @@ -66,11 +62,9 @@ index 85088d1fff619..e4951b30b923b 100644 pci_info(dev, "Overriding RP PIO Log Size to 4\n"); dev->dpc_rp_log_size = 4; } -diff --git a/include/uapi/linux/pci_regs.h b/include/uapi/linux/pci_regs.h -index 2052d0bb363d7..07fbf28344167 100644 --- a/include/uapi/linux/pci_regs.h +++ b/include/uapi/linux/pci_regs.h -@@ -1044,6 +1044,7 @@ +@@ -1043,6 +1043,7 @@ #define PCI_EXP_DPC_STATUS_INTERRUPT 0x0008 /* Interrupt Status */ #define PCI_EXP_DPC_RP_BUSY 0x0010 /* Root Port Busy */ #define PCI_EXP_DPC_STATUS_TRIGGER_RSN_EXT 0x0060 /* Trig Reason Extension */ @@ -78,6 +72,3 @@ index 2052d0bb363d7..07fbf28344167 100644 #define PCI_EXP_DPC_SOURCE_ID 0x0A /* DPC Source Identifier */ --- -2.43.0 - diff --git a/queue-6.1/pci-use-pci_header_type_-instead-of-literals.patch b/queue-6.1/pci-use-pci_header_type_-instead-of-literals.patch deleted file mode 100644 index c2ae454398..0000000000 --- a/queue-6.1/pci-use-pci_header_type_-instead-of-literals.patch +++ /dev/null @@ -1,323 +0,0 @@ -From bbdb07bf407ffaef3f01c1d29791f16b7d587e8d Mon Sep 17 00:00:00 2001 -From: Sasha Levin <sashal@kernel.org> -Date: Tue, 3 Oct 2023 15:53:00 +0300 -Subject: PCI: Use PCI_HEADER_TYPE_* instead of literals -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -From: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> - -[ Upstream commit 83c088148c8e5c439eec6c7651692f797547e1a8 ] - -Replace literals under drivers/pci/ with PCI_HEADER_TYPE_MASK, -PCI_HEADER_TYPE_NORMAL, and PCI_HEADER_TYPE_MFD. - -Also replace !! boolean conversions with FIELD_GET(). - -Link: https://lore.kernel.org/r/20231003125300.5541-4-ilpo.jarvinen@linux.intel.com -Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> -Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> -Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com> # for Renesas R-Car -Signed-off-by: Sasha Levin <sashal@kernel.org> ---- - drivers/pci/controller/dwc/pci-layerscape.c | 2 +- - .../controller/mobiveil/pcie-mobiveil-host.c | 2 +- - drivers/pci/controller/pcie-iproc.c | 2 +- - drivers/pci/controller/pcie-rcar-ep.c | 2 +- - drivers/pci/controller/pcie-rcar-host.c | 2 +- - drivers/pci/controller/vmd.c | 2 +- - drivers/pci/hotplug/cpqphp_ctrl.c | 6 ++--- - drivers/pci/hotplug/cpqphp_pci.c | 22 +++++++++---------- - drivers/pci/hotplug/ibmphp.h | 5 +++-- - drivers/pci/hotplug/ibmphp_pci.c | 2 +- - drivers/pci/pci.c | 2 +- - drivers/pci/quirks.c | 6 ++--- - 12 files changed, 28 insertions(+), 27 deletions(-) - -diff --git a/drivers/pci/controller/dwc/pci-layerscape.c b/drivers/pci/controller/dwc/pci-layerscape.c -index 879b8692f96a5..b133df32e14d5 100644 ---- a/drivers/pci/controller/dwc/pci-layerscape.c -+++ b/drivers/pci/controller/dwc/pci-layerscape.c -@@ -42,7 +42,7 @@ static bool ls_pcie_is_bridge(struct ls_pcie *pcie) - u32 header_type; - - header_type = ioread8(pci->dbi_base + PCI_HEADER_TYPE); -- header_type &= 0x7f; -+ header_type &= PCI_HEADER_TYPE_MASK; - - return header_type == PCI_HEADER_TYPE_BRIDGE; - } -diff --git a/drivers/pci/controller/mobiveil/pcie-mobiveil-host.c b/drivers/pci/controller/mobiveil/pcie-mobiveil-host.c -index 31a7bdebe5403..461e2da5f4e6a 100644 ---- a/drivers/pci/controller/mobiveil/pcie-mobiveil-host.c -+++ b/drivers/pci/controller/mobiveil/pcie-mobiveil-host.c -@@ -542,7 +542,7 @@ static bool mobiveil_pcie_is_bridge(struct mobiveil_pcie *pcie) - u32 header_type; - - header_type = mobiveil_csr_readb(pcie, PCI_HEADER_TYPE); -- header_type &= 0x7f; -+ header_type &= PCI_HEADER_TYPE_MASK; - - return header_type == PCI_HEADER_TYPE_BRIDGE; - } -diff --git a/drivers/pci/controller/pcie-iproc.c b/drivers/pci/controller/pcie-iproc.c -index 2519201b0e51c..0c66e6ec1d228 100644 ---- a/drivers/pci/controller/pcie-iproc.c -+++ b/drivers/pci/controller/pcie-iproc.c -@@ -784,7 +784,7 @@ static int iproc_pcie_check_link(struct iproc_pcie *pcie) - - /* make sure we are not in EP mode */ - iproc_pci_raw_config_read32(pcie, 0, PCI_HEADER_TYPE, 1, &hdr_type); -- if ((hdr_type & 0x7f) != PCI_HEADER_TYPE_BRIDGE) { -+ if ((hdr_type & PCI_HEADER_TYPE_MASK) != PCI_HEADER_TYPE_BRIDGE) { - dev_err(dev, "in EP mode, hdr=%#02x\n", hdr_type); - return -EFAULT; - } -diff --git a/drivers/pci/controller/pcie-rcar-ep.c b/drivers/pci/controller/pcie-rcar-ep.c -index f9682df1da619..7034c0ff23d0d 100644 ---- a/drivers/pci/controller/pcie-rcar-ep.c -+++ b/drivers/pci/controller/pcie-rcar-ep.c -@@ -43,7 +43,7 @@ static void rcar_pcie_ep_hw_init(struct rcar_pcie *pcie) - rcar_rmw32(pcie, REXPCAP(0), 0xff, PCI_CAP_ID_EXP); - rcar_rmw32(pcie, REXPCAP(PCI_EXP_FLAGS), - PCI_EXP_FLAGS_TYPE, PCI_EXP_TYPE_ENDPOINT << 4); -- rcar_rmw32(pcie, RCONF(PCI_HEADER_TYPE), 0x7f, -+ rcar_rmw32(pcie, RCONF(PCI_HEADER_TYPE), PCI_HEADER_TYPE_MASK, - PCI_HEADER_TYPE_NORMAL); - - /* Write out the physical slot number = 0 */ -diff --git a/drivers/pci/controller/pcie-rcar-host.c b/drivers/pci/controller/pcie-rcar-host.c -index e4faf90feaf5c..311a52170d990 100644 ---- a/drivers/pci/controller/pcie-rcar-host.c -+++ b/drivers/pci/controller/pcie-rcar-host.c -@@ -475,7 +475,7 @@ static int rcar_pcie_hw_init(struct rcar_pcie *pcie) - rcar_rmw32(pcie, REXPCAP(0), 0xff, PCI_CAP_ID_EXP); - rcar_rmw32(pcie, REXPCAP(PCI_EXP_FLAGS), - PCI_EXP_FLAGS_TYPE, PCI_EXP_TYPE_ROOT_PORT << 4); -- rcar_rmw32(pcie, RCONF(PCI_HEADER_TYPE), 0x7f, -+ rcar_rmw32(pcie, RCONF(PCI_HEADER_TYPE), PCI_HEADER_TYPE_MASK, - PCI_HEADER_TYPE_BRIDGE); - - /* Enable data link layer active state reporting */ -diff --git a/drivers/pci/controller/vmd.c b/drivers/pci/controller/vmd.c -index 5c35884c226e6..5560439fed159 100644 ---- a/drivers/pci/controller/vmd.c -+++ b/drivers/pci/controller/vmd.c -@@ -512,7 +512,7 @@ static void vmd_domain_reset(struct vmd_dev *vmd) - - hdr_type = readb(base + PCI_HEADER_TYPE); - -- functions = (hdr_type & 0x80) ? 8 : 1; -+ functions = (hdr_type & PCI_HEADER_TYPE_MFD) ? 8 : 1; - for (fn = 0; fn < functions; fn++) { - base = vmd->cfgbar + PCIE_ECAM_OFFSET(bus, - PCI_DEVFN(dev, fn), 0); -diff --git a/drivers/pci/hotplug/cpqphp_ctrl.c b/drivers/pci/hotplug/cpqphp_ctrl.c -index e429ecddc8feb..c01968ef0bd7b 100644 ---- a/drivers/pci/hotplug/cpqphp_ctrl.c -+++ b/drivers/pci/hotplug/cpqphp_ctrl.c -@@ -2059,7 +2059,7 @@ int cpqhp_process_SS(struct controller *ctrl, struct pci_func *func) - return rc; - - /* If it's a bridge, check the VGA Enable bit */ -- if ((header_type & 0x7F) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - rc = pci_bus_read_config_byte(pci_bus, devfn, PCI_BRIDGE_CONTROL, &BCR); - if (rc) - return rc; -@@ -2342,7 +2342,7 @@ static int configure_new_function(struct controller *ctrl, struct pci_func *func - if (rc) - return rc; - -- if ((temp_byte & 0x7F) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((temp_byte & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - /* set Primary bus */ - dbg("set Primary bus = %d\n", func->bus); - rc = pci_bus_write_config_byte(pci_bus, devfn, PCI_PRIMARY_BUS, func->bus); -@@ -2739,7 +2739,7 @@ static int configure_new_function(struct controller *ctrl, struct pci_func *func - * PCI_BRIDGE_CTL_SERR | - * PCI_BRIDGE_CTL_NO_ISA */ - rc = pci_bus_write_config_word(pci_bus, devfn, PCI_BRIDGE_CONTROL, command); -- } else if ((temp_byte & 0x7F) == PCI_HEADER_TYPE_NORMAL) { -+ } else if ((temp_byte & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_NORMAL) { - /* Standard device */ - rc = pci_bus_read_config_byte(pci_bus, devfn, 0x0B, &class_code); - -diff --git a/drivers/pci/hotplug/cpqphp_pci.c b/drivers/pci/hotplug/cpqphp_pci.c -index 3b248426a9f42..e9f1fb333a718 100644 ---- a/drivers/pci/hotplug/cpqphp_pci.c -+++ b/drivers/pci/hotplug/cpqphp_pci.c -@@ -363,7 +363,7 @@ int cpqhp_save_config(struct controller *ctrl, int busnumber, int is_hot_plug) - return rc; - - /* If multi-function device, set max_functions to 8 */ -- if (header_type & 0x80) -+ if (header_type & PCI_HEADER_TYPE_MFD) - max_functions = 8; - else - max_functions = 1; -@@ -372,7 +372,7 @@ int cpqhp_save_config(struct controller *ctrl, int busnumber, int is_hot_plug) - - do { - DevError = 0; -- if ((header_type & 0x7F) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - /* Recurse the subordinate bus - * get the subordinate bus number - */ -@@ -487,13 +487,13 @@ int cpqhp_save_slot_config(struct controller *ctrl, struct pci_func *new_slot) - pci_bus_read_config_byte(ctrl->pci_bus, PCI_DEVFN(new_slot->device, 0), 0x0B, &class_code); - pci_bus_read_config_byte(ctrl->pci_bus, PCI_DEVFN(new_slot->device, 0), PCI_HEADER_TYPE, &header_type); - -- if (header_type & 0x80) /* Multi-function device */ -+ if (header_type & PCI_HEADER_TYPE_MFD) - max_functions = 8; - else - max_functions = 1; - - while (function < max_functions) { -- if ((header_type & 0x7F) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - /* Recurse the subordinate bus */ - pci_bus_read_config_byte(ctrl->pci_bus, PCI_DEVFN(new_slot->device, function), PCI_SECONDARY_BUS, &secondary_bus); - -@@ -571,7 +571,7 @@ int cpqhp_save_base_addr_length(struct controller *ctrl, struct pci_func *func) - /* Check for Bridge */ - pci_bus_read_config_byte(pci_bus, devfn, PCI_HEADER_TYPE, &header_type); - -- if ((header_type & 0x7F) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - pci_bus_read_config_byte(pci_bus, devfn, PCI_SECONDARY_BUS, &secondary_bus); - - sub_bus = (int) secondary_bus; -@@ -625,7 +625,7 @@ int cpqhp_save_base_addr_length(struct controller *ctrl, struct pci_func *func) - - } /* End of base register loop */ - -- } else if ((header_type & 0x7F) == 0x00) { -+ } else if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_NORMAL) { - /* Figure out IO and memory base lengths */ - for (cloop = 0x10; cloop <= 0x24; cloop += 4) { - temp_register = 0xFFFFFFFF; -@@ -723,7 +723,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) - /* Check for Bridge */ - pci_bus_read_config_byte(pci_bus, devfn, PCI_HEADER_TYPE, &header_type); - -- if ((header_type & 0x7F) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - /* Clear Bridge Control Register */ - command = 0x00; - pci_bus_write_config_word(pci_bus, devfn, PCI_BRIDGE_CONTROL, command); -@@ -858,7 +858,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) - } - } /* End of base register loop */ - /* Standard header */ -- } else if ((header_type & 0x7F) == 0x00) { -+ } else if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_NORMAL) { - /* Figure out IO and memory base lengths */ - for (cloop = 0x10; cloop <= 0x24; cloop += 4) { - pci_bus_read_config_dword(pci_bus, devfn, cloop, &save_base); -@@ -975,7 +975,7 @@ int cpqhp_configure_board(struct controller *ctrl, struct pci_func *func) - pci_bus_read_config_byte(pci_bus, devfn, PCI_HEADER_TYPE, &header_type); - - /* If this is a bridge device, restore subordinate devices */ -- if ((header_type & 0x7F) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - pci_bus_read_config_byte(pci_bus, devfn, PCI_SECONDARY_BUS, &secondary_bus); - - sub_bus = (int) secondary_bus; -@@ -1067,7 +1067,7 @@ int cpqhp_valid_replace(struct controller *ctrl, struct pci_func *func) - /* Check for Bridge */ - pci_bus_read_config_byte(pci_bus, devfn, PCI_HEADER_TYPE, &header_type); - -- if ((header_type & 0x7F) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - /* In order to continue checking, we must program the - * bus registers in the bridge to respond to accesses - * for its subordinate bus(es) -@@ -1090,7 +1090,7 @@ int cpqhp_valid_replace(struct controller *ctrl, struct pci_func *func) - - } - /* Check to see if it is a standard config header */ -- else if ((header_type & 0x7F) == PCI_HEADER_TYPE_NORMAL) { -+ else if ((header_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_NORMAL) { - /* Check subsystem vendor and ID */ - pci_bus_read_config_dword(pci_bus, devfn, PCI_SUBSYSTEM_VENDOR_ID, &temp_register); - -diff --git a/drivers/pci/hotplug/ibmphp.h b/drivers/pci/hotplug/ibmphp.h -index 0399c60d2ec1a..5c43edd8831e0 100644 ---- a/drivers/pci/hotplug/ibmphp.h -+++ b/drivers/pci/hotplug/ibmphp.h -@@ -17,6 +17,7 @@ - */ - - #include <linux/pci_hotplug.h> -+#include <linux/pci_regs.h> - - extern int ibmphp_debug; - -@@ -288,8 +289,8 @@ int ibmphp_register_pci(void); - - /* pci specific defines */ - #define PCI_VENDOR_ID_NOTVALID 0xFFFF --#define PCI_HEADER_TYPE_MULTIDEVICE 0x80 --#define PCI_HEADER_TYPE_MULTIBRIDGE 0x81 -+#define PCI_HEADER_TYPE_MULTIDEVICE (PCI_HEADER_TYPE_MFD|PCI_HEADER_TYPE_NORMAL) -+#define PCI_HEADER_TYPE_MULTIBRIDGE (PCI_HEADER_TYPE_MFD|PCI_HEADER_TYPE_BRIDGE) - - #define LATENCY 0x64 - #define CACHE 64 -diff --git a/drivers/pci/hotplug/ibmphp_pci.c b/drivers/pci/hotplug/ibmphp_pci.c -index 754c3f23282e3..e4ee37d84ffac 100644 ---- a/drivers/pci/hotplug/ibmphp_pci.c -+++ b/drivers/pci/hotplug/ibmphp_pci.c -@@ -1087,7 +1087,7 @@ static struct res_needed *scan_behind_bridge(struct pci_func *func, u8 busno) - pci_bus_read_config_dword(ibmphp_pci_bus, devfn, PCI_CLASS_REVISION, &class); - - debug("hdr_type behind the bridge is %x\n", hdr_type); -- if ((hdr_type & 0x7f) == PCI_HEADER_TYPE_BRIDGE) { -+ if ((hdr_type & PCI_HEADER_TYPE_MASK) == PCI_HEADER_TYPE_BRIDGE) { - err("embedded bridges not supported for hot-plugging.\n"); - amount->not_correct = 1; - return amount; -diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c -index 5368a37154cf9..8771e03d2052a 100644 ---- a/drivers/pci/pci.c -+++ b/drivers/pci/pci.c -@@ -519,7 +519,7 @@ u8 pci_bus_find_capability(struct pci_bus *bus, unsigned int devfn, int cap) - - pci_bus_read_config_byte(bus, devfn, PCI_HEADER_TYPE, &hdr_type); - -- pos = __pci_bus_find_cap_start(bus, devfn, hdr_type & 0x7f); -+ pos = __pci_bus_find_cap_start(bus, devfn, hdr_type & PCI_HEADER_TYPE_MASK); - if (pos) - pos = __pci_find_next_cap(bus, devfn, pos, cap); - -diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c -index 7e5b3186db78b..85088d1fff619 100644 ---- a/drivers/pci/quirks.c -+++ b/drivers/pci/quirks.c -@@ -1756,8 +1756,8 @@ static void quirk_jmicron_ata(struct pci_dev *pdev) - - /* Update pdev accordingly */ - pci_read_config_byte(pdev, PCI_HEADER_TYPE, &hdr); -- pdev->hdr_type = hdr & 0x7f; -- pdev->multifunction = !!(hdr & 0x80); -+ pdev->hdr_type = hdr & PCI_HEADER_TYPE_MASK; -+ pdev->multifunction = FIELD_GET(PCI_HEADER_TYPE_MFD, hdr); - - pci_read_config_dword(pdev, PCI_CLASS_REVISION, &class); - pdev->class = class >> 8; -@@ -5617,7 +5617,7 @@ static void quirk_nvidia_hda(struct pci_dev *gpu) - - /* The GPU becomes a multi-function device when the HDA is enabled */ - pci_read_config_byte(gpu, PCI_HEADER_TYPE, &hdr_type); -- gpu->multifunction = !!(hdr_type & 0x80); -+ gpu->multifunction = FIELD_GET(PCI_HEADER_TYPE_MFD, hdr_type); - } - DECLARE_PCI_FIXUP_CLASS_HEADER(PCI_VENDOR_ID_NVIDIA, PCI_ANY_ID, - PCI_BASE_CLASS_DISPLAY, 16, quirk_nvidia_hda); --- -2.43.0 - diff --git a/queue-6.1/series b/queue-6.1/series index 8ba8f7bfca..558a2bfe8f 100644 --- a/queue-6.1/series +++ b/queue-6.1/series @@ -70,8 +70,6 @@ alsa-scarlett2-move-usb-ids-out-from-device_info-str.patch alsa-scarlett2-add-support-for-clarett-8pre-usb.patch asoc-ti-convert-pandora-asoc-to-gpio-descriptors.patch usb-pci-quirks-group-amd-specific-quirk-code-togethe.patch -pci-add-pci_header_type_mfd-definition.patch -pci-use-pci_header_type_-instead-of-literals.patch alsa-scarlett2-default-mixer-driver-to-enabled.patch alsa-scarlett2-add-correct-product-series-name-to-me.patch alsa-scarlett2-add-focusrite-clarett-2pre-and-4pre-s.patch |