diff options
author | Brian Norris <computersforpeace@gmail.com> | 2012-09-24 20:40:52 -0700 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2012-09-29 15:57:58 +0100 |
commit | e3b88bd604283ef83ae6e8f53622d5b1ffe9d43a (patch) | |
tree | 7263eeadca07ad77f7e9108ba456158b039da502 /virt/kvm | |
parent | f23a481c4e0ccb006470b1c890cc7236ba634e67 (diff) |
mtd: nand: add generic READ ID length calculation functions
When decoding the extended ID bytes of a NAND chip, we have to calculate the ID
length according to some heuristic patterns (e.g., Does the ID wrap around?
Does it end in trailing zeros?). Currently, these heuristics are built into
complicated if/else blocks that can be hard to understand.
Now, these checks can be done generically in a function, making them more
robust and reusable. In fact, this sort of calculation is needed in future
additions to nand_base.c. And with this advancement, we get the added benefit
of a more readable "extended ID decode".
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'virt/kvm')
0 files changed, 0 insertions, 0 deletions