Skip to content

Commit c21b53d

Browse files
larsclausenkwilczynski
authored andcommitted
PCI: endpoint: pci-epf-vntb: Make struct pci_epf_ops const
The pci_epf_ops struct for the PCI endpoint vNTB driver is never modified. Mark it as const so it can be placed in the read-only section. [kwilczynski: commit log] Link: https://lore.kernel.org/linux-pci/20230722230848.589428-4-lars@metafoo.de Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Krzysztof Wilczyński <kwilczynski@kernel.org> Reviewed-by: Manivannan Sadhasivam <mani@kernel.org>
1 parent 54f22c9 commit c21b53d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/pci/endpoint/functions/pci-epf-vntb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1387,7 +1387,7 @@ static void epf_ntb_unbind(struct pci_epf *epf)
13871387
}
13881388

13891389
// EPF driver probe
1390-
static struct pci_epf_ops epf_ntb_ops = {
1390+
static const struct pci_epf_ops epf_ntb_ops = {
13911391
.bind = epf_ntb_bind,
13921392
.unbind = epf_ntb_unbind,
13931393
.add_cfs = epf_ntb_add_cfs,

0 commit comments

Comments
 (0)