* [PATCH 2/2] PCI: endpoint: Set .owner = THIS_MODULE in remaining pci_epc_ops
[not found] <20261203171642.440891-1-irogers@google.com>
@ 2026-12-03 17:16 ` Ian Rogers
0 siblings, 0 replies; only message in thread
From: Ian Rogers @ 2026-12-03 17:16 UTC (permalink / raw)
To: Manivannan Sadhasivam, Lorenzo Pieralisi,
Krzysztof Wilczyński, Bjorn Helgaas
Cc: Rob Herring, Nathan Chancellor, linux-pci, llvm, linux-kernel,
Ian Rogers, Jingoo Han, Marek Vasut, Yoshihiro Shimoda,
Geert Uytterhoeven, Magnus Damm, Shawn Lin, Heiko Stuebner,
linux-renesas-soc, linux-rockchip, linux-arm-kernel
pcie-designware-ep, pcie-rcar-ep, and pcie-rockchip-ep are currently
bool Kconfig options (where THIS_MODULE is NULL), so omitting .owner in
their struct pci_epc_ops definitions does not affect runtime module
reference counting today.
Initialize .owner = THIS_MODULE in all three for consistency across all
struct pci_epc_ops definitions and to prepare for annotating
pci_epc_ops::owner with Clang's require_explicit_initialization
attribute.
Signed-off-by: Ian Rogers <irogers@google.com>
---
drivers/pci/controller/dwc/pcie-designware-ep.c | 2 ++
drivers/pci/controller/pcie-rcar-ep.c | 2 ++
drivers/pci/controller/pcie-rockchip-ep.c | 2 ++
3 files changed, 6 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-designware-ep.c b/drivers/pci/controller/dwc/pcie-designware-ep.c
index e6060bb0bbbd..d5223597b5c9 100644
--- a/drivers/pci/controller/dwc/pcie-designware-ep.c
+++ b/drivers/pci/controller/dwc/pcie-designware-ep.c
@@ -8,6 +8,7 @@
#include <linux/align.h>
#include <linux/bitfield.h>
+#include <linux/module.h>
#include <linux/of.h>
#include <linux/overflow.h>
#include <linux/platform_device.h>
@@ -949,6 +950,7 @@ static const struct pci_epc_ops epc_ops = {
.get_features = dw_pcie_ep_get_features,
.get_aux_resources_count = dw_pcie_ep_get_aux_resources_count,
.get_aux_resources = dw_pcie_ep_get_aux_resources,
+ .owner = THIS_MODULE,
};
/**
diff --git a/drivers/pci/controller/pcie-rcar-ep.c b/drivers/pci/controller/pcie-rcar-ep.c
index e33c66caa1a6..b9df4699178c 100644
--- a/drivers/pci/controller/pcie-rcar-ep.c
+++ b/drivers/pci/controller/pcie-rcar-ep.c
@@ -7,6 +7,7 @@
*/
#include <linux/delay.h>
+#include <linux/module.h>
#include <linux/of_address.h>
#include <linux/of_platform.h>
#include <linux/pci.h>
@@ -463,6 +464,7 @@ static const struct pci_epc_ops rcar_pcie_epc_ops = {
.start = rcar_pcie_ep_start,
.stop = rcar_pcie_ep_stop,
.get_features = rcar_pcie_ep_get_features,
+ .owner = THIS_MODULE,
};
static const struct of_device_id rcar_pcie_ep_of_match[] = {
diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c
index a20536d50c9c..4a6c9dfeab83 100644
--- a/drivers/pci/controller/pcie-rockchip-ep.c
+++ b/drivers/pci/controller/pcie-rockchip-ep.c
@@ -14,6 +14,7 @@
#include <linux/iopoll.h>
#include <linux/kernel.h>
#include <linux/irq.h>
+#include <linux/module.h>
#include <linux/of.h>
#include <linux/pci-epc.h>
#include <linux/platform_device.h>
@@ -704,6 +705,7 @@ static const struct pci_epc_ops rockchip_pcie_epc_ops = {
.start = rockchip_pcie_ep_start,
.stop = rockchip_pcie_ep_stop,
.get_features = rockchip_pcie_ep_get_features,
+ .owner = THIS_MODULE,
};
static int rockchip_pcie_ep_get_resources(struct rockchip_pcie *rockchip,
--
2.56.1.839.g22a8290db9-goog
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-12-03 17:17 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20261203171642.440891-1-irogers@google.com>
2026-12-03 17:16 ` [PATCH 2/2] PCI: endpoint: Set .owner = THIS_MODULE in remaining pci_epc_ops Ian Rogers
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox