mtd/omap2: fix dmaengine_slave_config error handling
authorArnd Bergmann <arnd@arndb.de>
Sat, 4 Aug 2012 11:05:25 +0000 (11:05 +0000)
committerArnd Bergmann <arnd@arndb.de>
Fri, 10 Aug 2012 10:27:46 +0000 (12:27 +0200)
commitd680e2c11eb0ddd21ba438b3a537e2eb093ff86f
tree46a94ebf41980f2cc3e25d2a4d8cf26a5a9b2f48
parent38eaed327dc5bea2e5548ea3d195de83a2070c6d
mtd/omap2: fix dmaengine_slave_config error handling

The newly added dmaengine support in the omap2 nand driver
potentially causes an undefined return value from the
omap_nand_probe function when dmaengine_slave_config
reports an error. Let's handle this by returning the
same error back to the caller.

Without this patch, building omap2plus_defconfig results in:

drivers/mtd/nand/omap2.c: In function 'omap_nand_probe':
drivers/mtd/nand/omap2.c:1154:6: warning: 'err' may be used uninitialized in this function [-Wuninitialized]

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Cc: Russell King <rmk+kernel@arm.linux.org.uk>
Cc: Grazvydas Ignotas <notasas@gmail.com>
drivers/mtd/nand/omap2.c
This page took 0.032425 seconds and 5 git commands to generate.