Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1596454 > unrolled thread
| Started by | simran singhal <singhalsimran0@gmail.com> |
|---|---|
| First post | 2017-03-10 00:00 +0100 |
| Last post | 2017-03-10 00:00 +0100 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH v1 6/7] staging: gc2235: Use x instead of x != NULL simran singhal <singhalsimran0@gmail.com> - 2017-03-10 00:00 +0100
| From | simran singhal <singhalsimran0@gmail.com> |
|---|---|
| Date | 2017-03-10 00:00 +0100 |
| Subject | [PATCH v1 6/7] staging: gc2235: Use x instead of x != NULL |
| Message-ID | <tjfcm-3bj-13@gated-at.bofh.it> |
Use x instead of x != NULL . This patch removes the explicit NULL comparisons.This issue is found by checkpatch.pl script. Signed-off-by: simran singhal <singhalsimran0@gmail.com> --- drivers/staging/media/atomisp/i2c/gc2235.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/staging/media/atomisp/i2c/gc2235.c b/drivers/staging/media/atomisp/i2c/gc2235.c index 165dcb3..40a5a2f 100644 --- a/drivers/staging/media/atomisp/i2c/gc2235.c +++ b/drivers/staging/media/atomisp/i2c/gc2235.c @@ -255,7 +255,7 @@ static int gc2235_get_intg_factor(struct i2c_client *client, u16 reg_val, reg_val_h, dummy; int ret; - if (info == NULL) + if (!info) return -EINVAL; /* pixel clock calculattion */ @@ -797,7 +797,7 @@ static int gc2235_set_fmt(struct v4l2_subdev *sd, int idx; gc2235_info = v4l2_get_subdev_hostdata(sd); - if (gc2235_info == NULL) + if (!gc2235_info) return -EINVAL; if (format->pad) return -EINVAL; @@ -917,7 +917,7 @@ static int gc2235_s_config(struct v4l2_subdev *sd, struct i2c_client *client = v4l2_get_subdevdata(sd); int ret = 0; - if (platform_data == NULL) + if (!platform_data) return -ENODEV; dev->platform_data = -- 2.7.4
Back to top | Article view | linux.kernel
csiph-web