From ece550b5758645809876e6e7862bf485c3a8d15c Mon Sep 17 00:00:00 2001 From: Bhumika Goyal Date: Mon, 16 Oct 2017 17:18:42 +0200 Subject: target: make config_item_type const Make these structures const as they are either passed to the functions having the argument as const or stored as a reference in the "ci_type" const field of a config_item structure. Done using Coccinelle. Signed-off-by: Bhumika Goyal Signed-off-by: Christoph Hellwig --- drivers/target/target_core_stat.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'drivers/target/target_core_stat.c') diff --git a/drivers/target/target_core_stat.c b/drivers/target/target_core_stat.c index 8038255b21e8..f0db91ebd735 100644 --- a/drivers/target/target_core_stat.c +++ b/drivers/target/target_core_stat.c @@ -96,7 +96,7 @@ static struct configfs_attribute *target_stat_scsi_dev_attrs[] = { NULL, }; -static struct config_item_type target_stat_scsi_dev_cit = { +static const struct config_item_type target_stat_scsi_dev_cit = { .ct_attrs = target_stat_scsi_dev_attrs, .ct_owner = THIS_MODULE, }; @@ -193,7 +193,7 @@ static struct configfs_attribute *target_stat_scsi_tgt_dev_attrs[] = { NULL, }; -static struct config_item_type target_stat_scsi_tgt_dev_cit = { +static const struct config_item_type target_stat_scsi_tgt_dev_cit = { .ct_attrs = target_stat_scsi_tgt_dev_attrs, .ct_owner = THIS_MODULE, }; @@ -414,7 +414,7 @@ static struct configfs_attribute *target_stat_scsi_lu_attrs[] = { NULL, }; -static struct config_item_type target_stat_scsi_lu_cit = { +static const struct config_item_type target_stat_scsi_lu_cit = { .ct_attrs = target_stat_scsi_lu_attrs, .ct_owner = THIS_MODULE, }; @@ -540,7 +540,7 @@ static struct configfs_attribute *target_stat_scsi_port_attrs[] = { NULL, }; -static struct config_item_type target_stat_scsi_port_cit = { +static const struct config_item_type target_stat_scsi_port_cit = { .ct_attrs = target_stat_scsi_port_attrs, .ct_owner = THIS_MODULE, }; @@ -724,7 +724,7 @@ static struct configfs_attribute *target_stat_scsi_tgt_port_attrs[] = { NULL, }; -static struct config_item_type target_stat_scsi_tgt_port_cit = { +static const struct config_item_type target_stat_scsi_tgt_port_cit = { .ct_attrs = target_stat_scsi_tgt_port_attrs, .ct_owner = THIS_MODULE, }; @@ -844,7 +844,7 @@ static struct configfs_attribute *target_stat_scsi_transport_attrs[] = { NULL, }; -static struct config_item_type target_stat_scsi_transport_cit = { +static const struct config_item_type target_stat_scsi_transport_cit = { .ct_attrs = target_stat_scsi_transport_attrs, .ct_owner = THIS_MODULE, }; @@ -1206,7 +1206,7 @@ static struct configfs_attribute *target_stat_scsi_auth_intr_attrs[] = { NULL, }; -static struct config_item_type target_stat_scsi_auth_intr_cit = { +static const struct config_item_type target_stat_scsi_auth_intr_cit = { .ct_attrs = target_stat_scsi_auth_intr_attrs, .ct_owner = THIS_MODULE, }; @@ -1378,7 +1378,7 @@ static struct configfs_attribute *target_stat_scsi_ath_intr_port_attrs[] = { NULL, }; -static struct config_item_type target_stat_scsi_att_intr_port_cit = { +static const struct config_item_type target_stat_scsi_att_intr_port_cit = { .ct_attrs = target_stat_scsi_ath_intr_port_attrs, .ct_owner = THIS_MODULE, }; -- cgit v1.2.3