From: Brian Norris Date: Sat, 14 Dec 2013 05:19:58 +0000 (-0800) Subject: mtd: nand-gpio: don't waste memory for OF failure X-Git-Tag: v3.14-rc1~65^2~34 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=103cdd8520b5ec85ab4345f54db5cc32a517f468;p=pandora-kernel.git mtd: nand-gpio: don't waste memory for OF failure We shouldn't try to allocate a resource until we're sure the of_property_read_u64() call didn't fail. This is especially important if we use this code for both CONFIG_OF and !CONFIG_OF builds, since of_property_read_u64() will always return -ENOSYS for !CONFIG_OF. Signed-off-by: Brian Norris --- Reading git-diff-tree failed