Re: [PATCH 13/13] media: i2c: ds90ub953: Add error handling for i2c reads/writes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 04, 2024 at 05:46:44PM +0300, Tomi Valkeinen wrote:
> Add error handling for i2c reads/writes in various places.

...

> +	ret = ub953_write(priv, UB953_REG_CLKOUT_CTRL1, clkout_ctrl1);
> +	if (ret)
> +		return ret;
> +
> +	return 0;

This is just a more verbose version of

	return ub953_write(priv, UB953_REG_CLKOUT_CTRL1, clkout_ctrl1);

...

> -	ub953_write_clkout_regs(priv, &clkout_data);
> -
> -	return 0;
> +	return ub953_write_clkout_regs(priv, &clkout_data);

...and seems you use that pattern.

-- 
With Best Regards,
Andy Shevchenko






[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux