MR: https://gitlab.com/redhat/centos-stream/src/kernel/centos-stream-9/-/merge_requests/4682
Upstream Status: RHEL Only
JIRA: https://issues.redhat.com/browse/RHEL-47218
When upstream commit fc7a6209d571 ("bus: Make remove callback return
void") was backported into CS9 via commit a5384e8ee5 ("bus: Make
remove callback return void"), the 'return 0' was not included for
this driver. This is causing the following compiler error now that
this driver is enabled:
drivers/pci/endpoint/pci-epf-core.c: In function ‘pci_epf_device_remove’:
drivers/pci/endpoint/pci-epf-core.c:509:16: error: ‘return’ with a value, in function returning void [-Werror=return-type]
509 | return 0;
| ^
drivers/pci/endpoint/pci-epf-core.c:500:13: note: declared here
500 | static void pci_epf_device_remove(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~~~
Let's fix this by adding the 'return 0' that was missing from that
backport.
Fixes: a5384e8ee5 ("bus: Make remove callback return void")
Signed-off-by: Brian Masney <bmasney@redhat.com>
(cherry picked from commit 349ae41a2a)
Signed-off-by: Radu Rendec <rrendec@redhat.com>
Approved-by: John W. Linville <linville@redhat.com>
Approved-by: Myron Stowe <mstowe@redhat.com>
Approved-by: Brian Masney <bmasney@redhat.com>
Approved-by: Eric Chanudet <echanude@redhat.com>
Approved-by: CKI KWF Bot <cki-ci-bot+kwf-gitlab-com@redhat.com>
Merged-by: Lucas Zampieri <lzampier@redhat.com>