nand: Send device tree partitions to kernel

With the GPT on SPI, it is easier for depthcharge to parse the GPT
than the kernel. The NAND design is that depthcharge will parse the
GPT and then send it to the kernel through the device tree. No
kernel changes are required, and the interface will be maintained
when vboot2 kernel selection is used and the partition table is
stored differently.

TEST=Booted from NAND with a partition table that just includes
the kernel at partition 1, and observed the following:
root@localhost $ cat /proc/mtd
dev:    size   erasesize  name
mtd0: 40000000 00040000 "device"
mtd1: 01000000 00040000 "KERN-A"
TEST=Put the kernel partition at partition 2 and observed the
boot to fail (since the numbering would mismatch)
TEST=Observed booting success with two partitions
BRANCH=none
BUG=chromium:403432

Signed-off-by: Dan Ehrenberg <dehrenberg@chromium.org>

Change-Id: Ic612b0c5e1f55805c11ed6fae90bf9b5f63658be
Reviewed-on: https://chromium-review.googlesource.com/225100
Reviewed-by: Julius Werner <jwerner@chromium.org>
Commit-Queue: Daniel Ehrenberg <dehrenberg@chromium.org>
Tested-by: Daniel Ehrenberg <dehrenberg@chromium.org>
3 files changed