[0/3] PCI/portdrv: Squash into portdrv.c

Message ID 20221019204127.44463-1-helgaas@kernel.org
Headers
Series PCI/portdrv: Squash into portdrv.c |

Message

Bjorn Helgaas Oct. 19, 2022, 8:41 p.m. UTC
  From: Bjorn Helgaas <bhelgaas@google.com>

The PCIe portdrv is split across portdrv_core.c and portdrv_pci.c, but
neither is very big and it's a hassle to figure out which to look at.

Squash them into a single portdrv.c file.  Make functions static and
non-exported when possible, and move some private things out of portdrv.h.

Please comment.

Bjorn Helgaas (3):
  PCI/portdrv: Squash into portdrv.c
  PCI/portdrv: Move private things to portdrv.c
  PCI/portdrv: Unexport pcie_port_service_register(),
    pcie_port_service_unregister()

 drivers/pci/pcie/Makefile                     |   2 +-
 .../pci/pcie/{portdrv_core.c => portdrv.c}    | 263 +++++++++++++++++-
 drivers/pci/pcie/portdrv.h                    |  19 --
 drivers/pci/pcie/portdrv_pci.c                | 252 -----------------
 4 files changed, 253 insertions(+), 283 deletions(-)
 rename drivers/pci/pcie/{portdrv_core.c => portdrv.c} (69%)
 delete mode 100644 drivers/pci/pcie/portdrv_pci.c
  

Comments

Keith Busch Oct. 19, 2022, 8:44 p.m. UTC | #1
On Wed, Oct 19, 2022 at 03:41:24PM -0500, Bjorn Helgaas wrote:
> From: Bjorn Helgaas <bhelgaas@google.com>
> 
> The PCIe portdrv is split across portdrv_core.c and portdrv_pci.c, but
> neither is very big and it's a hassle to figure out which to look at.
> 
> Squash them into a single portdrv.c file.  Make functions static and
> non-exported when possible, and move some private things out of portdrv.h.

Looks like a nice cleanup.

Reviewed-by: Keith Busch <kbusch@kernel.org>
  
Bjorn Helgaas Oct. 24, 2022, 8:15 p.m. UTC | #2
On Wed, Oct 19, 2022 at 03:41:24PM -0500, Bjorn Helgaas wrote:
> From: Bjorn Helgaas <bhelgaas@google.com>
> 
> The PCIe portdrv is split across portdrv_core.c and portdrv_pci.c, but
> neither is very big and it's a hassle to figure out which to look at.
> 
> Squash them into a single portdrv.c file.  Make functions static and
> non-exported when possible, and move some private things out of portdrv.h.
> 
> Please comment.
> 
> Bjorn Helgaas (3):
>   PCI/portdrv: Squash into portdrv.c
>   PCI/portdrv: Move private things to portdrv.c
>   PCI/portdrv: Unexport pcie_port_service_register(),
>     pcie_port_service_unregister()
> 
>  drivers/pci/pcie/Makefile                     |   2 +-
>  .../pci/pcie/{portdrv_core.c => portdrv.c}    | 263 +++++++++++++++++-
>  drivers/pci/pcie/portdrv.h                    |  19 --
>  drivers/pci/pcie/portdrv_pci.c                | 252 -----------------
>  4 files changed, 253 insertions(+), 283 deletions(-)
>  rename drivers/pci/pcie/{portdrv_core.c => portdrv.c} (69%)
>  delete mode 100644 drivers/pci/pcie/portdrv_pci.c

I applied these to pci/portdrv for v6.2 with Reviewed-Bys from
Christoph and Keith.  Thanks for taking a look!

Bjorn