i2c: taos-evm: Remove duplicate NULL check

Since i2c_unregister_device() became NULL-aware we may remove duplicate
NULL check.

Signed-off-by: Andy Shevchenko <[email protected]>
Reviewed-by: Jean Delvare <[email protected]>
Signed-off-by: Wolfram Sang <[email protected]>
This commit is contained in:
Andy Shevchenko 2017-10-31 16:21:36 +02:00 • committed by Wolfram Sang
commit bfd9621259

View file

@ -282,8 +282,7 @@ static void taos_disconnect(struct serio *serio)
{
struct taos_data *taos = serio_get_drvdata(serio);
if (taos->client)
i2c_unregister_device(taos->client);
i2c_unregister_device(taos->client);
i2c_del_adapter(&taos->adapter);
serio_close(serio);
kfree(taos);