summaryrefslogtreecommitdiff
path: root/drivers/mtd/sm_ftl.c
diff options
context:
space:
mode:
authorBrian Norris <computersforpeace@gmail.com>2014-07-21 19:06:27 -0700
committerBrian Norris <computersforpeace@gmail.com>2014-08-19 11:53:07 -0700
commit0c2b4e21444d0e274e91fc7db85caddb30988853 (patch)
tree32be90002a86d1fe29f1675c1baed664bcf290ff /drivers/mtd/sm_ftl.c
parent36c6a7ac74044b8025488c018279115bb3c32eb0 (diff)
mtd: correct upper bounds check for mtd_*() APIs
When checking the upper boundary (i.e., whether an address is higher than the maximum size of the MTD), we should be doing an inclusive check (greater or equal). For instance, an address of 16MB (0x1000000) on a 16MB device is invalid. The strengthening of this bounds check is redundant for those which already have a address+length check and ensure that the length is non-zero, but let's just fix them all, for completeness. Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Diffstat (limited to 'drivers/mtd/sm_ftl.c')
0 files changed, 0 insertions, 0 deletions