-
Notifications
You must be signed in to change notification settings - Fork 53
minerva-ag: Support i2c telemetry command and support fru product custom data and modify bootstrap command with setting hex-value #2261
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
Conversation
@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. (Because this pull request was imported automatically, there will not be any future comments.) |
ARG_UNUSED(args); | ||
|
||
update_sensor_data_0_2_table(); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason why we aren't updating the other sensors?
plat_sensor_init_data_0_1 *sensor_init_data_0_1_table[2] = { NULL }; | ||
plat_sensor_init_data_0_2 *sensor_init_data_0_2_table[4] = { NULL }; | ||
plat_sensor_init_data_0_6 *sensor_init_data_0_6_table[1] = { NULL }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the rationale for using malloc instead of making this statically assigned?
|
||
void init_sensor_data_0_1_table() | ||
{ | ||
for (int reg_offset = 0; reg_offset < 2; reg_offset++) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For all of these for
loops, that use reg_offset, it's not clear that you are going through all the elements in the corresponding array. Can we create variables/constants to make the relationship clear?
#define DATA_0_1_TABLE_LENGTH 2
plat_sensor_init_data_0_1 *sensor_init_data_0_1_table[DATA_0_1_TABLE_LENGTH] = ...
for (int reg_offset = 0; reg_offset < DATA_0_1_TABLE_LENGTH; reg_offset++) {
{ | ||
for (int reg_offset = 0; reg_offset < 2; reg_offset++) { | ||
// Calculate num_idx | ||
int num_idx = (PLAT_SENSOR_NUM_MAX - 1) - (248 * reg_offset); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is 248 and can we make a variable/constant for that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I use #define on it.
void init_sensor_data_0_2_table() | ||
{ | ||
for (int reg_offset = 0; reg_offset < 4; reg_offset++) { | ||
int num_idx = (PLAT_SENSOR_NUM_MAX - 1) - (50 * reg_offset); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
similar question on the 50 here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I use #define on it.
f463798
to
065f5fe
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
1 similar comment
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
76eac5f
to
19b97ad
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
19b97ad
to
941775f
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
941775f
to
38df263
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
38df263
to
46128dc
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
46128dc
to
1652cff
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
1 similar comment
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
c5d8282
to
2e97c0a
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
2e97c0a
to
b0e8906
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
b0e8906
to
78044a9
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
78044a9
to
6fe2a0d
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@LisaChang-Quanta please fix failing checks and rebase
6fe2a0d
to
902cb7a
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
1 similar comment
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@LisaChang-Quanta one of the checks are still failing. Please fix.
Summary: - Support i2c telemetry command - Support reg: 0x00 ~ 0x05 - Support part of reg: 0x06 - Add comment on i2c_target_config: rd_data_collect_func Test Plan: - Build code: PASS
…ommand Summary: - Support fru product custom data - Support i2c telemetry write command - Support reg: 0x08 ~ 0x76 Test Plan: - Build code: PASS
Summary: - Support i2c telemetry i2c bridge master write/read command - Support reg: 0x40 ~ 0x42 Test Plan: - Build code: PASS
Summary: - Modify bootstrap default value - base on cpld version: 0070d010 - change: SOC_BOOT_SOURCE_0_4, S_OWL_BOOT_SOURCE_0_7, N_OWL_BOOT_SOURCE_0_7 Test Plan: - Build code: PASS
Summary: - Support telemetry control sensor polling command - Support reg: 0xF0 Test Plan: - Build code: PASS
5234cab
to
073435d
Compare
@LisaChang-Quanta has updated the pull request. You must reimport the pull request before landing. |
This pull request has been merged in 63af749. |
Summary:
Test Plan: