* [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata
@ 2025-03-05 21:43 Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 01/12] clk: samsung: exynos2200: " Krzysztof Kozlowski
` (12 more replies)
0 siblings, 13 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
RFT/RFC because testing needed. I tried to do the same on exynos5-subcmu
and it caused weird oopses which even KASAN did not narrow. Probably
because of multiple exynos5-subcmu devices?
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Best regards,
Krzysztof
---
Krzysztof Kozlowski (12):
clk: samsung: exynos2200: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynos4412-isp: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynos5433: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynos7870: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynos7885: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynos850: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynos8895: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynos990: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynosautov9: Use platform_driver_probe() to avoid __refdata
clk: samsung: exynosautov920: Use platform_driver_probe() to avoid __refdata
clk: samsung: fsd: Use platform_driver_probe() to avoid __refdata
clk: samsung: gs101: Use platform_driver_probe() to avoid __refdata
drivers/clk/samsung/clk-exynos2200.c | 7 +++----
drivers/clk/samsung/clk-exynos4412-isp.c | 7 +++----
drivers/clk/samsung/clk-exynos5433.c | 7 +++----
drivers/clk/samsung/clk-exynos7870.c | 7 +++----
drivers/clk/samsung/clk-exynos7885.c | 7 +++----
drivers/clk/samsung/clk-exynos850.c | 7 +++----
drivers/clk/samsung/clk-exynos8895.c | 7 +++----
drivers/clk/samsung/clk-exynos990.c | 7 +++----
drivers/clk/samsung/clk-exynosautov9.c | 5 ++---
drivers/clk/samsung/clk-exynosautov920.c | 7 +++----
drivers/clk/samsung/clk-fsd.c | 7 +++----
drivers/clk/samsung/clk-gs101.c | 7 +++----
12 files changed, 35 insertions(+), 47 deletions(-)
---
base-commit: 7ec162622e66a4ff886f8f28712ea1b13069e1aa
change-id: 20250305-clk-samsung-ref-init-data-6b2cd242409f
Best regards,
--
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
^ permalink raw reply [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 01/12] clk: samsung: exynos2200: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 02/12] clk: samsung: exynos4412-isp: " Krzysztof Kozlowski
` (11 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
Testing needed.
My initial tests on Exynos5422 lead to weird, unrelated oopses, probably
because of multiple exynos5-subcmu devices. Not sure if applicable here,
but change of initcal might have actual impact.
---
drivers/clk/samsung/clk-exynos2200.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynos2200.c b/drivers/clk/samsung/clk-exynos2200.c
index 151bdb35a46c42d0b50f48d47974065a892bbb5f..f1251d4f01781fd503f24189cc53b23e627ab5e1 100644
--- a/drivers/clk/samsung/clk-exynos2200.c
+++ b/drivers/clk/samsung/clk-exynos2200.c
@@ -3912,17 +3912,16 @@ static const struct of_device_id exynos2200_cmu_of_match[] = {
}, { }
};
-static struct platform_driver exynos2200_cmu_driver __refdata = {
+static struct platform_driver exynos2200_cmu_driver __initdata = {
.driver = {
.name = "exynos2200-cmu",
.of_match_table = exynos2200_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = exynos2200_cmu_probe,
};
static int __init exynos2200_cmu_init(void)
{
- return platform_driver_register(&exynos2200_cmu_driver);
+ return platform_driver_probe(&exynos2200_cmu_driver, exynos2200_cmu_probe);
}
-core_initcall(exynos2200_cmu_init);
+subsys_initcall(exynos2200_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 02/12] clk: samsung: exynos4412-isp: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 01/12] clk: samsung: exynos2200: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 03/12] clk: samsung: exynos5433: " Krzysztof Kozlowski
` (10 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynos4412-isp.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynos4412-isp.c b/drivers/clk/samsung/clk-exynos4412-isp.c
index 29c5644f059379f8a0770ce2214c32b9df7d76e3..f288c152d3f769fbb5123c3b79fe4ddc8c23aa55 100644
--- a/drivers/clk/samsung/clk-exynos4412-isp.c
+++ b/drivers/clk/samsung/clk-exynos4412-isp.c
@@ -155,18 +155,17 @@ static const struct dev_pm_ops exynos4x12_isp_pm_ops = {
pm_runtime_force_resume)
};
-static struct platform_driver exynos4x12_isp_clk_driver __refdata = {
+static struct platform_driver exynos4x12_isp_clk_driver __initdata = {
.driver = {
.name = "exynos4x12-isp-clk",
.of_match_table = exynos4x12_isp_clk_of_match,
.suppress_bind_attrs = true,
.pm = &exynos4x12_isp_pm_ops,
},
- .probe = exynos4x12_isp_clk_probe,
};
static int __init exynos4x12_isp_clk_init(void)
{
- return platform_driver_register(&exynos4x12_isp_clk_driver);
+ return platform_driver_probe(&exynos4x12_isp_clk_driver, exynos4x12_isp_clk_probe);
}
-core_initcall(exynos4x12_isp_clk_init);
+subsys_initcall(exynos4x12_isp_clk_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 03/12] clk: samsung: exynos5433: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 01/12] clk: samsung: exynos2200: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 02/12] clk: samsung: exynos4412-isp: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 04/12] clk: samsung: exynos7870: " Krzysztof Kozlowski
` (9 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynos5433.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynos5433.c b/drivers/clk/samsung/clk-exynos5433.c
index 609d31a7aa5247e6318884609d1e651001616b73..d18b4f7b96b66e48fb94b86b663443ec691e968d 100644
--- a/drivers/clk/samsung/clk-exynos5433.c
+++ b/drivers/clk/samsung/clk-exynos5433.c
@@ -5555,18 +5555,17 @@ static const struct dev_pm_ops exynos5433_cmu_pm_ops = {
pm_runtime_force_resume)
};
-static struct platform_driver exynos5433_cmu_driver __refdata = {
+static struct platform_driver exynos5433_cmu_driver __initdata = {
.driver = {
.name = "exynos5433-cmu",
.of_match_table = exynos5433_cmu_of_match,
.suppress_bind_attrs = true,
.pm = &exynos5433_cmu_pm_ops,
},
- .probe = exynos5433_cmu_probe,
};
static int __init exynos5433_cmu_init(void)
{
- return platform_driver_register(&exynos5433_cmu_driver);
+ return platform_driver_probe(&exynos5433_cmu_driver, exynos5433_cmu_probe);
}
-core_initcall(exynos5433_cmu_init);
+subsys_initcall(exynos5433_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 04/12] clk: samsung: exynos7870: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (2 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 03/12] clk: samsung: exynos5433: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 05/12] clk: samsung: exynos7885: " Krzysztof Kozlowski
` (8 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynos7870.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynos7870.c b/drivers/clk/samsung/clk-exynos7870.c
index 2ec4a4e489be30bd1cd2e6deac006bb8ac5bdc57..c3d7d816cab673518c7b01ce35b0faf249692835 100644
--- a/drivers/clk/samsung/clk-exynos7870.c
+++ b/drivers/clk/samsung/clk-exynos7870.c
@@ -1814,17 +1814,16 @@ static const struct of_device_id exynos7870_cmu_of_match[] = {
},
};
-static struct platform_driver exynos7870_cmu_driver __refdata = {
+static struct platform_driver exynos7870_cmu_driver __initdata = {
.driver = {
.name = "exynos7870-cmu",
.of_match_table = exynos7870_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = exynos7870_cmu_probe,
};
static int __init exynos7870_cmu_init(void)
{
- return platform_driver_register(&exynos7870_cmu_driver);
+ return platform_driver_probe(&exynos7870_cmu_driver, exynos7870_cmu_probe);
}
-core_initcall(exynos7870_cmu_init);
+subsys_initcall(exynos7870_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 05/12] clk: samsung: exynos7885: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (3 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 04/12] clk: samsung: exynos7870: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 06/12] clk: samsung: exynos850: " Krzysztof Kozlowski
` (7 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynos7885.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynos7885.c b/drivers/clk/samsung/clk-exynos7885.c
index fc42251731edb6f8368d38638179056f8bc58335..0066c89e3515b852c7c6265322f8a1dc07af57ad 100644
--- a/drivers/clk/samsung/clk-exynos7885.c
+++ b/drivers/clk/samsung/clk-exynos7885.c
@@ -832,17 +832,16 @@ static const struct of_device_id exynos7885_cmu_of_match[] = {
},
};
-static struct platform_driver exynos7885_cmu_driver __refdata = {
+static struct platform_driver exynos7885_cmu_driver __initdata = {
.driver = {
.name = "exynos7885-cmu",
.of_match_table = exynos7885_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = exynos7885_cmu_probe,
};
static int __init exynos7885_cmu_init(void)
{
- return platform_driver_register(&exynos7885_cmu_driver);
+ return platform_driver_probe(&exynos7885_cmu_driver, exynos7885_cmu_probe);
}
-core_initcall(exynos7885_cmu_init);
+subsys_initcall(exynos7885_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 06/12] clk: samsung: exynos850: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (4 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 05/12] clk: samsung: exynos7885: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 07/12] clk: samsung: exynos8895: " Krzysztof Kozlowski
` (6 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynos850.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynos850.c b/drivers/clk/samsung/clk-exynos850.c
index e00e213b1201c82ac0c70cfe23d5ccc9c04f2aa3..37c06cbbe78f87e18877d33425fcd03b97a61e7f 100644
--- a/drivers/clk/samsung/clk-exynos850.c
+++ b/drivers/clk/samsung/clk-exynos850.c
@@ -2322,17 +2322,16 @@ static const struct of_device_id exynos850_cmu_of_match[] = {
},
};
-static struct platform_driver exynos850_cmu_driver __refdata = {
+static struct platform_driver exynos850_cmu_driver __initdata = {
.driver = {
.name = "exynos850-cmu",
.of_match_table = exynos850_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = exynos850_cmu_probe,
};
static int __init exynos850_cmu_init(void)
{
- return platform_driver_register(&exynos850_cmu_driver);
+ return platform_driver_probe(&exynos850_cmu_driver, exynos850_cmu_probe);
}
-core_initcall(exynos850_cmu_init);
+subsys_initcall(exynos850_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 07/12] clk: samsung: exynos8895: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (5 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 06/12] clk: samsung: exynos850: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 08/12] clk: samsung: exynos990: " Krzysztof Kozlowski
` (5 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynos8895.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynos8895.c b/drivers/clk/samsung/clk-exynos8895.c
index 29ec0c4a863524fe3fc5c223d762da87e5f13013..6b85d917871d20fd3a3f6768937eb5694760ffd2 100644
--- a/drivers/clk/samsung/clk-exynos8895.c
+++ b/drivers/clk/samsung/clk-exynos8895.c
@@ -2787,17 +2787,16 @@ static const struct of_device_id exynos8895_cmu_of_match[] = {
{ }
};
-static struct platform_driver exynos8895_cmu_driver __refdata = {
+static struct platform_driver exynos8895_cmu_driver __initdata = {
.driver = {
.name = "exynos8895-cmu",
.of_match_table = exynos8895_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = exynos8895_cmu_probe,
};
static int __init exynos8895_cmu_init(void)
{
- return platform_driver_register(&exynos8895_cmu_driver);
+ return platform_driver_probe(&exynos8895_cmu_driver, exynos8895_cmu_probe);
}
-core_initcall(exynos8895_cmu_init);
+subsys_initcall(exynos8895_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 08/12] clk: samsung: exynos990: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (6 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 07/12] clk: samsung: exynos8895: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-09 13:49 ` Igor Belwon
2025-03-05 21:43 ` [PATCH RFC/RFT 09/12] clk: samsung: exynosautov9: " Krzysztof Kozlowski
` (4 subsequent siblings)
12 siblings, 1 reply; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynos990.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynos990.c b/drivers/clk/samsung/clk-exynos990.c
index 76f22a4a4631fadf400420b977f3f59f40f840c7..d00050d8765f25042698cbe6bfa06623931c7414 100644
--- a/drivers/clk/samsung/clk-exynos990.c
+++ b/drivers/clk/samsung/clk-exynos990.c
@@ -1504,18 +1504,17 @@ static const struct of_device_id exynos990_cmu_of_match[] = {
{ },
};
-static struct platform_driver exynos990_cmu_driver __refdata = {
+static struct platform_driver exynos990_cmu_driver __initdata = {
.driver = {
.name = "exynos990-cmu",
.of_match_table = exynos990_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = exynos990_cmu_probe,
};
static int __init exynos990_cmu_init(void)
{
- return platform_driver_register(&exynos990_cmu_driver);
+ return platform_driver_probe(&exynos990_cmu_driver, exynos990_cmu_probe);
}
-core_initcall(exynos990_cmu_init);
+subsys_initcall(exynos990_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 09/12] clk: samsung: exynosautov9: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (7 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 08/12] clk: samsung: exynos990: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 10/12] clk: samsung: exynosautov920: " Krzysztof Kozlowski
` (3 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynosautov9.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynosautov9.c b/drivers/clk/samsung/clk-exynosautov9.c
index 5971e680e566336ecdf55bdccacc3cea09a33201..627f3d2666740fc4cba205e6e2da65f53b8df186 100644
--- a/drivers/clk/samsung/clk-exynosautov9.c
+++ b/drivers/clk/samsung/clk-exynosautov9.c
@@ -2190,17 +2190,16 @@ static const struct of_device_id exynosautov9_cmu_of_match[] = {
},
};
-static struct platform_driver exynosautov9_cmu_driver __refdata = {
+static struct platform_driver exynosautov9_cmu_driver __initdata = {
.driver = {
.name = "exynosautov9-cmu",
.of_match_table = exynosautov9_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = exynosautov9_cmu_probe,
};
static int __init exynosautov9_cmu_init(void)
{
- return platform_driver_register(&exynosautov9_cmu_driver);
+ return platform_driver_probe(&exynosautov9_cmu_driver, exynosautov9_cmu_probe);
}
core_initcall(exynosautov9_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 10/12] clk: samsung: exynosautov920: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (8 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 09/12] clk: samsung: exynosautov9: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 11/12] clk: samsung: fsd: " Krzysztof Kozlowski
` (2 subsequent siblings)
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-exynosautov920.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-exynosautov920.c b/drivers/clk/samsung/clk-exynosautov920.c
index 2a8bfd5d9abc8acced4e5a3eaacefe5fa724cbd2..e0ba75fd20177022dc7f461af5968c154b6a8a37 100644
--- a/drivers/clk/samsung/clk-exynosautov920.c
+++ b/drivers/clk/samsung/clk-exynosautov920.c
@@ -1447,17 +1447,16 @@ static const struct of_device_id exynosautov920_cmu_of_match[] = {
{ }
};
-static struct platform_driver exynosautov920_cmu_driver __refdata = {
+static struct platform_driver exynosautov920_cmu_driver __initdata = {
.driver = {
.name = "exynosautov920-cmu",
.of_match_table = exynosautov920_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = exynosautov920_cmu_probe,
};
static int __init exynosautov920_cmu_init(void)
{
- return platform_driver_register(&exynosautov920_cmu_driver);
+ return platform_driver_probe(&exynosautov920_cmu_driver, exynosautov920_cmu_probe);
}
-core_initcall(exynosautov920_cmu_init);
+subsys_initcall(exynosautov920_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 11/12] clk: samsung: fsd: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (9 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 10/12] clk: samsung: exynosautov920: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 12/12] clk: samsung: gs101: " Krzysztof Kozlowski
2025-03-07 14:29 ` [PATCH RFC/RFT 00/12] clk: samsung: " André Draszik
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-fsd.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-fsd.c b/drivers/clk/samsung/clk-fsd.c
index 9a6006c298c2a80da0e29aeca3b09cc827caac0c..bc0287c780bfe3a68a38f53f554440b3000b1ca7 100644
--- a/drivers/clk/samsung/clk-fsd.c
+++ b/drivers/clk/samsung/clk-fsd.c
@@ -1794,17 +1794,16 @@ static const struct of_device_id fsd_cmu_of_match[] = {
},
};
-static struct platform_driver fsd_cmu_driver __refdata = {
+static struct platform_driver fsd_cmu_driver __initdata = {
.driver = {
.name = "fsd-cmu",
.of_match_table = fsd_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = fsd_cmu_probe,
};
static int __init fsd_cmu_init(void)
{
- return platform_driver_register(&fsd_cmu_driver);
+ return platform_driver_probe(&fsd_cmu_driver, fsd_cmu_probe);
}
-core_initcall(fsd_cmu_init);
+subsys_initcall(fsd_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* [PATCH RFC/RFT 12/12] clk: samsung: gs101: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (10 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 11/12] clk: samsung: fsd: " Krzysztof Kozlowski
@ 2025-03-05 21:43 ` Krzysztof Kozlowski
2025-03-07 14:29 ` [PATCH RFC/RFT 00/12] clk: samsung: " André Draszik
12 siblings, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-05 21:43 UTC (permalink / raw)
To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
Alim Akhtar, Michael Turquette, Stephen Boyd, Sam Protsenko,
Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel,
Krzysztof Kozlowski
Switch registering platform driver to platform_driver_probe(), so the
'struct platform_driver' can be properly discarded after init and there
won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
The change requires using subsys_initcall instead of core_initcall,
because no device drivers would bound in the latter, as required by
platform_driver_probe().
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/clk/samsung/clk-gs101.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/clk/samsung/clk-gs101.c b/drivers/clk/samsung/clk-gs101.c
index 86b39edba12276745a124df6a2ea9c22d74b915a..69c121d478f3fec98dcd84e0639e204fe604e91c 100644
--- a/drivers/clk/samsung/clk-gs101.c
+++ b/drivers/clk/samsung/clk-gs101.c
@@ -4412,17 +4412,16 @@ static const struct of_device_id gs101_cmu_of_match[] = {
},
};
-static struct platform_driver gs101_cmu_driver __refdata = {
+static struct platform_driver gs101_cmu_driver __initdata = {
.driver = {
.name = "gs101-cmu",
.of_match_table = gs101_cmu_of_match,
.suppress_bind_attrs = true,
},
- .probe = gs101_cmu_probe,
};
static int __init gs101_cmu_init(void)
{
- return platform_driver_register(&gs101_cmu_driver);
+ return platform_driver_probe(&gs101_cmu_driver, gs101_cmu_probe);
}
-core_initcall(gs101_cmu_init);
+subsys_initcall(gs101_cmu_init);
--
2.43.0
^ permalink raw reply related [flat|nested] 17+ messages in thread
* Re: [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
` (11 preceding siblings ...)
2025-03-05 21:43 ` [PATCH RFC/RFT 12/12] clk: samsung: gs101: " Krzysztof Kozlowski
@ 2025-03-07 14:29 ` André Draszik
2025-03-07 15:00 ` Krzysztof Kozlowski
2025-03-07 19:04 ` Stephen Boyd
12 siblings, 2 replies; 17+ messages in thread
From: André Draszik @ 2025-03-07 14:29 UTC (permalink / raw)
To: Krzysztof Kozlowski, Krzysztof Kozlowski, Sylwester Nawrocki,
Chanwoo Choi, Alim Akhtar, Michael Turquette, Stephen Boyd,
Sam Protsenko, Peter Griffin, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel
Hi Krzysztof,
Nice idea!
On Wed, 2025-03-05 at 22:43 +0100, Krzysztof Kozlowski wrote:
> RFT/RFC because testing needed. I tried to do the same on exynos5-subcmu
> and it caused weird oopses which even KASAN did not narrow. Probably
> because of multiple exynos5-subcmu devices?
I've tried this on top of next-20250225, and it doesn't work on gs101
either and OOPSes several times during boot in different places, but
I can not dig deeper right now.
[ 11.502919][ T58] Unable to handle kernel paging request at virtual address ffffbfe2ab25cc30
[ 11.503128][ T58] Mem abort info:
[ 11.503202][ T58] ESR = 0x0000000096000007
[ 11.503295][ T58] EC = 0x25: DABT (current EL), IL = 32 bits
[ 11.503419][ T58] SET = 0, FnV = 0
[ 11.503498][ T58] EA = 0, S1PTW = 0
[ 11.503579][ T58] FSC = 0x07: level 3 translation fault
[ 11.503695][ T58] Data abort info:
[ 11.503769][ T58] ISV = 0, ISS = 0x00000007, ISS2 = 0x00000000
[ 11.503896][ T58] CM = 0, WnR = 0, TnD = 0, TagAccess = 0
[ 11.504058][ T58] GCS = 0, Overlay = 0, DirtyBit = 0, Xs = 0
[ 11.504288][ T58] swapper pgtable: 4k pages, 48-bit VAs, pgdp=000000008208c000
[ 11.504570][ T58] [ffffbfe2ab25cc30] pgd=0000000000000000, p4d=1000000082a58003, pud=1000000082a59003, pmd=1000000082a5d003,
pte=0000000000000000
[ 11.505079][ T58] Internal error: Oops: 0000000096000007 [#1] PREEMPT SMP
[ 11.505346][ T58] Modules linked in:
[ 11.505495][ T58] CPU: 6 UID: 0 PID: 58 Comm: kworker/u32:1 Tainted: G T 6.14.0-rc4-next-20250225+ #12
[ 11.505902][ T58] Tainted: [T]=RANDSTRUCT
[ 11.506061][ T58] Hardware name: Raven (DT)
[ 11.506230][ T58] Workqueue: events_unbound deferred_probe_work_func
[ 11.506477][ T58] pstate: 20400005 (nzCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[ 11.506768][ T58] pc : __device_attach_driver+0x18/0x254
[ 11.506978][ T58] lr : bus_for_each_drv+0xfc/0x154
[ 11.507168][ T58] sp : ffff8000803abc00
[ 11.507321][ T58] x29: ffff8000803abc10 x28: ffff00ed403363d0 x27: ffff00ed40336400
[ 11.507620][ T58] x26: 0000000000000000 x25: ffff00ed4002380d x24: ffff00ed40028000
[ 11.507919][ T58] x23: ffffbfe2aba26000 x22: 0000000000000000 x21: ffff00ed409f8400
[ 11.508219][ T58] x20: ffff8000803abca8 x19: ffffbfe2a9a4cf4c x18: 0000000000000040
[ 11.508518][ T58] x17: 0000000000000001 x16: 0000000000000001 x15: 0000000000000010
[ 11.508817][ T58] x14: 0000000000000010 x13: 0000000000000093 x12: 0000000000000002
[ 11.509117][ T58] x11: ffffffffff6070d2 x10: 0000bef56a420260 x9 : 0000000100000000
[ 11.509416][ T58] x8 : 0000000100000000 x7 : ff7f7f7f7f7f7f7f x6 : 455242436f53531d
[ 11.509715][ T58] x5 : 1d53536f43425245 x4 : 0000000000000000 x3 : e8c6e6e4bec6c65a
[ 11.510015][ T58] x2 : 0000000000000062 x1 : ffff8000803abca8 x0 : ffffbfe2ab25cc28
[ 11.510315][ T58] Call trace:
[ 11.510436][ T58] __device_attach_driver+0x18/0x254 (P)
[ 11.510644][ T58] bus_for_each_drv+0xfc/0x154
[ 11.510819][ T58] __device_attach+0x100/0x1cc
[ 11.510996][ T58] device_initial_probe+0x14/0x20
[ 11.511182][ T58] bus_probe_device+0x94/0x100
[ 11.511359][ T58] deferred_probe_work_func+0xa0/0xfc
[ 11.511558][ T58] process_scheduled_works+0x194/0x2c4
[ 11.511761][ T58] worker_thread+0x28c/0x394
[ 11.511930][ T58] kthread+0x1c0/0x204
[ 11.512081][ T58] ret_from_fork+0x10/0x20
[ 11.512248][ T58] Code: a9017bfd f90013f5 a9034ff4 910043fd (f9400408)
[ 11.512506][ T58] ---[ end trace 0000000000000000 ]---
and
+ udevadm trigger '--action=add'
[ 390.387986][ T394] Unable to handle kernel paging request at virtual address ffffbfe2ab25cc28
[ 390.388207][ T394] Mem abort info:
[ 390.388282][ T394] ESR = 0x0000000096000007
[ 390.388378][ T394] EC = 0x25: DABT (current EL), IL = 32 bits
[ 390.388506][ T394] SET = 0, FnV = 0
[ 390.388586][ T394] EA = 0, S1PTW = 0
[ 390.388669][ T394] FSC = 0x07: level 3 translation fault
[ 390.388787][ T394] Data abort info:
[ 390.388862][ T394] ISV = 0, ISS = 0x00000007, ISS2 = 0x00000000
[ 390.388990][ T394] CM = 0, WnR = 0, TnD = 0, TagAccess = 0
[ 390.389137][ T394] GCS = 0, Overlay = 0, DirtyBit = 0, Xs = 0
[ 390.389367][ T394] swapper pgtable: 4k pages, 48-bit VAs, pgdp=000000008208c000
[ 390.389650][ T394] [ffffbfe2ab25cc28] pgd=0000000000000000, p4d=1000000082a58003, pud=1000000082a59003, pmd=1000000082a5d003,
pte=0000000000000000
[ 390.390173][ T394] Internal error: Oops: 0000000096000007 [#2] PREEMPT SMP
[ 390.390426][ T394] Modules linked in:
[ 390.390580][ T394] CPU: 7 UID: 0 PID: 394 Comm: udevadm Tainted: G D T 6.14.0-rc4-next-20250225+ #12
[ 390.390969][ T394] Tainted: [D]=DIE, [T]=RANDSTRUCT
[ 390.391153][ T394] Hardware name: Raven (DT)
[ 390.391322][ T394] pstate: 80400005 (Nzcv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[ 390.391612][ T394] pc : dev_uevent+0x144/0x2d8
[ 390.391785][ T394] lr : kobject_uevent_env+0x1e0/0x3a8
[ 390.391985][ T394] sp : ffff8000810fbb40
[ 390.392137][ T394] x29: ffff8000810fbb60 x28: 0000000000000002 x27: ffffbfe2aa859240
[ 390.392437][ T394] x26: ffffbfe2aae1ca12 x25: 0000000000000000 x24: ffff00ed41167540
[ 390.392736][ T394] x23: ffff00ed41070000 x22: ffff8000810fbbf8 x21: 0000000000000000
[ 390.393035][ T394] x20: ffff00ed41070000 x19: ffff00ed41083010 x18: 0000000000000000
[ 390.393335][ T394] x17: 0000000000000000 x16: 0000000000000000 x15: 0000ffffc7e40360
[ 390.393634][ T394] x14: 00000000ffffffd0 x13: aaaaaaaaaaaaaaaa x12: aaaaaaaaaaaa0000
[ 390.393933][ T394] x11: 0000000000000000 x10: 0000000000000004 x9 : 3bc04d1231e6a100
[ 390.394233][ T394] x8 : ffffbfe2ab25cc28 x7 : 3d4d455453595342 x6 : 4554535953425553
[ 390.394532][ T394] x5 : ffff00ed4107026b x4 : ffffbfe2aae64508 x3 : ffffffffffff0a00
[ 390.394831][ T394] x2 : 0000000000000000 x1 : ffff00ed41070000 x0 : ffff00ed41083010
[ 390.395132][ T394] Call trace:
[ 390.395252][ T394] dev_uevent+0x144/0x2d8 (P)
[ 390.395425][ T394] kobject_uevent_env+0x1e0/0x3a8
[ 390.395610][ T394] kobject_synth_uevent+0x3ec/0x440
[ 390.395802][ T394] uevent_store+0x28/0x64
[ 390.395962][ T394] dev_attr_store+0x18/0x2c
[ 390.396128][ T394] sysfs_kf_write+0x80/0xa0
[ 390.396295][ T394] kernfs_fop_write_iter+0xdc/0x178
[ 390.396488][ T394] vfs_write+0x344/0x3a0
[ 390.396644][ T394] ksys_write+0x7c/0xe8
[ 390.396797][ T394] __arm64_sys_write+0x1c/0x28
[ 390.396973][ T394] invoke_syscall+0x40/0xf8
[ 390.397139][ T394] el0_svc_common+0xac/0xdc
[ 390.397306][ T394] do_el0_svc+0x1c/0x28
[ 390.397459][ T394] el0_svc+0x34/0x9c
[ 390.397602][ T394] el0t_64_sync_handler+0x84/0x108
[ 390.397791][ T394] el0t_64_sync+0x1a4/0x1a8
[ 390.397963][ T394] Code: aa1403e0 94232d4d f9403668 b40000c8 (f9400102)
[ 390.398221][ T394] ---[ end trace 0000000000000000 ]---
Cheers,
Andre'
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata
2025-03-07 14:29 ` [PATCH RFC/RFT 00/12] clk: samsung: " André Draszik
@ 2025-03-07 15:00 ` Krzysztof Kozlowski
2025-03-07 19:04 ` Stephen Boyd
1 sibling, 0 replies; 17+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-07 15:00 UTC (permalink / raw)
To: André Draszik, Krzysztof Kozlowski, Sylwester Nawrocki,
Chanwoo Choi, Alim Akhtar, Michael Turquette, Stephen Boyd,
Sam Protsenko, Peter Griffin, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel
On 07/03/2025 15:29, André Draszik wrote:
> Hi Krzysztof,
>
> Nice idea!
>
> On Wed, 2025-03-05 at 22:43 +0100, Krzysztof Kozlowski wrote:
>> RFT/RFC because testing needed. I tried to do the same on exynos5-subcmu
>> and it caused weird oopses which even KASAN did not narrow. Probably
>> because of multiple exynos5-subcmu devices?
>
> I've tried this on top of next-20250225, and it doesn't work on gs101
> either and OOPSes several times during boot in different places, but
> I can not dig deeper right now.
>
> [ 11.502919][ T58] Unable to handle kernel paging request at virtual address ffffbfe2ab25cc30
Thanks. I'll dig more once have a bit more time. The calltrace is
exactly what I saw with exynos5-subcmu and it puzzles me.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata
2025-03-07 14:29 ` [PATCH RFC/RFT 00/12] clk: samsung: " André Draszik
2025-03-07 15:00 ` Krzysztof Kozlowski
@ 2025-03-07 19:04 ` Stephen Boyd
1 sibling, 0 replies; 17+ messages in thread
From: Stephen Boyd @ 2025-03-07 19:04 UTC (permalink / raw)
To: Alim Akhtar, André Draszik, Chanwoo Choi,
Krzysztof Kozlowski, Krzysztof Kozlowski, Michael Turquette,
Peter Griffin, Sam Protsenko, Sylwester Nawrocki, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel
Quoting André Draszik (2025-03-07 06:29:18)
>
> I've tried this on top of next-20250225, and it doesn't work on gs101
> either and OOPSes several times during boot in different places, but
> I can not dig deeper right now.
>
> [ 11.502919][ T58] Unable to handle kernel paging request at virtual address ffffbfe2ab25cc30
> [ 11.503128][ T58] Mem abort info:
> [ 11.503202][ T58] ESR = 0x0000000096000007
> [ 11.503295][ T58] EC = 0x25: DABT (current EL), IL = 32 bits
> [ 11.503419][ T58] SET = 0, FnV = 0
> [ 11.503498][ T58] EA = 0, S1PTW = 0
> [ 11.503579][ T58] FSC = 0x07: level 3 translation fault
> [ 11.503695][ T58] Data abort info:
> [ 11.503769][ T58] ISV = 0, ISS = 0x00000007, ISS2 = 0x00000000
> [ 11.503896][ T58] CM = 0, WnR = 0, TnD = 0, TagAccess = 0
> [ 11.504058][ T58] GCS = 0, Overlay = 0, DirtyBit = 0, Xs = 0
> [ 11.504288][ T58] swapper pgtable: 4k pages, 48-bit VAs, pgdp=000000008208c000
> [ 11.504570][ T58] [ffffbfe2ab25cc30] pgd=0000000000000000, p4d=1000000082a58003, pud=1000000082a59003, pmd=1000000082a5d003,
> pte=0000000000000000
> [ 11.505079][ T58] Internal error: Oops: 0000000096000007 [#1] PREEMPT SMP
> [ 11.505346][ T58] Modules linked in:
> [ 11.505495][ T58] CPU: 6 UID: 0 PID: 58 Comm: kworker/u32:1 Tainted: G T 6.14.0-rc4-next-20250225+ #12
> [ 11.505902][ T58] Tainted: [T]=RANDSTRUCT
> [ 11.506061][ T58] Hardware name: Raven (DT)
> [ 11.506230][ T58] Workqueue: events_unbound deferred_probe_work_func
> [ 11.506477][ T58] pstate: 20400005 (nzCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
> [ 11.506768][ T58] pc : __device_attach_driver+0x18/0x254
> [ 11.506978][ T58] lr : bus_for_each_drv+0xfc/0x154
> [ 11.507168][ T58] sp : ffff8000803abc00
> [ 11.507321][ T58] x29: ffff8000803abc10 x28: ffff00ed403363d0 x27: ffff00ed40336400
> [ 11.507620][ T58] x26: 0000000000000000 x25: ffff00ed4002380d x24: ffff00ed40028000
> [ 11.507919][ T58] x23: ffffbfe2aba26000 x22: 0000000000000000 x21: ffff00ed409f8400
> [ 11.508219][ T58] x20: ffff8000803abca8 x19: ffffbfe2a9a4cf4c x18: 0000000000000040
> [ 11.508518][ T58] x17: 0000000000000001 x16: 0000000000000001 x15: 0000000000000010
> [ 11.508817][ T58] x14: 0000000000000010 x13: 0000000000000093 x12: 0000000000000002
> [ 11.509117][ T58] x11: ffffffffff6070d2 x10: 0000bef56a420260 x9 : 0000000100000000
> [ 11.509416][ T58] x8 : 0000000100000000 x7 : ff7f7f7f7f7f7f7f x6 : 455242436f53531d
> [ 11.509715][ T58] x5 : 1d53536f43425245 x4 : 0000000000000000 x3 : e8c6e6e4bec6c65a
> [ 11.510015][ T58] x2 : 0000000000000062 x1 : ffff8000803abca8 x0 : ffffbfe2ab25cc28
> [ 11.510315][ T58] Call trace:
> [ 11.510436][ T58] __device_attach_driver+0x18/0x254 (P)
> [ 11.510644][ T58] bus_for_each_drv+0xfc/0x154
> [ 11.510819][ T58] __device_attach+0x100/0x1cc
> [ 11.510996][ T58] device_initial_probe+0x14/0x20
> [ 11.511182][ T58] bus_probe_device+0x94/0x100
> [ 11.511359][ T58] deferred_probe_work_func+0xa0/0xfc
platform_driver_probe() is incompatible with deferred probe. It
should have set drv->prevent_deferred_probe to true so the driver must
have gotten onto the deferred probe list somehow when it shouldn't have.
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH RFC/RFT 08/12] clk: samsung: exynos990: Use platform_driver_probe() to avoid __refdata
2025-03-05 21:43 ` [PATCH RFC/RFT 08/12] clk: samsung: exynos990: " Krzysztof Kozlowski
@ 2025-03-09 13:49 ` Igor Belwon
0 siblings, 0 replies; 17+ messages in thread
From: Igor Belwon @ 2025-03-09 13:49 UTC (permalink / raw)
To: Krzysztof Kozlowski, Krzysztof Kozlowski, Sylwester Nawrocki,
Chanwoo Choi, Alim Akhtar, Michael Turquette, Stephen Boyd,
Sam Protsenko, Peter Griffin, André Draszik, Tudor Ambarus
Cc: linux-samsung-soc, linux-clk, linux-arm-kernel, linux-kernel
On Wed Mar 5, 2025 at 10:43 PM CET, Krzysztof Kozlowski wrote:
> Switch registering platform driver to platform_driver_probe(), so the
> 'struct platform_driver' can be properly discarded after init and there
> won't be need of __refdata to silence DEBUG_SECTION_MISMATCH.
>
> The change requires using subsys_initcall instead of core_initcall,
> because no device drivers would bound in the latter, as required by
> platform_driver_probe().
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Hi Krzysztof and apologies for the delay in testing.
On my Exynos990 platforms this patch causes similar oopses to those
sent by André (different places each boot). I am unable to get the logs from
UART right now though (refactoring my testing setup). Apologies.
So this bug seems to be platformwide :(
Best regards,
Igor
^ permalink raw reply [flat|nested] 17+ messages in thread
end of thread, other threads:[~2025-03-09 13:55 UTC | newest]
Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-05 21:43 [PATCH RFC/RFT 00/12] clk: samsung: Use platform_driver_probe() to avoid __refdata Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 01/12] clk: samsung: exynos2200: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 02/12] clk: samsung: exynos4412-isp: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 03/12] clk: samsung: exynos5433: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 04/12] clk: samsung: exynos7870: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 05/12] clk: samsung: exynos7885: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 06/12] clk: samsung: exynos850: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 07/12] clk: samsung: exynos8895: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 08/12] clk: samsung: exynos990: " Krzysztof Kozlowski
2025-03-09 13:49 ` Igor Belwon
2025-03-05 21:43 ` [PATCH RFC/RFT 09/12] clk: samsung: exynosautov9: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 10/12] clk: samsung: exynosautov920: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 11/12] clk: samsung: fsd: " Krzysztof Kozlowski
2025-03-05 21:43 ` [PATCH RFC/RFT 12/12] clk: samsung: gs101: " Krzysztof Kozlowski
2025-03-07 14:29 ` [PATCH RFC/RFT 00/12] clk: samsung: " André Draszik
2025-03-07 15:00 ` Krzysztof Kozlowski
2025-03-07 19:04 ` Stephen Boyd
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).