summaryrefslogtreecommitdiffstats
path: root/drivers/ata/libata-core.c
diff options
context:
space:
mode:
authorBhumika Goyal2017-09-30 18:40:40 +0200
committerTejun Heo2017-10-02 18:57:55 +0200
commit8df82c13a3756f831b0d748226ce932515728e04 (patch)
treef543ab6512a622e3d682c0ed9f9072383159aee3 /drivers/ata/libata-core.c
parentlibata: make static arrays const, reduces object code size (diff)
downloadkernel-qcow2-linux-8df82c13a3756f831b0d748226ce932515728e04.tar.gz
kernel-qcow2-linux-8df82c13a3756f831b0d748226ce932515728e04.tar.xz
kernel-qcow2-linux-8df82c13a3756f831b0d748226ce932515728e04.zip
libata: make ata_port_type const
Make this const as it is only stored in the const field of a device structure. Make the declaration in header const too. Structure found using Coccinelle and changes done by hand. Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'drivers/ata/libata-core.c')
-rw-r--r--drivers/ata/libata-core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index 65f7574afc55..29e351669353 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -5824,7 +5824,7 @@ void ata_host_resume(struct ata_host *host)
}
#endif
-struct device_type ata_port_type = {
+const struct device_type ata_port_type = {
.name = "ata_port",
#ifdef CONFIG_PM
.pm = &ata_port_pm_ops,