Files
openwrt-master/target/linux/bcm27xx/patches-6.6/950-0921-media-ov64a40-Better-check-for-error-on-clk_get.patch
domenico c06fb25d1f
Some checks failed
Build Kernel / Build all affected Kernels (push) Has been cancelled
Build all core packages / Build all core packages for selected target (push) Has been cancelled
Build and Push prebuilt tools container / Build and Push all prebuilt containers (push) Has been cancelled
Build Toolchains / Build Toolchains for each target (push) Has been cancelled
Build host tools / Build host tools for linux and macos based systems (push) Has been cancelled
Coverity scan build / Coverity x86/64 build (push) Has been cancelled
Initial commit
2025-06-24 14:35:53 +02:00

26 lines
894 B
Diff

From 3eadbb7806945ea433cf62867bccfadac3fdb201 Mon Sep 17 00:00:00 2001
From: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
Date: Thu, 29 Feb 2024 09:38:15 +0100
Subject: [PATCH 0921/1085] media: ov64a40: Better check for error on clk_get()
The clk_get() function returns "a valid IS_ERR() condition with
corresponding errno". Use the IS_ERR() macro insted of just checking
for the pointer not being NULL.
Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
---
drivers/media/i2c/ov64a40.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/media/i2c/ov64a40.c
+++ b/drivers/media/i2c/ov64a40.c
@@ -3555,7 +3555,7 @@ static int ov64a40_probe(struct i2c_clie
}
ov64a40->xclk = devm_clk_get(&client->dev, NULL);
- if (!ov64a40->xclk)
+ if (IS_ERR(ov64a40->xclk))
return dev_err_probe(&client->dev, PTR_ERR(ov64a40->xclk),
"Failed to get clock\n");