summaryrefslogtreecommitdiff
path: root/net/wireless/lib80211_crypt_wep.c
diff options
context:
space:
mode:
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>2024-08-05 08:40:38 +0200
committerJohannes Berg <johannes.berg@intel.com>2024-08-27 10:28:51 +0200
commit1842442007cded42decd8c27ce84cfc570b8f5f4 (patch)
treebbd4471cc92c6b09050dfccfd11166bf8ca9bf2b /net/wireless/lib80211_crypt_wep.c
parent3a3d1afd25ea2e142c78b67fb769df5be7d308c3 (diff)
wifi: lib80211: Constify struct lib80211_crypto_ops
Now that functions in lib80211 handle "const struct lib80211_crypto_ops", some structure can be constified as well. Constifying these structures moves some data to a read-only section, so increase overall security. Before: text data bss dec hex filename 7273 604 16 7893 1ed5 net/wireless/lib80211.o After: text data bss dec hex filename 7429 444 16 7889 1ed1 net/wireless/lib80211.o Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Reviewed-by: Simon Horman <horms@kernel.org> Link: https://patch.msgid.link/0cc3741c15f2c502cc85bddda9d6582b5977c8f9.1722839425.git.christophe.jaillet@wanadoo.fr Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless/lib80211_crypt_wep.c')
-rw-r--r--net/wireless/lib80211_crypt_wep.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/wireless/lib80211_crypt_wep.c b/net/wireless/lib80211_crypt_wep.c
index 6ab9957b8f96..3b148c7bef85 100644
--- a/net/wireless/lib80211_crypt_wep.c
+++ b/net/wireless/lib80211_crypt_wep.c
@@ -226,7 +226,7 @@ static void lib80211_wep_print_stats(struct seq_file *m, void *priv)
seq_printf(m, "key[%d] alg=WEP len=%d\n", wep->key_idx, wep->key_len);
}
-static struct lib80211_crypto_ops lib80211_crypt_wep = {
+static const struct lib80211_crypto_ops lib80211_crypt_wep = {
.name = "WEP",
.init = lib80211_wep_init,
.deinit = lib80211_wep_deinit,