diff options
author | Wolfram Sang <wsa@the-dreams.de> | 2018-01-18 13:11:32 +0100 |
---|---|---|
committer | Wolfram Sang <wsa@the-dreams.de> | 2018-02-26 20:40:46 +0100 |
commit | 4f3ae38acb3c93cbd8aab9a9fb76d5f661ab578d (patch) | |
tree | 337da4e5f9ed8b18311ef18fb18cfba5fdd3c9d3 /drivers/i2c/i2c-core-of.c | |
parent | c49b0e077594b2cb5531eacd88664badb2635e7f (diff) | |
download | talos-obmc-linux-4f3ae38acb3c93cbd8aab9a9fb76d5f661ab578d.tar.gz talos-obmc-linux-4f3ae38acb3c93cbd8aab9a9fb76d5f661ab578d.zip |
i2c: of: remove duplicated check for valid address
The very same check is done when calling i2c_new_device(). Remove it
here to avoid code duplication.
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c/i2c-core-of.c')
-rw-r--r-- | drivers/i2c/i2c-core-of.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/i2c/i2c-core-of.c b/drivers/i2c/i2c-core-of.c index 4b573ee4a820..bbfff3f61b1f 100644 --- a/drivers/i2c/i2c-core-of.c +++ b/drivers/i2c/i2c-core-of.c @@ -57,12 +57,6 @@ static struct i2c_client *of_i2c_register_device(struct i2c_adapter *adap, info.flags |= I2C_CLIENT_SLAVE; } - if (i2c_check_addr_validity(addr, info.flags)) { - dev_err(&adap->dev, "of_i2c: invalid addr=%x on %pOF\n", - addr, node); - return ERR_PTR(-EINVAL); - } - info.addr = addr; info.archdata = &dev_ad; info.of_node = of_node_get(node); |