[PATCH v4 9/9] staging: media: atomisp: remove unwanted dev_*() calls

Deepak R Varma
2021-04-28T18:11:13Z

Delete diagnostic messages that only print the function name. We can use
ftrace for such debugging. The clean up also enables removing (now) unused
device pointers.

Suggested-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Deepak R Varma <drv@mailo.com>
---

Changes since v3:
- Patch introduced based on other patch review feedback
Changes since v2:
- Patch not part of set
Changes since v1:
- Patch not part of set

drivers/staging/media/atomisp/i2c/atomisp-gc0310.c | 2 --
drivers/staging/media/atomisp/i2c/atomisp-gc2235.c | 2 --
drivers/staging/media/atomisp/i2c/atomisp-ov2680.c | 7 -------
drivers/staging/media/atomisp/i2c/atomisp-ov2722.c | 2 --
4 files changed, 13 deletions(-)

diff --git a/drivers/staging/media/atomisp/i2c/atomisp-gc0310.c b/drivers/staging/media/atomisp/i2c/atomisp-gc0310.c
index 5f1929a49b07..d5acd261c977 100644
--- a/drivers/staging/media/atomisp/i2c/atomisp-gc0310.c
+++ b/drivers/staging/media/atomisp/i2c/atomisp-gc0310.c
@@ -1276,8 +1276,6 @@ static int gc0310_remove(struct i2c_client *client)
struct v4l2_subdev *sd = i2c_get_clientdata(client);
struct gc0310_device *dev = to_gc0310_sensor(sd);

- dev_dbg(&client->dev, "%s...\n", __func__);
-
dev->platform_data->csi_cfg(sd, 0);

v4l2_device_unregister_subdev(sd);
diff --git a/drivers/staging/media/atomisp/i2c/atomisp-gc2235.c b/drivers/staging/media/atomisp/i2c/atomisp-gc2235.c
index 6ee6e8414f0e..0b95b738af0e 100644
--- a/drivers/staging/media/atomisp/i2c/atomisp-gc2235.c
+++ b/drivers/staging/media/atomisp/i2c/atomisp-gc2235.c
@@ -1037,8 +1037,6 @@ static int gc2235_remove(struct i2c_client *client)
struct v4l2_subdev *sd = i2c_get_clientdata(client);
struct gc2235_device *dev = to_gc2235_sensor(sd);

- dev_dbg(&client->dev, "%s...\n", __func__);
-
dev->platform_data->csi_cfg(sd, 0);

v4l2_device_unregister_subdev(sd);
diff --git a/drivers/staging/media/atomisp/i2c/atomisp-ov2680.c b/drivers/staging/media/atomisp/i2c/atomisp-ov2680.c
index d5fa3ea624ef..708288d6addc 100644
--- a/drivers/staging/media/atomisp/i2c/atomisp-ov2680.c
+++ b/drivers/staging/media/atomisp/i2c/atomisp-ov2680.c
@@ -144,9 +144,7 @@ static int ov2680_g_fnumber_range(struct v4l2_subdev *sd, s32 *val)
static int ov2680_g_bin_factor_x(struct v4l2_subdev *sd, s32 *val)
{
struct ov2680_device *dev = to_ov2680_sensor(sd);
- struct i2c_client *client = v4l2_get_subdevdata(sd);

- dev_dbg(&client->dev, "++++%s\n", __func__);
*val = ov2680_res[dev->fmt_idx].bin_factor_x;

return 0;
@@ -155,10 +153,8 @@ static int ov2680_g_bin_factor_x(struct v4l2_subdev *sd, s32 *val)
static int ov2680_g_bin_factor_y(struct v4l2_subdev *sd, s32 *val)
{
struct ov2680_device *dev = to_ov2680_sensor(sd);
- struct i2c_client *client = v4l2_get_subdevdata(sd);

*val = ov2680_res[dev->fmt_idx].bin_factor_y;
- dev_dbg(&client->dev, "++++%s\n", __func__);
return 0;
}

@@ -173,7 +169,6 @@ static int ov2680_get_intg_factor(struct i2c_client *client,
u16 reg_val;
int ret;

- dev_dbg(&client->dev, "++++%s\n", __func__);
if (!info)
return -EINVAL;

@@ -1232,8 +1227,6 @@ static int ov2680_remove(struct i2c_client *client)
struct v4l2_subdev *sd = i2c_get_clientdata(client);
struct ov2680_device *dev = to_ov2680_sensor(sd);

- dev_dbg(&client->dev, "%s...\n", __func__);
-
dev->platform_data->csi_cfg(sd, 0);

v4l2_device_unregister_subdev(sd);
diff --git a/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c b/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
index 69409f8447b5..4ed268e5e1b7 100644
--- a/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
+++ b/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
@@ -1175,8 +1175,6 @@ static int ov2722_remove(struct i2c_client *client)
struct v4l2_subdev *sd = i2c_get_clientdata(client);
struct ov2722_device *dev = to_ov2722_sensor(sd);

- dev_dbg(&client->dev, "%s...\n", __func__);
-
dev->platform_data->csi_cfg(sd, 0);
v4l2_ctrl_handler_free(&dev->ctrl_handler);
v4l2_device_unregister_subdev(sd);
--
2.31.1