]> git.baikalelectronics.ru Git - uboot.git/commit
spi: mxc_spi: fix warnings if CLK_ENABLED not set
authorStefano Babic <sbabic@denx.de>
Sat, 10 Jul 2021 14:31:29 +0000 (16:31 +0200)
committerStefano Babic <sbabic@denx.de>
Sat, 10 Jul 2021 16:14:54 +0000 (18:14 +0200)
commit0a179dfcba418013de7bd1e17f2a2521ac06f978
tree8afee9668af5b251d4e671a8d7489651ae9b946e
parent00db4840252d614b4ffa174add270e21bbecef85
spi: mxc_spi: fix warnings if CLK_ENABLED not set

Following warnings (unused variables) are raised:

drivers/spi/mxc_spi.c: In function 'mxc_spi_probe':
drivers/spi/mxc_spi.c:595:14: error: unused variable 'blob' [-Werror=unused-variable]
595 |  const void *blob = gd->fdt_blob;
    |              ^~~~
drivers/spi/mxc_spi.c:594:6: error: unused variable 'node' [-Werror=unused-variable]
594 |  int node = dev_of_offset(bus);

Move the variable declaration inside the code where they are used.

Signed-off-by: Stefano Babic <sbabic@denx.de>
drivers/spi/mxc_spi.c