[PATCH] staging: media: atomisp: remove unnecessary parentheses

Ali Nasrollahi posted 1 patch 2 months ago
drivers/staging/media/atomisp/i2c/atomisp-ov2722.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[PATCH] staging: media: atomisp: remove unnecessary parentheses
Posted by Ali Nasrollahi 2 months ago
Remove unnecessary parentheses around comparison expressions in ov2722.c
to be alinged with kernel coding style. This patch is only cosmetic and
does not change the logic.

Signed-off-by: Ali Nasrollahi <A.Nasrolahi01@gmail.com>
---
 drivers/staging/media/atomisp/i2c/atomisp-ov2722.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c b/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
index 2c41c496daa6..475bc521651b 100644
--- a/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
+++ b/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
@@ -731,7 +731,7 @@ static int ov2722_detect(struct i2c_client *client)
 			OV2722_SC_CMMN_CHIP_ID_L, &low);
 	id = (high << 8) | low;
 
-	if ((id != OV2722_ID) && (id != OV2720_ID)) {
+	if (id != OV2722_ID && id != OV2720_ID) {
 		dev_err(&client->dev, "sensor ID error\n");
 		return -ENODEV;
 	}
-- 
2.55.0
Re: [PATCH] staging: media: atomisp: remove unnecessary parentheses
Posted by Dan Carpenter 2 months ago
On Fri, Jul 31, 2026 at 09:03:10PM +0330, Ali Nasrollahi wrote:
> Remove unnecessary parentheses around comparison expressions in ov2722.c
> to be alinged with kernel coding style. This patch is only cosmetic and
> does not change the logic.
> 
> Signed-off-by: Ali Nasrollahi <A.Nasrolahi01@gmail.com>
> ---

How are you even seeing this checkpatch warning?  I disabled it
for staging.  Just leave it as-is.

You didn't CC the maintainers for this.  Next time use:
./scripts/get_maintainer.pl -f drivers/staging/media/atomisp/i2c/atomisp-ov2722.c

regards,
dan carpenter
Re: [PATCH] staging: media: atomisp: remove unnecessary parentheses
Posted by Ali Nasrollahi 1 month, 4 weeks ago
On 26/08/01 12:18AM, Dan Carpenter wrote:
> On Fri, Jul 31, 2026 at 09:03:10PM +0330, Ali Nasrollahi wrote:
> > Remove unnecessary parentheses around comparison expressions in ov2722.c
> > to be alinged with kernel coding style. This patch is only cosmetic and
> > does not change the logic.
> > 
> > Signed-off-by: Ali Nasrollahi <A.Nasrolahi01@gmail.com>
> > ---
> 
> How are you even seeing this checkpatch warning?  I disabled it
> for staging.  Just leave it as-is.
> 
> You didn't CC the maintainers for this.  Next time use:
> ./scripts/get_maintainer.pl -f drivers/staging/media/atomisp/i2c/atomisp-ov2722.c

Thank you for the reply; I will.
-Ali