linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] [media] mt9t001: constify v4l2_subdev_internal_ops structure
@ 2015-10-11 11:57 Julia Lawall
  2015-11-09 14:34 ` Laurent Pinchart
  0 siblings, 1 reply; 2+ messages in thread
From: Julia Lawall @ 2015-10-11 11:57 UTC (permalink / raw)
  To: Laurent Pinchart
  Cc: kernel-janitors, Mauro Carvalho Chehab, linux-media, linux-kernel

This v4l2_subdev_internal_ops structure is never modified.  All other
v4l2_subdev_internal_ops structures are declared as const.

Done with the help of Coccinelle.

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
 drivers/media/i2c/mt9t001.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/i2c/mt9t001.c b/drivers/media/i2c/mt9t001.c
index 8ae99f7..4383a5d 100644
--- a/drivers/media/i2c/mt9t001.c
+++ b/drivers/media/i2c/mt9t001.c
@@ -834,7 +834,7 @@ static struct v4l2_subdev_ops mt9t001_subdev_ops = {
 	.pad = &mt9t001_subdev_pad_ops,
 };
 
-static struct v4l2_subdev_internal_ops mt9t001_subdev_internal_ops = {
+static const struct v4l2_subdev_internal_ops mt9t001_subdev_internal_ops = {
 	.registered = mt9t001_registered,
 	.open = mt9t001_open,
 	.close = mt9t001_close,


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] [media] mt9t001: constify v4l2_subdev_internal_ops structure
  2015-10-11 11:57 [PATCH] [media] mt9t001: constify v4l2_subdev_internal_ops structure Julia Lawall
@ 2015-11-09 14:34 ` Laurent Pinchart
  0 siblings, 0 replies; 2+ messages in thread
From: Laurent Pinchart @ 2015-11-09 14:34 UTC (permalink / raw)
  To: Julia Lawall
  Cc: kernel-janitors, Mauro Carvalho Chehab, linux-media, linux-kernel

Hi Julia,

Thank you for the patch.

On Sunday 11 October 2015 13:57:13 Julia Lawall wrote:
> This v4l2_subdev_internal_ops structure is never modified.  All other
> v4l2_subdev_internal_ops structures are declared as const.
> 
> Done with the help of Coccinelle.
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

and applied to my tree.

> ---
>  drivers/media/i2c/mt9t001.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/media/i2c/mt9t001.c b/drivers/media/i2c/mt9t001.c
> index 8ae99f7..4383a5d 100644
> --- a/drivers/media/i2c/mt9t001.c
> +++ b/drivers/media/i2c/mt9t001.c
> @@ -834,7 +834,7 @@ static struct v4l2_subdev_ops mt9t001_subdev_ops = {
>  	.pad = &mt9t001_subdev_pad_ops,
>  };
> 
> -static struct v4l2_subdev_internal_ops mt9t001_subdev_internal_ops = {
> +static const struct v4l2_subdev_internal_ops mt9t001_subdev_internal_ops =
> { .registered = mt9t001_registered,
>  	.open = mt9t001_open,
>  	.close = mt9t001_close,

-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-11-09 14:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-11 11:57 [PATCH] [media] mt9t001: constify v4l2_subdev_internal_ops structure Julia Lawall
2015-11-09 14:34 ` Laurent Pinchart

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).