lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Sun, 15 Jan 2017 23:09:29 +0530
From:   Bhumika Goyal <bhumirks@...il.com>
To:     julia.lawall@...6.fr, lgirdwood@...il.com, broonie@...nel.org,
        perex@...ex.cz, tiwai@...e.com, linux-tegra@...r.kernel.org,
        thierry.reding@...il.com, gnurou@...il.com,
        alsa-devel@...a-project.org, linux-kernel@...r.kernel.org
Cc:     Bhumika Goyal <bhumirks@...il.com>
Subject: [PATCH] ASoC: tegra: constify tegra30_ahub_soc_data structures

The tegra30_ahub_soc_data structures are only stored in the data field
of of_device_id structures. This field is of type const, so
tegra30_ahub_soc_data structures having the same property can be
declared const too.

File size before: sound/soc/tegra/tegra30_ahub.o
   text	   data	    bss	    dec	    hex	filename
   7079	    240	      8	   7327	   1c9f	sound/soc/tegra/tegra30_ahub.o

File size after: sound/soc/tegra/tegra30_ahub.o
   text	   data	    bss	    dec	    hex	filename
   7143	    192	      8	   7343	   1caf	sound/soc/tegra/tegra30_ahub.o

Signed-off-by: Bhumika Goyal <bhumirks@...il.com>
---
 sound/soc/tegra/tegra30_ahub.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/sound/soc/tegra/tegra30_ahub.c b/sound/soc/tegra/tegra30_ahub.c
index fef3b9a..e63ef8d 100644
--- a/sound/soc/tegra/tegra30_ahub.c
+++ b/sound/soc/tegra/tegra30_ahub.c
@@ -493,17 +493,17 @@ static bool tegra30_ahub_ahub_wr_rd_reg(struct device *dev, unsigned int reg)
 	.cache_type = REGCACHE_FLAT,
 };
 
-static struct tegra30_ahub_soc_data soc_data_tegra30 = {
+static const struct tegra30_ahub_soc_data soc_data_tegra30 = {
 	.mod_list_mask = MOD_LIST_MASK_TEGRA30,
 	.set_audio_cif = tegra30_ahub_set_cif,
 };
 
-static struct tegra30_ahub_soc_data soc_data_tegra114 = {
+static const struct tegra30_ahub_soc_data soc_data_tegra114 = {
 	.mod_list_mask = MOD_LIST_MASK_TEGRA114,
 	.set_audio_cif = tegra30_ahub_set_cif,
 };
 
-static struct tegra30_ahub_soc_data soc_data_tegra124 = {
+static const struct tegra30_ahub_soc_data soc_data_tegra124 = {
 	.mod_list_mask = MOD_LIST_MASK_TEGRA124,
 	.set_audio_cif = tegra124_ahub_set_cif,
 };
-- 
1.9.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ