Browse Source

crypto: padlock-sha - constify x86_cpu_id

x86_cpu_id are not supposed to change at runtime. MODULE_DEVICE_TABLE
and x86_match_cpu are working with const x86_cpu_id. So mark the
non-const x86_cpu_id structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Arvind Yadav 8 years ago
parent
commit
16d5cee5cf
1 changed files with 1 additions and 1 deletions
  1. 1 1
      drivers/crypto/padlock-sha.c

+ 1 - 1
drivers/crypto/padlock-sha.c

@@ -509,7 +509,7 @@ static struct shash_alg sha256_alg_nano = {
 	}
 	}
 };
 };
 
 
-static struct x86_cpu_id padlock_sha_ids[] = {
+static const struct x86_cpu_id padlock_sha_ids[] = {
 	X86_FEATURE_MATCH(X86_FEATURE_PHE),
 	X86_FEATURE_MATCH(X86_FEATURE_PHE),
 	{}
 	{}
 };
 };