vpnor: create hostboot bootloader partition

The hostboot bootloader code doesn't use mbox.

It has specific requirements:
- The PNOR TOC should be at the 'PNOR end - TOC size - page size'
  offset. It searches for the TOC here, if not found, the search moves
  down page by page.
- The PNOR should be 64M. The page size and erase block should be 4K.
  The TOC should be 32K.

Copy what the bootloader expects to the LPC memory when mboxd starts up.
The same needs to be done in the case of an mbox reset (irrespective of
where the reset comes from).

Skiboot expects that the TOC should be at offset 0, but it uses mbox to
read the TOC. So this commit doesn't impact skiboot requirements.

Change-Id: I7de556dccfea85f2faa5f401177006a3a562494e
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
9 files changed
tree: be589e2398aa46815813fc789591b348f5621c58
  1. Documentation/
  2. m4/
  3. test/
  4. .gitignore
  5. bootstrap.sh
  6. common.c
  7. common.h
  8. configure.ac
  9. dbus.h
  10. LICENSE
  11. Makefile.am
  12. mbox.h
  13. mboxctl.c
  14. mboxd.c
  15. mboxd_dbus.c
  16. mboxd_dbus.h
  17. mboxd_flash.h
  18. mboxd_flash_physical.c
  19. mboxd_flash_virtual.cpp
  20. mboxd_lpc.c
  21. mboxd_lpc.h
  22. mboxd_lpc_physical.c
  23. mboxd_lpc_virtual.cpp
  24. mboxd_msg.c
  25. mboxd_msg.h
  26. mboxd_pnor_partition_table.cpp
  27. mboxd_pnor_partition_table.h
  28. mboxd_windows.c
  29. mboxd_windows.h
  30. mtd.c
  31. pnor_partition.cpp
  32. pnor_partition.hpp
  33. pnor_partition_defs.h
  34. pnor_partition_table.cpp
  35. pnor_partition_table.hpp
  36. README.md
README.md

Copyright 2017 IBM

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

MBOX

This repo contains the protocol definition for the host to BMC mailbox communication specification which can be found in Documentation/mbox_procotol.md.

There is also a reference implementation of a BMC mailbox daemon, the details of which can be found in Documentation/mboxd.md.

Finally there is also an implementation of a mailbox daemon control program, the details of which can be found in Documentation/mboxctl.md.