diff --git a/drivers/media/i2c/m5mols/m5mols.h b/drivers/media/i2c/m5mols/m5mols.h index bb589917b65b26b743744ed1c78234060238fb2d..527e7b2965df3a351dc3d5d1ff48614adb4a7eeb 100644 --- a/drivers/media/i2c/m5mols/m5mols.h +++ b/drivers/media/i2c/m5mols/m5mols.h @@ -323,12 +323,12 @@ static inline struct v4l2_subdev *to_sd(struct v4l2_ctrl *ctrl) static inline void m5mols_set_ctrl_mode(struct v4l2_ctrl *ctrl, unsigned int mode) { - ctrl->priv = (void *)mode; + ctrl->priv = (void *)(uintptr_t)mode; } static inline unsigned int m5mols_get_ctrl_mode(struct v4l2_ctrl *ctrl) { - return (unsigned int)ctrl->priv; + return (unsigned int)(uintptr_t)ctrl->priv; } #endif /* M5MOLS_H */ diff --git a/drivers/media/i2c/m5mols/m5mols_controls.c b/drivers/media/i2c/m5mols/m5mols_controls.c index fdbc205a29698a1836b94d1fb9b6d9f8de0e798a..f34429e452abf4e01dfd71d38ceb690d3c5ab021 100644 --- a/drivers/media/i2c/m5mols/m5mols_controls.c +++ b/drivers/media/i2c/m5mols/m5mols_controls.c @@ -463,8 +463,8 @@ static int m5mols_s_ctrl(struct v4l2_ctrl *ctrl) return 0; } - v4l2_dbg(1, m5mols_debug, sd, "%s: %s, val: %d, priv: %#x\n", - __func__, ctrl->name, ctrl->val, (int)ctrl->priv); + v4l2_dbg(1, m5mols_debug, sd, "%s: %s, val: %d, priv: %p\n", + __func__, ctrl->name, ctrl->val, ctrl->priv); if (ctrl_mode && ctrl_mode != info->mode) { ret = m5mols_set_mode(info, ctrl_mode);