diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2017-10-31 16:21:37 +0200 |
---|---|---|
committer | Wolfram Sang <wsa@the-dreams.de> | 2017-11-02 00:01:31 +0100 |
commit | 620c50dc0b301f09b85ce27022d8f7420bf14e7f (patch) | |
tree | 451106fca4d9f2fbd1b9a597ba3f024f7261af3e /drivers/i2c/busses | |
parent | bfd9621259970904b25ad198030275328f09ed46 (diff) |
i2c: thunderx: Remove duplicate NULL check
Since i2c_unregister_device() became NULL-aware we may remove duplicate
NULL check.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c/busses')
-rw-r--r-- | drivers/i2c/busses/i2c-thunderx-pcidrv.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/i2c/busses/i2c-thunderx-pcidrv.c b/drivers/i2c/busses/i2c-thunderx-pcidrv.c index 1a7cad874756..19f8eec38717 100644 --- a/drivers/i2c/busses/i2c-thunderx-pcidrv.c +++ b/drivers/i2c/busses/i2c-thunderx-pcidrv.c @@ -143,8 +143,7 @@ static int thunder_i2c_smbus_setup(struct octeon_i2c *i2c, static void thunder_i2c_smbus_remove(struct octeon_i2c *i2c) { - if (i2c->ara) - i2c_unregister_device(i2c->ara); + i2c_unregister_device(i2c->ara); } static int thunder_i2c_probe_pci(struct pci_dev *pdev, |