OSDN Git Service

spi: No need to assign dummy value in spi_unregister_controller()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Sat, 15 Jun 2019 17:41:35 +0000 (20:41 +0300)
committerMark Brown <broonie@kernel.org>
Mon, 17 Jun 2019 12:50:52 +0000 (13:50 +0100)
commitebc37af5e0a134355ea2b62ed4141458bdbd5389
treec75018efc02c6dfced5f6a20f7d3bb97cc909746
parent36f34737ff48f66c8a19b8788311e4b40d4adf80
spi: No need to assign dummy value in spi_unregister_controller()

The device_for_each_child() doesn't require the returned value to be checked.
Thus, drop the dummy variable completely and have no warning anymore:

drivers/spi/spi.c: In function ‘spi_unregister_controller’:
drivers/spi/spi.c:2480:6: warning: variable ‘dummy’ set but not used [-Wunused-but-set-variable]
  int dummy;
      ^~~~~

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi.c