hwrng: pseries - constify vio_device_id
authorArvind Yadav <arvind.yadav.cs@gmail.com>
Thu, 17 Aug 2017 17:36:23 +0000 (23:06 +0530)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 22 Sep 2017 09:43:05 +0000 (17:43 +0800)
vio_device_id are not supposed to change at runtime. All functions
working with vio_device_id provided by <asm/vio.h> work with
const vio_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/char/hw_random/pseries-rng.c

index d9f46b437cc20d93556957168cc6440c0cb96785..4e2a3f63527725f7cd45cdf3dda286a8fed7ca88 100644 (file)
@@ -72,7 +72,7 @@ static int pseries_rng_remove(struct vio_dev *dev)
        return 0;
 }
 
-static struct vio_device_id pseries_rng_driver_ids[] = {
+static const struct vio_device_id pseries_rng_driver_ids[] = {
        { "ibm,random-v1", "ibm,random"},
        { "", "" }
 };