]> www.infradead.org Git - mtd-utils.git/commit
mtd-utils: nandwrite: Clarify usage of aligned "erasesize"
authorBrian Norris <computersforpeace@gmail.com>
Wed, 3 Nov 2010 08:27:20 +0000 (01:27 -0700)
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Sat, 13 Nov 2010 11:42:37 +0000 (13:42 +0200)
commit1bbaf1e86a75cdafc4b445db6b9a6d60322b928e
treeffc385cc23364dd34f54c90e7e5d9bab384b18ca
parentd96b3e1775d254cc56dafad6bf824cdffb0e09fa
mtd-utils: nandwrite: Clarify usage of aligned "erasesize"

Due to the presence of the "--block-align" flag, nandwrite uses a
blocksize throughout that, depeding on the execution parameters, may
not be the actual erasesize of the NAND flash. In order to clarify
this situation for the untrained viewer of nandwrite's code, we should
not change the value of "meminfo.erasesize" itself; rather, we can
utilize a separate, calculated "ebsize_aligned". Then, when a user
actually wants to refer to the physical erasesize, it's straightforward.

Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
nandwrite.c