i2c: tegra: drop duplicated code for assigning algo
authorBarry Song <21cnbao@gmail.com>
Mon, 7 Sep 2015 03:08:55 +0000 (03:08 +0000)
committerWolfram Sang <wsa@the-dreams.de>
Tue, 20 Oct 2015 15:38:19 +0000 (17:38 +0200)
This code is repeated in probe:
i2c_dev->adapter.algo = &tegra_i2c_algo;

Cc: Donglin Peng <pengdonglin137@163.com>
Signed-off-by: Barry Song <21cnbao@gmail.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/busses/i2c-tegra.c

index b7e1a36..a0522fc 100644 (file)
@@ -873,7 +873,6 @@ static int tegra_i2c_probe(struct platform_device *pdev)
        i2c_dev->adapter.class = I2C_CLASS_DEPRECATED;
        strlcpy(i2c_dev->adapter.name, "Tegra I2C adapter",
                sizeof(i2c_dev->adapter.name));
-       i2c_dev->adapter.algo = &tegra_i2c_algo;
        i2c_dev->adapter.dev.parent = &pdev->dev;
        i2c_dev->adapter.nr = pdev->id;
        i2c_dev->adapter.dev.of_node = pdev->dev.of_node;