* [PATCH] memory: renesas-rpc-if: Add missing static keyword
@ 2025-05-07 16:21 Biju Das
2025-05-07 17:12 ` Geert Uytterhoeven
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Biju Das @ 2025-05-07 16:21 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Biju Das, Geert Uytterhoeven, Prabhakar Mahadev Lad, Biju Das,
linux-renesas-soc, kernel test robot
Fix the below sparse warnings:
symbol 'rpcif_impl' was not declared. Should it be static?
symbol 'xspi_impl' was not declared. Should it be static?
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202505072013.1EqwjtaR-lkp@intel.com/
Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
---
drivers/memory/renesas-rpc-if.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/memory/renesas-rpc-if.c b/drivers/memory/renesas-rpc-if.c
index 4b2e903f2b0d..4a417b693080 100644
--- a/drivers/memory/renesas-rpc-if.c
+++ b/drivers/memory/renesas-rpc-if.c
@@ -1063,7 +1063,7 @@ static void rpcif_remove(struct platform_device *pdev)
platform_device_unregister(rpc->vdev);
}
-struct rpcif_impl rpcif_impl = {
+static const struct rpcif_impl rpcif_impl = {
.hw_init = rpcif_hw_init_impl,
.prepare = rpcif_prepare_impl,
.manual_xfer = rpcif_manual_xfer_impl,
@@ -1072,7 +1072,7 @@ struct rpcif_impl rpcif_impl = {
.status_mask = RPCIF_CMNSR_TEND,
};
-struct rpcif_impl xspi_impl = {
+static const struct rpcif_impl xspi_impl = {
.hw_init = xspi_hw_init_impl,
.prepare = xspi_prepare_impl,
.manual_xfer = xspi_manual_xfer_impl,
--
2.43.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] memory: renesas-rpc-if: Add missing static keyword
2025-05-07 16:21 [PATCH] memory: renesas-rpc-if: Add missing static keyword Biju Das
@ 2025-05-07 17:12 ` Geert Uytterhoeven
2025-05-08 8:57 ` Krzysztof Kozlowski
2025-05-08 9:25 ` Krzysztof Kozlowski
2 siblings, 0 replies; 7+ messages in thread
From: Geert Uytterhoeven @ 2025-05-07 17:12 UTC (permalink / raw)
To: Biju Das
Cc: Krzysztof Kozlowski, Prabhakar Mahadev Lad, Biju Das,
linux-renesas-soc, kernel test robot
On Wed, 7 May 2025 at 18:21, Biju Das <biju.das.jz@bp.renesas.com> wrote:
> Fix the below sparse warnings:
> symbol 'rpcif_impl' was not declared. Should it be static?
> symbol 'xspi_impl' was not declared. Should it be static?
>
> Reported-by: kernel test robot <lkp@intel.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202505072013.1EqwjtaR-lkp@intel.com/
> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] memory: renesas-rpc-if: Add missing static keyword
2025-05-07 16:21 [PATCH] memory: renesas-rpc-if: Add missing static keyword Biju Das
2025-05-07 17:12 ` Geert Uytterhoeven
@ 2025-05-08 8:57 ` Krzysztof Kozlowski
2025-05-08 9:05 ` Biju Das
2025-05-08 9:25 ` Krzysztof Kozlowski
2 siblings, 1 reply; 7+ messages in thread
From: Krzysztof Kozlowski @ 2025-05-08 8:57 UTC (permalink / raw)
To: Biju Das
Cc: Geert Uytterhoeven, Prabhakar Mahadev Lad, Biju Das,
linux-renesas-soc, kernel test robot
On 07/05/2025 18:21, Biju Das wrote:
> Fix the below sparse warnings:
> symbol 'rpcif_impl' was not declared. Should it be static?
> symbol 'xspi_impl' was not declared. Should it be static?
Did you test now your code with sparse and smatch? Otherwise I will wait
for more reports.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 7+ messages in thread
* RE: [PATCH] memory: renesas-rpc-if: Add missing static keyword
2025-05-08 8:57 ` Krzysztof Kozlowski
@ 2025-05-08 9:05 ` Biju Das
2025-05-08 9:10 ` Krzysztof Kozlowski
0 siblings, 1 reply; 7+ messages in thread
From: Biju Das @ 2025-05-08 9:05 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Geert Uytterhoeven, Prabhakar Mahadev Lad, biju.das.au,
linux-renesas-soc@vger.kernel.org, kernel test robot
Hi Krzysztof,
> -----Original Message-----
> From: Krzysztof Kozlowski <krzk@kernel.org>
> Sent: 08 May 2025 09:57
> Subject: Re: [PATCH] memory: renesas-rpc-if: Add missing static keyword
>
> On 07/05/2025 18:21, Biju Das wrote:
> > Fix the below sparse warnings:
> > symbol 'rpcif_impl' was not declared. Should it be static?
> > symbol 'xspi_impl' was not declared. Should it be static?
>
>
> Did you test now your code with sparse and smatch? Otherwise I will wait for more reports.
Yes, I tested with the instructions in [1] and the patch fixes the above issues.
[1] https://download.01.org/0day-ci/archive/20250507/202505072013.1EqwjtaR-lkp@intel.com/reproduce
Cheers,
Biju
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] memory: renesas-rpc-if: Add missing static keyword
2025-05-08 9:05 ` Biju Das
@ 2025-05-08 9:10 ` Krzysztof Kozlowski
2025-05-08 18:13 ` Biju Das
0 siblings, 1 reply; 7+ messages in thread
From: Krzysztof Kozlowski @ 2025-05-08 9:10 UTC (permalink / raw)
To: Biju Das
Cc: Geert Uytterhoeven, Prabhakar Mahadev Lad, biju.das.au,
linux-renesas-soc@vger.kernel.org, kernel test robot
On 08/05/2025 11:05, Biju Das wrote:
> Hi Krzysztof,
>
>> -----Original Message-----
>> From: Krzysztof Kozlowski <krzk@kernel.org>
>> Sent: 08 May 2025 09:57
>> Subject: Re: [PATCH] memory: renesas-rpc-if: Add missing static keyword
>>
>> On 07/05/2025 18:21, Biju Das wrote:
>>> Fix the below sparse warnings:
>>> symbol 'rpcif_impl' was not declared. Should it be static?
>>> symbol 'xspi_impl' was not declared. Should it be static?
>>
>>
>> Did you test now your code with sparse and smatch? Otherwise I will wait for more reports.
>
> Yes, I tested with the instructions in [1] and the patch fixes the above issues.
>
I meant other issues. So you did not test with smatch? That's your task
and you should not rely on the community to provide such tests/checks
instead.
Please run standard kernel tools for static analysis, like coccinelle,
smatch and sparse, and fix reported warnings. Also please check for
warnings when building with W=1 for gcc and clang. Most of these
commands (checks or W=1 build) can build specific targets, like some
directory, to narrow the scope to only your code. The code here looks
like it needs a fix. Feel free to get in touch if the warning is not clear.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] memory: renesas-rpc-if: Add missing static keyword
2025-05-07 16:21 [PATCH] memory: renesas-rpc-if: Add missing static keyword Biju Das
2025-05-07 17:12 ` Geert Uytterhoeven
2025-05-08 8:57 ` Krzysztof Kozlowski
@ 2025-05-08 9:25 ` Krzysztof Kozlowski
2 siblings, 0 replies; 7+ messages in thread
From: Krzysztof Kozlowski @ 2025-05-08 9:25 UTC (permalink / raw)
To: Krzysztof Kozlowski, Biju Das
Cc: Geert Uytterhoeven, Prabhakar Mahadev Lad, Biju Das,
linux-renesas-soc, kernel test robot
On Wed, 07 May 2025 17:21:44 +0100, Biju Das wrote:
> Fix the below sparse warnings:
> symbol 'rpcif_impl' was not declared. Should it be static?
> symbol 'xspi_impl' was not declared. Should it be static?
>
>
Applied, thanks!
[1/1] memory: renesas-rpc-if: Add missing static keyword
https://git.kernel.org/krzk/linux-mem-ctrl/c/798dc3f19c9e3855c18c3afb610bc5d27195ef44
Best regards,
--
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
^ permalink raw reply [flat|nested] 7+ messages in thread
* RE: [PATCH] memory: renesas-rpc-if: Add missing static keyword
2025-05-08 9:10 ` Krzysztof Kozlowski
@ 2025-05-08 18:13 ` Biju Das
0 siblings, 0 replies; 7+ messages in thread
From: Biju Das @ 2025-05-08 18:13 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Geert Uytterhoeven, Prabhakar Mahadev Lad, biju.das.au,
linux-renesas-soc@vger.kernel.org, kernel test robot
Hi Krzysztof,
> -----Original Message-----
> From: Krzysztof Kozlowski <krzk@kernel.org>
> Subject: Re: [PATCH] memory: renesas-rpc-if: Add missing static keyword
>
> On 08/05/2025 11:05, Biju Das wrote:
> > Hi Krzysztof,
> >
> >> -----Original Message-----
> >> From: Krzysztof Kozlowski <krzk@kernel.org>
> >> Sent: 08 May 2025 09:57
> >> Subject: Re: [PATCH] memory: renesas-rpc-if: Add missing static
> >> keyword
> >>
> >> On 07/05/2025 18:21, Biju Das wrote:
> >>> Fix the below sparse warnings:
> >>> symbol 'rpcif_impl' was not declared. Should it be static?
> >>> symbol 'xspi_impl' was not declared. Should it be static?
> >>
> >>
> >> Did you test now your code with sparse and smatch? Otherwise I will wait for more reports.
> >
> > Yes, I tested with the instructions in [1] and the patch fixes the above issues.
> >
> I meant other issues. So you did not test with smatch? That's your task and you should not rely on the
> community to provide such tests/checks instead.
>
> Please run standard kernel tools for static analysis, like coccinelle, smatch and sparse, and fix
> reported warnings. Also please check for warnings when building with W=1 for gcc and clang. Most of
> these commands (checks or W=1 build) can build specific targets, like some directory, to narrow the
> scope to only your code. The code here looks like it needs a fix. Feel free to get in touch if the
> warning is not clear.
OK got it. will run these jobs in our local CI.
Cheers,
Biju
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2025-05-08 18:13 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-05-07 16:21 [PATCH] memory: renesas-rpc-if: Add missing static keyword Biju Das
2025-05-07 17:12 ` Geert Uytterhoeven
2025-05-08 8:57 ` Krzysztof Kozlowski
2025-05-08 9:05 ` Biju Das
2025-05-08 9:10 ` Krzysztof Kozlowski
2025-05-08 18:13 ` Biju Das
2025-05-08 9:25 ` Krzysztof Kozlowski
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.