forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-12-19 9370bb92b2d16684ee45cf24e879c93c509162da
kernel/drivers/media/i2c/s5k6a3.c
....@@ -1,12 +1,9 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Samsung S5K6A3 image sensor driver
34 *
45 * Copyright (C) 2013 Samsung Electronics Co., Ltd.
56 * Author: Sylwester Nawrocki <s.nawrocki@samsung.com>
6
- *
7
- * This program is free software; you can redistribute it and/or modify
8
- * it under the terms of the GNU General Public License version 2 as
9
- * published by the Free Software Foundation.
107 */
118
129 #include <linux/clk.h>
....@@ -200,7 +197,7 @@
200197
201198 ret = pm_runtime_get(sensor->dev);
202199 if (ret < 0)
203
- return ret;
200
+ goto error_rpm_put;
204201
205202 ret = regulator_enable(sensor->supplies[i].consumer);
206203 if (ret < 0)
....@@ -278,8 +275,7 @@
278275 .pad = &s5k6a3_pad_ops,
279276 };
280277
281
-static int s5k6a3_probe(struct i2c_client *client,
282
- const struct i2c_device_id *id)
278
+static int s5k6a3_probe(struct i2c_client *client)
283279 {
284280 struct device *dev = &client->dev;
285281 struct s5k6a3 *sensor;
....@@ -381,7 +377,7 @@
381377 .of_match_table = of_match_ptr(s5k6a3_of_match),
382378 .name = S5K6A3_DRV_NAME,
383379 },
384
- .probe = s5k6a3_probe,
380
+ .probe_new = s5k6a3_probe,
385381 .remove = s5k6a3_remove,
386382 .id_table = s5k6a3_ids,
387383 };