nvram: Introduce helper functions for CHRP "system" and "free space" partitions
commit55d9950aaa8e87372cfae2a7efc810f078f36818
authorThomas Huth <thuth@redhat.com>
Tue, 18 Oct 2016 20:46:40 +0000 (18 22:46 +0200)
committerDavid Gibson <david@gibson.dropbear.id.au>
Thu, 27 Oct 2016 22:36:58 +0000 (28 09:36 +1100)
tree380dd8412616b8579230f40a90c1cf32364fecac
parent4bcfa56ca9f6970974255dd5621b08e5aa9e5af5
nvram: Introduce helper functions for CHRP "system" and "free space" partitions

The "system partition" and "free space" partition layouts are
defined by the CHRP and LoPAPR specification, and used by
OpenBIOS and SLOF. We can re-use this code for other machines
that use OpenBIOS and SLOF, too. So let's make this code independent
from the MAC NVRAM environment and put it into two proper helper
functions.

Signed-off-by: Thomas Huth <thuth@redhat.com>
Tested-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
hw/nvram/Makefile.objs
hw/nvram/chrp_nvram.c [new file with mode: 0644]
hw/nvram/mac_nvram.c
include/hw/nvram/chrp_nvram.h [new file with mode: 0644]