forked from coreboot/coreboot
-
Notifications
You must be signed in to change notification settings - Fork 0
istep 8.6 as powerbus.c #82
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 7 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
ee59e7b
soc/power9/mvpd.c: rename several variables
SergiiDmytruk b0eeeb4
soc/power9/mvpd.c: extract mvpd_get_keyword()
SergiiDmytruk a7ee870
soc/power9/mvpd.c: add mvpd_extract_keyword()
SergiiDmytruk ab5a774
soc/power9: implement istep 8.6 as powerbus.c
SergiiDmytruk 6659112
soc/power9/istep_13_8.c: use powerbus.c unit
SergiiDmytruk 32a46b2
soc/power9/powerbus.c: assume EPS_TYPE_LE
SergiiDmytruk 5658eba
soc/power9/mvpd.c: add mvpd_get_voltage_data()
SergiiDmytruk 0b9b191
Review corrections
SergiiDmytruk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,52 @@ | ||
| /* SPDX-License-Identifier: GPL-2.0-only */ | ||
|
|
||
| #ifndef CPU_PPC64_POWERBUS_H | ||
| #define CPU_PPC64_POWERBUS_H | ||
|
|
||
| #include <stdint.h> | ||
|
|
||
| enum FABRIC_CORE_FLOOR_RATIO | ||
| { | ||
| FABRIC_CORE_FLOOR_RATIO_RATIO_8_8 = 0x0, | ||
| FABRIC_CORE_FLOOR_RATIO_RATIO_7_8 = 0x1, | ||
| FABRIC_CORE_FLOOR_RATIO_RATIO_6_8 = 0x2, | ||
| FABRIC_CORE_FLOOR_RATIO_RATIO_5_8 = 0x3, | ||
| FABRIC_CORE_FLOOR_RATIO_RATIO_4_8 = 0x4, | ||
| FABRIC_CORE_FLOOR_RATIO_RATIO_2_8 = 0x5, | ||
| }; | ||
|
|
||
| enum FABRIC_CORE_CEILING_RATIO | ||
| { | ||
| FABRIC_CORE_CEILING_RATIO_RATIO_8_8 = 0x0, | ||
| FABRIC_CORE_CEILING_RATIO_RATIO_7_8 = 0x1, | ||
| FABRIC_CORE_CEILING_RATIO_RATIO_6_8 = 0x2, | ||
| FABRIC_CORE_CEILING_RATIO_RATIO_5_8 = 0x3, | ||
| FABRIC_CORE_CEILING_RATIO_RATIO_4_8 = 0x4, | ||
| FABRIC_CORE_CEILING_RATIO_RATIO_2_8 = 0x5, | ||
| }; | ||
|
|
||
| #define NUM_EPSILON_READ_TIERS 3 | ||
| #define NUM_EPSILON_WRITE_TIERS 2 | ||
|
|
||
| /* Description of PowerBus configuration */ | ||
| struct powerbus_cfg | ||
| { | ||
| /* Data computed from #V of LRP0 in MVPD, is MHz */ | ||
| uint32_t freq_core_floor; | ||
| uint32_t freq_core_ceiling; | ||
| uint32_t fabric_freq; | ||
|
|
||
| /* Derived from data above */ | ||
| enum FABRIC_CORE_FLOOR_RATIO core_floor_ratio; | ||
| enum FABRIC_CORE_CEILING_RATIO core_ceiling_ratio; | ||
|
|
||
| /* Derived from all data above */ | ||
| /* ATTR_PROC_EPS_READ_CYCLES_T* */ | ||
| uint32_t eps_r[NUM_EPSILON_READ_TIERS]; | ||
| /* ATTR_PROC_EPS_WRITE_CYCLES_T* */ | ||
| uint32_t eps_w[NUM_EPSILON_WRITE_TIERS]; | ||
| }; | ||
|
|
||
| const struct powerbus_cfg *powerbus_cfg(void); | ||
|
|
||
| #endif // CPU_PPC64_POWERBUS_H |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.