Skip to content

Commit

Permalink
media: v4l2-subdev: Don't use __u32 internally
Browse files Browse the repository at this point in the history
Commit a8fa550 ("media: v4l2-subdev: Verify arguments in
v4l2_subdev_call()") and commit 374d62e ("media: v4l2-subdev:
Verify v4l2_subdev_call() pad config argument") introduced a few local
functions, unfortunately with arguments of type __u32, reserved for use
in Linux uAPI.  Use u32 instead.

Suggested-by: Sakari Ailus <[email protected]>
Signed-off-by: Janusz Krzysztofik <[email protected]>
Acked-by: Sakari Ailus <[email protected]>
Signed-off-by: Hans Verkuil <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
  • Loading branch information
jkrzyszt authored and mchehab committed Nov 5, 2019
1 parent 704c6c8 commit 3cbd3d9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/media/v4l2-core/v4l2-subdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ static int subdev_close(struct file *file)
return 0;
}

static inline int check_which(__u32 which)
static inline int check_which(u32 which)
{
if (which != V4L2_SUBDEV_FORMAT_TRY &&
which != V4L2_SUBDEV_FORMAT_ACTIVE)
Expand All @@ -121,7 +121,7 @@ static inline int check_which(__u32 which)
return 0;
}

static inline int check_pad(struct v4l2_subdev *sd, __u32 pad)
static inline int check_pad(struct v4l2_subdev *sd, u32 pad)
{
#if defined(CONFIG_MEDIA_CONTROLLER)
if (sd->entity.num_pads) {
Expand All @@ -136,7 +136,7 @@ static inline int check_pad(struct v4l2_subdev *sd, __u32 pad)
return 0;
}

static int check_cfg(__u32 which, struct v4l2_subdev_pad_config *cfg)
static int check_cfg(u32 which, struct v4l2_subdev_pad_config *cfg)
{
if (which == V4L2_SUBDEV_FORMAT_TRY && !cfg)
return -EINVAL;
Expand Down

0 comments on commit 3cbd3d9

Please sign in to comment.