2024-04-03 14:18:23

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH v2 0/7] mmc/wifi/bluetooth: store owner from modules with sdio_register_driver()

Changes in v2:
1. Add "wifi: ath10k: sdio: simplify module initialization" patch, from
my other patchset to avoid conflicts.
2. Add Acks/Rb tags.
3. Drop applied SDIO patch, which was the dependency for the rest
cleanups.
4. Update subjects according to feedback.
- Link to v1: https://lore.kernel.org/r/[email protected]

Merging
=======
With Acks from Kalle, please take entire set via mmc/sdio.

Description
===========
Modules registering driver with sdio_register_driver() might
forget to set .owner field.

Solve the problem by moving this task away from the drivers to the core
code, just like we did for platform_driver in commit 9447057eaff8
("platform_device: use a macro instead of platform_driver_register").

Best regards,
Krzysztof

---
Krzysztof Kozlowski (7):
Bluetooth: btmrvl_sdio: drop driver owner initialization
Bluetooth: btmtksdio: drop driver owner initialization
wifi: ath10k: sdio: simplify module initialization
wifi: ath10k: sdio: drop driver owner initialization
wifi: brcm80211: drop driver owner initialization
wifi: mwifiex: drop driver owner initialization
wifi: wfx: drop driver owner initialization

drivers/bluetooth/btmrvl_sdio.c | 1 -
drivers/bluetooth/btmtksdio.c | 1 -
drivers/net/wireless/ath/ath10k/sdio.c | 21 +--------------------
.../wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c | 1 -
drivers/net/wireless/marvell/mwifiex/sdio.c | 1 -
drivers/net/wireless/silabs/wfx/bus_sdio.c | 1 -
6 files changed, 1 insertion(+), 25 deletions(-)
---
base-commit: 7d860d3177a745017d38b37bc2bff2f090631148
change-id: 20240329-module-owner-sdio-abd5de3f1d74

Best regards,
--
Krzysztof Kozlowski <[email protected]>



2024-04-03 14:18:23

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH v2 1/7] Bluetooth: btmrvl_sdio: drop driver owner initialization

Core in sdio_register_driver() already sets the .owner, so driver does
not need to.

Signed-off-by: Krzysztof Kozlowski <[email protected]>

---

Depends on the patch in mmc tree.
---
drivers/bluetooth/btmrvl_sdio.c | 1 -
1 file changed, 1 deletion(-)

diff --git a/drivers/bluetooth/btmrvl_sdio.c b/drivers/bluetooth/btmrvl_sdio.c
index d76c799553aa..85b7f2bb4259 100644
--- a/drivers/bluetooth/btmrvl_sdio.c
+++ b/drivers/bluetooth/btmrvl_sdio.c
@@ -1736,7 +1736,6 @@ static struct sdio_driver bt_mrvl_sdio = {
.probe = btmrvl_sdio_probe,
.remove = btmrvl_sdio_remove,
.drv = {
- .owner = THIS_MODULE,
.coredump = btmrvl_sdio_coredump,
.pm = &btmrvl_sdio_pm_ops,
}

--
2.34.1


2024-04-03 14:18:41

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH v2 2/7] Bluetooth: btmtksdio: drop driver owner initialization

Core in sdio_register_driver() already sets the .owner, so driver does
not need to.

Signed-off-by: Krzysztof Kozlowski <[email protected]>

---

Depends on the patch in mmc tree.
---
drivers/bluetooth/btmtksdio.c | 1 -
1 file changed, 1 deletion(-)

diff --git a/drivers/bluetooth/btmtksdio.c b/drivers/bluetooth/btmtksdio.c
index ff4868c83cd8..8ded9ef8089a 100644
--- a/drivers/bluetooth/btmtksdio.c
+++ b/drivers/bluetooth/btmtksdio.c
@@ -1519,7 +1519,6 @@ static struct sdio_driver btmtksdio_driver = {
.remove = btmtksdio_remove,
.id_table = btmtksdio_table,
.drv = {
- .owner = THIS_MODULE,
.pm = BTMTKSDIO_PM_OPS,
}
};

--
2.34.1


2024-04-03 14:19:20

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH v2 4/7] wifi: ath10k: sdio: drop driver owner initialization

Core in sdio_register_driver() already sets the .owner, so driver does
not need to.

Signed-off-by: Krzysztof Kozlowski <[email protected]>
Acked-by: Jeff Johnson <[email protected]>
---

Depends on the patch in mmc tree.
---
drivers/net/wireless/ath/ath10k/sdio.c | 1 -
1 file changed, 1 deletion(-)

diff --git a/drivers/net/wireless/ath/ath10k/sdio.c b/drivers/net/wireless/ath/ath10k/sdio.c
index 1acb9fba9a8e..cddd9e3010ee 100644
--- a/drivers/net/wireless/ath/ath10k/sdio.c
+++ b/drivers/net/wireless/ath/ath10k/sdio.c
@@ -2667,7 +2667,6 @@ static struct sdio_driver ath10k_sdio_driver = {
.probe = ath10k_sdio_probe,
.remove = ath10k_sdio_remove,
.drv = {
- .owner = THIS_MODULE,
.pm = ATH10K_SDIO_PM_OPS,
},
};

--
2.34.1


2024-04-03 14:20:48

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH v2 6/7] wifi: mwifiex: drop driver owner initialization

Core in sdio_register_driver() already sets the .owner, so driver does
not need to.

Signed-off-by: Krzysztof Kozlowski <[email protected]>
Acked-by: Kalle Valo <[email protected]>
Reviewed-by: Francesco Dolcini <[email protected]>
---

Depends on the patch in mmc tree.
---
drivers/net/wireless/marvell/mwifiex/sdio.c | 1 -
1 file changed, 1 deletion(-)

diff --git a/drivers/net/wireless/marvell/mwifiex/sdio.c b/drivers/net/wireless/marvell/mwifiex/sdio.c
index f41048b5cd3c..bda9b2b8a1f3 100644
--- a/drivers/net/wireless/marvell/mwifiex/sdio.c
+++ b/drivers/net/wireless/marvell/mwifiex/sdio.c
@@ -979,7 +979,6 @@ static struct sdio_driver mwifiex_sdio = {
.probe = mwifiex_sdio_probe,
.remove = mwifiex_sdio_remove,
.drv = {
- .owner = THIS_MODULE,
.coredump = mwifiex_sdio_coredump,
.pm = &mwifiex_sdio_pm_ops,
}

--
2.34.1


2024-04-03 14:56:55

by bluez.test.bot

[permalink] [raw]
Subject: RE: mmc/wifi/bluetooth: store owner from modules with sdio_register_driver()

This is automated email and please do not reply to this email!

Dear submitter,

Thank you for submitting the patches to the linux bluetooth mailing list.
This is a CI test results with your patch series:
PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=841110

---Test result---

Test Summary:
CheckPatch PASS 3.07 seconds
GitLint PASS 1.40 seconds
SubjectPrefix FAIL 0.69 seconds
BuildKernel PASS 29.73 seconds
CheckAllWarning PASS 32.46 seconds
CheckSparse PASS 38.12 seconds
CheckSmatch FAIL 34.81 seconds
BuildKernel32 PASS 29.06 seconds
TestRunnerSetup PASS 518.13 seconds
TestRunner_l2cap-tester PASS 21.01 seconds
TestRunner_iso-tester PASS 29.85 seconds
TestRunner_bnep-tester PASS 4.62 seconds
TestRunner_mgmt-tester PASS 110.07 seconds
TestRunner_rfcomm-tester PASS 7.10 seconds
TestRunner_sco-tester PASS 14.66 seconds
TestRunner_ioctl-tester PASS 7.49 seconds
TestRunner_mesh-tester PASS 5.64 seconds
TestRunner_smp-tester PASS 6.63 seconds
TestRunner_userchan-tester PASS 4.80 seconds
IncrementalBuild PASS 57.83 seconds

Details
##############################
Test: SubjectPrefix - FAIL
Desc: Check subject contains "Bluetooth" prefix
Output:
"Bluetooth: " prefix is not specified in the subject
"Bluetooth: " prefix is not specified in the subject
"Bluetooth: " prefix is not specified in the subject
"Bluetooth: " prefix is not specified in the subject
"Bluetooth: " prefix is not specified in the subject
##############################
Test: CheckSmatch - FAIL
Desc: Run smatch tool with source
Output:

Segmentation fault (core dumped)
make[4]: *** [scripts/Makefile.build:244: net/bluetooth/hci_core.o] Error 139
make[4]: *** Deleting file 'net/bluetooth/hci_core.o'
make[3]: *** [scripts/Makefile.build:485: net/bluetooth] Error 2
make[2]: *** [scripts/Makefile.build:485: net] Error 2
make[2]: *** Waiting for unfinished jobs....
Segmentation fault (core dumped)
make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/bcm203x.o] Error 139
make[4]: *** Deleting file 'drivers/bluetooth/bcm203x.o'
make[4]: *** Waiting for unfinished jobs....
make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2
make[2]: *** [scripts/Makefile.build:485: drivers] Error 2
make[1]: *** [/github/workspace/src/src/Makefile:1919: .] Error 2
make: *** [Makefile:240: __sub-make] Error 2


---
Regards,
Linux Bluetooth