phram: cleanup error handling and associated messages
commit64da392ab08a88ad83f4c3f60283711ee090c9ef
authorMike Frysinger <vapier@gentoo.org>
Tue, 16 Jun 2009 19:20:40 +0000 (16 19:20 +0000)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Sat, 19 Sep 2009 20:11:12 +0000 (19 13:11 -0700)
treeb9980fa27bb3dd9edb3563a8ccf75ea7ab79a091
parentaa3651e4625e21c2eb8a8e504d9bbc3c2a964be0
phram: cleanup error handling and associated messages

The error handling in the phram driver is pretty bad -- in many places,
errors are silently ignored or logged, but then still ignored in the
return value.  So convert all of the code to pass back the correct return
value and log error messages properly (and using the new pr_fmt() helper).

If everything does go smoothly, rather than exit silently, dump a helpful
info message like pretty much every other MTD driver does.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Acked-by: Joern Engel <joern@logfs.org>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/mtd/devices/phram.c