11
29
Fork
You've already forked ipmitool
33

Allow Sensor Data records to use 6-bit ASCII encoding #14

Open
Howitzer105mm wants to merge 1 commit from Howitzer105mm/ipmitool:feature/9023b5b-allow-6-bit-encoded-sdr-strings into master
pull from: Howitzer105mm/ipmitool:feature/9023b5b-allow-6-bit-encoded-sdr-strings
merge into: IPMITool:master
IPMITool:master
IPMITool:bugfix/43-Fix-timezone-and-DST-in-SEL
IPMITool:pages
IPMITool:bugfix/fix-ci-builds
IPMITool:feature/refactor-sdr-name-handling
IPMITool:cleanup/nm
IPMITool:feature/add-support-for-boot-mailbox
IPMITool:codefactor
IPMITool:bugfix/26
Contributor
Copy link

IPMI sensor names are permitted to be encoded as 6-bit ASCII. ipmitool
assumes these strings are only UTF/Latin1 encoded. Enabling 6-bit
encoding allows the sensor names to present up to 21 characaters,
instead of 16.

The OpenBMC project is introducing a change that allows the sensor
names to be extended to use the full 31 bytes of the Type/Len
encoding. OpenBMC is also enabling 6-bit ASCII encoding of the sensor
names along with the full 31 bytes of the string name. This allows
OpenBMC to express sensor names up to 41 characters in length.

The IPMI specification says SDR strings are 16 bytes maximum. It also
states any extra characters beyond 16 should be ignored. It does not
say they must be ignored. OpenBMC has been creating workarounds that
do not work well to live within the 16 character limit. Allowing 41
character string names is expected to be satisfactory.

Resolves: Allows sensor names to use 6-bit ASCII encoding
Signed-off-by: Johnathan Mantey johnathanx.mantey@intel.com

IPMI sensor names are permitted to be encoded as 6-bit ASCII. ipmitool assumes these strings are only UTF/Latin1 encoded. Enabling 6-bit encoding allows the sensor names to present up to 21 characaters, instead of 16. The OpenBMC project is introducing a change that allows the sensor names to be extended to use the full 31 bytes of the Type/Len encoding. OpenBMC is also enabling 6-bit ASCII encoding of the sensor names along with the full 31 bytes of the string name. This allows OpenBMC to express sensor names up to 41 characters in length. The IPMI specification says SDR strings are 16 bytes maximum. It also states any extra characters beyond 16 *should* be ignored. It does not say they *must* be ignored. OpenBMC has been creating workarounds that do not work well to live within the 16 character limit. Allowing 41 character string names is expected to be satisfactory. Resolves: Allows sensor names to use 6-bit ASCII encoding Signed-off-by: Johnathan Mantey <johnathanx.mantey@intel.com>
vmauery approved these changes 2023年10月26日 23:18:52 +02:00
Dismissed
lib/ipmi_fru.c Outdated
@ -196,0 +208,4 @@
* returns a pointer to a C string containing the decoded ID string
* The caller must free the allocated memory
*/
char * decode_idstring(uint8_t * data, uint32_t * offset, uint8_t * id_string_len)

Please try to reuse get_fru_area_str() that does essentially the same.

Please try to reuse ` get_fru_area_str()` that does essentially the same.
Author
Contributor
Copy link

Pushed a new version with the change you requested.

Pushed a new version with the change you requested.
Howitzer105mm marked this conversation as resolved
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from 9023b5b721 to 643cb65683 2023年10月30日 20:38:13 +01:00 Compare
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

vmauery requested changes 2023年10月31日 19:13:33 +01:00
Dismissed
lib/ipmi_fru.c Outdated
@ -272,1 +276,3 @@
str[j++] = ((u.chars[char_idx] & 0x3f) + 0x20);
for (k=0; k<rem; k++) {
str[j] = ((u.chars[char_idx] & 0x3f) + 0x20);
if (rem == 4 && (str[j] == 0x20)) {
First-time contributor
Copy link

This logic removes spaces (and any bytes from this 4-byte chunk that follow) from within the string as well. It would be better to just back off the spaces from the end once they are decoded.

Put this down before 'size = j;':

while (j > 1 && str[j-1] == 0x20)
str[--j] = '0円';

This logic removes spaces (and any bytes from this 4-byte chunk that follow) from within the string as well. It would be better to just back off the spaces from the end once they are decoded. Put this down before 'size = j;': while (j > 1 && str[j-1] == 0x20) str[--j] = '0円';
Author
Contributor
Copy link

Implemented.

Implemented.
Howitzer105mm marked this conversation as resolved
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from 643cb65683 to c518141baa 2023年11月01日 14:44:20 +01:00 Compare
vmauery approved these changes 2023年11月01日 17:51:41 +01:00
Dismissed
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Lexden approved these changes 2023年11月01日 22:31:59 +01:00
Dismissed
vmauery approved these changes 2023年11月01日 22:36:18 +01:00
Dismissed
vmauery left a comment
Copy link

Looks good to me.

Looks good to me.
Author
Contributor
Copy link

Do you have any additional feedback Alexander?

Do you have any additional feedback Alexander?
@ -466,3 +466,3 @@
uint8_t oem; /* reserved for OEM use */
uint8_t id_code; /* sensor ID string type/length code */
uint8_t id_string[16]; /* sensor ID string bytes, only if id_code != 0 */
uint8_t id_string[42]; /* sensor ID string bytes, only if id_code != 0 */

This is the structure used to receive data from BMC.
According to the IPMI 2.0 Specification Table 43-2, this field is max 16 bytes.
If OpenBMC now violates the spec (by playing on the subtle difference between 'should' and 'must'), then please explicitly state here something llike:

/* 16 per IPMI 2.0 Table 43-2, but some BMCs violate that and may send as many as 42 */

Also, I'd like you to define this number just once via some macro and then use it everywhere. A name like #define SENSOR_ID_STR_MAXLEN 42 would do with the comment similar to the above.

Also, why exactly 42 ? See the question about 32 in ipmi_fru.c below.

This is the structure used to receive data from BMC. According to the IPMI 2.0 Specification Table 43-2, this field is max 16 bytes. If OpenBMC now violates the spec (by playing on the subtle difference between 'should' and 'must'), then please explicitly state here something llike: ```c /* 16 per IPMI 2.0 Table 43-2, but some BMCs violate that and may send as many as 42 */ ``` Also, I'd like you to define this number just once via some macro and then use it everywhere. A name like `#define SENSOR_ID_STR_MAXLEN 42` would do with the comment similar to the above. Also, why exactly `42` ? See the question about `32` in ipmi_fru.c below.
Author
Contributor
Copy link

The reason for using 42 is due to using non-integer math:

The assumption is that the Type/Len can/will be assigned 0x1F. There is already ample code within ipmitool allowing this, for example ipmi_fru_print.

As a result, 31 is an allowed value.

(31 * 4 chars) / 3 bytes = 41 1/3 characters
Round the fraction up, to permit capturing that 1/3 character, and you get 42 bytes.

The reason for using 42 is due to using non-integer math: The assumption is that the Type/Len can/will be assigned 0x1F. There is already ample code within ipmitool allowing this, for example ipmi_fru_print. As a result, 31 is an allowed value. (31 * 4 chars) / 3 bytes = 41 1/3 characters Round the fraction up, to permit capturing that 1/3 character, and you get 42 bytes.
Author
Contributor
Copy link

FWIW, I avoided creating the #defines you recommended, as there were already bunches of hard coded values. I was not certain creating the #defines would have been approved, so I left the code with a bunch of 16->42 entries.

FWIW, I avoided creating the #defines you recommended, as there were already bunches of hard coded values. I was not certain creating the #defines would have been approved, so I left the code with a bunch of 16->42 entries.
Author
Contributor
Copy link

I have added the string length #define, and described why that number is being used.
It is also being used for the FRU records as well.
There is bug in the OpenBMC IPMI code. The Type encoding is set to UTF8 instead of Ascii/Latin.
If I haven't already I will submit a commit that fixes that.

I have also done another pass through the code and found additional areas that hadn't been covered.

I have added the string length #define, and described why that number is being used. It is also being used for the FRU records as well. There is bug in the OpenBMC IPMI code. The Type encoding is set to UTF8 instead of Ascii/Latin. If I haven't already I will submit a commit that fixes that. I have also done another pass through the code and found additional areas that hadn't been covered.

I avoided creating the #defines you recommended, as there were already bunches of hard coded values

That's the legacy code. There is a lot of hard-code in ipmitool and that makes me really sad.
Let's try to avoid those bad practices with the new code and fix them whenever possible.

Thank you.

> I avoided creating the #defines you recommended, as there were already bunches of hard coded values That's the legacy code. There is a lot of hard-code in `ipmitool` and that makes me really sad. Let's try to avoid those bad practices with the new code and fix them whenever possible. Thank you.
lib/ipmi_fru.c Outdated
@ -3204,3 +3217,3 @@
ipmi_fru_print(struct ipmi_intf * intf, struct sdr_record_fru_locator * fru)
{
char desc[17];
char desc[32];

Ok, this needs a macro too. And a comment about spec violation as well, I guess.
Also, where does 32 come from? By specification, SDR FRU device description is 16 bytes long, plus the preceding type/length byte. That's the original 17. With 6-bit encoding that's 16*4/3 + 1 = 22. With full length of type/length field that's 2^6 - 1 = 63 bytes of data or 64 bytes total. Using6-bit encoding 63*4/3 + 1 = 85. So, why 32 ? I don't get it.

Ok, this needs a macro too. And a comment about spec violation as well, I guess. Also, where does `32` come from? By specification, SDR FRU device description is 16 bytes long, plus the preceding type/length byte. That's the original `17`. With 6-bit encoding that's `16*4/3 + 1 = 22`. With full length of type/length field that's `2^6 - 1 = 63` bytes of data or 64 bytes total. Using6-bit encoding `63*4/3 + 1 = 85`. So, why 32 ? I don't get it.
Author
Contributor
Copy link

This is one of those places where the Type/Len already allowed 31 bytes:

memset(desc, 0, sizeof(desc)); memcpy(desc, fru->id_string, __min(fru->id_code & 0x01f, sizeof(desc))); desc[fru->id_code & 0x01f] = 0;
Changing this to 32 allows the id_code to use the full range.
I don't think the FRU print is using the non-latin encoding scheme.

This is one of those places where the Type/Len already allowed 31 bytes: ` memset(desc, 0, sizeof(desc)); memcpy(desc, fru->id_string, __min(fru->id_code & 0x01f, sizeof(desc))); desc[fru->id_code & 0x01f] = 0; ` Changing this to 32 allows the id_code to use the full range. I don't think the FRU print is using the non-latin encoding scheme.

Good example. I've checked the IPMI spec again and found that there is a difference in the description of the Type/Length field between the IPMI and FRU specs. In FRU the length is 6-bit (5..0), whereas in IPMI it's just 5 bit (4..0). Also bits 7:6 = 00 define a Unicode string in IPMI whereas they define binary string in FRU spec.

I believe we now need to introduce two different macros because both approaches are applicable in different parts of code. That is probably out of scope of this change though.

My understanding now is that for some strings the type/length may be as long as 31 bytes, and for some it may be up to 63. Careful checking is needed.

I'll need to look further into this. Please do so as well.

Good example. I've checked the IPMI spec again and found that there is a difference in the description of the Type/Length field between the IPMI and FRU specs. In FRU the length is 6-bit (5..0), whereas in IPMI it's just 5 bit (4..0). Also bits 7:6 = 00 define a Unicode string in IPMI whereas they define binary string in FRU spec. I believe we now need to introduce two different macros because both approaches are applicable in different parts of code. That is probably out of scope of this change though. My understanding now is that for some strings the type/length may be as long as 31 bytes, and for some it may be up to 63. Careful checking is needed. I'll need to look further into this. Please do so as well.
lib/ipmi_sdr.c Outdated
@ -1789,3 +1797,3 @@
* print sensor name, reading, state
*/
printf("%-16s | ", sr->s_id);
printf("%-41s | ", sr->s_id);

This should be smth like:

printf("%-*s | ", SENSOR_ID_STR_MAXLEN - 1, sr->s_id);
This should be smth like: ```c printf("%-*s | ", SENSOR_ID_STR_MAXLEN - 1, sr->s_id); ```
Author
Contributor
Copy link

Looks like I need to update this PR. I did not adjust for the six bits of the FRU Type/Len record.

Looks like I need to update this PR. I did not adjust for the six bits of the FRU Type/Len record.
Howitzer105mm marked this conversation as resolved
lib/ipmi_sdr.c Outdated
@ -1827,3 +1835,3 @@
* print sensor name, number, state, entity, reading
*/
printf("%-16s | %02Xh | ",
printf("%-41s | %02Xh | ",

This too. And everywhere else.

This too. And everywhere else.
Howitzer105mm marked this conversation as resolved
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from a434ad0c8b to d39e8fcbae 2023年12月20日 23:32:53 +01:00 Compare
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Reason:

New commits pushed, approval review dismissed automatically according to repository settings

vmauery approved these changes 2024年01月26日 02:52:42 +01:00
Dismissed
vmauery left a comment
Copy link

Overall, I think it looks good. I think the note at the top of fru.h explains well how much openbmc is bending the the ipmi specification. I noticed one misaligned whitespace situation and figured there might be more, but didn't hunt. You might consider doing a search and replace or something.

Overall, I think it looks good. I think the note at the top of fru.h explains well how much openbmc is bending the the ipmi specification. I noticed one misaligned whitespace situation and figured there might be more, but didn't hunt. You might consider doing a search and replace or something.
@ -2746,6 +2746,7 @@ ipmi_ek_display_board_info_area(FILE *input_file, char *board_type,
unsigned char len = 0;
unsigned int size_board = 0;
int custom_fields = 0;
uint8_t string_len;
First-time contributor
Copy link

this has spaces instead of tabs

this has spaces instead of tabs
Howitzer105mm marked this conversation as resolved
Lexden approved these changes 2024年01月26日 19:53:44 +01:00
Dismissed
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from d39e8fcbae to 5975f17ef4 2024年02月02日 21:12:18 +01:00 Compare
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Author
Contributor
Copy link

Cleaned formatting

Cleaned formatting
@ -430,0 +437,4 @@
* There are BMC implementations, specifically OpenBMC, which are choosing to
* ignore the guidance, and use the full range of the Type/Len byte. This
* allows longer strings to be transferred.
* In addition, this code change enables 6-bit string encoding per Table

I don't think we need to mention some 'this code change' in this comment that will persist for some long time here. Please reword.

I don't think we need to mention some 'this code change' in this comment that will persist for some long time here. Please reword.
Author
Contributor
Copy link

Modified to be less temporal

Modified to be less temporal
AlexanderAmelkin marked this conversation as resolved
@ -430,0 +442,4 @@
* Type/Len record with 31 bytes reported will allow:
* (31 bytes * 4 chars) / 3 bytes = 41 1/3 available characters.
* Rounding down allows for 41 full characters. Room must be made for the
* terminating NULL, for a total size of 42 bytes.

Nit: it's not NULL, it's NUL. That's how the 0円 character is called in ASCII.

Nit: it's not NULL, it's NUL. That's how the `0円` character is called in ASCII.
Howitzer105mm marked this conversation as resolved
@ -466,3 +485,3 @@
uint8_t oem; /* reserved for OEM use */
uint8_t id_code; /* sensor ID string type/length code */
uint8_t id_string[16]; /* sensor ID string bytes, only if id_code != 0 */
uint8_t id_string[SDR_MAX_ID_STR_LEN]; /* sensor ID string bytes, only if id_code != 0 */

Looks to me like these are actually 31, not 42. These are the lengths of raw data, if I get it right. Aren't they?
I guess that's why they were 16 and not 17 here.

Looks to me like these are actually `31`, not `42`. These are the lengths of raw data, if I get it right. Aren't they? I guess that's why they were `16` and not `17` here.
AlexanderAmelkin marked this conversation as resolved
@ -430,0 +444,4 @@
* Rounding down allows for 41 full characters. Room must be made for the
* terminating NULL, for a total size of 42 bytes.
*/
#define SDR_MAX_ID_STR_LEN 42

Probably we need some #define SDR_MAX_ID_STR_RAW_LEN 31.

Probably we need some `#define SDR_MAX_ID_STR_RAW_LEN 31`.

And probably it would worth it to rename SDR_MAX_ID_STR_LEN to SDR_MAX_ID_STR_DECODED_LEN or something like that

And probably it would worth it to rename `SDR_MAX_ID_STR_LEN` to `SDR_MAX_ID_STR_DECODED_LEN` or something like that
Author
Contributor
Copy link

Created two constants per your suggestion.

Created two constants per your suggestion.
AlexanderAmelkin marked this conversation as resolved
lib/ipmi_fru.c Outdated
@ -191,1 +190,3 @@
* @offset: offset into data for area
* @data: raw FRU/SDR string, including the Type/Length
* @offset: offset into data indicating the Type/Length position.
* @string_len: output containing the number of bytes allocated for

I guess this is the place where the difference in Type/Length field definition may kick in.
When this is called for IPMI fields like SDR id_string, it must treat the field as per IPMI spec.
However, when called on a FRU area data, it must follow the FRU spec for the field.

I guess this is the place where the difference in Type/Length field definition may kick in. When this is called for IPMI fields like SDR id_string, it must treat the field as per IPMI spec. However, when called on a FRU area data, it must follow the FRU spec for the field.

Probably, we need a worker function with a spec type parameter that would do the actual job, and then some wrappers like the original get_fru_area_str and the new get_ipmi_typelen_str.

Probably, we need a worker function with a spec type parameter that would do the actual job, and then some wrappers like the original `get_fru_area_str` and the new `get_ipmi_typelen_str`.

You may probably then drop the string_len parameter from the get_fru_area_str wrapper and restore it's original API

You may probably then drop the `string_len` parameter from the `get_fru_area_str` wrapper and restore it's original API
Author
Contributor
Copy link

I prefer returning the already calculated string length.
The function has already determined the size of the string. This makes using strlen() unnecessary. Why recalculate the string length using strlen() when the answer is already available? Especially since it is done in a way that doesn't rely on NUL termination?

I prefer returning the already calculated string length. The function has already determined the size of the string. This makes using strlen() unnecessary. Why recalculate the string length using strlen() when the answer is already available? Especially since it is done in a way that doesn't rely on NUL termination?
lib/ipmi_fru.c Outdated
@ -3244,1 +3256,3 @@
printf("FRU Device Description : %s (ID %d)\n", desc, fru->device_id);
id_string = get_fru_area_str(&fru->id_code, &offset, &id_string_len);
if (id_string) {
printf("FRU Device Description :%s (ID %d)\n", id_string, fru->device_id);

You've lost a space after the colon here.
Please restore it here and below as well.

You've lost a space after the colon here. Please restore it here and below as well.
Author
Contributor
Copy link

Restored the formatting.

Restored the formatting.
Howitzer105mm marked this conversation as resolved
AlexanderAmelkin left a comment
Copy link

Please address my new comments

Please address my new comments
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from 5975f17ef4 to 43ecd96baf 2024年02月06日 21:51:07 +01:00 Compare
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from 43ecd96baf to d1945af984 2024年02月06日 22:13:33 +01:00 Compare
Author
Contributor
Copy link

Alexander,
I believe I have implemented all of your suggestions. Thank you for providing them.
I have also found a few conditions in the code that were not being handled.
I think what is here will correctly handle both FRU and SDR records.

Alexander, I believe I have implemented all of your suggestions. Thank you for providing them. I have also found a few conditions in the code that were not being handled. I think what is here will correctly handle both FRU and SDR records.
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from d1945af984 to 032b4a72ee 2024年02月23日 20:08:16 +01:00 Compare
Author
Contributor
Copy link

Rebase only.

Rebase only.
vmauery requested changes 2024年02月23日 22:56:32 +01:00
Dismissed
@ -665,2 +668,3 @@
int ipmi_fru_print(struct ipmi_intf *intf, struct sdr_record_fru_locator *fru);
char *get_fru_area_str(uint8_t *data, uint32_t *offset);
char *get_fru_area_str(uint8_t *data, uint32_t *offset, bool isSDR,
uint8_t * string_len);
First-time contributor
Copy link

this should be all spaces and no tabs (since the first line is not indented at all)

this should be all spaces and no tabs (since the first line is not indented at all)
Author
Contributor
Copy link

Updated.

Updated.
AlexanderAmelkin marked this conversation as resolved
lib/ipmi_fru.c Outdated
@ -236,3 +251,4 @@
str = malloc(size+1);
if (!str)
return NULL;
First-time contributor
Copy link

In other cases where returning NULL, *string_len is set to 0. It probably should be here as well. Or it could be set at the top once to 0 and then only set to a real value once below.

In other cases where returning NULL, *string_len is set to 0. It probably should be here as well. Or it could be set at the top once to 0 and then only set to a real value once below.
Author
Contributor
Copy link

Updated per your second suggestion.

Updated per your second suggestion.
Howitzer105mm marked this conversation as resolved
@ -85,1 +80,3 @@
id, sensor->cmn.keys.sensor_num);
uint8_t id_string_len = 0;
uint32_t offset = 0;
char *id_string = get_fru_area_str(&sensor->id_code, &offset, true,
First-time contributor
Copy link

The wrapped function calls in this section need to have the tab/space fixup.

The wrapped function calls in this section need to have the tab/space fixup.
Author
Contributor
Copy link

Updated

Updated
Howitzer105mm marked this conversation as resolved
Author
Contributor
Copy link

Performed a review of all code change lines, and updated whitespace as needed.

Performed a review of all code change lines, and updated whitespace as needed.
vmauery approved these changes 2024年02月26日 22:13:19 +01:00
Dismissed
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from fd99edb7ef to f7c9ba80e7 2024年03月28日 20:21:52 +01:00 Compare
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Author
Contributor
Copy link

Rebased on top of latest merged commits

Rebased on top of latest merged commits
Lexden approved these changes 2024年04月09日 20:16:22 +02:00
Dismissed
vmauery approved these changes 2024年04月09日 20:22:42 +02:00
Dismissed
Author
Contributor
Copy link

@AlexanderAmelkin
Alexander, are there any other changes required for this PR?
I'd like to be able to get this, and the companion OpenBMC commits wrapped.

@AlexanderAmelkin Alexander, are there any other changes required for this PR? I'd like to be able to get this, and the companion OpenBMC commits wrapped.
Author
Contributor
Copy link

Alexander, will you please merge this change into the mainline?

Alexander, will you please merge this change into the mainline?
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from f7c9ba80e7 to 9aeeef7984 2024年06月24日 18:49:18 +02:00 Compare
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from 9aeeef7984 to 0a57b7040d 2024年06月24日 19:55:20 +02:00 Compare
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Reason:

New commits pushed, approval review dismissed automatically according to repository settings

vmauery approved these changes 2024年07月22日 17:37:58 +02:00
Dismissed
Lexden approved these changes 2024年07月22日 19:46:43 +02:00
Dismissed
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from b569a78eac to d1d91d298d 2024年09月04日 19:02:23 +02:00 Compare
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from d1d91d298d to a94053169e 2024年09月09日 18:13:15 +02:00 Compare
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Author
Contributor
Copy link

Alexander....
I finally understood the gist of your comments.
I believe this commit addresses the suggested course of action.

Alexander.... I finally understood the gist of your comments. I believe this commit addresses the suggested course of action.
vmauery approved these changes 2024年09月09日 19:51:58 +02:00
Dismissed
Lexden approved these changes 2024年09月17日 18:35:11 +02:00
Dismissed
Lexden left a comment
Copy link

A couple nits on the documentation presented in ipmi_sdr.h, but nothing which affects logic.

A couple nits on the documentation presented in ipmi_sdr.h, but nothing which affects logic.
@ -433,0 +436,4 @@
* Type/Len record allowing more than 16 byte string names, there is
* qualifying text stating the maximum string length is 16 bytes. See the Full
* Sensor Data record table. The same section also states any additional bytes
* SHOULD be ignored. It does not madate they MUST be ignored.
Contributor
Copy link

nit: mandate* typo

nit: mandate* typo
@ -433,0 +445,4 @@
* with 31 bytes reported will allow:
* (31 bytes * 4 chars) / 3 bytes = 41 1/3 available characters.
* Rounding down allows for 41 full characters. Room must be made for the
* terminating NUL, for a total size of 42 bytes.
Contributor
Copy link

32 bytes? Or 42 characters? I do not see how we get to 42 bytes.

32 bytes? Or 42 characters? I do not see how we get to 42 bytes.
Howitzer105mm force-pushed feature/9023b5b-allow-6-bit-encoded-sdr-strings from 47ece3188a to 774bfd4b74 2024年09月17日 20:35:28 +02:00 Compare
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

Reason:

New commits pushed, approval review dismissed automatically according to repository settings

This pull request has changes conflicting with the target branch.
  • lib/ipmi_sdr.c
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u feature/9023b5b-allow-6-bit-encoded-sdr-strings:Howitzer105mm-feature/9023b5b-allow-6-bit-encoded-sdr-strings
git switch Howitzer105mm-feature/9023b5b-allow-6-bit-encoded-sdr-strings
Sign in to join this conversation.
Labels
Clear labels
No items
No labels
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
4 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
IPMITool/ipmitool!14
Reference in a new issue
IPMITool/ipmitool
No description provided.
Delete branch "Howitzer105mm/ipmitool:feature/9023b5b-allow-6-bit-encoded-sdr-strings"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?