drivers: rtc: pcf8536: Remove redundant variable
Subsystems (5)
Arm i.MX and Layerscape GPIO Voltage and current regulator framework Real time clock (RTC) +1 more subsystems
PATCH 1/6 drivers: rtc: pcf8536: Remove redundant variable
Signed-off-by Alexander Shiyan <[email protected]>
--- drivers/rtc/rtc-pcf85363.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/rtc/rtc-pcf85363.c +1 -4
@@ -131,7 +131,6 @@ static int pcf85363_probe(struct device_d *dev)struct i2c_client *client =to_i2c_client (dev);struct pcf85363 *pcf85363;struct regmap *regmap; -int ret; regmap =regmap_init_i2c (client, &pcf85363_regmap_i2c_config);
@@ -147,9 +146,7 @@ static int pcf85363_probe(struct device_d *dev) pcf85363->rtc.ops = &rtc_ops; pcf85363->rtc.dev = dev; - ret =rtc_register (&pcf85363->rtc); - -return ret; +return rtc_register (&pcf85363->rtc); }static struct platform_device_id dev_ids[] = {
Signature · 1 line
2.32.0
PATCH 2/6 drivers: rtc: abracon: Remove redundant variable
Signed-off-by Alexander Shiyan <[email protected]>
--- drivers/rtc/rtc-abracon.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/rtc/rtc-abracon.c +1 -4
@@ -84,7 +84,6 @@ static int abracon_probe(struct device_d *dev) {struct i2c_client *client =to_i2c_client (dev);struct abracon *abracon; -int ret; abracon =xzalloc (sizeof (*abracon));
@@ -93,9 +92,7 @@ static int abracon_probe(struct device_d *dev) abracon->rtc.ops = &ds13xx_rtc_ops; abracon->rtc.dev = dev; - ret =rtc_register (&abracon->rtc); - -return ret; +return rtc_register (&abracon->rtc); };static struct platform_device_id abracon_id[] = {
Signature · 1 line
2.32.0
PATCH 3/6 drivers: regulator: fixed: Fix error path in probe
In reply to Alexander ShiyanSigned-off-by Alexander Shiyan <[email protected]>
--- drivers/regulator/fixed.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/regulator/fixed.c +2 -3
@@ -78,10 +78,9 @@ static int regulator_fixed_probe(struct device_d *dev) } ret =of_regulator_register (&fix->rdev, dev->device_node); -if (ret) -return ret; +if (!ret) +return 0 ; -return 0 ; err:free (fix);
Signature · 1 line
2.32.0
PATCH 4/6 drivers: pwm: imx: Remove redundant assignment
In reply to Alexander ShiyanSigned-off-by Alexander Shiyan <[email protected]>
--- drivers/pwm/pwm-imx.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-)
drivers/pwm/pwm-imx.c +2 -6
@@ -206,7 +206,7 @@ static int imx_pwm_probe(struct device_d *dev)struct resource *iores;const struct imx_pwm_data *data;struct imx_chip *imx; -int ret =0 ; +int ret; ret =dev_get_drvdata (dev, (const void **)&data);if (ret)
@@ -236,11 +236,7 @@ static int imx_pwm_probe(struct device_d *dev) imx->config = data->config; imx->set_enable = data->set_enable; - ret =pwmchip_add (&imx->chip, dev); -if (ret <0 ) -return ret; - -return 0 ; +return pwmchip_add (&imx->chip, dev);; }static struct driver_d imx_pwm_driver = {
Signature · 1 line
2.32.0
PATCH 5/6 drivers: gpio: pcf857x: Remove redundant assignment
In reply to Alexander ShiyanSigned-off-by Alexander Shiyan <[email protected]>
--- drivers/gpio/gpio-pcf857x.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)
drivers/gpio/gpio-pcf857x.c +1 -5
@@ -219,11 +219,7 @@ static int pcf857x_probe(struct device_d *dev)*/ gpio->out = ~n_latch; - ret =gpiochip_add (&gpio->chip); -if (ret) -return ret; - -return ret; +return gpiochip_add (&gpio->chip); }static const struct of_device_id pcf857x_dt_ids[] = {
Signature · 1 line
2.32.0
PATCH 6/6 drivers: led: pca955x: Remove redundant assignment
In reply to Alexander ShiyanSigned-off-by Alexander Shiyan <[email protected]>
--- drivers/led/led-pca955x.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/led/led-pca955x.c +2 -3
@@ -387,11 +387,10 @@ static int led_pca955x_probe(struct device_d *dev) err =pca955x_write_psc (client,0 ,0 );if (err)return err; + err =pca955x_write_psc (client,1 ,0 ); -if (err) -return err; -return 0 ; +return err; }static struct driver_d led_pca955x_driver = {
Signature · 1 line
2.32.0
Sascha Hauer
AppliedQuoted 4 lines · Alexander Shiyan
Signed-off-by Alexander Shiyan <[email protected]>--- drivers/rtc/rtc-pcf85363.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
Applied, thanks
Sascha
Quoted 29 lines
drivers/rtc/rtc-pcf85363.c +1
-4@@ -131,7 +131,6 @@ static int pcf85363_probe(struct device_d *dev)struct i2c_client *client =to_i2c_client (dev);struct pcf85363 *pcf85363;struct regmap *regmap; -int ret; regmap =regmap_init_i2c (client, &pcf85363_regmap_i2c_config);@@ -147,9 +146,7 @@ static int pcf85363_probe(struct device_d *dev) pcf85363->rtc.ops = &rtc_ops; pcf85363->rtc.dev = dev; - ret =rtc_register (&pcf85363->rtc); - -return ret; +return rtc_register (&pcf85363->rtc); }static struct platform_device_id dev_ids[] = {Signature · 1 line
2.32.0
Signature · 4 lines
Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |