* [PATCH] ide: palm_bk3710: add __initdata to palm_bk3710_port_info
@ 2016-12-30 9:20 Bhumika Goyal
2017-02-28 1:45 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Bhumika Goyal @ 2016-12-30 9:20 UTC (permalink / raw)
To: julia.lawall, davem, linux-ide, linux-kernel; +Cc: Bhumika Goyal
The object palm_bk3710_port_info of type ide_port_info is never
referenced anywhere after initialization by palm_bk3710_probe. It is
also passed as a parameter to ide_host_add which is called from the init
function but this call doesn't store the object reference anywhere, and
it only dereferences the values of the fields. Therefore add __initdata
to its declaration.
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
---
Compiled, but not tested
drivers/ide/palm_bk3710.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/ide/palm_bk3710.c b/drivers/ide/palm_bk3710.c
index 46427ea..157f2d1 100644
--- a/drivers/ide/palm_bk3710.c
+++ b/drivers/ide/palm_bk3710.c
@@ -300,7 +300,7 @@ static int palm_bk3710_init_dma(ide_hwif_t *hwif, const struct ide_port_info *d)
.cable_detect = palm_bk3710_cable_detect,
};
-static struct ide_port_info palm_bk3710_port_info = {
+static struct ide_port_info palm_bk3710_port_info __initdata = {
.init_dma = palm_bk3710_init_dma,
.port_ops = &palm_bk3710_ports_ops,
.dma_ops = &sff_dma_ops,
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] ide: palm_bk3710: add __initdata to palm_bk3710_port_info
2016-12-30 9:20 [PATCH] ide: palm_bk3710: add __initdata to palm_bk3710_port_info Bhumika Goyal
@ 2017-02-28 1:45 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2017-02-28 1:45 UTC (permalink / raw)
To: bhumirks; +Cc: julia.lawall, linux-ide, linux-kernel
From: Bhumika Goyal <bhumirks@gmail.com>
Date: Fri, 30 Dec 2016 14:50:02 +0530
> The object palm_bk3710_port_info of type ide_port_info is never
> referenced anywhere after initialization by palm_bk3710_probe. It is
> also passed as a parameter to ide_host_add which is called from the init
> function but this call doesn't store the object reference anywhere, and
> it only dereferences the values of the fields. Therefore add __initdata
> to its declaration.
>
> Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
Applied, thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-02-28 2:03 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-30 9:20 [PATCH] ide: palm_bk3710: add __initdata to palm_bk3710_port_info Bhumika Goyal
2017-02-28 1:45 ` David Miller
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).