Skip to content
Commit 2b6f0090 authored by Boris Brezillon's avatar Boris Brezillon
Browse files

mtd: Check add_mtd_device() ret code



add_mtd_device() can fail. We should always check its return value
and gracefully handle the failure case. Fix the call sites where this
not done (in mtdpart.c) and add a __must_check attribute to the
prototype to avoid this kind of mistakes.

Signed-off-by: default avatarBoris Brezillon <bbrezillon@kernel.org>
parent 19e16fb4
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment