diff --git a/drivers/base/platform.c b/drivers/base/platform.c index 937d58021d1b36e3fc069c8e960212ada9c5977a..575e08bc6630b7f01b94fb9f2b5051d2d6ede8dc 100644 --- a/drivers/base/platform.c +++ b/drivers/base/platform.c @@ -636,7 +636,7 @@ static int platform_uevent(struct device *dev, struct kobj_uevent_env *env) } static const struct platform_device_id *platform_match_id( - struct platform_device_id *id, + const struct platform_device_id *id, struct platform_device *pdev) { while (id->name[0]) { diff --git a/include/linux/platform_device.h b/include/linux/platform_device.h index 2c2d035bfb927799ad73e8f22e0845c976439bf3..212da17d06afa66fb07749b6498aa4f3d4f6f727 100644 --- a/include/linux/platform_device.h +++ b/include/linux/platform_device.h @@ -62,7 +62,7 @@ struct platform_driver { int (*suspend)(struct platform_device *, pm_message_t state); int (*resume)(struct platform_device *); struct device_driver driver; - struct platform_device_id *id_table; + const struct platform_device_id *id_table; }; extern int platform_driver_register(struct platform_driver *);