Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit b4ccc4d2 authored by Kuppuswamy Sathyanarayanan's avatar Kuppuswamy Sathyanarayanan Committed by Lee Jones
Browse files

mfd: bxtwc: Remove unnecessary i2c_addr checks in ipc calls



In the following code block, BXTWC_DEVICE1_ADDR value is
already fixed and hence there no need to check for
if (!i2c_addr) in every ipc read/write calls. Even if this
check is required it can be moved to probe function.

i2c_addr = BXTWC_DEVICE1_ADDR;
if (!i2c_addr) {
	dev_err(pmic->dev, "I2C address not set\n");
	return -EINVAL;
}

This patch remove this extra check and adds some NULL
parameter checks.

Signed-off-by: default avatarKuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
parent 4407319d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment