{"push_id":1423859558,"size":1,"distinct_size":1,"ref":"refs/heads/master","head":"7fa254ea43c767917942d726d911e5d618833fb0","before":"bbc0a0af063034f7b9763760be118d11b6ee8c40","commits":[{"sha":"7fa254ea43c767917942d726d911e5d618833fb0","author":{"name":"landonf","email":"56cee983e1ccd99bfa5a5fbe036a4765b0950d54@FreeBSD.org"},"message":"bhnd(4): Unify NVRAM/SPROM parsing, implement compact SPROM layout encoding.\n\n\n- Defined an abstract NVRAM I/O API (bhnd_nvram_io), decoupling NVRAM/SPROM\n  parsing from the actual underlying NVRAM data provider (e.g. CFE firmware\n  devices).\n- Defined an abstract NVRAM data API (bhnd_nvram_data), decoupling\n  higher-level NVRAM operations (indexed lookup, data conversion, etc) from\n  the underlying NVRAM file format parsing/serialization.\n- Implemented a new high-level bhnd_nvram_store API, providing indexed\n  variable lookup, pending write tracking, etc on top of an arbitrary\n  bhnd_nvram_data instance.\n- Migrated all bhnd(4) NVRAM device drivers to the common bhnd_nvram_store\n  API.\n- Implemented a common bhnd_nvram_val API for parsing/encoding NVRAM\n  variable values, including applying format-specific behavior when\n  converting to/from the NVRAM string representations.\n- Dropped the now unnecessary bhnd_nvram driver, and moved the\n  broadcom/mips-specific CFE NVRAM driver out into sys/mips/broadcom.\n- Implemented a new nvram_map file format:\n        - Variable definitions are now defined separately from the SPROM\n          layout. This will also allow us to define CIS tuple NVRAM\n          mappings referencing the common NVRAM variable definitions.\n        - Variables can now be defined within arbitrary named groups.\n        - Textual descriptions and help information can be defined inline\n          for both variables and variable groups.\n        - Implemented a new, compact encoding of SPROM image layout\n          offsets.\n- Source-level (but not build system) support for building the NVRAM file\n  format APIs (bhnd_nvram_io, bhnd_nvram_data, bhnd_nvram_store) as a\n  userspace library.\n\nThe new compact SPROM image layout encoding is loosely modeled on Apple\ndyld compressed LINKEDIT symbol binding opcodes; it provides a compact\nstate-machine encoding of the mapping between NVRAM variables and the SPROM\nimage offset, mask, and shift instructions necessary to decode or encode\nthe SPROM variable data.\n\nThe compact encoding reduces the size of the generated SPROM layout data\nfrom roughly 60KB to 3KB. The sequential nature SPROM layout opcode tables\nalso simplify iteration of the SPROM variables, as it's no longer\nneccessary to iterate the full NVRAM variable definition table, but\ninstead simply scan the SPROM revision's layout opcode table.\n\nApproved by:    adrian (mentor)\nDifferential Revision:  https://reviews.freebsd.org/D8645","distinct":true,"url":"https://api.github.com/repos/freebsd/freebsd/commits/7fa254ea43c767917942d726d911e5d618833fb0"}]}
{"actor":{"display_login":"uqs"}}