PCI: Remove most pcim_iounmap_regions() users
Subsystems (9)
v8 cover PCI: Remove most pcim_iounmap_regions() users
Merge plan for this is the PCI-Tree.
After this series, only two users (net/ethernet/stmicro and vdpa/solidrun) will remain to be ported in the subsequent merge window. Doing them right now proved very difficult because of various conflicts as they are currently also being reworked.
Changes in v8:
- Patch "gpio: ..": Fix a bug: don't print the wrong error code. (Simon)
- Split patch 1 into two patches to make adding of the new public API obvious (Bartosz)
- Patch "ethernet: cavium: ...": Remove outdated sentences from the commit message.
Changes in v7:
- Add Paolo's Acked-by.
- Rebase on current master; drop patch No.1 which made pcim_request_region() public.
Changes in v6:
- Remove the patches for "vdpa: solidrun" since the maintainer seems unwilling to review and discuss, not to mention approve, anything that is part of a wider patch series across other subsystems.
- Change series's name to highlight that not all callers are removed by it.
Changes in v5:
- Patch "ethernet: cavium": Re-add accidentally removed
pcim_iounmap_region(). (Me)
- Add Jens's Reviewed-by to patch "block: mtip32xx". (Jens)
Changes in v4:
- Drop the "ethernet: stmicro: [...] patch since it doesn't apply to net-next, and making it apply to that prevents it from being applyable to PCI ._. (Serge, me)
- Instead, deprecate pcim_iounmap_regions() and keep "ethernet:
stimicro" as the last user for now.
- ethernet: cavium: Use PTR_ERR_OR_ZERO(). (Andy)
- vdpa: solidrun (Bugfix) Correct wrong printf string (was "psnet" instead of
"snet"). (Christophe)
- vdpa: solidrun (Bugfix): Add missing blank line. (Andy)
- vdpa: solidrun (Portation): Use PTR_ERR_OR_ZERO(). (Andy)
- Apply Reviewed-by's from Andy and Xu Yilun.
Changes in v3:
- fpga/dfl-pci.c: remove now surplus wrapper around
pcim_iomap_region(). (Andy)
- block: mtip32xx: remove now surplus label. (Andy)
- vdpa: solidrun: Bugfix: Include forgotten place where stack UB occurs. (Andy, Christophe)
- Some minor wording improvements in commit messages. (Me)
Changes in v2:
- Add a fix for the UB stack usage bug in vdap/solidrun. Separate patch, put stable kernel on CC. (Christophe, Andy).
- Drop unnecessary pcim_release_region() in mtip32xx (Andy)
- Consequently, drop patch "PCI: Make pcim_release_region() a public function", since there's no user anymore. (obsoletes the squash requested by Damien).
- vdap/solidrun:
• make 'i' an 'unsigned short' (Andy, me)
• Use 'continue' to simplify loop (Andy)
• Remove leftover blank line
- Apply given Reviewed- / acked-bys (Andy, Damien, Bartosz)
Important things first:
This series is based on [1] and [2] which Bjorn Helgaas has currently queued for v6.12 in the PCI tree.
This series shall remove pcim_iounmap_regions() in order to make way to remove its brother, pcim_iomap_regions().
Regards,
P.
[1] https://lore.kernel.org/all/[email protected]/
[2] https://lore.kernel.org/all/[email protected]/
Philipp Stanner (6):
PCI: Make pcim_iounmap_region() a public function
PCI: Deprecate pcim_iounmap_regions() fpga/dfl-pci.c: Replace deprecated PCI functions
block: mtip32xx: Replace deprecated PCI functions
gpio: Replace deprecated PCI functions
ethernet: cavium: Replace deprecated PCI functions
drivers/block/mtip32xx/mtip32xx.c | 18 ++++++++---------- drivers/fpga/dfl-pci.c | 16 ++++------------ drivers/gpio/gpio-merrifield.c | 15 ++++++++------- .../net/ethernet/cavium/common/cavium_ptp.c | 7 +++---- drivers/pci/devres.c | 8 ++++++-- include/linux/pci.h | 1 + 6 files changed, 30 insertions(+), 35 deletions(-)
Signature · 1 line
2.47.0
PATCH v8 1/6 PCI: Make pcim_iounmap_region() a public function
The function pcim_iounmap_regions() is problematic because it uses a bitmask mechanism to release / iounmap multiple BARs at once. It, thus, prevents getting rid of the problematic iomap table mechanism which was deprecated in commit e354bb84a4c1 ("PCI: Deprecate pcim_iomap_table(), pcim_iomap_regions_request_all()").
pcim_iounmap_region() does not have that problem. Make it public as the successor of pcim_iounmap_regions().
--- drivers/pci/devres.c | 3 ++- include/linux/pci.h | 1 + 2 files changed, 3 insertions(+), 1 deletion(-)
drivers/pci/devres.c +2 -1
@@ -773,7 +773,7 @@ EXPORT_SYMBOL(pcim_iomap_region);* Unmap a BAR and release its region manually. Only pass BARs that were * previously mapped by pcim_iomap_region(). */ -static void pcim_iounmap_region (struct pci_dev *pdev,int bar) +void pcim_iounmap_region (struct pci_dev *pdev,int bar) {struct pcim_addr_devres res_searched;
@@ -784,6 +784,7 @@ static void pcim_iounmap_region(struct pci_dev *pdev, int bar)devres_release (&pdev->dev, pcim_addr_resource_release, pcim_addr_resources_match, &res_searched); } +EXPORT_SYMBOL (pcim_iounmap_region);/** * pcim_iomap_regions - Request and iomap PCI BARs (DEPRECATED)
include/linux/pci.h +1 -0
@@ -2296,6 +2296,7 @@ static inline void pci_fixup_device(enum pci_fixup_pass pass,void __iomem *pcim_iomap (struct pci_dev *pdev,int bar,unsigned long maxlen);void __iomem *pcim_iomap_region (struct pci_dev *pdev,int bar,const char *name); +void pcim_iounmap_region (struct pci_dev *pdev,int bar);void pcim_iounmap (struct pci_dev *pdev,void __iomem *addr);void __iomem *const *pcim_iomap_table (struct pci_dev *pdev);int pcim_request_region (struct pci_dev *pdev,int bar,const char *name);
Signature · 1 line
2.47.0
PATCH v8 2/6 PCI: Deprecate pcim_iounmap_regions()
In reply to Philipp Stannerpcim_ionumap_region() has recently been made a public function and does not have the disadvantage of having to deal with the legacy iomap table, as pcim_iounmap_regions() does.
Deprecate pcim_iounmap_regions().
--- drivers/pci/devres.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/pci/devres.c +4 -1
@@ -1016,11 +1016,14 @@ int pcim_iomap_regions_request_all(struct pci_dev *pdev, int mask,EXPORT_SYMBOL (pcim_iomap_regions_request_all);/** -* pcim_iounmap_regions - Unmap and release PCI BARs +* pcim_iounmap_regions - Unmap and release PCI BARs (DEPRECATED) * @pdev: PCI device to map IO resources for * @mask: Mask of BARs to unmap and release * * Unmap and release regions specified by @mask. +* +* This function is DEPRECATED. Do not use it in new code. +* Use pcim_iounmap_region() instead. */ void pcim_iounmap_regions (struct pci_dev *pdev,int mask) {
Signature · 1 line
2.47.0
Andy Shevchenko
maintainerRe: [PATCH v8 2/6] PCI: Deprecate pcim_iounmap_regions()
Quoted 5 lines · Philipp Stanner
pcim_ionumap_region()has recently been made a public function and does not have the disadvantage of having to deal with the legacy iomap table, aspcim_iounmap_regions()does.Deprecate
pcim_iounmap_regions().
...
Quoted 1 line
+ * This function is DEPRECATED. Do not use it in new code.
Interestingly that the syntax of the DEPRECATED is not documented (yet?), however the sphinx parser hints us about **DEPRECATED** format — see Documentation/sphinx/parse-headers.pl:251. In any case the above seems like second used (in a form of the full sentence) and will be updated in accordance with the above mentioned script.
Signature · 2 lines
With Best Regards, Andy Shevchenko
Re: [PATCH v8 2/6] PCI: Deprecate pcim_iounmap_regions()
Quoted 13 lines · Andy Shevchenko
Quoted 7 lines · Philipp Stanner
pcim_ionumap_region()has recently been made a public function and does
not have the disadvantage of having to deal with the legacy iomap table,
aspcim_iounmap_regions()does.Deprecate
pcim_iounmap_regions()....
Quoted 1 line
+ * This function is DEPRECATED. Do not use it in new code.
Quoted 7 lines
Interestingly that the syntax of the DEPRECATED is not documented (yet?),
however the sphinx parser hints us about **DEPRECATED** format — seeDocumentation/sphinx/parse-headers.pl:251. In any case the above seems
like second used (in a form of the full sentence) and will be updated in accordance with the above mentioned script.
Can't completely follow – so one should always write "**DEPRECATED**", correct?
Is that a blocker for you?
All the docstrings in pci/pci.c and pci/devres.c so far just use "DEPRECATED".
P.
Andy Shevchenko
maintainerRe: [PATCH v8 2/6] PCI: Deprecate pcim_iounmap_regions()
Quoted 2 lines · Philipp Stanner
Quoted 1 line · Andy Shevchenko
On Wed, Oct 16, 2024 at 11:49:05AM +0200, Philipp Stanner wrote:
...
Quoted 10 lines
Quoted 9 lines
Quoted 1 line
+ * This function is DEPRECATED. Do not use it in new code.
Interestingly that the syntax of the DEPRECATED is not documented (yet?),
however the sphinx parser hints us about **DEPRECATED** format — seeDocumentation/sphinx/parse-headers.pl:251. In any case the above seems
like second used (in a form of the full sentence) and will be updated in accordance with the above mentioned script.
Quoted 2 lines
Can't completely follow – so one should always write "**DEPRECATED**", correct?
I can't answer to this, because there may be "rendered" form and in this case it should not be surrounded by double asterisks, otherwise it's better to have at the start.
Quoted 1 line
Is that a blocker for you?
Nope, I mentioned this in the last sentence in my previous reply.
Quoted 2 lines
All the docstrings in
pci/pci.candpci/devres.cso far just use "DEPRECATED".
Yeah, this, if ever needed, has to be changed at once.
Signature · 2 lines
With Best Regards, Andy Shevchenko
PATCH v8 3/6 fpga/dfl-pci.c: Replace deprecated PCI functions
In reply to Philipp Stannerpcim_iomap_regions() and pcim_iomap_table() have been deprecated by the PCI subsystem in commit e354bb84a4c1 ("PCI: Deprecate pcim_iomap_table(), pcim_iomap_regions_request_all()").
Port dfl-pci.c to the successor, pcim_iomap_region().
Consistently, replace pcim_iounmap_regions() with pcim_iounmap_region().
--- drivers/fpga/dfl-pci.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-)
drivers/fpga/dfl-pci.c +4 -12
@@ -39,14 +39,6 @@ struct cci_drvdata {struct dfl_fpga_cdev *cdev;/* container device */ }; -static void __iomem *cci_pci_ioremap_bar0 (struct pci_dev *pcidev) -{ -if (pcim_iomap_regions (pcidev,BIT (0 ),DRV_NAME )) -return NULL ; - -return pcim_iomap_table (pcidev)[0 ]; -} -static int cci_pci_alloc_irq (struct pci_dev *pcidev) {int ret, nvec =pci_msix_vec_count (pcidev);
@@ -235,9 +227,9 @@ static int find_dfls_by_default(struct pci_dev *pcidev,u64 v;/* start to find Device Feature List from Bar 0 */ - base =cci_pci_ioremap_bar0 (pcidev); -if (!base) -return -ENOMEM ; + base =pcim_iomap_region (pcidev,0 ,DRV_NAME ); +if (IS_ERR (base)) +return PTR_ERR (base);/* * PF device has FME and Ports/AFUs, and VF device only has one
@@ -296,7 +288,7 @@ static int find_dfls_by_default(struct pci_dev *pcidev, }/* release I/O mappings for next step enumeration */ -pcim_iounmap_regions (pcidev,BIT (0 )); +pcim_iounmap_region (pcidev,0 );return ret; }
Signature · 1 line
2.47.0
PATCH v8 4/6 block: mtip32xx: Replace deprecated PCI functions
In reply to Philipp Stannerpcim_iomap_regions() and pcim_iomap_table() have been deprecated by the PCI subsystem in commit e354bb84a4c1 ("PCI: Deprecate pcim_iomap_table(), pcim_iomap_regions_request_all()").
In mtip32xx, these functions can easily be replaced by their respective successors, pcim_request_region() and pcim_iomap(). Moreover, the driver's calls to pcim_iounmap_regions() in probe()'s error path and in remove() are not necessary. Cleanup can be performed by PCI devres automatically.
Replace pcim_iomap_regions() and pcim_iomap_table().
Remove the calls to pcim_iounmap_regions().
--- drivers/block/mtip32xx/mtip32xx.c | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-)
drivers/block/mtip32xx/mtip32xx.c +8 -10
@@ -2701,7 +2701,9 @@ static int mtip_hw_init(struct driver_data *dd)int rv;unsigned long timeout, timetaken; - dd->mmio =pcim_iomap_table (dd->pdev)[MTIP_ABAR ]; + dd->mmio =pcim_iomap (dd->pdev,MTIP_ABAR ,0 ); +if (!dd->mmio) +return -ENOMEM ;mtip_detect_product (dd);if (dd->product_type ==MTIP_PRODUCT_UNKNOWN ) {
@@ -3707,14 +3709,14 @@ static int mtip_pci_probe(struct pci_dev *pdev, rv =pcim_enable_device (pdev);if (rv <0 ) {dev_err (&pdev->dev,"Unable to enable device\n" ); - goto iomap_err; + goto setmask_err; } -/* Map BAR5 to memory. */ - rv =pcim_iomap_regions (pdev,1 <<MTIP_ABAR ,MTIP_DRV_NAME ); +/* Request BAR5. */ + rv =pcim_request_region (pdev,MTIP_ABAR ,MTIP_DRV_NAME );if (rv <0 ) { -dev_err (&pdev->dev,"Unable to map regions\n" ); - goto iomap_err; +dev_err (&pdev->dev,"Unable to request regions\n" ); + goto setmask_err; } rv =dma_set_mask_and_coherent (&pdev->dev,DMA_BIT_MASK (64 ));
@@ -3834,9 +3836,6 @@ static int mtip_pci_probe(struct pci_dev *pdev,drop_cpu (dd->work[2 ].cpu_binding); } setmask_err: -pcim_iounmap_regions (pdev,1 <<MTIP_ABAR ); - -iomap_err:kfree (dd);pci_set_drvdata (pdev,NULL );return rv;
@@ -3910,7 +3909,6 @@ static void mtip_pci_remove(struct pci_dev *pdev)pci_disable_msi (pdev); -pcim_iounmap_regions (pdev,1 <<MTIP_ABAR );pci_set_drvdata (pdev,NULL );put_disk (dd->disk);
Signature · 1 line
2.47.0
PATCH v8 5/6 gpio: Replace deprecated PCI functions
In reply to Philipp Stannerpcim_iomap_regions() and pcim_iomap_table() have been deprecated by the PCI subsystem in commit e354bb84a4c1 ("PCI: Deprecate pcim_iomap_table(), pcim_iomap_regions_request_all()").
Replace those functions with calls to pcim_iomap_region().
--- drivers/gpio/gpio-merrifield.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-)
drivers/gpio/gpio-merrifield.c +8 -7
@@ -78,24 +78,25 @@ static int mrfld_gpio_probe(struct pci_dev *pdev, const struct pci_device_id *idif (retval)return retval; - retval =pcim_iomap_regions (pdev,BIT (1 ) |BIT (0 ),pci_name (pdev)); -if (retval) -return dev_err_probe (dev, retval,"I/O memory mapping error\n" ); - - base =pcim_iomap_table (pdev)[1 ]; + base =pcim_iomap_region (pdev,1 ,pci_name (pdev)); +if (IS_ERR (base)) +return dev_err_probe (dev,PTR_ERR (base),"I/O memory mapping error\n" ); irq_base =readl (base +0 *sizeof (u32)); gpio_base =readl (base +1 *sizeof (u32));/* Release the IO mapping, since we already get the info from BAR1 */ -pcim_iounmap_regions (pdev,BIT (1 )); +pcim_iounmap_region (pdev,1 ); priv =devm_kzalloc (dev,sizeof (*priv),GFP_KERNEL );if (!priv)return -ENOMEM ; priv->dev = dev; - priv->reg_base =pcim_iomap_table (pdev)[0 ]; + priv->reg_base =pcim_iomap_region (pdev,0 ,pci_name (pdev)); +if (IS_ERR (priv->reg_base)) +return dev_err_probe (dev,PTR_ERR (priv->reg_base), +"I/O memory mapping error\n" ); priv->pin_info.pin_ranges = mrfld_gpio_ranges; priv->pin_info.nranges =ARRAY_SIZE (mrfld_gpio_ranges);
Signature · 1 line
2.47.0
PATCH v8 6/6 ethernet: cavium: Replace deprecated PCI functions
In reply to Philipp Stannerpcim_iomap_regions() and pcim_iomap_table() have been deprecated by the PCI subsystem in commit e354bb84a4c1 ("PCI: Deprecate pcim_iomap_table(), pcim_iomap_regions_request_all()").
Replace the deprecated PCI functions with their successors.
--- drivers/net/ethernet/cavium/common/cavium_ptp.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/net/ethernet/cavium/common/cavium_ptp.c +3 -4
@@ -239,12 +239,11 @@ static int cavium_ptp_probe(struct pci_dev *pdev,if (err) goto error_free; - err =pcim_iomap_regions (pdev,1 <<PCI_PTP_BAR_NO ,pci_name (pdev)); + clock->reg_base =pcim_iomap_region (pdev,PCI_PTP_BAR_NO ,pci_name (pdev)); + err =PTR_ERR_OR_ZERO (clock->reg_base);if (err) goto error_free; - clock->reg_base =pcim_iomap_table (pdev)[PCI_PTP_BAR_NO ]; -spin_lock_init (&clock->spin_lock); cc = &clock->cycle_counter;
@@ -292,7 +291,7 @@ static int cavium_ptp_probe(struct pci_dev *pdev, clock_cfg =readq (clock->reg_base +PTP_CLOCK_CFG ); clock_cfg &= ~PTP_CLOCK_CFG_PTP_EN ;writeq (clock_cfg, clock->reg_base +PTP_CLOCK_CFG ); -pcim_iounmap_regions (pdev,1 <<PCI_PTP_BAR_NO ); +pcim_iounmap_region (pdev,PCI_PTP_BAR_NO ); error_free:devm_kfree (dev, clock);
Signature · 1 line
2.47.0
@Bjorn:
Are you OK with taking this?
Regards,
P.
Quoted 108 lines · Philipp Stanner
Merge plan for this is the PCI-Tree.
After this series, only two users (
net/ethernet/stmicroand vdpa/solidrun) will remain to be ported in the subsequent merge window.
Doing them right now proved very difficult because of various conflicts
as they are currently also being reworked.Changes in v8:
- Patch "gpio: ..": Fix a bug: don't print the wrong error code. (Simon)
- Split patch 1 into two patches to make adding of the new public API
obvious (Bartosz)
- Patch "ethernet: cavium: ...": Remove outdated sentences from the commit message.Changes in v7:
- Add Paolo's Acked-by.
- Rebase on current master; drop patch No.1 which madepcim_request_region()public.Changes in v6:
- Remove the patches for "vdpa: solidrun" since the maintainer seems
unwilling to review and discuss, not to mention approve, anything that is part of a wider patch series across other subsystems.
- Change series's name to highlight that not all callers are removed
by it.Changes in v5:
- Patch "ethernet: cavium": Re-add accidentally removedpcim_iounmap_region(). (Me)
- Add Jens's Reviewed-by to patch "block: mtip32xx". (Jens)Changes in v4:
- Drop the "ethernet: stmicro: [...] patch since it doesn't apply to
net-next, and making it apply to that prevents it from being applyable to PCI ._. (Serge, me)
- Instead, deprecatepcim_iounmap_regions()and keep "ethernet:
stimicro" as the last user for now.
- ethernet: cavium: UsePTR_ERR_OR_ZERO(). (Andy)
- vdpa: solidrun (Bugfix) Correct wrong printf string (was "psnet" instead of
"snet"). (Christophe)
- vdpa: solidrun (Bugfix): Add missing blank line. (Andy)
- vdpa: solidrun (Portation): UsePTR_ERR_OR_ZERO(). (Andy)
- Apply Reviewed-by's from Andy and Xu Yilun.Changes in v3:
-fpga/dfl-pci.c: remove now surplus wrapper aroundpcim_iomap_region(). (Andy)
- block: mtip32xx: remove now surplus label. (Andy)
- vdpa: solidrun: Bugfix: Include forgotten place where stack UB occurs. (Andy, Christophe)
- Some minor wording improvements in commit messages. (Me)Changes in v2:
- Add a fix for the UB stack usage bug in vdap/solidrun. Separate patch, put stable kernel on CC. (Christophe, Andy).
- Drop unnecessarypcim_release_region()in mtip32xx (Andy)
- Consequently, drop patch "PCI: Makepcim_release_region()a public
function", since there's no user anymore. (obsoletes the squash requested by Damien).
- vdap/solidrun:
• make 'i' an 'unsigned short' (Andy, me)
• Use 'continue' to simplify loop (Andy)
• Remove leftover blank line
- Apply given Reviewed- / acked-bys (Andy, Damien, Bartosz)Important things first:
This series is based on [1] and [2] which Bjorn Helgaas has currently queued for v6.12 in the PCI tree.This series shall remove
pcim_iounmap_regions()in order to make way to
remove its brother,pcim_iomap_regions().Regards,
P.[1]
https://lore.kernel.org/all/[email protected]/
[2]
https://lore.kernel.org/all/[email protected]/Philipp Stanner (6):
PCI: Makepcim_iounmap_region()a public function
PCI: Deprecatepcim_iounmap_regions()fpga/dfl-pci.c: Replace deprecated PCI functions
block: mtip32xx: Replace deprecated PCI functions
gpio: Replace deprecated PCI functions
ethernet: cavium: Replace deprecated PCI functionsdrivers/block/mtip32xx/mtip32xx.c | 18 ++++++++-------- --
drivers/fpga/dfl-pci.c | 16 ++++------------ drivers/gpio/gpio-merrifield.c | 15 ++++++++------- .../net/ethernet/cavium/common/cavium_ptp.c | 7 +++---- drivers/pci/devres.c | 8 ++++++-- include/linux/pci.h | 1 +6 files changed, 30 insertions(+), 35 deletions(-)
Bjorn Helgaas
AppliedQuoted 87 lines · Philipp Stanner
Merge plan for this is the PCI-Tree.
After this series, only two users (
net/ethernet/stmicroand vdpa/solidrun) will remain to be ported in the subsequent merge window. Doing them right now proved very difficult because of various conflicts as they are currently also being reworked.Changes in v8:
- Patch "gpio: ..": Fix a bug: don't print the wrong error code. (Simon)
- Split patch 1 into two patches to make adding of the new public API obvious (Bartosz)
- Patch "ethernet: cavium: ...": Remove outdated sentences from the commit message.Changes in v7:
- Add Paolo's Acked-by.
- Rebase on current master; drop patch No.1 which madepcim_request_region()public.Changes in v6:
- Remove the patches for "vdpa: solidrun" since the maintainer seems unwilling to review and discuss, not to mention approve, anything that is part of a wider patch series across other subsystems.
- Change series's name to highlight that not all callers are removed by it.Changes in v5:
- Patch "ethernet: cavium": Re-add accidentally removedpcim_iounmap_region(). (Me)- Add Jens's Reviewed-by to patch "block: mtip32xx". (Jens)
Changes in v4:
- Drop the "ethernet: stmicro: [...] patch since it doesn't apply to net-next, and making it apply to that prevents it from being applyable to PCI ._. (Serge, me)
- Instead, deprecatepcim_iounmap_regions()and keep "ethernet:
stimicro" as the last user for now.
- ethernet: cavium: UsePTR_ERR_OR_ZERO(). (Andy)
- vdpa: solidrun (Bugfix) Correct wrong printf string (was "psnet" instead of"snet"). (Christophe)- vdpa: solidrun (Bugfix): Add missing blank line. (Andy)
- vdpa: solidrun (Portation): UsePTR_ERR_OR_ZERO(). (Andy)
- Apply Reviewed-by's from Andy and Xu Yilun.Changes in v3:
-fpga/dfl-pci.c: remove now surplus wrapper aroundpcim_iomap_region(). (Andy)- block: mtip32xx: remove now surplus label. (Andy)
- vdpa: solidrun: Bugfix: Include forgotten place where stack UB occurs. (Andy, Christophe)
- Some minor wording improvements in commit messages. (Me)Changes in v2:
- Add a fix for the UB stack usage bug in vdap/solidrun. Separate patch, put stable kernel on CC. (Christophe, Andy).
- Drop unnecessarypcim_release_region()in mtip32xx (Andy)
- Consequently, drop patch "PCI: Makepcim_release_region()a public function", since there's no user anymore. (obsoletes the squash requested by Damien).
- vdap/solidrun:
• make 'i' an 'unsigned short' (Andy, me)
• Use 'continue' to simplify loop (Andy)
• Remove leftover blank line
- Apply given Reviewed- / acked-bys (Andy, Damien, Bartosz)Important things first:
This series is based on [1] and [2] which Bjorn Helgaas has currently queued for v6.12 in the PCI tree.This series shall remove
pcim_iounmap_regions()in order to make way to remove its brother,pcim_iomap_regions().Regards,
P.[1] https://lore.kernel.org/all/[email protected]/
[2] https://lore.kernel.org/all/[email protected]/Philipp Stanner (6):
PCI: Makepcim_iounmap_region()a public function
PCI: Deprecatepcim_iounmap_regions()fpga/dfl-pci.c: Replace deprecated PCI functions
block: mtip32xx: Replace deprecated PCI functions
gpio: Replace deprecated PCI functions
ethernet: cavium: Replace deprecated PCI functions
Quoted 7 lines
drivers/block/mtip32xx/mtip32xx.c | 18 ++++++++---------- drivers/fpga/dfl-pci.c | 16 ++++------------ drivers/gpio/gpio-merrifield.c | 15 ++++++++------- .../net/ethernet/cavium/common/cavium_ptp.c | 7 +++---- drivers/pci/devres.c | 8 ++++++-- include/linux/pci.h | 1 + 6 files changed, 30 insertions(+), 35 deletions(-)
Applied to pci/devm for v6.13, thanks!