Skip to content

Commit

Permalink
Construct MVPD partition in memory on startup (#102)
Browse files Browse the repository at this point in the history
* First try to read VPD from EEPROM

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* WIP: Now it reads some VPD data

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* Finding and iterating VTOC

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* MVPD construction

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* Fix EEPROM addressing and MVPD construction

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* Use constructed MVPD instead of PNOR cache

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* Enable reading both EEPROM chips

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* Fixes for EEPROM access

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* Code cleanup

Change-Id: Ib7b53149ec2f12c7f541cf7f60e3b023556b0c24
Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>

* Review corrections

Change-Id: Ib5376210c5ef175aff4afddd79f42c3ab913670e
Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
  • Loading branch information
SergiiDmytruk committed Oct 19, 2021
1 parent 137bb83 commit f03fd4d
Show file tree
Hide file tree
Showing 4 changed files with 282 additions and 48 deletions.
2 changes: 2 additions & 0 deletions src/include/cpu/power/vpd.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
#include <stdint.h>

#define VPD_RECORD_NAME_LEN 4
#define VPD_KWD_NAME_LEN 2
#define VPD_RECORD_SIZE_LEN 2

void vpd_pnor_main(void);

Expand Down
1 change: 1 addition & 0 deletions src/soc/ibm/power9/Makefile.inc
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,6 @@ ramstage-y += powerbus.c
ramstage-y += pstates.c
ramstage-y += xive.c
ramstage-y += int_vectors.S
ramstage-y += i2c.c

endif
Loading

0 comments on commit f03fd4d

Please sign in to comment.