PCI: Move pci_clear_and_set_dword() helper to PCI header
authorShuai Xue <xueshuai@linux.alibaba.com>
Fri, 8 Dec 2023 02:56:50 +0000 (10:56 +0800)
committerWill Deacon <will@kernel.org>
Wed, 13 Dec 2023 13:35:41 +0000 (13:35 +0000)
commitac16087134b837d42b75bb1c741070b6c142f258
treee075f97329c7dca7a2dd883818f3bb3a4274dec9
parentad6534c626fedd818718d76c36d69c7d8e7b61cc
PCI: Move pci_clear_and_set_dword() helper to PCI header

The clear and set pattern is commonly used for accessing PCI config,
move the helper pci_clear_and_set_dword() from aspm.c into PCI header.
In addition, rename to pci_clear_and_set_config_dword() to retain the
"config" information and match the other accessors.

No functional change intended.

Signed-off-by: Shuai Xue <xueshuai@linux.alibaba.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Tested-by: Ilkka Koskinen <ilkka@os.amperecomputing.com>
Link: https://lore.kernel.org/r/20231208025652.87192-4-xueshuai@linux.alibaba.com
Signed-off-by: Will Deacon <will@kernel.org>
drivers/pci/access.c
drivers/pci/pcie/aspm.c
include/linux/pci.h