msgbuf: Add error code personalities
libpldm is in a bit of a transitional period with respect to returned
error codes. A historical choice was to return PLDM completion codes
from the library API to indicate errors. This is unfortunate because
we're now constrained to errors that are specified by the PLDM protocol,
which is much less expressive than the set of errors that might be
produced by a run-time environment for the library.
The choice going forward is to return C's errno codes. However at this
point we step on another rake in the libpldm design, which is that some
internal data structures are very much the wire format of corresponding
PLDM messages (such as the PDR repository implementation). Working with
wire-format buffers is most safely done via the msgbuf APIs, however we
then hit the conflict of different error code styles in various parts of
the API surface.
Do a bit of surgery to provide different error code personalities for
msgbuf, such that the caller can pick the style of error code they need
it to return to maintain consistency.
Note that like the previous patch marking all msgbuf APIs as
__attribute__((always_inline)), the rework here makes another small
impact on the argument register allocation of several stable APIs. The
ABI dump is updated accordingly.
Change-Id: Id59c39c5c822f514f546dab88575317071a97c96
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>
diff --git a/abi/x86_64/gcc.dump b/abi/x86_64/gcc.dump
index db7fdab..0d240a2 100644
--- a/abi/x86_64/gcc.dump
+++ b/abi/x86_64/gcc.dump
@@ -1505,7 +1505,7 @@
'Return' => '100',
'ShortName' => 'encode_get_date_time_req'
},
- '38356' => {
+ '57581' => {
'Header' => 'platform.h',
'Line' => '1748',
'Param' => {
@@ -1551,7 +1551,7 @@
'9' => {
'name' => 'event_data',
'offset' => '24',
- 'type' => '40934'
+ 'type' => '60289'
},
'10' => {
'name' => 'event_data_integrity_checksum',
@@ -1562,7 +1562,7 @@
'Return' => '100',
'ShortName' => 'decode_poll_for_platform_event_message_resp'
},
- '40939' => {
+ '60294' => {
'Header' => 'platform.h',
'Line' => '1722',
'Param' => {
@@ -1599,7 +1599,7 @@
'Return' => '100',
'ShortName' => 'encode_poll_for_platform_event_message_req'
},
- '42229' => {
+ '61715' => {
'Header' => 'platform.h',
'Line' => '2201',
'Param' => {
@@ -1619,7 +1619,7 @@
'Return' => '100',
'ShortName' => 'encode_set_event_receiver_resp'
},
- '42400' => {
+ '61886' => {
'Header' => 'platform.h',
'Line' => '2187',
'Param' => {
@@ -1651,7 +1651,7 @@
'Return' => '100',
'ShortName' => 'decode_set_event_receiver_req'
},
- '43692' => {
+ '63302' => {
'Header' => 'platform.h',
'Line' => '2165',
'Param' => {
@@ -1676,7 +1676,7 @@
'Return' => '100',
'ShortName' => 'decode_set_event_receiver_resp'
},
- '44219' => {
+ '63957' => {
'Header' => 'platform.h',
'Line' => '2151',
'Param' => {
@@ -1708,7 +1708,7 @@
'Return' => '100',
'ShortName' => 'encode_set_event_receiver_req'
},
- '44475' => {
+ '64213' => {
'Header' => 'platform.h',
'Line' => '1356',
'Param' => {
@@ -1732,7 +1732,7 @@
'Return' => '100',
'ShortName' => 'decode_get_sensor_reading_req'
},
- '45331' => {
+ '65191' => {
'Header' => 'platform.h',
'Line' => '1382',
'Param' => {
@@ -1789,7 +1789,7 @@
'Return' => '100',
'ShortName' => 'encode_get_sensor_reading_resp'
},
- '45881' => {
+ '65741' => {
'Header' => 'platform.h',
'Line' => '2126',
'Param' => {
@@ -1841,7 +1841,7 @@
'Return' => '100',
'ShortName' => 'decode_get_sensor_reading_resp'
},
- '49340' => {
+ '69333' => {
'Header' => 'platform.h',
'Line' => '2101',
'Param' => {
@@ -1865,7 +1865,7 @@
'Return' => '100',
'ShortName' => 'encode_get_sensor_reading_req'
},
- '49556' => {
+ '69549' => {
'Header' => 'platform.h',
'Line' => '2082',
'Param' => {
@@ -1892,14 +1892,14 @@
},
'Reg' => {
'0' => 'rdi',
- '2' => 'r9',
- '3' => 'rdx',
+ '2' => 'rdx',
+ '3' => 'r9',
'4' => 'r8'
},
'Return' => '100',
'ShortName' => 'decode_pldm_pdr_repository_change_record_data'
},
- '52476' => {
+ '72826' => {
'Header' => 'platform.h',
'Line' => '1965',
'Param' => {
@@ -1926,14 +1926,14 @@
},
'Reg' => {
'0' => 'rdi',
- '2' => 'r9',
- '3' => 'rdx',
+ '2' => 'rdx',
+ '3' => 'r9',
'4' => 'r8'
},
'Return' => '100',
'ShortName' => 'decode_pldm_pdr_repository_chg_event_data'
},
- '53235' => {
+ '73701' => {
'Header' => 'platform.h',
'Line' => '2036',
'Param' => {
@@ -1955,11 +1955,11 @@
},
'4' => {
'name' => 'change_entries',
- 'type' => '53553'
+ 'type' => '74019'
},
'5' => {
'name' => 'event_data',
- 'type' => '53568'
+ 'type' => '74034'
},
'6' => {
'name' => 'actual_change_records_size',
@@ -1983,7 +1983,7 @@
'Return' => '100',
'ShortName' => 'encode_pldm_pdr_repository_chg_event_data'
},
- '53578' => {
+ '74044' => {
'Header' => 'platform.h',
'Line' => '1943',
'Param' => {
@@ -2020,7 +2020,7 @@
'Return' => '100',
'ShortName' => 'decode_get_numeric_effecter_value_resp'
},
- '57800' => {
+ '78392' => {
'Header' => 'platform.h',
'Line' => '1313',
'Param' => {
@@ -2040,7 +2040,7 @@
'Return' => '100',
'ShortName' => 'decode_get_numeric_effecter_value_req'
},
- '58431' => {
+ '79152' => {
'Header' => 'platform.h',
'Line' => '1337',
'Param' => {
@@ -2082,7 +2082,7 @@
'Return' => '100',
'ShortName' => 'encode_get_numeric_effecter_value_resp'
},
- '59121' => {
+ '79842' => {
'Header' => 'platform.h',
'Line' => '1922',
'Param' => {
@@ -2102,7 +2102,7 @@
'Return' => '100',
'ShortName' => 'encode_get_numeric_effecter_value_req'
},
- '59317' => {
+ '80038' => {
'Header' => 'platform.h',
'Line' => '1907',
'Param' => {
@@ -2116,13 +2116,13 @@
},
'2' => {
'name' => 'pdr_value',
- 'type' => '89026'
+ 'type' => '137431'
}
},
'Return' => '100',
'ShortName' => 'decode_numeric_sensor_pdr_data'
},
- '89031' => {
+ '137436' => {
'Header' => 'platform.h',
'Line' => '1895',
'Param' => {
@@ -2152,13 +2152,13 @@
}
},
'Reg' => {
- '0' => 'rdi',
+ '3' => 'r10',
'5' => 'r9'
},
'Return' => '100',
'ShortName' => 'decode_numeric_sensor_data'
},
- '91543' => {
+ '140072' => {
'Header' => 'platform.h',
'Line' => '1874',
'Param' => {
@@ -2185,14 +2185,14 @@
},
'Reg' => {
'0' => 'rdi',
- '2' => 'r9',
- '3' => 'rdx',
+ '2' => 'rdx',
+ '3' => 'r9',
'4' => 'r8'
},
'Return' => '100',
'ShortName' => 'decode_state_sensor_data'
},
- '92500' => {
+ '141147' => {
'Header' => 'platform.h',
'Line' => '1856',
'Param' => {
@@ -2221,7 +2221,7 @@
'Return' => '100',
'ShortName' => 'decode_sensor_op_data'
},
- '93239' => {
+ '142003' => {
'Header' => 'platform.h',
'Line' => '1839',
'Param' => {
@@ -2249,7 +2249,7 @@
'Return' => '100',
'ShortName' => 'decode_sensor_event_data'
},
- '94093' => {
+ '142935' => {
'Header' => 'platform.h',
'Line' => '1818',
'Param' => {
@@ -2289,13 +2289,14 @@
}
},
'Reg' => {
+ '3' => 'r10',
'4' => 'r8',
'5' => 'r9'
},
'Return' => '100',
'ShortName' => 'decode_event_message_supported_resp'
},
- '95616' => {
+ '144566' => {
'Header' => 'platform.h',
'Line' => '1801',
'Param' => {
@@ -2315,7 +2316,7 @@
'Return' => '100',
'ShortName' => 'encode_event_message_supported_req'
},
- '95812' => {
+ '144762' => {
'Header' => 'platform.h',
'Line' => '1774',
'Param' => {
@@ -2339,7 +2340,7 @@
'Return' => '100',
'ShortName' => 'decode_event_message_buffer_size_resp'
},
- '96661' => {
+ '145741' => {
'Header' => 'platform.h',
'Line' => '1787',
'Param' => {
@@ -2362,7 +2363,7 @@
'Return' => '100',
'ShortName' => 'encode_event_message_buffer_size_req'
},
- '96857' => {
+ '145937' => {
'Header' => 'platform.h',
'Line' => '1763',
'Param' => {
@@ -2384,13 +2385,12 @@
}
},
'Reg' => {
- '0' => 'r8',
- '3' => 'rdi'
+ '3' => 'r8'
},
'Return' => '100',
'ShortName' => 'decode_platform_event_message_resp'
},
- '97572' => {
+ '146743' => {
'Header' => 'platform.h',
'Line' => '1706',
'Param' => {
@@ -2432,7 +2432,7 @@
'Return' => '100',
'ShortName' => 'encode_platform_event_message_req'
},
- '97971' => {
+ '147142' => {
'Header' => 'platform.h',
'Line' => '1686',
'Param' => {
@@ -2494,7 +2494,7 @@
'Return' => '100',
'ShortName' => 'encode_poll_for_platform_event_message_resp'
},
- '100524' => {
+ '149836' => {
'Header' => 'platform.h',
'Line' => '1664',
'Param' => {
@@ -2518,7 +2518,7 @@
'Return' => '100',
'ShortName' => 'encode_platform_event_message_resp'
},
- '100740' => {
+ '150052' => {
'Header' => 'platform.h',
'Line' => '1649',
'Param' => {
@@ -2550,7 +2550,7 @@
'Return' => '100',
'ShortName' => 'decode_poll_for_platform_event_message_req'
},
- '102090' => {
+ '151488' => {
'Header' => 'platform.h',
'Line' => '1633',
'Param' => {
@@ -2580,7 +2580,7 @@
}
},
'Reg' => {
- '0' => 'rdi',
+ '1' => 'rsi',
'2' => 'rdx',
'3' => 'r10',
'4' => 'r8',
@@ -2589,13 +2589,13 @@
'Return' => '100',
'ShortName' => 'decode_platform_event_message_req'
},
- '103067' => {
+ '152601' => {
'Header' => 'platform.h',
'Line' => '2060',
'Param' => {
'0' => {
'name' => 'event_data',
- 'type' => '103257'
+ 'type' => '152791'
},
'1' => {
'name' => 'event_data_size',
@@ -2607,7 +2607,7 @@
},
'3' => {
'name' => 'sensor_event_class',
- 'type' => '14081'
+ 'type' => '14122'
},
'4' => {
'name' => 'sensor_offset',
@@ -2624,7 +2624,7 @@
},
'7' => {
'name' => 'actual_event_data_size',
- 'type' => '50320'
+ 'type' => '70429'
}
},
'Reg' => {
@@ -2638,7 +2638,7 @@
'Return' => '100',
'ShortName' => 'encode_sensor_event_data'
},
- '103272' => {
+ '152806' => {
'Header' => 'platform.h',
'Line' => '1278',
'Param' => {
@@ -2666,7 +2666,7 @@
'Return' => '100',
'ShortName' => 'decode_get_state_sensor_readings_req'
},
- '104346' => {
+ '154003' => {
'Header' => 'platform.h',
'Line' => '1614',
'Param' => {
@@ -2688,17 +2688,18 @@
},
'4' => {
'name' => 'field',
- 'type' => '105946'
+ 'type' => '155712'
}
},
'Reg' => {
- '3' => 'rdi',
+ '1' => 'rsi',
+ '3' => 'r9',
'4' => 'r8'
},
'Return' => '100',
'ShortName' => 'decode_get_state_sensor_readings_resp'
},
- '105951' => {
+ '155717' => {
'Header' => 'platform.h',
'Line' => '1594',
'Param' => {
@@ -2726,7 +2727,7 @@
'Return' => '100',
'ShortName' => 'encode_get_state_sensor_readings_req'
},
- '106187' => {
+ '155953' => {
'Header' => 'platform.h',
'Line' => '1298',
'Param' => {
@@ -2744,7 +2745,7 @@
},
'3' => {
'name' => 'field',
- 'type' => '105946'
+ 'type' => '155712'
},
'4' => {
'name' => 'msg',
@@ -2754,7 +2755,7 @@
'Return' => '100',
'ShortName' => 'encode_get_state_sensor_readings_resp'
},
- '106539' => {
+ '156305' => {
'Header' => 'platform.h',
'Line' => '1575',
'Param' => {
@@ -2779,7 +2780,7 @@
'Return' => '100',
'ShortName' => 'decode_set_numeric_effecter_value_resp'
},
- '106615' => {
+ '156381' => {
'Header' => 'platform.h',
'Line' => '1562',
'Param' => {
@@ -2814,7 +2815,7 @@
'Return' => '100',
'ShortName' => 'encode_set_numeric_effecter_value_req'
},
- '107083' => {
+ '156849' => {
'Header' => 'platform.h',
'Line' => '1169',
'Param' => {
@@ -2838,7 +2839,7 @@
'Return' => '100',
'ShortName' => 'encode_set_numeric_effecter_value_resp'
},
- '107274' => {
+ '157040' => {
'Header' => 'platform.h',
'Line' => '1153',
'Param' => {
@@ -2866,7 +2867,7 @@
'Return' => '100',
'ShortName' => 'decode_set_numeric_effecter_value_req'
},
- '109750' => {
+ '159639' => {
'Header' => 'platform.h',
'Line' => '1493',
'Param' => {
@@ -2921,7 +2922,7 @@
'Return' => '100',
'ShortName' => 'decode_get_pdr_resp'
},
- '111923' => {
+ '161942' => {
'Header' => 'platform.h',
'Line' => '1462',
'Param' => {
@@ -2966,7 +2967,7 @@
'Return' => '100',
'ShortName' => 'encode_get_pdr_req'
},
- '112211' => {
+ '162230' => {
'Header' => 'platform.h',
'Line' => '1436',
'Param' => {
@@ -3018,7 +3019,7 @@
'Return' => '100',
'ShortName' => 'decode_get_pdr_repository_info_resp'
},
- '114555' => {
+ '164705' => {
'Header' => 'platform.h',
'Line' => '1412',
'Param' => {
@@ -3070,7 +3071,7 @@
'Return' => '100',
'ShortName' => 'encode_get_pdr_repository_info_resp'
},
- '115031' => {
+ '165181' => {
'Header' => 'platform.h',
'Line' => '1236',
'Param' => {
@@ -3117,7 +3118,7 @@
'Return' => '100',
'ShortName' => 'encode_get_pdr_resp'
},
- '115483' => {
+ '165633' => {
'Header' => 'platform.h',
'Line' => '1257',
'Param' => {
@@ -3154,7 +3155,7 @@
'Return' => '100',
'ShortName' => 'decode_get_pdr_req'
},
- '117249' => {
+ '167524' => {
'Header' => 'platform.h',
'Line' => '1208',
'Param' => {
@@ -3176,13 +3177,13 @@
},
'4' => {
'name' => 'field',
- 'type' => '118556'
+ 'type' => '168936'
}
},
'Return' => '100',
'ShortName' => 'decode_set_state_effecter_states_req'
},
- '118561' => {
+ '168941' => {
'Header' => 'platform.h',
'Line' => '1541',
'Param' => {
@@ -3207,7 +3208,7 @@
'Return' => '100',
'ShortName' => 'decode_set_state_effecter_states_resp'
},
- '118634' => {
+ '169014' => {
'Header' => 'platform.h',
'Line' => '1522',
'Param' => {
@@ -3225,7 +3226,7 @@
},
'3' => {
'name' => 'field',
- 'type' => '118556'
+ 'type' => '168936'
},
'4' => {
'name' => 'msg',
@@ -3238,7 +3239,7 @@
'Return' => '100',
'ShortName' => 'encode_set_state_effecter_states_req'
},
- '118977' => {
+ '169357' => {
'Header' => 'platform.h',
'Line' => '1186',
'Param' => {
@@ -3258,13 +3259,13 @@
'Return' => '100',
'ShortName' => 'encode_set_state_effecter_states_resp'
},
- '119143' => {
+ '169523' => {
'Header' => 'platform.h',
'Line' => '631',
'Param' => {
'0' => {
'name' => 'sensor',
- 'type' => '119527'
+ 'type' => '169907'
},
'1' => {
'name' => 'allocation_size',
@@ -3272,7 +3273,7 @@
},
'2' => {
'name' => 'possible_states',
- 'type' => '119537'
+ 'type' => '169917'
},
'3' => {
'name' => 'possible_states_size',
@@ -3280,7 +3281,7 @@
},
'4' => {
'name' => 'actual_size',
- 'type' => '50320'
+ 'type' => '70429'
}
},
'Reg' => {
@@ -3293,13 +3294,13 @@
'Return' => '100',
'ShortName' => 'encode_state_sensor_pdr'
},
- '119547' => {
+ '169927' => {
'Header' => 'platform.h',
'Line' => '833',
'Param' => {
'0' => {
'name' => 'effecter',
- 'type' => '119931'
+ 'type' => '170311'
},
'1' => {
'name' => 'allocation_size',
@@ -3307,7 +3308,7 @@
},
'2' => {
'name' => 'possible_states',
- 'type' => '119941'
+ 'type' => '170321'
},
'3' => {
'name' => 'possible_states_size',
@@ -3315,7 +3316,7 @@
},
'4' => {
'name' => 'actual_size',
- 'type' => '50320'
+ 'type' => '70429'
}
},
'Reg' => {
@@ -3328,7 +3329,7 @@
'Return' => '100',
'ShortName' => 'encode_state_effecter_pdr'
},
- '124627' => {
+ '176735' => {
'Header' => 'utils.h',
'Line' => '39',
'Param' => {
@@ -3347,7 +3348,7 @@
'Return' => '152',
'ShortName' => 'crc32'
},
- '124710' => {
+ '176818' => {
'Header' => 'bios_table.h',
'Line' => '633',
'Param' => {
@@ -3367,7 +3368,7 @@
'Return' => '5123',
'ShortName' => 'pldm_bios_table_checksum'
},
- '124855' => {
+ '176963' => {
'Header' => 'bios_table.h',
'Line' => '624',
'Param' => {
@@ -3403,7 +3404,7 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_value_copy_and_update'
},
- '125543' => {
+ '177651' => {
'Header' => 'bios_table.h',
'Line' => '590',
'Param' => {
@@ -3423,10 +3424,10 @@
'Reg' => {
'2' => 'r8'
},
- 'Return' => '125538',
+ 'Return' => '177646',
'ShortName' => 'pldm_bios_table_attr_value_find_by_handle'
},
- '125806' => {
+ '177914' => {
'Header' => 'bios_table.h',
'Line' => '197',
'Param' => {
@@ -3446,10 +3447,10 @@
'Reg' => {
'2' => 'r8'
},
- 'Return' => '125952',
+ 'Return' => '178060',
'ShortName' => 'pldm_bios_table_attr_find_by_string_handle'
},
- '126073' => {
+ '178181' => {
'Header' => 'bios_table.h',
'Line' => '187',
'Param' => {
@@ -3469,10 +3470,10 @@
'Reg' => {
'2' => 'r8'
},
- 'Return' => '125952',
+ 'Return' => '178060',
'ShortName' => 'pldm_bios_table_attr_find_by_handle'
},
- '126335' => {
+ '178443' => {
'Header' => 'bios_table.h',
'Line' => '146',
'Param' => {
@@ -3494,10 +3495,10 @@
'1' => 'r12',
'2' => 'rbx'
},
- 'Return' => '126556',
+ 'Return' => '178664',
'ShortName' => 'pldm_bios_table_string_find_by_string'
},
- '126725' => {
+ '178833' => {
'Header' => 'bios_table.h',
'Line' => '155',
'Param' => {
@@ -3517,16 +3518,16 @@
'Reg' => {
'2' => 'r8'
},
- 'Return' => '126556',
+ 'Return' => '178664',
'ShortName' => 'pldm_bios_table_string_find_by_handle'
},
- '127486' => {
+ '179594' => {
'Header' => 'bios_table.h',
'Line' => '52',
'Param' => {
'0' => {
'name' => 'iter',
- 'type' => '125533'
+ 'type' => '177641'
}
},
'Reg' => {
@@ -3535,43 +3536,43 @@
'Return' => '5342',
'ShortName' => 'pldm_bios_table_iter_value'
},
- '127534' => {
+ '179642' => {
'Header' => 'bios_table.h',
'Line' => '46',
'Param' => {
'0' => {
'name' => 'iter',
- 'type' => '125533'
+ 'type' => '177641'
}
},
'Return' => '1',
'ShortName' => 'pldm_bios_table_iter_next'
},
- '127644' => {
+ '179752' => {
'Header' => 'bios_table.h',
'Line' => '41',
'Param' => {
'0' => {
'name' => 'iter',
- 'type' => '127719'
+ 'type' => '179827'
}
},
'Return' => '5123',
'ShortName' => 'pldm_bios_table_iter_is_end'
},
- '127724' => {
+ '179832' => {
'Header' => 'bios_table.h',
'Line' => '34',
'Param' => {
'0' => {
'name' => 'iter',
- 'type' => '125533'
+ 'type' => '177641'
}
},
'Return' => '1',
'ShortName' => 'pldm_bios_table_iter_free'
},
- '127796' => {
+ '179904' => {
'Header' => 'bios_table.h',
'Line' => '28',
'Param' => {
@@ -3585,7 +3586,7 @@
},
'2' => {
'name' => 'type',
- 'type' => '123409'
+ 'type' => '175517'
}
},
'Reg' => {
@@ -3593,10 +3594,10 @@
'1' => 'r12',
'2' => 'rbx'
},
- 'Return' => '125533',
+ 'Return' => '177641',
'ShortName' => 'pldm_bios_table_iter_create'
},
- '128034' => {
+ '180142' => {
'Header' => 'bios_table.h',
'Line' => '609',
'Param' => {
@@ -3621,7 +3622,7 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_append_pad_checksum_check'
},
- '128334' => {
+ '180442' => {
'Header' => 'bios_table.h',
'Line' => '597',
'Param' => {
@@ -3633,13 +3634,13 @@
'Return' => '453',
'ShortName' => 'pldm_bios_table_pad_checksum_size'
},
- '128689' => {
+ '180797' => {
'Header' => 'bios_table.h',
'Line' => '572',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
}
},
'Reg' => {
@@ -3648,34 +3649,34 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_attr_value_entry_decode_handle'
},
- '128738' => {
+ '180846' => {
'Header' => 'bios_table.h',
'Line' => '579',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
}
},
'Return' => '453',
'ShortName' => 'pldm_bios_table_attr_value_entry_length'
},
- '129222' => {
+ '181330' => {
'Header' => 'bios_table.h',
'Line' => '546',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
}
},
'Reg' => {
'0' => 'rdi'
},
- 'Return' => '123263',
+ 'Return' => '175371',
'ShortName' => 'pldm_bios_table_attr_value_entry_integer_decode_cv'
},
- '129362' => {
+ '181470' => {
'Header' => 'bios_table.h',
'Line' => '562',
'Param' => {
@@ -3697,7 +3698,7 @@
},
'4' => {
'name' => 'cv',
- 'type' => '123263'
+ 'type' => '175371'
}
},
'Reg' => {
@@ -3710,13 +3711,13 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_value_entry_encode_integer_check'
},
- '129631' => {
+ '181739' => {
'Header' => 'bios_table.h',
'Line' => '540',
'Return' => '453',
'ShortName' => 'pldm_bios_table_attr_value_entry_encode_integer_length'
},
- '129793' => {
+ '181901' => {
'Header' => 'bios_table.h',
'Line' => '533',
'Param' => {
@@ -3756,13 +3757,13 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_value_entry_encode_string_check'
},
- '130193' => {
+ '182301' => {
'Header' => 'bios_table.h',
'Line' => '514',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
},
'1' => {
'name' => 'current_string',
@@ -3772,13 +3773,13 @@
'Return' => '1',
'ShortName' => 'pldm_bios_table_attr_value_entry_string_decode_string'
},
- '130288' => {
+ '182396' => {
'Header' => 'bios_table.h',
'Line' => '504',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
}
},
'Reg' => {
@@ -3787,7 +3788,7 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_attr_value_entry_string_decode_length'
},
- '130429' => {
+ '182537' => {
'Header' => 'bios_table.h',
'Line' => '498',
'Param' => {
@@ -3802,7 +3803,7 @@
'Return' => '453',
'ShortName' => 'pldm_bios_table_attr_value_entry_encode_string_length'
},
- '130611' => {
+ '182719' => {
'Header' => 'bios_table.h',
'Line' => '488',
'Param' => {
@@ -3839,13 +3840,13 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_value_entry_encode_enum_check'
},
- '130930' => {
+ '183038' => {
'Header' => 'bios_table.h',
'Line' => '469',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
},
'1' => {
'name' => 'handles',
@@ -3859,13 +3860,13 @@
'Return' => '140',
'ShortName' => 'pldm_bios_table_attr_value_entry_enum_decode_handles'
},
- '131177' => {
+ '183285' => {
'Header' => 'bios_table.h',
'Line' => '459',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
}
},
'Reg' => {
@@ -3874,7 +3875,7 @@
'Return' => '140',
'ShortName' => 'pldm_bios_table_attr_value_entry_enum_decode_number'
},
- '131226' => {
+ '183334' => {
'Header' => 'bios_table.h',
'Line' => '453',
'Param' => {
@@ -3889,13 +3890,13 @@
'Return' => '453',
'ShortName' => 'pldm_bios_table_attr_value_entry_encode_enum_length'
},
- '131275' => {
+ '183383' => {
'Header' => 'bios_table.h',
'Line' => '446',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
}
},
'Reg' => {
@@ -3904,13 +3905,13 @@
'Return' => '140',
'ShortName' => 'pldm_bios_table_attr_value_entry_decode_attribute_type'
},
- '131324' => {
+ '183432' => {
'Header' => 'bios_table.h',
'Line' => '439',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125538'
+ 'type' => '177646'
}
},
'Reg' => {
@@ -3919,21 +3920,21 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_attr_value_entry_decode_attribute_handle'
},
- '131871' => {
+ '183979' => {
'Header' => 'bios_table.h',
'Line' => '431',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
},
'1' => {
'name' => 'lower',
- 'type' => '131992'
+ 'type' => '184100'
},
'2' => {
'name' => 'upper',
- 'type' => '131992'
+ 'type' => '184100'
},
'3' => {
'name' => 'scalar',
@@ -3941,7 +3942,7 @@
},
'4' => {
'name' => 'def',
- 'type' => '131992'
+ 'type' => '184100'
}
},
'Reg' => {
@@ -3954,7 +3955,7 @@
'Return' => '1',
'ShortName' => 'pldm_bios_table_attr_entry_integer_decode'
},
- '132007' => {
+ '184115' => {
'Header' => 'bios_table.h',
'Line' => '419',
'Param' => {
@@ -3968,7 +3969,7 @@
},
'2' => {
'name' => 'info',
- 'type' => '132269'
+ 'type' => '184377'
}
},
'Reg' => {
@@ -3979,35 +3980,35 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_integer_encode_check'
},
- '132279' => {
+ '184387' => {
'Header' => 'bios_table.h',
'Line' => '400',
'Param' => {
'0' => {
'name' => 'info',
- 'type' => '132269'
+ 'type' => '184377'
},
'1' => {
'name' => 'errmsg',
- 'type' => '132578'
+ 'type' => '184686'
}
},
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_integer_info_check'
},
- '132583' => {
+ '184691' => {
'Header' => 'bios_table.h',
'Line' => '407',
'Return' => '453',
'ShortName' => 'pldm_bios_table_attr_entry_integer_encode_length'
},
- '132745' => {
+ '184853' => {
'Header' => 'bios_table.h',
'Line' => '374',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
},
'1' => {
'name' => 'buffer',
@@ -4021,13 +4022,13 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_attr_entry_string_decode_def_string'
},
- '133014' => {
+ '185122' => {
'Header' => 'bios_table.h',
'Line' => '366',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
}
},
'Reg' => {
@@ -4036,13 +4037,13 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_attr_entry_string_decode_min_length'
},
- '133083' => {
+ '185191' => {
'Header' => 'bios_table.h',
'Line' => '358',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
}
},
'Reg' => {
@@ -4051,13 +4052,13 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_attr_entry_string_decode_max_length'
},
- '133152' => {
+ '185260' => {
'Header' => 'bios_table.h',
'Line' => '350',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
}
},
'Reg' => {
@@ -4066,13 +4067,13 @@
'Return' => '140',
'ShortName' => 'pldm_bios_table_attr_entry_string_decode_string_type'
},
- '133221' => {
+ '185329' => {
'Header' => 'bios_table.h',
'Line' => '342',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
},
'1' => {
'name' => 'def_string_length',
@@ -4086,7 +4087,7 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_string_decode_def_string_length_check'
},
- '133391' => {
+ '185499' => {
'Header' => 'bios_table.h',
'Line' => '331',
'Param' => {
@@ -4100,7 +4101,7 @@
},
'2' => {
'name' => 'info',
- 'type' => '133750'
+ 'type' => '185858'
}
},
'Reg' => {
@@ -4110,17 +4111,17 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_string_encode_check'
},
- '133755' => {
+ '185863' => {
'Header' => 'bios_table.h',
'Line' => '310',
'Param' => {
'0' => {
'name' => 'info',
- 'type' => '133750'
+ 'type' => '185858'
},
'1' => {
'name' => 'errmsg',
- 'type' => '132578'
+ 'type' => '184686'
}
},
'Reg' => {
@@ -4129,7 +4130,7 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_string_info_check'
},
- '134024' => {
+ '186132' => {
'Header' => 'bios_table.h',
'Line' => '318',
'Param' => {
@@ -4144,13 +4145,13 @@
'Return' => '453',
'ShortName' => 'pldm_bios_table_attr_entry_string_encode_length'
},
- '134256' => {
+ '186364' => {
'Header' => 'bios_table.h',
'Line' => '284',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
},
'1' => {
'name' => 'def_indices',
@@ -4164,13 +4165,13 @@
'Return' => '140',
'ShortName' => 'pldm_bios_table_attr_entry_enum_decode_def_indices'
},
- '134535' => {
+ '186643' => {
'Header' => 'bios_table.h',
'Line' => '272',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
},
'1' => {
'name' => 'pv_hdls',
@@ -4189,13 +4190,13 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_enum_decode_pv_hdls_check'
},
- '134700' => {
+ '186808' => {
'Header' => 'bios_table.h',
'Line' => '255',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
},
'1' => {
'name' => 'def_num',
@@ -4209,13 +4210,13 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_enum_decode_def_num_check'
},
- '134861' => {
+ '186969' => {
'Header' => 'bios_table.h',
'Line' => '245',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
},
'1' => {
'name' => 'pv_num',
@@ -4229,7 +4230,7 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_enum_decode_pv_num_check'
},
- '134921' => {
+ '187029' => {
'Header' => 'bios_table.h',
'Line' => '234',
'Param' => {
@@ -4243,7 +4244,7 @@
},
'2' => {
'name' => 'info',
- 'type' => '135250'
+ 'type' => '187358'
}
},
'Reg' => {
@@ -4253,7 +4254,7 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_attr_entry_enum_encode_check'
},
- '135255' => {
+ '187363' => {
'Header' => 'bios_table.h',
'Line' => '220',
'Param' => {
@@ -4273,13 +4274,13 @@
'Return' => '453',
'ShortName' => 'pldm_bios_table_attr_entry_enum_encode_length'
},
- '135315' => {
+ '187423' => {
'Header' => 'bios_table.h',
'Line' => '177',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
}
},
'Reg' => {
@@ -4288,13 +4289,13 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_attr_entry_decode_string_handle'
},
- '135362' => {
+ '187470' => {
'Header' => 'bios_table.h',
'Line' => '169',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
}
},
'Reg' => {
@@ -4303,13 +4304,13 @@
'Return' => '140',
'ShortName' => 'pldm_bios_table_attr_entry_decode_attribute_type'
},
- '135409' => {
+ '187517' => {
'Header' => 'bios_table.h',
'Line' => '162',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '125952'
+ 'type' => '178060'
}
},
'Reg' => {
@@ -4318,13 +4319,13 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_attr_entry_decode_attribute_handle'
},
- '136042' => {
+ '188150' => {
'Header' => 'bios_table.h',
'Line' => '135',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '126556'
+ 'type' => '178664'
},
'1' => {
'name' => 'buffer',
@@ -4343,13 +4344,13 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_string_entry_decode_string_check'
},
- '136279' => {
+ '188387' => {
'Header' => 'bios_table.h',
'Line' => '120',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '126556'
+ 'type' => '178664'
}
},
'Reg' => {
@@ -4358,13 +4359,13 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_string_entry_decode_string_length'
},
- '136326' => {
+ '188434' => {
'Header' => 'bios_table.h',
'Line' => '113',
'Param' => {
'0' => {
'name' => 'entry',
- 'type' => '126556'
+ 'type' => '178664'
}
},
'Reg' => {
@@ -4373,7 +4374,7 @@
'Return' => '5573',
'ShortName' => 'pldm_bios_table_string_entry_decode_handle'
},
- '136373' => {
+ '188481' => {
'Header' => 'bios_table.h',
'Line' => '105',
'Param' => {
@@ -4397,7 +4398,7 @@
'Return' => '100',
'ShortName' => 'pldm_bios_table_string_entry_encode_check'
},
- '136734' => {
+ '188842' => {
'Header' => 'bios_table.h',
'Line' => '91',
'Param' => {
@@ -4412,7 +4413,7 @@
'Return' => '453',
'ShortName' => 'pldm_bios_table_string_entry_encode_length'
},
- '142777' => {
+ '194926' => {
'Header' => 'utils.h',
'Line' => '108',
'Param' => {
@@ -4424,7 +4425,7 @@
'Return' => '5123',
'ShortName' => 'is_transfer_flag_valid'
},
- '142923' => {
+ '195072' => {
'Header' => 'firmware_update.h',
'Line' => '1285',
'Param' => {
@@ -4442,11 +4443,11 @@
},
'3' => {
'name' => 'non_functioning_component_indication',
- 'type' => '143105'
+ 'type' => '195254'
},
'4' => {
'name' => 'non_functioning_component_bitmap',
- 'type' => '143110'
+ 'type' => '195259'
}
},
'Reg' => {
@@ -4457,7 +4458,7 @@
'Return' => '100',
'ShortName' => 'decode_cancel_update_resp'
},
- '143120' => {
+ '195269' => {
'Header' => 'firmware_update.h',
'Line' => '1268',
'Param' => {
@@ -4477,7 +4478,7 @@
'Return' => '100',
'ShortName' => 'encode_cancel_update_req'
},
- '143291' => {
+ '195441' => {
'Header' => 'firmware_update.h',
'Line' => '1253',
'Param' => {
@@ -4502,7 +4503,7 @@
'Return' => '100',
'ShortName' => 'decode_cancel_update_component_resp'
},
- '143367' => {
+ '195517' => {
'Header' => 'firmware_update.h',
'Line' => '1241',
'Param' => {
@@ -4522,7 +4523,7 @@
'Return' => '100',
'ShortName' => 'encode_cancel_update_component_req'
},
- '143538' => {
+ '195689' => {
'Header' => 'firmware_update.h',
'Line' => '1223',
'Param' => {
@@ -4568,7 +4569,7 @@
'9' => {
'name' => 'update_option_flags_enabled',
'offset' => '24',
- 'type' => '143865'
+ 'type' => '196016'
}
},
'Reg' => {
@@ -4580,7 +4581,7 @@
'Return' => '100',
'ShortName' => 'decode_get_status_resp'
},
- '143875' => {
+ '196026' => {
'Header' => 'firmware_update.h',
'Line' => '1203',
'Param' => {
@@ -4600,7 +4601,7 @@
'Return' => '100',
'ShortName' => 'encode_get_status_req'
},
- '144046' => {
+ '196198' => {
'Header' => 'firmware_update.h',
'Line' => '1187',
'Param' => {
@@ -4629,7 +4630,7 @@
'Return' => '100',
'ShortName' => 'decode_activate_firmware_resp'
},
- '144172' => {
+ '196324' => {
'Header' => 'firmware_update.h',
'Line' => '1173',
'Param' => {
@@ -4653,7 +4654,7 @@
'Return' => '100',
'ShortName' => 'encode_activate_firmware_req'
},
- '144414' => {
+ '196567' => {
'Header' => 'firmware_update.h',
'Line' => '1158',
'Param' => {
@@ -4677,7 +4678,7 @@
'Return' => '100',
'ShortName' => 'encode_apply_complete_resp'
},
- '144604' => {
+ '196758' => {
'Header' => 'firmware_update.h',
'Line' => '1141',
'Param' => {
@@ -4695,7 +4696,7 @@
},
'3' => {
'name' => 'comp_activation_methods_modification',
- 'type' => '144714'
+ 'type' => '196868'
}
},
'Reg' => {
@@ -4707,7 +4708,7 @@
'Return' => '100',
'ShortName' => 'decode_apply_complete_req'
},
- '144724' => {
+ '196878' => {
'Header' => 'firmware_update.h',
'Line' => '1128',
'Param' => {
@@ -4731,7 +4732,7 @@
'Return' => '100',
'ShortName' => 'encode_verify_complete_resp'
},
- '144914' => {
+ '197069' => {
'Header' => 'firmware_update.h',
'Line' => '1113',
'Param' => {
@@ -4756,7 +4757,7 @@
'Return' => '100',
'ShortName' => 'decode_verify_complete_req'
},
- '144990' => {
+ '197145' => {
'Header' => 'firmware_update.h',
'Line' => '1102',
'Param' => {
@@ -4780,7 +4781,7 @@
'Return' => '100',
'ShortName' => 'encode_transfer_complete_resp'
},
- '145180' => {
+ '197336' => {
'Header' => 'firmware_update.h',
'Line' => '1086',
'Param' => {
@@ -4805,7 +4806,7 @@
'Return' => '100',
'ShortName' => 'decode_transfer_complete_req'
},
- '145256' => {
+ '197412' => {
'Header' => 'firmware_update.h',
'Line' => '1073',
'Param' => {
@@ -4832,7 +4833,7 @@
'Return' => '100',
'ShortName' => 'encode_request_firmware_data_resp'
},
- '145446' => {
+ '197603' => {
'Header' => 'firmware_update.h',
'Line' => '1051',
'Param' => {
@@ -4862,7 +4863,7 @@
'Return' => '100',
'ShortName' => 'decode_request_firmware_data_req'
},
- '145566' => {
+ '197723' => {
'Header' => 'firmware_update.h',
'Line' => '1033',
'Param' => {
@@ -4888,7 +4889,7 @@
},
'5' => {
'name' => 'update_option_flags_enabled',
- 'type' => '143865'
+ 'type' => '196016'
},
'6' => {
'name' => 'time_before_req_fw_data',
@@ -4905,7 +4906,7 @@
'Return' => '100',
'ShortName' => 'decode_update_component_resp'
},
- '145800' => {
+ '197957' => {
'Header' => 'firmware_update.h',
'Line' => '1009',
'Param' => {
@@ -4936,7 +4937,7 @@
'6' => {
'name' => 'update_option_flags',
'offset' => '0',
- 'type' => '138232'
+ 'type' => '190340'
},
'7' => {
'name' => 'comp_ver_str_type',
@@ -4951,7 +4952,7 @@
'9' => {
'name' => 'comp_ver_str',
'offset' => '24',
- 'type' => '146268'
+ 'type' => '198426'
},
'10' => {
'name' => 'msg',
@@ -4967,7 +4968,7 @@
'Return' => '100',
'ShortName' => 'encode_update_component_req'
},
- '146278' => {
+ '198436' => {
'Header' => 'firmware_update.h',
'Line' => '982',
'Param' => {
@@ -5000,7 +5001,7 @@
'Return' => '100',
'ShortName' => 'decode_pass_component_table_resp'
},
- '146477' => {
+ '198635' => {
'Header' => 'firmware_update.h',
'Line' => '964',
'Param' => {
@@ -5041,7 +5042,7 @@
'8' => {
'name' => 'comp_ver_str',
'offset' => '16',
- 'type' => '146268'
+ 'type' => '198426'
},
'9' => {
'name' => 'msg',
@@ -5057,7 +5058,7 @@
'Return' => '100',
'ShortName' => 'encode_pass_component_table_req'
},
- '146962' => {
+ '199121' => {
'Header' => 'firmware_update.h',
'Line' => '939',
'Param' => {
@@ -5091,7 +5092,7 @@
'Return' => '100',
'ShortName' => 'decode_request_update_resp'
},
- '147109' => {
+ '199268' => {
'Header' => 'firmware_update.h',
'Line' => '920',
'Param' => {
@@ -5127,7 +5128,7 @@
'7' => {
'name' => 'comp_img_set_ver_str',
'offset' => '8',
- 'type' => '146268'
+ 'type' => '198426'
},
'8' => {
'name' => 'msg',
@@ -5143,7 +5144,7 @@
'Return' => '100',
'ShortName' => 'encode_request_update_req'
},
- '151924' => {
+ '204393' => {
'Header' => 'firmware_update.h',
'Line' => '827',
'Param' => {
@@ -5157,7 +5158,7 @@
},
'2' => {
'name' => 'component_data',
- 'type' => '152246'
+ 'type' => '204715'
},
'3' => {
'name' => 'active_comp_ver_str',
@@ -5177,7 +5178,7 @@
'Return' => '100',
'ShortName' => 'decode_get_firmware_parameters_resp_comp_entry'
},
- '152251' => {
+ '204720' => {
'Header' => 'firmware_update.h',
'Line' => '808',
'Param' => {
@@ -5191,7 +5192,7 @@
},
'2' => {
'name' => 'resp_data',
- 'type' => '152471'
+ 'type' => '204940'
},
'3' => {
'name' => 'active_comp_image_set_ver_str',
@@ -5217,7 +5218,7 @@
'Return' => '100',
'ShortName' => 'decode_get_firmware_parameters_resp'
},
- '152476' => {
+ '204945' => {
'Header' => 'firmware_update.h',
'Line' => '791',
'Param' => {
@@ -5242,7 +5243,7 @@
'Return' => '100',
'ShortName' => 'encode_get_firmware_parameters_req'
},
- '152616' => {
+ '205085' => {
'Header' => 'firmware_update.h',
'Line' => '773',
'Param' => {
@@ -5268,7 +5269,7 @@
},
'5' => {
'name' => 'descriptor_data',
- 'type' => '152772'
+ 'type' => '205241'
}
},
'Reg' => {
@@ -5280,7 +5281,7 @@
'Return' => '100',
'ShortName' => 'decode_query_device_identifiers_resp'
},
- '152782' => {
+ '205251' => {
'Header' => 'firmware_update.h',
'Line' => '758',
'Param' => {
@@ -5305,7 +5306,7 @@
'Return' => '100',
'ShortName' => 'encode_query_device_identifiers_req'
},
- '152922' => {
+ '205391' => {
'Header' => 'firmware_update.h',
'Line' => '742',
'Param' => {
@@ -5319,7 +5320,7 @@
},
'2' => {
'name' => 'pldm_comp_image_info',
- 'type' => '153069'
+ 'type' => '205538'
},
'3' => {
'name' => 'comp_version_str',
@@ -5335,7 +5336,7 @@
'Return' => '100',
'ShortName' => 'decode_pldm_comp_image_info'
},
- '153074' => {
+ '205543' => {
'Header' => 'firmware_update.h',
'Line' => '727',
'Param' => {
@@ -5370,7 +5371,7 @@
'Return' => '100',
'ShortName' => 'decode_vendor_defined_descriptor_value'
},
- '153256' => {
+ '205725' => {
'Header' => 'firmware_update.h',
'Line' => '711',
'Param' => {
@@ -5399,7 +5400,7 @@
'Return' => '100',
'ShortName' => 'decode_descriptor_type_length_value'
},
- '153428' => {
+ '205897' => {
'Header' => 'firmware_update.h',
'Line' => '692',
'Param' => {
@@ -5417,7 +5418,7 @@
},
'3' => {
'name' => 'fw_device_id_record',
- 'type' => '153685'
+ 'type' => '206154'
},
'4' => {
'name' => 'applicable_components',
@@ -5447,7 +5448,7 @@
'Return' => '100',
'ShortName' => 'decode_firmware_device_id_record'
},
- '153690' => {
+ '206159' => {
'Header' => 'firmware_update.h',
'Line' => '671',
'Param' => {
@@ -5461,7 +5462,7 @@
},
'2' => {
'name' => 'package_header_info',
- 'type' => '153995'
+ 'type' => '206464'
},
'3' => {
'name' => 'package_version_str',
@@ -5477,7 +5478,7 @@
'Return' => '100',
'ShortName' => 'decode_pldm_package_header_info'
},
- '156958' => {
+ '209739' => {
'Header' => 'fru.h',
'Line' => '501',
'Param' => {
@@ -5505,7 +5506,7 @@
'Return' => '100',
'ShortName' => 'encode_set_fru_record_table_resp'
},
- '157198' => {
+ '209979' => {
'Header' => 'fru.h',
'Line' => '486',
'Param' => {
@@ -5539,7 +5540,7 @@
'Return' => '100',
'ShortName' => 'decode_set_fru_record_table_req'
},
- '157365' => {
+ '210146' => {
'Header' => 'fru.h',
'Line' => '360',
'Param' => {
@@ -5576,7 +5577,7 @@
'Return' => '100',
'ShortName' => 'decode_get_fru_record_table_resp'
},
- '157595' => {
+ '210376' => {
'Header' => 'fru.h',
'Line' => '387',
'Param' => {
@@ -5623,7 +5624,7 @@
'Return' => '100',
'ShortName' => 'decode_get_fru_record_table_resp_safe'
},
- '157916' => {
+ '210697' => {
'Header' => 'fru.h',
'Line' => '339',
'Param' => {
@@ -5651,7 +5652,7 @@
'Return' => '100',
'ShortName' => 'encode_get_fru_record_table_req'
},
- '158151' => {
+ '210932' => {
'Header' => 'fru.h',
'Line' => '451',
'Param' => {
@@ -5690,7 +5691,7 @@
'Return' => '100',
'ShortName' => 'decode_get_fru_record_by_option_resp'
},
- '158318' => {
+ '211099' => {
'Header' => 'fru.h',
'Line' => '313',
'Param' => {
@@ -5735,7 +5736,7 @@
'Return' => '100',
'ShortName' => 'encode_get_fru_record_by_option_resp'
},
- '158709' => {
+ '211490' => {
'Header' => 'fru.h',
'Line' => '292',
'Param' => {
@@ -5784,7 +5785,7 @@
'Return' => '100',
'ShortName' => 'decode_get_fru_record_by_option_req'
},
- '158911' => {
+ '211692' => {
'Header' => 'fru.h',
'Line' => '433',
'Param' => {
@@ -5831,7 +5832,7 @@
'Return' => '100',
'ShortName' => 'encode_get_fru_record_by_option_req'
},
- '159208' => {
+ '211989' => {
'Header' => 'fru.h',
'Line' => '468',
'Param' => {
@@ -5868,7 +5869,7 @@
'Return' => '100',
'ShortName' => 'get_fru_record_by_option_check'
},
- '159867' => {
+ '212648' => {
'Header' => 'fru.h',
'Line' => '409',
'Param' => {
@@ -5923,7 +5924,7 @@
'Return' => '100',
'ShortName' => 'encode_fru_record'
},
- '160189' => {
+ '212970' => {
'Header' => 'fru.h',
'Line' => '269',
'Param' => {
@@ -5951,7 +5952,7 @@
'Return' => '100',
'ShortName' => 'encode_get_fru_record_table_resp'
},
- '160411' => {
+ '213192' => {
'Header' => 'fru.h',
'Line' => '251',
'Param' => {
@@ -5981,7 +5982,7 @@
'Return' => '100',
'ShortName' => 'decode_get_fru_record_table_req'
},
- '160515' => {
+ '213296' => {
'Header' => 'fru.h',
'Line' => '232',
'Param' => {
@@ -6033,7 +6034,7 @@
'Return' => '100',
'ShortName' => 'encode_get_fru_record_table_metadata_resp'
},
- '160818' => {
+ '213599' => {
'Header' => 'fru.h',
'Line' => '203',
'Param' => {
@@ -6092,7 +6093,7 @@
'Return' => '100',
'ShortName' => 'decode_get_fru_record_table_metadata_resp'
},
- '161028' => {
+ '213809' => {
'Header' => 'fru.h',
'Line' => '178',
'Param' => {
@@ -6112,7 +6113,7 @@
'Return' => '100',
'ShortName' => 'encode_get_fru_record_table_metadata_req'
},
- '162751' => {
+ '215532' => {
'Header' => 'pdr.h',
'Line' => '589',
'Param' => {
@@ -6130,7 +6131,7 @@
},
'3' => {
'name' => 'entities',
- 'type' => '163064'
+ 'type' => '215845'
}
},
'Reg' => {
@@ -6140,13 +6141,13 @@
'Return' => '1',
'ShortName' => 'pldm_entity_association_pdr_extract'
},
- '163084' => {
+ '215865' => {
'Header' => 'pdr.h',
'Line' => '577',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
}
},
'Reg' => {
@@ -6155,13 +6156,13 @@
'Return' => '5123',
'ShortName' => 'pldm_is_empty_entity_assoc_tree'
},
- '163138' => {
+ '215919' => {
'Header' => 'pdr.h',
'Line' => '567',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
}
},
'Reg' => {
@@ -6170,65 +6171,65 @@
'Return' => '1',
'ShortName' => 'pldm_entity_association_tree_destroy_root'
},
- '163201' => {
+ '215982' => {
'Header' => 'pdr.h',
'Line' => '557',
'Param' => {
'0' => {
'name' => 'org_tree',
- 'type' => '163133'
+ 'type' => '215914'
},
'1' => {
'name' => 'new_tree',
- 'type' => '163133'
+ 'type' => '215914'
}
},
'Return' => '1',
'ShortName' => 'pldm_entity_association_tree_copy_root'
},
- '163585' => {
+ '216366' => {
'Header' => 'pdr.h',
'Line' => '531',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
},
'1' => {
'name' => 'entity',
- 'type' => '163069'
+ 'type' => '215850'
}
},
- 'Return' => '162671',
+ 'Return' => '215452',
'ShortName' => 'pldm_entity_association_tree_find'
},
- '163865' => {
+ '216646' => {
'Header' => 'pdr.h',
'Line' => '545',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
},
'1' => {
'name' => 'entity',
- 'type' => '163069'
+ 'type' => '215850'
},
'2' => {
'name' => 'is_remote',
'type' => '5123'
}
},
- 'Return' => '162671',
+ 'Return' => '215452',
'ShortName' => 'pldm_entity_association_tree_find_with_locality'
},
- '164247' => {
+ '217028' => {
'Header' => 'pdr.h',
'Line' => '200',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
},
'1' => {
'name' => 'first',
@@ -6243,16 +6244,16 @@
'1' => 'rsi',
'2' => 'rdx'
},
- 'Return' => '162666',
+ 'Return' => '215447',
'ShortName' => 'pldm_pdr_find_last_in_range'
},
- '164374' => {
+ '217155' => {
'Header' => 'pdr.h',
'Line' => '165',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164622'
+ 'type' => '217403'
}
},
'Reg' => {
@@ -6261,13 +6262,13 @@
'Return' => '1',
'ShortName' => 'pldm_pdr_remove_remote_pdrs'
},
- '164627' => {
+ '217408' => {
'Header' => 'pdr.h',
'Line' => '174',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164622'
+ 'type' => '217403'
},
'1' => {
'name' => 'terminus_handle',
@@ -6281,41 +6282,41 @@
'Return' => '1',
'ShortName' => 'pldm_pdr_remove_pdrs_by_terminus_handle'
},
- '164895' => {
+ '217676' => {
'Header' => 'pdr.h',
'Line' => '492',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
},
'1' => {
'name' => 'entity',
- 'type' => '161750'
+ 'type' => '214531'
},
'2' => {
'name' => 'node',
- 'type' => '163580'
+ 'type' => '216361'
}
},
'Return' => '1',
'ShortName' => 'pldm_find_entity_ref_in_tree'
},
- '165182' => {
+ '217963' => {
'Header' => 'pdr.h',
'Line' => '481',
'Param' => {
'0' => {
'name' => 'node',
- 'type' => '162671'
+ 'type' => '215452'
},
'1' => {
'name' => 'repo',
- 'type' => '164622'
+ 'type' => '217403'
},
'2' => {
'name' => 'entities',
- 'type' => '163064'
+ 'type' => '215845'
},
'3' => {
'name' => 'num_entities',
@@ -6346,21 +6347,21 @@
'Return' => '100',
'ShortName' => 'pldm_entity_association_pdr_add_from_node_with_record_handle'
},
- '165415' => {
+ '218196' => {
'Header' => 'pdr.h',
'Line' => '464',
'Param' => {
'0' => {
'name' => 'node',
- 'type' => '162671'
+ 'type' => '215452'
},
'1' => {
'name' => 'repo',
- 'type' => '164622'
+ 'type' => '217403'
},
'2' => {
'name' => 'entities',
- 'type' => '163064'
+ 'type' => '215845'
},
'3' => {
'name' => 'num_entities',
@@ -6378,17 +6379,17 @@
'Return' => '100',
'ShortName' => 'pldm_entity_association_pdr_add_from_node_check'
},
- '165633' => {
+ '218414' => {
'Header' => 'pdr.h',
'Line' => '451',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
},
'1' => {
'name' => 'repo',
- 'type' => '164622'
+ 'type' => '217403'
},
'2' => {
'name' => 'is_remote',
@@ -6402,17 +6403,17 @@
'Return' => '100',
'ShortName' => 'pldm_entity_association_pdr_add_check'
},
- '167156' => {
+ '219937' => {
'Header' => 'pdr.h',
'Line' => '518',
'Param' => {
'0' => {
'name' => 'parent',
- 'type' => '162671'
+ 'type' => '215452'
},
'1' => {
'name' => 'node',
- 'type' => '163069'
+ 'type' => '215850'
}
},
'Reg' => {
@@ -6422,13 +6423,13 @@
'Return' => '5123',
'ShortName' => 'pldm_is_current_parent_child'
},
- '167245' => {
+ '220026' => {
'Header' => 'pdr.h',
'Line' => '504',
'Param' => {
'0' => {
'name' => 'node',
- 'type' => '162671'
+ 'type' => '215452'
},
'1' => {
'name' => 'association_type',
@@ -6442,13 +6443,13 @@
'Return' => '140',
'ShortName' => 'pldm_entity_get_num_children'
},
- '167460' => {
+ '220241' => {
'Header' => 'pdr.h',
'Line' => '422',
'Param' => {
'0' => {
'name' => 'node',
- 'type' => '162671'
+ 'type' => '215452'
}
},
'Reg' => {
@@ -6457,37 +6458,37 @@
'Return' => '5123',
'ShortName' => 'pldm_entity_is_exist_parent'
},
- '167615' => {
+ '220396' => {
'Header' => 'pdr.h',
'Line' => '412',
'Param' => {
'0' => {
'name' => 'node',
- 'type' => '162671'
+ 'type' => '215452'
}
},
- 'Return' => '161750',
+ 'Return' => '214531',
'ShortName' => 'pldm_entity_get_parent'
},
- '167770' => {
+ '220551' => {
'Header' => 'pdr.h',
'Line' => '402',
'Param' => {
'0' => {
'name' => 'node',
- 'type' => '162671'
+ 'type' => '215452'
}
},
'Return' => '5123',
'ShortName' => 'pldm_entity_is_node_parent'
},
- '167925' => {
+ '220706' => {
'Header' => 'pdr.h',
'Line' => '392',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
}
},
'Reg' => {
@@ -6496,17 +6497,17 @@
'Return' => '1',
'ShortName' => 'pldm_entity_association_tree_destroy'
},
- '168104' => {
+ '220885' => {
'Header' => 'pdr.h',
'Line' => '364',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
},
'1' => {
'name' => 'entities',
- 'type' => '163064'
+ 'type' => '215845'
},
'2' => {
'name' => 'size',
@@ -6519,17 +6520,17 @@
'Return' => '1',
'ShortName' => 'pldm_entity_association_tree_visit'
},
- '168563' => {
+ '221344' => {
'Header' => 'pdr.h',
'Line' => '346',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
},
'1' => {
'name' => 'entity',
- 'type' => '163069'
+ 'type' => '215850'
},
'2' => {
'name' => 'entity_instance_number',
@@ -6537,7 +6538,7 @@
},
'3' => {
'name' => 'parent',
- 'type' => '162671'
+ 'type' => '215452'
},
'4' => {
'name' => 'association_type',
@@ -6558,20 +6559,20 @@
'type' => '5573'
}
},
- 'Return' => '162671',
+ 'Return' => '215452',
'ShortName' => 'pldm_entity_association_tree_add_entity'
},
- '169090' => {
+ '221871' => {
'Header' => 'pdr.h',
'Line' => '318',
'Param' => {
'0' => {
'name' => 'tree',
- 'type' => '163133'
+ 'type' => '215914'
},
'1' => {
'name' => 'entity',
- 'type' => '163069'
+ 'type' => '215850'
},
'2' => {
'name' => 'entity_instance_number',
@@ -6579,53 +6580,53 @@
},
'3' => {
'name' => 'parent',
- 'type' => '162671'
+ 'type' => '215452'
},
'4' => {
'name' => 'association_type',
'type' => '140'
}
},
- 'Return' => '162671',
+ 'Return' => '215452',
'ShortName' => 'pldm_entity_association_tree_add'
},
- '169523' => {
+ '222304' => {
'Header' => 'pdr.h',
'Line' => '301',
- 'Return' => '163133',
+ 'Return' => '215914',
'ShortName' => 'pldm_entity_association_tree_init'
},
- '169597' => {
+ '222378' => {
'Header' => 'pdr.h',
'Line' => '386',
'Param' => {
'0' => {
'name' => 'entity',
- 'type' => '169731'
+ 'type' => '222512'
}
},
'Return' => '5573',
'ShortName' => 'pldm_entity_node_get_remote_container_id'
},
- '169757' => {
+ '222538' => {
'Header' => 'pdr.h',
'Line' => '375',
'Param' => {
'0' => {
'name' => 'node',
- 'type' => '162671'
+ 'type' => '215452'
}
},
- 'Return' => '161750',
+ 'Return' => '214531',
'ShortName' => 'pldm_entity_extract'
},
- '170551' => {
+ '223332' => {
'Header' => 'pdr.h',
'Line' => '187',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
},
'1' => {
'name' => 'terminus_handle',
@@ -6653,13 +6654,13 @@
'Return' => '1',
'ShortName' => 'pldm_pdr_update_TL_pdr'
},
- '170910' => {
+ '223691' => {
'Header' => 'pdr.h',
'Line' => '266',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
},
'1' => {
'name' => 'fru_rsi',
@@ -6685,16 +6686,16 @@
'Reg' => {
'2' => 'r12'
},
- 'Return' => '170895',
+ 'Return' => '223676',
'ShortName' => 'pldm_pdr_fru_record_set_find_by_rsi'
},
- '171264' => {
+ '224045' => {
'Header' => 'pdr.h',
'Line' => '245',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164622'
+ 'type' => '217403'
},
'1' => {
'name' => 'terminus_handle',
@@ -6725,65 +6726,65 @@
'Return' => '100',
'ShortName' => 'pldm_pdr_add_fru_record_set_check'
},
- '171607' => {
+ '224388' => {
'Header' => 'pdr.h',
'Line' => '157',
'Param' => {
'0' => {
'name' => 'record',
- 'type' => '170895'
+ 'type' => '223676'
}
},
'Return' => '5123',
'ShortName' => 'pldm_pdr_record_is_remote'
},
- '171761' => {
+ '224542' => {
'Header' => 'pdr.h',
'Line' => '94',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
},
'1' => {
'name' => 'record',
- 'type' => '170895'
+ 'type' => '223676'
}
},
'Return' => '152',
'ShortName' => 'pldm_pdr_get_record_handle'
},
- '171975' => {
+ '224756' => {
'Header' => 'pdr.h',
'Line' => '62',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
}
},
'Return' => '152',
'ShortName' => 'pldm_pdr_get_repo_size'
},
- '172106' => {
+ '224887' => {
'Header' => 'pdr.h',
'Line' => '52',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
}
},
'Return' => '152',
'ShortName' => 'pldm_pdr_get_record_count'
},
- '172237' => {
+ '225018' => {
'Header' => 'pdr.h',
'Line' => '147',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
},
'1' => {
'name' => 'pdr_type',
@@ -6791,11 +6792,11 @@
},
'2' => {
'name' => 'curr_record',
- 'type' => '170895'
+ 'type' => '223676'
},
'3' => {
'name' => 'data',
- 'type' => '152772'
+ 'type' => '205241'
},
'4' => {
'name' => 'size',
@@ -6807,24 +6808,24 @@
'3' => 'rcx',
'4' => 'r8'
},
- 'Return' => '170895',
+ 'Return' => '223676',
'ShortName' => 'pldm_pdr_find_record_by_type'
},
- '172408' => {
+ '225189' => {
'Header' => 'pdr.h',
'Line' => '129',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
},
'1' => {
'name' => 'curr_record',
- 'type' => '170895'
+ 'type' => '223676'
},
'2' => {
'name' => 'data',
- 'type' => '152772'
+ 'type' => '205241'
},
'3' => {
'name' => 'size',
@@ -6842,16 +6843,16 @@
'3' => 'rcx',
'4' => 'rbp'
},
- 'Return' => '170895',
+ 'Return' => '223676',
'ShortName' => 'pldm_pdr_get_next_record'
},
- '172575' => {
+ '225356' => {
'Header' => 'pdr.h',
'Line' => '110',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164369'
+ 'type' => '217150'
},
'1' => {
'name' => 'record_handle',
@@ -6859,7 +6860,7 @@
},
'2' => {
'name' => 'data',
- 'type' => '152772'
+ 'type' => '205241'
},
'3' => {
'name' => 'size',
@@ -6877,16 +6878,16 @@
'3' => 'rcx',
'4' => 'rbp'
},
- 'Return' => '170895',
+ 'Return' => '223676',
'ShortName' => 'pldm_pdr_find_record'
},
- '172743' => {
+ '225524' => {
'Header' => 'pdr.h',
'Line' => '42',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164622'
+ 'type' => '217403'
}
},
'Reg' => {
@@ -6895,19 +6896,19 @@
'Return' => '1',
'ShortName' => 'pldm_pdr_destroy'
},
- '172896' => {
+ '225677' => {
'Header' => 'pdr.h',
'Line' => '36',
- 'Return' => '164622',
+ 'Return' => '217403',
'ShortName' => 'pldm_pdr_init'
},
- '172968' => {
+ '225749' => {
'Header' => 'pdr.h',
'Line' => '79',
'Param' => {
'0' => {
'name' => 'repo',
- 'type' => '164622'
+ 'type' => '217403'
},
'1' => {
'name' => 'data',
@@ -6939,7 +6940,7 @@
'Return' => '100',
'ShortName' => 'pldm_pdr_add_check'
},
- '175356' => {
+ '228137' => {
'Header' => 'utils.h',
'Line' => '87',
'Param' => {
@@ -6951,7 +6952,7 @@
'Return' => '152',
'ShortName' => 'dec2bcd32'
},
- '175485' => {
+ '228266' => {
'Header' => 'utils.h',
'Line' => '81',
'Param' => {
@@ -6963,7 +6964,7 @@
'Return' => '152',
'ShortName' => 'bcd2dec32'
},
- '175913' => {
+ '228694' => {
'Header' => 'utils.h',
'Line' => '51',
'Param' => {
@@ -6984,10 +6985,10 @@
'0' => 'rdi',
'1' => 'rcx'
},
- 'Return' => '124045',
+ 'Return' => '176153',
'ShortName' => 'ver2str'
},
- '176041' => {
+ '228822' => {
'Header' => 'utils.h',
'Line' => '31',
'Param' => {
@@ -7006,53 +7007,53 @@
'Return' => '140',
'ShortName' => 'crc8'
},
- '177355' => {
+ '230136' => {
'Header' => 'instance-id.h',
'Line' => '85',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '177578'
+ 'type' => '230359'
},
'1' => {
'name' => 'tid',
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'name' => 'iid',
- 'type' => '173995'
+ 'type' => '226776'
}
},
'Return' => '100',
'ShortName' => 'pldm_instance_id_free'
},
- '177583' => {
+ '230364' => {
'Header' => 'instance-id.h',
'Line' => '68',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '177578'
+ 'type' => '230359'
},
'1' => {
'name' => 'tid',
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'name' => 'iid',
- 'type' => '178003'
+ 'type' => '230784'
}
},
'Return' => '100',
'ShortName' => 'pldm_instance_id_alloc'
},
- '178008' => {
+ '230789' => {
'Header' => 'instance-id.h',
'Line' => '51',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '177578'
+ 'type' => '230359'
}
},
'Reg' => {
@@ -7061,25 +7062,25 @@
'Return' => '100',
'ShortName' => 'pldm_instance_db_destroy'
},
- '178093' => {
+ '230874' => {
'Header' => 'instance-id.h',
'Line' => '41',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '178179'
+ 'type' => '230960'
}
},
'Return' => '100',
'ShortName' => 'pldm_instance_db_init_default'
},
- '178184' => {
+ '230965' => {
'Header' => 'instance-id.h',
'Line' => '28',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '178179'
+ 'type' => '230960'
},
'1' => {
'name' => 'dbpath',
@@ -7089,17 +7090,17 @@
'Return' => '100',
'ShortName' => 'pldm_instance_db_init'
},
- '179100' => {
+ '231881' => {
'Header' => 'transport.h',
'Line' => '53',
'Param' => {
'0' => {
'name' => 'transport',
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
'name' => 'tid',
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'name' => 'pldm_msg',
@@ -7116,20 +7117,20 @@
'2' => 'rdx',
'3' => 'rcx'
},
- 'Return' => '179051',
+ 'Return' => '231832',
'ShortName' => 'pldm_transport_send_msg'
},
- '179147' => {
+ '231928' => {
'Header' => 'transport.h',
'Line' => '118',
'Param' => {
'0' => {
'name' => 'transport',
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
'name' => 'tid',
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'name' => 'pldm_req_msg',
@@ -7141,7 +7142,7 @@
},
'4' => {
'name' => 'pldm_resp_msg',
- 'type' => '40934'
+ 'type' => '60289'
},
'5' => {
'name' => 'resp_msg_len',
@@ -7151,16 +7152,16 @@
'Reg' => {
'2' => 'r14'
},
- 'Return' => '179051',
+ 'Return' => '231832',
'ShortName' => 'pldm_transport_send_recv_msg'
},
- '179204' => {
+ '231985' => {
'Header' => 'mctp-demux.h',
'Line' => '18',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '179095'
+ 'type' => '231876'
}
},
'Reg' => {
@@ -7169,21 +7170,21 @@
'Return' => '1',
'ShortName' => 'pldm_transport_mctp_demux_destroy'
},
- '179241' => {
+ '232022' => {
'Header' => 'transport.h',
'Line' => '81',
'Param' => {
'0' => {
'name' => 'transport',
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
'name' => 'tid',
- 'type' => '179278'
+ 'type' => '232059'
},
'2' => {
'name' => 'pldm_msg',
- 'type' => '40934'
+ 'type' => '60289'
},
'3' => {
'name' => 'msg_len',
@@ -7196,24 +7197,24 @@
'2' => 'rbp',
'3' => 'rcx'
},
- 'Return' => '179051',
+ 'Return' => '231832',
'ShortName' => 'pldm_transport_recv_msg'
},
- '179283' => {
+ '232064' => {
'Header' => 'mctp-demux.h',
'Line' => '32',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '179095'
+ 'type' => '231876'
},
'1' => {
'name' => 'tid',
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'name' => 'eid',
- 'type' => '178936'
+ 'type' => '231717'
}
},
'Reg' => {
@@ -7224,28 +7225,28 @@
'Return' => '100',
'ShortName' => 'pldm_transport_mctp_demux_map_tid'
},
- '179315' => {
+ '232096' => {
'Header' => 'mctp-demux.h',
'Line' => '22',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '179095'
+ 'type' => '231876'
}
},
'Reg' => {
'0' => 'rdi'
},
- 'Return' => '179137',
+ 'Return' => '231918',
'ShortName' => 'pldm_transport_mctp_demux_core'
},
- '179359' => {
+ '232140' => {
'Header' => 'mctp-demux.h',
'Line' => '15',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '179381'
+ 'type' => '232162'
}
},
'Reg' => {
@@ -7254,19 +7255,19 @@
'Return' => '100',
'ShortName' => 'pldm_transport_mctp_demux_init'
},
- '179440' => {
+ '232221' => {
'Header' => 'pldm.h',
'Line' => '119',
'Return' => '1',
'ShortName' => 'pldm_close'
},
- '179484' => {
+ '232265' => {
'Header' => 'pldm.h',
'Line' => '75',
'Param' => {
'0' => {
'name' => 'eid',
- 'type' => '178936'
+ 'type' => '231717'
},
'1' => {
'name' => 'mctp_fd',
@@ -7287,16 +7288,16 @@
'2' => 'rdx',
'3' => 'rcx'
},
- 'Return' => '179051',
+ 'Return' => '231832',
'ShortName' => 'pldm_send'
},
- '179903' => {
+ '232684' => {
'Header' => 'pldm.h',
'Line' => '57',
'Param' => {
'0' => {
'name' => 'eid',
- 'type' => '178936'
+ 'type' => '231717'
},
'1' => {
'name' => 'mctp_fd',
@@ -7312,7 +7313,7 @@
},
'4' => {
'name' => 'pldm_resp_msg',
- 'type' => '152772'
+ 'type' => '205241'
},
'5' => {
'name' => 'resp_msg_len',
@@ -7327,16 +7328,16 @@
'4' => 'r8',
'5' => 'r9'
},
- 'Return' => '179051',
+ 'Return' => '231832',
'ShortName' => 'pldm_send_recv'
},
- '180386' => {
+ '233167' => {
'Header' => 'pldm.h',
'Line' => '94',
'Param' => {
'0' => {
'name' => 'eid',
- 'type' => '178936'
+ 'type' => '231717'
},
'1' => {
'name' => 'mctp_fd',
@@ -7348,7 +7349,7 @@
},
'3' => {
'name' => 'pldm_resp_msg',
- 'type' => '152772'
+ 'type' => '205241'
},
'4' => {
'name' => 'resp_msg_len',
@@ -7358,16 +7359,16 @@
'Reg' => {
'3' => 'rbx'
},
- 'Return' => '179051',
+ 'Return' => '231832',
'ShortName' => 'pldm_recv'
},
- '180612' => {
+ '233393' => {
'Header' => 'pldm.h',
'Line' => '112',
'Param' => {
'0' => {
'name' => 'eid',
- 'type' => '178936'
+ 'type' => '231717'
},
'1' => {
'name' => 'mctp_fd',
@@ -7375,7 +7376,7 @@
},
'2' => {
'name' => 'pldm_resp_msg',
- 'type' => '152772'
+ 'type' => '205241'
},
'3' => {
'name' => 'resp_msg_len',
@@ -7386,26 +7387,26 @@
'2' => 'r12',
'3' => 'r13'
},
- 'Return' => '179051',
+ 'Return' => '231832',
'ShortName' => 'pldm_recv_any'
},
- '181065' => {
+ '233846' => {
'Header' => 'pldm.h',
'Line' => '39',
- 'Return' => '179051',
+ 'Return' => '231832',
'ShortName' => 'pldm_open'
},
- '183434' => {
+ '236215' => {
'Header' => 'af-mctp.h',
'Line' => '54',
'Param' => {
'0' => {
'name' => 'transport',
- 'type' => '183590'
+ 'type' => '236371'
},
'1' => {
'name' => 'smctp',
- 'type' => '183595'
+ 'type' => '236376'
},
'2' => {
'name' => 'len',
@@ -7419,13 +7420,13 @@
'Return' => '100',
'ShortName' => 'pldm_transport_af_mctp_bind'
},
- '183600' => {
+ '236381' => {
'Header' => 'af-mctp.h',
'Line' => '19',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '183590'
+ 'type' => '236371'
}
},
'Reg' => {
@@ -7434,13 +7435,13 @@
'Return' => '1',
'ShortName' => 'pldm_transport_af_mctp_destroy'
},
- '183684' => {
+ '236465' => {
'Header' => 'af-mctp.h',
'Line' => '16',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '183908'
+ 'type' => '236689'
}
},
'Reg' => {
@@ -7449,21 +7450,21 @@
'Return' => '100',
'ShortName' => 'pldm_transport_af_mctp_init'
},
- '185103' => {
+ '237884' => {
'Header' => 'af-mctp.h',
'Line' => '37',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '183590'
+ 'type' => '236371'
},
'1' => {
'name' => 'tid',
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'name' => 'eid',
- 'type' => '178936'
+ 'type' => '231717'
}
},
'Reg' => {
@@ -7474,21 +7475,21 @@
'Return' => '100',
'ShortName' => 'pldm_transport_af_mctp_unmap_tid'
},
- '185176' => {
+ '237957' => {
'Header' => 'af-mctp.h',
'Line' => '33',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '183590'
+ 'type' => '236371'
},
'1' => {
'name' => 'tid',
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'name' => 'eid',
- 'type' => '178936'
+ 'type' => '231717'
}
},
'Reg' => {
@@ -7499,17 +7500,17 @@
'Return' => '100',
'ShortName' => 'pldm_transport_af_mctp_map_tid'
},
- '185417' => {
+ '238198' => {
'Header' => 'af-mctp.h',
'Line' => '28',
'Param' => {
'0' => {
'name' => 't',
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
'name' => 'pollfd',
- 'type' => '182100'
+ 'type' => '234881'
}
},
'Reg' => {
@@ -7519,36 +7520,36 @@
'Return' => '100',
'ShortName' => 'pldm_transport_af_mctp_init_pollfd'
},
- '185495' => {
+ '238276' => {
'Header' => 'af-mctp.h',
'Line' => '23',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '183590'
+ 'type' => '236371'
}
},
'Reg' => {
'0' => 'rdi'
},
- 'Return' => '179137',
+ 'Return' => '231918',
'ShortName' => 'pldm_transport_af_mctp_core'
},
- '189166' => {
+ '241947' => {
'Header' => 'mctp-demux.h',
'Line' => '36',
'Param' => {
'0' => {
'name' => 'ctx',
- 'type' => '179095'
+ 'type' => '231876'
},
'1' => {
'name' => 'tid',
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'name' => 'eid',
- 'type' => '178936'
+ 'type' => '231717'
}
},
'Reg' => {
@@ -7559,17 +7560,17 @@
'Return' => '100',
'ShortName' => 'pldm_transport_mctp_demux_unmap_tid'
},
- '189480' => {
+ '242261' => {
'Header' => 'mctp-demux.h',
'Line' => '27',
'Param' => {
'0' => {
'name' => 't',
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
'name' => 'pollfd',
- 'type' => '182100'
+ 'type' => '234881'
}
},
'Reg' => {
@@ -7579,13 +7580,13 @@
'Return' => '100',
'ShortName' => 'pldm_transport_mctp_demux_init_pollfd'
},
- '194413' => {
+ '247194' => {
'Header' => 'transport.h',
'Line' => '31',
'Param' => {
'0' => {
'name' => 'transport',
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
'name' => 'timeout',
@@ -7595,7 +7596,7 @@
'Return' => '100',
'ShortName' => 'pldm_transport_poll'
},
- '199472' => {
+ '252253' => {
'Header' => 'file_io.h',
'Line' => '912',
'Param' => {
@@ -7615,7 +7616,7 @@
'Return' => '100',
'ShortName' => 'encode_new_file_with_metadata_resp'
},
- '199672' => {
+ '252453' => {
'Header' => 'file_io.h',
'Line' => '898',
'Param' => {
@@ -7637,7 +7638,7 @@
},
'4' => {
'name' => 'length',
- 'type' => '131992'
+ 'type' => '184100'
},
'5' => {
'name' => 'file_meta_data_1',
@@ -7669,7 +7670,7 @@
'Return' => '100',
'ShortName' => 'decode_new_file_with_metadata_req'
},
- '199904' => {
+ '252685' => {
'Header' => 'file_io.h',
'Line' => '881',
'Param' => {
@@ -7694,7 +7695,7 @@
'Return' => '100',
'ShortName' => 'decode_new_file_with_metadata_resp'
},
- '200005' => {
+ '252786' => {
'Header' => 'file_io.h',
'Line' => '866',
'Param' => {
@@ -7712,7 +7713,7 @@
},
'3' => {
'name' => 'length',
- 'type' => '123263'
+ 'type' => '175371'
},
'4' => {
'name' => 'file_meta_data_1',
@@ -7744,7 +7745,7 @@
'Return' => '100',
'ShortName' => 'encode_new_file_with_metadata_req'
},
- '200302' => {
+ '253083' => {
'Header' => 'file_io.h',
'Line' => '824',
'Param' => {
@@ -7764,7 +7765,7 @@
'Return' => '100',
'ShortName' => 'encode_file_ack_with_meta_data_resp'
},
- '200497' => {
+ '253278' => {
'Header' => 'file_io.h',
'Line' => '811',
'Param' => {
@@ -7818,7 +7819,7 @@
'Return' => '100',
'ShortName' => 'decode_file_ack_with_meta_data_req'
},
- '200709' => {
+ '253490' => {
'Header' => 'file_io.h',
'Line' => '794',
'Param' => {
@@ -7843,7 +7844,7 @@
'Return' => '100',
'ShortName' => 'decode_file_ack_with_meta_data_resp'
},
- '200805' => {
+ '253586' => {
'Header' => 'file_io.h',
'Line' => '781',
'Param' => {
@@ -7893,7 +7894,7 @@
'Return' => '100',
'ShortName' => 'encode_file_ack_with_meta_data_req'
},
- '201102' => {
+ '253883' => {
'Header' => 'file_io.h',
'Line' => '741',
'Param' => {
@@ -7918,7 +7919,7 @@
'Return' => '100',
'ShortName' => 'decode_file_ack_resp'
},
- '201203' => {
+ '253984' => {
'Header' => 'file_io.h',
'Line' => '730',
'Param' => {
@@ -7946,7 +7947,7 @@
'Return' => '100',
'ShortName' => 'encode_file_ack_req'
},
- '201438' => {
+ '254219' => {
'Header' => 'file_io.h',
'Line' => '718',
'Param' => {
@@ -7966,7 +7967,7 @@
'Return' => '100',
'ShortName' => 'encode_file_ack_resp'
},
- '201628' => {
+ '254409' => {
'Header' => 'file_io.h',
'Line' => '706',
'Param' => {
@@ -8000,7 +8001,7 @@
'Return' => '100',
'ShortName' => 'decode_file_ack_req'
},
- '201770' => {
+ '254551' => {
'Header' => 'file_io.h',
'Line' => '675',
'Param' => {
@@ -8030,7 +8031,7 @@
'Return' => '100',
'ShortName' => 'decode_rw_file_by_type_resp'
},
- '201885' => {
+ '254666' => {
'Header' => 'file_io.h',
'Line' => '661',
'Param' => {
@@ -8067,7 +8068,7 @@
'Return' => '100',
'ShortName' => 'encode_rw_file_by_type_req'
},
- '202155' => {
+ '254936' => {
'Header' => 'file_io.h',
'Line' => '644',
'Param' => {
@@ -8095,7 +8096,7 @@
'Return' => '100',
'ShortName' => 'encode_rw_file_by_type_resp'
},
- '202385' => {
+ '255166' => {
'Header' => 'file_io.h',
'Line' => '626',
'Param' => {
@@ -8134,7 +8135,7 @@
'Return' => '100',
'ShortName' => 'decode_rw_file_by_type_req'
},
- '202547' => {
+ '255328' => {
'Header' => 'file_io.h',
'Line' => '590',
'Param' => {
@@ -8159,7 +8160,7 @@
'Return' => '100',
'ShortName' => 'decode_new_file_resp'
},
- '202648' => {
+ '255429' => {
'Header' => 'file_io.h',
'Line' => '579',
'Param' => {
@@ -8177,7 +8178,7 @@
},
'3' => {
'name' => 'length',
- 'type' => '123263'
+ 'type' => '175371'
},
'4' => {
'name' => 'msg',
@@ -8187,7 +8188,7 @@
'Return' => '100',
'ShortName' => 'encode_new_file_req'
},
- '202883' => {
+ '255664' => {
'Header' => 'file_io.h',
'Line' => '567',
'Param' => {
@@ -8207,7 +8208,7 @@
'Return' => '100',
'ShortName' => 'encode_new_file_resp'
},
- '203073' => {
+ '255854' => {
'Header' => 'file_io.h',
'Line' => '555',
'Param' => {
@@ -8229,7 +8230,7 @@
},
'4' => {
'name' => 'length',
- 'type' => '131992'
+ 'type' => '184100'
}
},
'Reg' => {
@@ -8241,7 +8242,7 @@
'Return' => '100',
'ShortName' => 'decode_new_file_req'
},
- '203215' => {
+ '255996' => {
'Header' => 'file_io.h',
'Line' => '523',
'Param' => {
@@ -8271,7 +8272,7 @@
'Return' => '100',
'ShortName' => 'decode_rw_file_by_type_memory_resp'
},
- '203330' => {
+ '256111' => {
'Header' => 'file_io.h',
'Line' => '509',
'Param' => {
@@ -8302,7 +8303,7 @@
'6' => {
'name' => 'address',
'offset' => '0',
- 'type' => '123263'
+ 'type' => '175371'
},
'7' => {
'name' => 'msg',
@@ -8313,7 +8314,7 @@
'Return' => '100',
'ShortName' => 'encode_rw_file_by_type_memory_req'
},
- '203615' => {
+ '256396' => {
'Header' => 'file_io.h',
'Line' => '491',
'Param' => {
@@ -8341,7 +8342,7 @@
'Return' => '100',
'ShortName' => 'encode_rw_file_by_type_memory_resp'
},
- '203845' => {
+ '256626' => {
'Header' => 'file_io.h',
'Line' => '473',
'Param' => {
@@ -8372,7 +8373,7 @@
'6' => {
'name' => 'address',
'offset' => '0',
- 'type' => '131992'
+ 'type' => '184100'
}
},
'Reg' => {
@@ -8385,7 +8386,7 @@
'Return' => '100',
'ShortName' => 'decode_rw_file_by_type_memory_req'
},
- '204022' => {
+ '256803' => {
'Header' => 'file_io.h',
'Line' => '435',
'Param' => {
@@ -8409,7 +8410,7 @@
'Return' => '100',
'ShortName' => 'encode_write_file_resp'
},
- '204237' => {
+ '257018' => {
'Header' => 'file_io.h',
'Line' => '422',
'Param' => {
@@ -8439,7 +8440,7 @@
'Return' => '100',
'ShortName' => 'decode_write_file_resp'
},
- '204347' => {
+ '257128' => {
'Header' => 'file_io.h',
'Line' => '410',
'Param' => {
@@ -8467,7 +8468,7 @@
'Return' => '100',
'ShortName' => 'encode_write_file_req'
},
- '204582' => {
+ '257363' => {
'Header' => 'file_io.h',
'Line' => '391',
'Param' => {
@@ -8505,7 +8506,7 @@
'Return' => '100',
'ShortName' => 'decode_write_file_req'
},
- '204737' => {
+ '257518' => {
'Header' => 'file_io.h',
'Line' => '377',
'Param' => {
@@ -8529,7 +8530,7 @@
'Return' => '100',
'ShortName' => 'encode_read_file_resp'
},
- '204952' => {
+ '257733' => {
'Header' => 'file_io.h',
'Line' => '359',
'Param' => {
@@ -8563,7 +8564,7 @@
'Return' => '100',
'ShortName' => 'decode_read_file_resp'
},
- '205088' => {
+ '257869' => {
'Header' => 'file_io.h',
'Line' => '344',
'Param' => {
@@ -8591,7 +8592,7 @@
'Return' => '100',
'ShortName' => 'encode_read_file_req'
},
- '205323' => {
+ '258104' => {
'Header' => 'file_io.h',
'Line' => '330',
'Param' => {
@@ -8625,7 +8626,7 @@
'Return' => '100',
'ShortName' => 'decode_read_file_req'
},
- '205459' => {
+ '258240' => {
'Header' => 'file_io.h',
'Line' => '274',
'Param' => {
@@ -8669,7 +8670,7 @@
'Return' => '100',
'ShortName' => 'decode_get_file_table_resp'
},
- '205633' => {
+ '258414' => {
'Header' => 'file_io.h',
'Line' => '258',
'Param' => {
@@ -8697,7 +8698,7 @@
'Return' => '100',
'ShortName' => 'encode_get_file_table_req'
},
- '205860' => {
+ '258641' => {
'Header' => 'file_io.h',
'Line' => '244',
'Param' => {
@@ -8737,7 +8738,7 @@
'Return' => '100',
'ShortName' => 'encode_get_file_table_resp'
},
- '206218' => {
+ '258999' => {
'Header' => 'file_io.h',
'Line' => '227',
'Param' => {
@@ -8771,7 +8772,7 @@
'Return' => '100',
'ShortName' => 'decode_get_file_table_req'
},
- '206353' => {
+ '259134' => {
'Header' => 'file_io.h',
'Line' => '183',
'Param' => {
@@ -8801,7 +8802,7 @@
'Return' => '100',
'ShortName' => 'decode_rw_file_memory_resp'
},
- '206462' => {
+ '259243' => {
'Header' => 'file_io.h',
'Line' => '169',
'Param' => {
@@ -8827,7 +8828,7 @@
},
'5' => {
'name' => 'address',
- 'type' => '123263'
+ 'type' => '175371'
},
'6' => {
'name' => 'msg',
@@ -8841,7 +8842,7 @@
'Return' => '100',
'ShortName' => 'encode_rw_file_memory_req'
},
- '206721' => {
+ '259502' => {
'Header' => 'file_io.h',
'Line' => '152',
'Param' => {
@@ -8869,7 +8870,7 @@
'Return' => '100',
'ShortName' => 'encode_rw_file_memory_resp'
},
- '206942' => {
+ '259723' => {
'Header' => 'file_io.h',
'Line' => '136',
'Param' => {
@@ -8895,7 +8896,7 @@
},
'5' => {
'name' => 'address',
- 'type' => '131992'
+ 'type' => '184100'
}
},
'Reg' => {
@@ -8908,7 +8909,7 @@
'Return' => '100',
'ShortName' => 'decode_rw_file_memory_req'
},
- '207991' => {
+ '260772' => {
'Header' => 'host.h',
'Line' => '101',
'Param' => {
@@ -8943,7 +8944,7 @@
'Return' => '100',
'ShortName' => 'encode_get_alert_status_resp'
},
- '208239' => {
+ '261020' => {
'Header' => 'host.h',
'Line' => '86',
'Param' => {
@@ -8968,7 +8969,7 @@
'Return' => '100',
'ShortName' => 'decode_get_alert_status_req'
},
- '208322' => {
+ '261103' => {
'Header' => 'host.h',
'Line' => '70',
'Param' => {
@@ -9002,7 +9003,7 @@
'Return' => '100',
'ShortName' => 'decode_get_alert_status_resp'
},
- '208461' => {
+ '261242' => {
'Header' => 'host.h',
'Line' => '52',
'Param' => {
@@ -9026,7 +9027,7 @@
'Return' => '100',
'ShortName' => 'encode_get_alert_status_req'
},
- '209523' => {
+ '262304' => {
'Header' => 'platform.h',
'Line' => '47',
'Param' => {
@@ -9063,7 +9064,7 @@
'Return' => '100',
'ShortName' => 'encode_bios_attribute_update_event_req'
},
- '210590' => {
+ '263409' => {
'Header' => 'file_io.h',
'Line' => '36',
'Param' => {
@@ -9979,7 +9980,7 @@
'Size' => '8',
'Type' => 'Pointer'
},
- '14047' => {
+ '14088' => {
'Header' => 'platform.h',
'Line' => '250',
'Memb' => {
@@ -10000,13 +10001,13 @@
'Size' => '4',
'Type' => 'Enum'
},
- '14081' => {
- 'BaseType' => '14047',
+ '14122' => {
+ 'BaseType' => '14088',
'Name' => 'enum sensor_event_class_states const',
'Size' => '4',
'Type' => 'Const'
},
- '14304' => {
+ '14345' => {
'Header' => 'platform.h',
'Line' => '472',
'Memb' => {
@@ -10040,14 +10041,14 @@
'Size' => '10',
'Type' => 'Struct'
},
- '14383' => {
+ '14424' => {
'Header' => 'platform.h',
'Line' => '547',
'Memb' => {
'0' => {
'name' => 'hdr',
'offset' => '0',
- 'type' => '14304'
+ 'type' => '14345'
},
'1' => {
'name' => 'terminus_handle',
@@ -10099,7 +10100,7 @@
'Size' => '24',
'Type' => 'Struct'
},
- '14527' => {
+ '14568' => {
'Header' => 'platform.h',
'Line' => '564',
'Memb' => {
@@ -10116,33 +10117,33 @@
'2' => {
'name' => 'states',
'offset' => '3',
- 'type' => '14585'
+ 'type' => '14626'
}
},
'Name' => 'struct state_sensor_possible_states',
'Size' => '4',
'Type' => 'Struct'
},
- '14580' => {
- 'BaseType' => '14527',
+ '14621' => {
+ 'BaseType' => '14568',
'Name' => 'struct state_sensor_possible_states const',
'Size' => '4',
'Type' => 'Const'
},
- '14585' => {
+ '14626' => {
'BaseType' => '318',
'Name' => 'bitfield8_t[1]',
'Size' => '1',
'Type' => 'Array'
},
- '14601' => {
+ '14642' => {
'Header' => 'platform.h',
'Line' => '574',
'Memb' => {
'0' => {
'name' => 'hdr',
'offset' => '0',
- 'type' => '14304'
+ 'type' => '14345'
},
'1' => {
'name' => 'terminus_handle',
@@ -10199,7 +10200,7 @@
'Size' => '26',
'Type' => 'Struct'
},
- '14946' => {
+ '14987' => {
'Header' => 'platform.h',
'Line' => '665',
'Memb' => {
@@ -10243,7 +10244,7 @@
'Size' => '4',
'Type' => 'Union'
},
- '15509' => {
+ '15550' => {
'Header' => 'platform.h',
'Line' => '722',
'Memb' => {
@@ -10282,7 +10283,7 @@
'Size' => '4',
'Type' => 'Union'
},
- '15521' => {
+ '15562' => {
'Header' => 'platform.h',
'Line' => '729',
'Memb' => {
@@ -10316,7 +10317,7 @@
'Size' => '12',
'Type' => 'Struct'
},
- '15600' => {
+ '15641' => {
'Header' => 'platform.h',
'Line' => '747',
'Memb' => {
@@ -10335,14 +10336,14 @@
'Size' => '2',
'Type' => 'Union'
},
- '15634' => {
+ '15675' => {
'Header' => 'platform.h',
'Line' => '742',
'Memb' => {
'0' => {
'name' => 'hdr',
'offset' => '0',
- 'type' => '15521'
+ 'type' => '15562'
},
'1' => {
'name' => 'terminus_handle',
@@ -10362,7 +10363,7 @@
'4' => {
'name' => 'unnamed0',
'offset' => '24',
- 'type' => '15600'
+ 'type' => '15641'
},
'5' => {
'name' => 'container_id',
@@ -10462,7 +10463,7 @@
'24' => {
'name' => 'hysteresis',
'offset' => '72',
- 'type' => '15509'
+ 'type' => '15550'
},
'25' => {
'name' => 'supported_thresholds',
@@ -10487,12 +10488,12 @@
'29' => {
'name' => 'max_readable',
'offset' => '100',
- 'type' => '15509'
+ 'type' => '15550'
},
'30' => {
'name' => 'min_readable',
'offset' => '104',
- 'type' => '15509'
+ 'type' => '15550'
},
'31' => {
'name' => 'range_field_format',
@@ -10507,54 +10508,54 @@
'33' => {
'name' => 'nominal_value',
'offset' => '118',
- 'type' => '14946'
+ 'type' => '14987'
},
'34' => {
'name' => 'normal_max',
'offset' => '128',
- 'type' => '14946'
+ 'type' => '14987'
},
'35' => {
'name' => 'normal_min',
'offset' => '132',
- 'type' => '14946'
+ 'type' => '14987'
},
'36' => {
'name' => 'warning_high',
'offset' => '136',
- 'type' => '14946'
+ 'type' => '14987'
},
'37' => {
'name' => 'warning_low',
'offset' => '146',
- 'type' => '14946'
+ 'type' => '14987'
},
'38' => {
'name' => 'critical_high',
'offset' => '150',
- 'type' => '14946'
+ 'type' => '14987'
},
'39' => {
'name' => 'critical_low',
'offset' => '256',
- 'type' => '14946'
+ 'type' => '14987'
},
'40' => {
'name' => 'fatal_high',
'offset' => '260',
- 'type' => '14946'
+ 'type' => '14987'
},
'41' => {
'name' => 'fatal_low',
'offset' => '264',
- 'type' => '14946'
+ 'type' => '14987'
}
},
'Name' => 'struct pldm_numeric_sensor_value_pdr',
'Size' => '112',
'Type' => 'Struct'
},
- '16187' => {
+ '16228' => {
'Header' => 'platform.h',
'Line' => '794',
'Memb' => {
@@ -10571,20 +10572,20 @@
'2' => {
'name' => 'states',
'offset' => '3',
- 'type' => '14585'
+ 'type' => '14626'
}
},
'Name' => 'struct state_effecter_possible_states',
'Size' => '4',
'Type' => 'Struct'
},
- '16240' => {
- 'BaseType' => '16187',
+ '16281' => {
+ 'BaseType' => '16228',
'Name' => 'struct state_effecter_possible_states const',
'Size' => '4',
'Type' => 'Const'
},
- '16245' => {
+ '16286' => {
'Header' => 'platform.h',
'Line' => '842',
'Memb' => {
@@ -10603,15 +10604,15 @@
'Size' => '2',
'Type' => 'Struct'
},
- '16285' => {
- 'BaseType' => '16245',
+ '16326' => {
+ 'BaseType' => '16286',
'Header' => 'platform.h',
'Line' => '845',
'Name' => 'set_effecter_state_field',
'Size' => '2',
'Type' => 'Typedef'
},
- '16297' => {
+ '16338' => {
'Header' => 'platform.h',
'Line' => '851',
'Memb' => {
@@ -10640,21 +10641,21 @@
'Size' => '4',
'Type' => 'Struct'
},
- '16363' => {
- 'BaseType' => '16297',
+ '16404' => {
+ 'BaseType' => '16338',
'Header' => 'platform.h',
'Line' => '859',
'Name' => 'get_sensor_state_field',
'Size' => '4',
'Type' => 'Typedef'
},
- '16562' => {
+ '16603' => {
'BaseType' => '140',
'Name' => 'uint8_t[13]',
'Size' => '13',
'Type' => 'Array'
},
- '17044' => {
+ '17085' => {
'Header' => 'platform.h',
'Line' => '996',
'Memb' => {
@@ -10678,7 +10679,7 @@
'Size' => '4',
'Type' => 'Struct'
},
- '17256' => {
+ '17297' => {
'Header' => 'platform.h',
'Line' => '1077',
'Memb' => {
@@ -10702,121 +10703,121 @@
'Size' => '3',
'Type' => 'Struct'
},
- '40934' => {
+ '60289' => {
'BaseType' => '126',
'Name' => 'void**',
'Size' => '8',
'Type' => 'Pointer'
},
- '50320' => {
+ '70429' => {
'BaseType' => '9819',
'Name' => 'size_t*const',
'Size' => '8',
'Type' => 'Const'
},
- '53553' => {
- 'BaseType' => '53563',
+ '74019' => {
+ 'BaseType' => '74029',
'Name' => 'uint32_t const*const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '53558' => {
+ '74024' => {
'BaseType' => '12654',
'Name' => 'uint32_t const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '53563' => {
- 'BaseType' => '53558',
+ '74029' => {
+ 'BaseType' => '74024',
'Name' => 'uint32_t const*const',
'Size' => '8',
'Type' => 'Const'
},
- '53568' => {
- 'BaseType' => '17256',
+ '74034' => {
+ 'BaseType' => '17297',
'Name' => 'struct pldm_pdr_repository_chg_event_data*',
'Size' => '8',
'Type' => 'Pointer'
},
- '89026' => {
- 'BaseType' => '15634',
+ '137431' => {
+ 'BaseType' => '15675',
'Name' => 'struct pldm_numeric_sensor_value_pdr*',
'Size' => '8',
'Type' => 'Pointer'
},
- '103252' => {
- 'BaseType' => '17044',
+ '152786' => {
+ 'BaseType' => '17085',
'Name' => 'struct pldm_sensor_event_data*',
'Size' => '8',
'Type' => 'Pointer'
},
- '103257' => {
- 'BaseType' => '103252',
+ '152791' => {
+ 'BaseType' => '152786',
'Name' => 'struct pldm_sensor_event_data*const',
'Size' => '8',
'Type' => 'Const'
},
- '105946' => {
- 'BaseType' => '16363',
+ '155712' => {
+ 'BaseType' => '16404',
'Name' => 'get_sensor_state_field*',
'Size' => '8',
'Type' => 'Pointer'
},
- '118556' => {
- 'BaseType' => '16285',
+ '168936' => {
+ 'BaseType' => '16326',
'Name' => 'set_effecter_state_field*',
'Size' => '8',
'Type' => 'Pointer'
},
- '119522' => {
- 'BaseType' => '14383',
+ '169902' => {
+ 'BaseType' => '14424',
'Name' => 'struct pldm_state_sensor_pdr*',
'Size' => '8',
'Type' => 'Pointer'
},
- '119527' => {
- 'BaseType' => '119522',
+ '169907' => {
+ 'BaseType' => '169902',
'Name' => 'struct pldm_state_sensor_pdr*const',
'Size' => '8',
'Type' => 'Const'
},
- '119532' => {
- 'BaseType' => '14580',
+ '169912' => {
+ 'BaseType' => '14621',
'Name' => 'struct state_sensor_possible_states const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '119537' => {
- 'BaseType' => '119532',
+ '169917' => {
+ 'BaseType' => '169912',
'Name' => 'struct state_sensor_possible_states const*const',
'Size' => '8',
'Type' => 'Const'
},
- '119926' => {
- 'BaseType' => '14601',
+ '170306' => {
+ 'BaseType' => '14642',
'Name' => 'struct pldm_state_effecter_pdr*',
'Size' => '8',
'Type' => 'Pointer'
},
- '119931' => {
- 'BaseType' => '119926',
+ '170311' => {
+ 'BaseType' => '170306',
'Name' => 'struct pldm_state_effecter_pdr*const',
'Size' => '8',
'Type' => 'Const'
},
- '119936' => {
- 'BaseType' => '16240',
+ '170316' => {
+ 'BaseType' => '16281',
'Name' => 'struct state_effecter_possible_states const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '119941' => {
- 'BaseType' => '119936',
+ '170321' => {
+ 'BaseType' => '170316',
'Name' => 'struct state_effecter_possible_states const*const',
'Size' => '8',
'Type' => 'Const'
},
- '123169' => {
+ '175277' => {
'BaseType' => '67',
'Header' => 'types.h',
'Line' => '45',
@@ -10825,7 +10826,7 @@
'Size' => '8',
'Type' => 'Typedef'
},
- '123188' => {
+ '175296' => {
'BaseType' => '119',
'Header' => 'types.h',
'Line' => '194',
@@ -10834,8 +10835,8 @@
'Size' => '8',
'Type' => 'Typedef'
},
- '123263' => {
- 'BaseType' => '123169',
+ '175371' => {
+ 'BaseType' => '175277',
'Header' => 'stdint-uintn.h',
'Line' => '27',
'Name' => 'uint64_t',
@@ -10843,7 +10844,7 @@
'Size' => '8',
'Type' => 'Typedef'
},
- '123409' => {
+ '175517' => {
'Header' => 'bios.h',
'Line' => '39',
'Memb' => {
@@ -10864,7 +10865,7 @@
'Size' => '4',
'Type' => 'Enum'
},
- '123443' => {
+ '175551' => {
'Header' => 'bios.h',
'Line' => '48',
'Memb' => {
@@ -10881,26 +10882,26 @@
'2' => {
'name' => 'name',
'offset' => '4',
- 'type' => '123500'
+ 'type' => '175608'
}
},
'Name' => 'struct pldm_bios_string_table_entry',
'Size' => '5',
'Type' => 'Struct'
},
- '123495' => {
- 'BaseType' => '123443',
+ '175603' => {
+ 'BaseType' => '175551',
'Name' => 'struct pldm_bios_string_table_entry const',
'Size' => '5',
'Type' => 'Const'
},
- '123500' => {
+ '175608' => {
'BaseType' => '133',
'Name' => 'char[1]',
'Size' => '1',
'Type' => 'Array'
},
- '123516' => {
+ '175624' => {
'Header' => 'bios.h',
'Line' => '54',
'Memb' => {
@@ -10929,13 +10930,13 @@
'Size' => '6',
'Type' => 'Struct'
},
- '123581' => {
- 'BaseType' => '123516',
+ '175689' => {
+ 'BaseType' => '175624',
'Name' => 'struct pldm_bios_attr_table_entry const',
'Size' => '6',
'Type' => 'Const'
},
- '123586' => {
+ '175694' => {
'Header' => 'bios.h',
'Line' => '66',
'Memb' => {
@@ -10959,13 +10960,13 @@
'Size' => '4',
'Type' => 'Struct'
},
- '123638' => {
- 'BaseType' => '123586',
+ '175746' => {
+ 'BaseType' => '175694',
'Name' => 'struct pldm_bios_attr_val_table_entry const',
'Size' => '4',
'Type' => 'Const'
},
- '123707' => {
+ '175815' => {
'Header' => 'bios_table.h',
'Line' => '206',
'Memb' => {
@@ -10987,7 +10988,7 @@
'3' => {
'name' => 'pv_handle',
'offset' => '8',
- 'type' => '123810'
+ 'type' => '175918'
},
'4' => {
'name' => 'def_num',
@@ -11004,19 +11005,19 @@
'Size' => '32',
'Type' => 'Struct'
},
- '123798' => {
- 'BaseType' => '123707',
+ '175906' => {
+ 'BaseType' => '175815',
'Name' => 'struct pldm_bios_table_attr_entry_enum_info const',
'Size' => '32',
'Type' => 'Const'
},
- '123810' => {
+ '175918' => {
'BaseType' => '12637',
'Name' => 'uint16_t const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '123820' => {
+ '175928' => {
'Header' => 'bios_table.h',
'Line' => '294',
'Memb' => {
@@ -11060,13 +11061,13 @@
'Size' => '24',
'Type' => 'Struct'
},
- '123932' => {
- 'BaseType' => '123820',
+ '176040' => {
+ 'BaseType' => '175928',
'Name' => 'struct pldm_bios_table_attr_entry_string_info const',
'Size' => '24',
'Type' => 'Const'
},
- '123942' => {
+ '176050' => {
'Header' => 'bios_table.h',
'Line' => '384',
'Memb' => {
@@ -11083,12 +11084,12 @@
'2' => {
'name' => 'lower_bound',
'offset' => '8',
- 'type' => '123263'
+ 'type' => '175371'
},
'3' => {
'name' => 'upper_bound',
'offset' => '22',
- 'type' => '123263'
+ 'type' => '175371'
},
'4' => {
'name' => 'scalar_increment',
@@ -11098,21 +11099,21 @@
'5' => {
'name' => 'default_value',
'offset' => '50',
- 'type' => '123263'
+ 'type' => '175371'
}
},
'Name' => 'struct pldm_bios_table_attr_entry_integer_info',
'Size' => '40',
'Type' => 'Struct'
},
- '124040' => {
- 'BaseType' => '123942',
+ '176148' => {
+ 'BaseType' => '176050',
'Name' => 'struct pldm_bios_table_attr_entry_integer_info const',
'Size' => '40',
'Type' => 'Const'
},
- '124045' => {
- 'BaseType' => '123188',
+ '176153' => {
+ 'BaseType' => '175296',
'Header' => 'types.h',
'Line' => '108',
'Name' => 'ssize_t',
@@ -11120,18 +11121,18 @@
'Size' => '8',
'Type' => 'Typedef'
},
- '124323' => {
+ '176431' => {
'Name' => 'ssize_t(*)(void const*)',
'Param' => {
'0' => {
'type' => '5342'
}
},
- 'Return' => '124045',
+ 'Return' => '176153',
'Size' => '8',
'Type' => 'FuncPtr'
},
- '124393' => {
+ '176501' => {
'Line' => '938',
'Memb' => {
'0' => {
@@ -11152,7 +11153,7 @@
'3' => {
'name' => 'entry_length_handler',
'offset' => '36',
- 'type' => '124323'
+ 'type' => '176431'
}
},
'Name' => 'struct pldm_bios_table_iter',
@@ -11161,80 +11162,80 @@
'Source' => 'bios_table.c',
'Type' => 'Struct'
},
- '124463' => {
- 'BaseType' => '124393',
+ '176571' => {
+ 'BaseType' => '176501',
'Name' => 'struct pldm_bios_table_iter const',
'Size' => '32',
'Type' => 'Const'
},
- '125533' => {
- 'BaseType' => '124393',
+ '177641' => {
+ 'BaseType' => '176501',
'Name' => 'struct pldm_bios_table_iter*',
'Size' => '8',
'Type' => 'Pointer'
},
- '125538' => {
- 'BaseType' => '123638',
+ '177646' => {
+ 'BaseType' => '175746',
'Name' => 'struct pldm_bios_attr_val_table_entry const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '125952' => {
- 'BaseType' => '123581',
+ '178060' => {
+ 'BaseType' => '175689',
'Name' => 'struct pldm_bios_attr_table_entry const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '126556' => {
- 'BaseType' => '123495',
+ '178664' => {
+ 'BaseType' => '175603',
'Name' => 'struct pldm_bios_string_table_entry const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '127719' => {
- 'BaseType' => '124463',
+ '179827' => {
+ 'BaseType' => '176571',
'Name' => 'struct pldm_bios_table_iter const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '131992' => {
- 'BaseType' => '123263',
+ '184100' => {
+ 'BaseType' => '175371',
'Name' => 'uint64_t*',
'Size' => '8',
'Type' => 'Pointer'
},
- '132269' => {
- 'BaseType' => '124040',
+ '184377' => {
+ 'BaseType' => '176148',
'Name' => 'struct pldm_bios_table_attr_entry_integer_info const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '132578' => {
+ '184686' => {
'BaseType' => '13466',
'Name' => 'char const**',
'Size' => '8',
'Type' => 'Pointer'
},
- '133750' => {
- 'BaseType' => '123932',
+ '185858' => {
+ 'BaseType' => '176040',
'Name' => 'struct pldm_bios_table_attr_entry_string_info const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '135250' => {
- 'BaseType' => '123798',
+ '187358' => {
+ 'BaseType' => '175906',
'Name' => 'struct pldm_bios_table_attr_entry_enum_info const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '137468' => {
+ '189576' => {
'Header' => 'pldm_types.h',
'Line' => '36',
'Name' => 'anon-struct-pldm_types.h-36',
'Size' => '2',
'Type' => 'Struct'
},
- '137732' => {
+ '189840' => {
'Header' => 'pldm_types.h',
'Line' => '54',
'Memb' => {
@@ -11246,21 +11247,21 @@
'1' => {
'name' => 'bits',
'offset' => '0',
- 'type' => '137468'
+ 'type' => '189576'
}
},
'Name' => 'union bitfield16_t',
'Size' => '2',
'Type' => 'Union'
},
- '137744' => {
+ '189852' => {
'Header' => 'pldm_types.h',
'Line' => '58',
'Name' => 'anon-struct-pldm_types.h-58',
'Size' => '4',
'Type' => 'Struct'
},
- '138232' => {
+ '190340' => {
'Header' => 'pldm_types.h',
'Line' => '92',
'Memb' => {
@@ -11272,47 +11273,47 @@
'1' => {
'name' => 'bits',
'offset' => '0',
- 'type' => '137744'
+ 'type' => '189852'
}
},
'Name' => 'union bitfield32_t',
'Size' => '4',
'Type' => 'Union'
},
- '138244' => {
+ '190352' => {
'Header' => 'pldm_types.h',
'Line' => '96',
'Name' => 'anon-struct-pldm_types.h-96',
'Size' => '8',
'Type' => 'Struct'
},
- '139180' => {
+ '191288' => {
'Header' => 'pldm_types.h',
'Line' => '162',
'Memb' => {
'0' => {
'name' => 'value',
'offset' => '0',
- 'type' => '123263'
+ 'type' => '175371'
},
'1' => {
'name' => 'bits',
'offset' => '0',
- 'type' => '138244'
+ 'type' => '190352'
}
},
'Name' => 'union bitfield64_t',
'Size' => '8',
'Type' => 'Union'
},
- '140952' => {
+ '193101' => {
'Header' => 'firmware_update.h',
'Line' => '372',
'Memb' => {
'0' => {
'name' => 'uuid',
'offset' => '0',
- 'type' => '141056'
+ 'type' => '193205'
},
'1' => {
'name' => 'package_header_format_version',
@@ -11327,7 +11328,7 @@
'3' => {
'name' => 'package_release_date_time',
'offset' => '25',
- 'type' => '16562'
+ 'type' => '16603'
},
'4' => {
'name' => 'component_bitmap_bit_length',
@@ -11349,13 +11350,13 @@
'Size' => '36',
'Type' => 'Struct'
},
- '141056' => {
+ '193205' => {
'BaseType' => '140',
'Name' => 'uint8_t[16]',
'Size' => '16',
'Type' => 'Array'
},
- '141088' => {
+ '193237' => {
'Header' => 'firmware_update.h',
'Line' => '386',
'Memb' => {
@@ -11372,7 +11373,7 @@
'2' => {
'name' => 'device_update_option_flags',
'offset' => '3',
- 'type' => '138232'
+ 'type' => '190340'
},
'3' => {
'name' => 'comp_image_set_version_string_type',
@@ -11394,7 +11395,7 @@
'Size' => '11',
'Type' => 'Struct'
},
- '141283' => {
+ '193432' => {
'Header' => 'firmware_update.h',
'Line' => '420',
'Memb' => {
@@ -11416,12 +11417,12 @@
'3' => {
'name' => 'comp_options',
'offset' => '8',
- 'type' => '137732'
+ 'type' => '189840'
},
'4' => {
'name' => 'requested_comp_activation_method',
'offset' => '16',
- 'type' => '137732'
+ 'type' => '189840'
},
'5' => {
'name' => 'comp_location_offset',
@@ -11448,7 +11449,7 @@
'Size' => '22',
'Type' => 'Struct'
},
- '141465' => {
+ '193614' => {
'Header' => 'firmware_update.h',
'Line' => '446',
'Memb' => {
@@ -11460,7 +11461,7 @@
'1' => {
'name' => 'capabilities_during_update',
'offset' => '1',
- 'type' => '138232'
+ 'type' => '190340'
},
'2' => {
'name' => 'comp_count',
@@ -11492,7 +11493,7 @@
'Size' => '11',
'Type' => 'Struct'
},
- '141647' => {
+ '193796' => {
'Header' => 'firmware_update.h',
'Line' => '474',
'Memb' => {
@@ -11529,7 +11530,7 @@
'6' => {
'name' => 'active_comp_release_date',
'offset' => '17',
- 'type' => '141829'
+ 'type' => '193978'
},
'7' => {
'name' => 'pending_comp_comparison_stamp',
@@ -11549,103 +11550,103 @@
'10' => {
'name' => 'pending_comp_release_date',
'offset' => '37',
- 'type' => '141829'
+ 'type' => '193978'
},
'11' => {
'name' => 'comp_activation_methods',
'offset' => '51',
- 'type' => '137732'
+ 'type' => '189840'
},
'12' => {
'name' => 'capabilities_during_update',
'offset' => '53',
- 'type' => '138232'
+ 'type' => '190340'
}
},
'Name' => 'struct pldm_component_parameter_entry',
'Size' => '39',
'Type' => 'Struct'
},
- '141829' => {
+ '193978' => {
'BaseType' => '140',
'Name' => 'uint8_t[8]',
'Size' => '8',
'Type' => 'Array'
},
- '142767' => {
+ '194916' => {
'BaseType' => '6778',
'Name' => 'struct variable_field const',
'Size' => '16',
'Type' => 'Const'
},
- '143105' => {
+ '195254' => {
'BaseType' => '12849',
'Name' => 'bool8_t*',
'Size' => '8',
'Type' => 'Pointer'
},
- '143110' => {
- 'BaseType' => '139180',
+ '195259' => {
+ 'BaseType' => '191288',
'Name' => 'bitfield64_t*',
'Size' => '8',
'Type' => 'Pointer'
},
- '143865' => {
- 'BaseType' => '138232',
+ '196016' => {
+ 'BaseType' => '190340',
'Name' => 'bitfield32_t*',
'Size' => '8',
'Type' => 'Pointer'
},
- '144714' => {
- 'BaseType' => '137732',
+ '196868' => {
+ 'BaseType' => '189840',
'Name' => 'bitfield16_t*',
'Size' => '8',
'Type' => 'Pointer'
},
- '146268' => {
- 'BaseType' => '142767',
+ '198426' => {
+ 'BaseType' => '194916',
'Name' => 'struct variable_field const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '152246' => {
- 'BaseType' => '141647',
+ '204715' => {
+ 'BaseType' => '193796',
'Name' => 'struct pldm_component_parameter_entry*',
'Size' => '8',
'Type' => 'Pointer'
},
- '152471' => {
- 'BaseType' => '141465',
+ '204940' => {
+ 'BaseType' => '193614',
'Name' => 'struct pldm_get_firmware_parameters_resp*',
'Size' => '8',
'Type' => 'Pointer'
},
- '152772' => {
+ '205241' => {
'BaseType' => '2076',
'Name' => 'uint8_t**',
'Size' => '8',
'Type' => 'Pointer'
},
- '153069' => {
- 'BaseType' => '141283',
+ '205538' => {
+ 'BaseType' => '193432',
'Name' => 'struct pldm_component_image_information*',
'Size' => '8',
'Type' => 'Pointer'
},
- '153685' => {
- 'BaseType' => '141088',
+ '206154' => {
+ 'BaseType' => '193237',
'Name' => 'struct pldm_firmware_device_id_record*',
'Size' => '8',
'Type' => 'Pointer'
},
- '153995' => {
- 'BaseType' => '140952',
+ '206464' => {
+ 'BaseType' => '193101',
'Name' => 'struct pldm_package_header_information*',
'Size' => '8',
'Type' => 'Pointer'
},
- '161515' => {
- 'BaseType' => '161532',
+ '214296' => {
+ 'BaseType' => '214313',
'Header' => 'pdr.h',
'Line' => '16',
'Name' => 'pldm_pdr',
@@ -11653,13 +11654,13 @@
'Size' => '24',
'Type' => 'Typedef'
},
- '161527' => {
- 'BaseType' => '161515',
+ '214308' => {
+ 'BaseType' => '214296',
'Name' => 'pldm_pdr const',
'Size' => '24',
'Type' => 'Const'
},
- '161532' => {
+ '214313' => {
'Line' => '20',
'Memb' => {
'0' => {
@@ -11675,12 +11676,12 @@
'2' => {
'name' => 'first',
'offset' => '8',
- 'type' => '162666'
+ 'type' => '215447'
},
'3' => {
'name' => 'last',
'offset' => '22',
- 'type' => '162666'
+ 'type' => '215447'
}
},
'Name' => 'struct pldm_pdr',
@@ -11689,8 +11690,8 @@
'Source' => 'pdr.c',
'Type' => 'Struct'
},
- '161592' => {
- 'BaseType' => '161609',
+ '214373' => {
+ 'BaseType' => '214390',
'Header' => 'pdr.h',
'Line' => '21',
'Name' => 'pldm_pdr_record',
@@ -11698,13 +11699,13 @@
'Size' => '32',
'Type' => 'Typedef'
},
- '161604' => {
- 'BaseType' => '161592',
+ '214385' => {
+ 'BaseType' => '214373',
'Name' => 'pldm_pdr_record const',
'Size' => '32',
'Type' => 'Const'
},
- '161609' => {
+ '214390' => {
'Line' => '11',
'Memb' => {
'0' => {
@@ -11725,7 +11726,7 @@
'3' => {
'name' => 'next',
'offset' => '22',
- 'type' => '162654'
+ 'type' => '215435'
},
'4' => {
'name' => 'is_remote',
@@ -11744,7 +11745,7 @@
'Source' => 'pdr.c',
'Type' => 'Struct'
},
- '161693' => {
+ '214474' => {
'Header' => 'pdr.h',
'Line' => '275',
'Memb' => {
@@ -11768,16 +11769,16 @@
'Size' => '6',
'Type' => 'Struct'
},
- '161750' => {
- 'BaseType' => '161693',
+ '214531' => {
+ 'BaseType' => '214474',
'Header' => 'pdr.h',
'Line' => '279',
'Name' => 'pldm_entity',
'Size' => '6',
'Type' => 'Typedef'
},
- '161794' => {
- 'BaseType' => '161806',
+ '214575' => {
+ 'BaseType' => '214587',
'Header' => 'pdr.h',
'Line' => '289',
'Name' => 'pldm_entity_association_tree',
@@ -11785,13 +11786,13 @@
'Size' => '16',
'Type' => 'Typedef'
},
- '161806' => {
+ '214587' => {
'Line' => '435',
'Memb' => {
'0' => {
'name' => 'root',
'offset' => '0',
- 'type' => '162671'
+ 'type' => '215452'
},
'1' => {
'name' => 'last_used_container_id',
@@ -11805,8 +11806,8 @@
'Source' => 'pdr.c',
'Type' => 'Struct'
},
- '161849' => {
- 'BaseType' => '161866',
+ '214630' => {
+ 'BaseType' => '214647',
'Header' => 'pdr.h',
'Line' => '294',
'Name' => 'pldm_entity_node',
@@ -11814,24 +11815,24 @@
'Size' => '40',
'Type' => 'Typedef'
},
- '161861' => {
- 'BaseType' => '161849',
+ '214642' => {
+ 'BaseType' => '214630',
'Name' => 'pldm_entity_node const',
'Size' => '40',
'Type' => 'Const'
},
- '161866' => {
+ '214647' => {
'Line' => '440',
'Memb' => {
'0' => {
'name' => 'entity',
'offset' => '0',
- 'type' => '161750'
+ 'type' => '214531'
},
'1' => {
'name' => 'parent',
'offset' => '6',
- 'type' => '161750'
+ 'type' => '214531'
},
'2' => {
'name' => 'remote_container_id',
@@ -11841,12 +11842,12 @@
'3' => {
'name' => 'first_child',
'offset' => '22',
- 'type' => '162671'
+ 'type' => '215452'
},
'4' => {
'name' => 'next_sibling',
'offset' => '36',
- 'type' => '162671'
+ 'type' => '215452'
},
'5' => {
'name' => 'association_type',
@@ -11860,73 +11861,73 @@
'Source' => 'pdr.c',
'Type' => 'Struct'
},
- '162654' => {
- 'BaseType' => '161609',
+ '215435' => {
+ 'BaseType' => '214390',
'Name' => 'struct pldm_pdr_record*',
'Size' => '8',
'Type' => 'Pointer'
},
- '162666' => {
- 'BaseType' => '161592',
+ '215447' => {
+ 'BaseType' => '214373',
'Name' => 'pldm_pdr_record*',
'Size' => '8',
'Type' => 'Pointer'
},
- '162671' => {
- 'BaseType' => '161849',
+ '215452' => {
+ 'BaseType' => '214630',
'Name' => 'pldm_entity_node*',
'Size' => '8',
'Type' => 'Pointer'
},
- '163064' => {
- 'BaseType' => '163069',
+ '215845' => {
+ 'BaseType' => '215850',
'Name' => 'pldm_entity**',
'Size' => '8',
'Type' => 'Pointer'
},
- '163069' => {
- 'BaseType' => '161750',
+ '215850' => {
+ 'BaseType' => '214531',
'Name' => 'pldm_entity*',
'Size' => '8',
'Type' => 'Pointer'
},
- '163133' => {
- 'BaseType' => '161794',
+ '215914' => {
+ 'BaseType' => '214575',
'Name' => 'pldm_entity_association_tree*',
'Size' => '8',
'Type' => 'Pointer'
},
- '163580' => {
- 'BaseType' => '162671',
+ '216361' => {
+ 'BaseType' => '215452',
'Name' => 'pldm_entity_node**',
'Size' => '8',
'Type' => 'Pointer'
},
- '164369' => {
- 'BaseType' => '161527',
+ '217150' => {
+ 'BaseType' => '214308',
'Name' => 'pldm_pdr const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '164622' => {
- 'BaseType' => '161515',
+ '217403' => {
+ 'BaseType' => '214296',
'Name' => 'pldm_pdr*',
'Size' => '8',
'Type' => 'Pointer'
},
- '169731' => {
- 'BaseType' => '161861',
+ '222512' => {
+ 'BaseType' => '214642',
'Name' => 'pldm_entity_node const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '170895' => {
- 'BaseType' => '161604',
+ '223676' => {
+ 'BaseType' => '214385',
'Name' => 'pldm_pdr_record const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '173983' => {
+ '226764' => {
'BaseType' => '140',
'Header' => 'base.h',
'Line' => '16',
@@ -11934,7 +11935,7 @@
'Size' => '1',
'Type' => 'Typedef'
},
- '173995' => {
+ '226776' => {
'BaseType' => '140',
'Header' => 'instance-id.h',
'Line' => '13',
@@ -11942,19 +11943,19 @@
'Size' => '1',
'Type' => 'Typedef'
},
- '174007' => {
+ '226788' => {
'Header' => 'responder.h',
'Line' => '10',
'Memb' => {
'0' => {
'name' => 'tid',
'offset' => '0',
- 'type' => '173983'
+ 'type' => '226764'
},
'1' => {
'name' => 'instance_id',
'offset' => '1',
- 'type' => '173995'
+ 'type' => '226776'
},
'2' => {
'name' => 'type',
@@ -11969,7 +11970,7 @@
'4' => {
'name' => 'next',
'offset' => '8',
- 'type' => '174087'
+ 'type' => '226868'
}
},
'Name' => 'struct pldm_responder_cookie',
@@ -11977,13 +11978,13 @@
'Size' => '16',
'Type' => 'Struct'
},
- '174087' => {
- 'BaseType' => '174007',
+ '226868' => {
+ 'BaseType' => '226788',
'Name' => 'struct pldm_responder_cookie*',
'Size' => '8',
'Type' => 'Pointer'
},
- '174092' => {
+ '226873' => {
'Header' => 'pldm.h',
'Line' => '15',
'Memb' => {
@@ -12048,13 +12049,13 @@
'Size' => '4',
'Type' => 'Enum'
},
- '177027' => {
+ '229808' => {
'Line' => '20',
'Memb' => {
'0' => {
'name' => 'prev',
'offset' => '0',
- 'type' => '173995'
+ 'type' => '226776'
},
'1' => {
'name' => 'allocations',
@@ -12068,13 +12069,13 @@
'Source' => 'instance-id.c',
'Type' => 'Struct'
},
- '177066' => {
+ '229847' => {
'Line' => '25',
'Memb' => {
'0' => {
'name' => 'state',
'offset' => '0',
- 'type' => '177108'
+ 'type' => '229889'
},
'1' => {
'name' => 'lock_db_fd',
@@ -12088,31 +12089,31 @@
'Source' => 'instance-id.c',
'Type' => 'Struct'
},
- '177108' => {
- 'BaseType' => '177027',
+ '229889' => {
+ 'BaseType' => '229808',
'Name' => 'struct pldm_tid_state[256]',
'Size' => '2048',
'Type' => 'Array'
},
- '177578' => {
- 'BaseType' => '177066',
+ '230359' => {
+ 'BaseType' => '229847',
'Name' => 'struct pldm_instance_db*',
'Size' => '8',
'Type' => 'Pointer'
},
- '178003' => {
- 'BaseType' => '173995',
+ '230784' => {
+ 'BaseType' => '226776',
'Name' => 'pldm_instance_id_t*',
'Size' => '8',
'Type' => 'Pointer'
},
- '178179' => {
- 'BaseType' => '177578',
+ '230960' => {
+ 'BaseType' => '230359',
'Name' => 'struct pldm_instance_db**',
'Size' => '8',
'Type' => 'Pointer'
},
- '178936' => {
+ '231717' => {
'BaseType' => '140',
'Header' => 'pldm.h',
'Line' => '13',
@@ -12120,21 +12121,21 @@
'Size' => '1',
'Type' => 'Typedef'
},
- '179051' => {
- 'BaseType' => '174092',
+ '231832' => {
+ 'BaseType' => '226873',
'Header' => 'pldm.h',
'Line' => '30',
'Name' => 'pldm_requester_rc_t',
'Size' => '4',
'Type' => 'Typedef'
},
- '179069' => {
+ '231850' => {
'Line' => '25',
'Memb' => {
'0' => {
'name' => 'transport',
'offset' => '0',
- 'type' => '179142'
+ 'type' => '231923'
},
'1' => {
'name' => 'socket',
@@ -12144,12 +12145,12 @@
'2' => {
'name' => 'tid_eid_map',
'offset' => '68',
- 'type' => '182774'
+ 'type' => '235555'
},
'3' => {
'name' => 'socket_send_buf',
'offset' => '768',
- 'type' => '181723'
+ 'type' => '234504'
}
},
'Name' => 'struct pldm_transport_mctp_demux',
@@ -12158,19 +12159,19 @@
'Source' => 'mctp-demux.c',
'Type' => 'Struct'
},
- '179095' => {
- 'BaseType' => '179069',
+ '231876' => {
+ 'BaseType' => '231850',
'Name' => 'struct pldm_transport_mctp_demux*',
'Size' => '8',
'Type' => 'Pointer'
},
- '179137' => {
- 'BaseType' => '179142',
+ '231918' => {
+ 'BaseType' => '231923',
'Name' => 'struct pldm_transport*',
'Size' => '8',
'Type' => 'Pointer'
},
- '179142' => {
+ '231923' => {
'Header' => 'transport.h',
'Line' => '18',
'Memb' => {
@@ -12187,17 +12188,17 @@
'2' => {
'name' => 'recv',
'offset' => '22',
- 'type' => '182034'
+ 'type' => '234815'
},
'3' => {
'name' => 'send',
'offset' => '36',
- 'type' => '182075'
+ 'type' => '234856'
},
'4' => {
'name' => 'init_pollfd',
'offset' => '50',
- 'type' => '182155'
+ 'type' => '234936'
}
},
'Name' => 'struct pldm_transport',
@@ -12205,19 +12206,19 @@
'Size' => '40',
'Type' => 'Struct'
},
- '179278' => {
- 'BaseType' => '173983',
+ '232059' => {
+ 'BaseType' => '226764',
'Name' => 'pldm_tid_t*',
'Size' => '8',
'Type' => 'Pointer'
},
- '179381' => {
- 'BaseType' => '179095',
+ '232162' => {
+ 'BaseType' => '231876',
'Name' => 'struct pldm_transport_mctp_demux**',
'Size' => '8',
'Type' => 'Pointer'
},
- '181443' => {
+ '234224' => {
'BaseType' => '46',
'Header' => 'int-ll64.h',
'Line' => '21',
@@ -12226,7 +12227,7 @@
'Size' => '1',
'Type' => 'Typedef'
},
- '181455' => {
+ '234236' => {
'BaseType' => '53',
'Header' => 'int-ll64.h',
'Line' => '24',
@@ -12235,7 +12236,7 @@
'Size' => '2',
'Type' => 'Typedef'
},
- '181723' => {
+ '234504' => {
'Header' => 'socket.h',
'Line' => '5',
'Memb' => {
@@ -12260,34 +12261,34 @@
'Size' => '12',
'Type' => 'Struct'
},
- '182034' => {
+ '234815' => {
'Name' => 'pldm_requester_rc_t(*)(struct pldm_transport*, pldm_tid_t*, void**, size_t*)',
'Param' => {
'0' => {
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
- 'type' => '179278'
+ 'type' => '232059'
},
'2' => {
- 'type' => '40934'
+ 'type' => '60289'
},
'3' => {
'type' => '9819'
}
},
- 'Return' => '179051',
+ 'Return' => '231832',
'Size' => '8',
'Type' => 'FuncPtr'
},
- '182075' => {
+ '234856' => {
'Name' => 'pldm_requester_rc_t(*)(struct pldm_transport*, pldm_tid_t, void const*, size_t)',
'Param' => {
'0' => {
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
- 'type' => '173983'
+ 'type' => '226764'
},
'2' => {
'type' => '5342'
@@ -12296,17 +12297,17 @@
'type' => '453'
}
},
- 'Return' => '179051',
+ 'Return' => '231832',
'Size' => '8',
'Type' => 'FuncPtr'
},
- '182100' => {
- 'BaseType' => '182105',
+ '234881' => {
+ 'BaseType' => '234886',
'Name' => 'struct pollfd*',
'Size' => '8',
'Type' => 'Pointer'
},
- '182105' => {
+ '234886' => {
'Header' => 'poll.h',
'Line' => '36',
'Memb' => {
@@ -12331,21 +12332,21 @@
'Size' => '8',
'Type' => 'Struct'
},
- '182155' => {
+ '234936' => {
'Name' => 'int(*)(struct pldm_transport*, struct pollfd*)',
'Param' => {
'0' => {
- 'type' => '179137'
+ 'type' => '231918'
},
'1' => {
- 'type' => '182100'
+ 'type' => '234881'
}
},
'Return' => '100',
'Size' => '8',
'Type' => 'FuncPtr'
},
- '182160' => {
+ '234941' => {
'BaseType' => '53',
'Header' => 'socket.h',
'Line' => '10',
@@ -12354,14 +12355,14 @@
'Size' => '2',
'Type' => 'Typedef'
},
- '182508' => {
+ '235289' => {
'Header' => 'mctp.h',
'Line' => '18',
'Memb' => {
'0' => {
'name' => 's_addr',
'offset' => '0',
- 'type' => '178936'
+ 'type' => '231717'
}
},
'Name' => 'struct mctp_addr',
@@ -12369,19 +12370,19 @@
'Size' => '1',
'Type' => 'Struct'
},
- '182534' => {
+ '235315' => {
'Header' => 'mctp.h',
'Line' => '22',
'Memb' => {
'0' => {
'name' => 'smctp_family',
'offset' => '0',
- 'type' => '182160'
+ 'type' => '234941'
},
'1' => {
'name' => '__smctp_pad0',
'offset' => '2',
- 'type' => '181455'
+ 'type' => '234236'
},
'2' => {
'name' => 'smctp_network',
@@ -12391,22 +12392,22 @@
'3' => {
'name' => 'smctp_addr',
'offset' => '8',
- 'type' => '182508'
+ 'type' => '235289'
},
'4' => {
'name' => 'smctp_type',
'offset' => '9',
- 'type' => '181443'
+ 'type' => '234224'
},
'5' => {
'name' => 'smctp_tag',
'offset' => '16',
- 'type' => '181443'
+ 'type' => '234224'
},
'6' => {
'name' => '__smctp_pad1',
'offset' => '17',
- 'type' => '181443'
+ 'type' => '234224'
}
},
'Name' => 'struct sockaddr_mctp',
@@ -12414,19 +12415,19 @@
'Size' => '12',
'Type' => 'Struct'
},
- '182638' => {
- 'BaseType' => '182534',
+ '235419' => {
+ 'BaseType' => '235315',
'Name' => 'struct sockaddr_mctp const',
'Size' => '12',
'Type' => 'Const'
},
- '182681' => {
+ '235462' => {
'Line' => '34',
'Memb' => {
'0' => {
'name' => 'transport',
'offset' => '0',
- 'type' => '179142'
+ 'type' => '231923'
},
'1' => {
'name' => 'socket',
@@ -12436,12 +12437,12 @@
'2' => {
'name' => 'tid_eid_map',
'offset' => '68',
- 'type' => '182774'
+ 'type' => '235555'
},
'3' => {
'name' => 'socket_send_buf',
'offset' => '768',
- 'type' => '181723'
+ 'type' => '234504'
},
'4' => {
'name' => 'bound',
@@ -12451,7 +12452,7 @@
'5' => {
'name' => 'cookie_jar',
'offset' => '800',
- 'type' => '174007'
+ 'type' => '226788'
}
},
'Name' => 'struct pldm_transport_af_mctp',
@@ -12460,26 +12461,26 @@
'Source' => 'af-mctp.c',
'Type' => 'Struct'
},
- '182774' => {
- 'BaseType' => '173983',
+ '235555' => {
+ 'BaseType' => '226764',
'Name' => 'pldm_tid_t[256]',
'Size' => '256',
'Type' => 'Array'
},
- '183590' => {
- 'BaseType' => '182681',
+ '236371' => {
+ 'BaseType' => '235462',
'Name' => 'struct pldm_transport_af_mctp*',
'Size' => '8',
'Type' => 'Pointer'
},
- '183595' => {
- 'BaseType' => '182638',
+ '236376' => {
+ 'BaseType' => '235419',
'Name' => 'struct sockaddr_mctp const*',
'Size' => '8',
'Type' => 'Pointer'
},
- '183908' => {
- 'BaseType' => '183590',
+ '236689' => {
+ 'BaseType' => '236371',
'Name' => 'struct pldm_transport_af_mctp**',
'Size' => '8',
'Type' => 'Pointer'
diff --git a/docs/checklists/changes.md b/docs/checklists/changes.md
index 386ebae..889349b 100644
--- a/docs/checklists/changes.md
+++ b/docs/checklists/changes.md
@@ -13,6 +13,12 @@
the `msgbuf` APIs found in `src/msgbuf.h` (and under `src/msgbuf/`) to
minimise concerns around spatial memory safety and endian-correctness.
+- [ ] If I've implemented a new function, then it returns a negative `errno`
+ value on error and not a PLDM completion code.
+
+ - [ ] The specific error values my function returns and their meaning in the
+ context of the function call are listed in the API documentation.
+
- [ ] If I've added support for a new PLDM message type, then I've implemented
both the encoder and decoder for that message. Note this applies for both
request _and_ response message types.
diff --git a/src/firmware_update.c b/src/firmware_update.c
index 4aafadc..9ebb970 100644
--- a/src/firmware_update.c
+++ b/src/firmware_update.c
@@ -903,8 +903,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_OPTIONAL_COMMAND_RESP_MIN_LEN,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_OPTIONAL_COMMAND_RESP_MIN_LEN,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -968,8 +968,9 @@
return rc;
}
- rc = pldm_msgbuf_init(buf, PLDM_QUERY_DOWNSTREAM_IDENTIFIERS_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_QUERY_DOWNSTREAM_IDENTIFIERS_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -996,8 +997,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_OPTIONAL_COMMAND_RESP_MIN_LEN,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_OPTIONAL_COMMAND_RESP_MIN_LEN,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
diff --git a/src/msgbuf.h b/src/msgbuf.h
index 5036211..f69c428 100644
--- a/src/msgbuf.h
+++ b/src/msgbuf.h
@@ -46,6 +46,7 @@
#include <assert.h>
#include <endian.h>
+#include <errno.h>
#include <limits.h>
#include <stdbool.h>
#include <stdint.h>
@@ -64,14 +65,62 @@
"Extraction and insertion value comparisons may be broken");
static_assert(INTMAX_MIN + INTMAX_MAX <= 0,
"Extraction and insertion arithmetic may be broken");
+ static_assert(PLDM_SUCCESS == 0, "Error handling is broken");
int compliance;
} build_assertions __attribute__((unused));
+enum pldm_msgbuf_error_mode {
+ PLDM_MSGBUF_PLDM_CC = 0x5a,
+ PLDM_MSGBUF_C_ERRNO = 0xa5,
+};
+
struct pldm_msgbuf {
uint8_t *cursor;
intmax_t remaining;
+ enum pldm_msgbuf_error_mode mode;
};
+__attribute__((always_inline)) static inline int
+pldm_msgbuf_status(struct pldm_msgbuf *ctx, unsigned int err)
+{
+ int rc;
+
+ assert(err != 0);
+ assert(err <= INT_MAX);
+
+ if (ctx->mode == PLDM_MSGBUF_C_ERRNO) {
+ if (err > INT_MAX) {
+ return -EINVAL;
+ }
+
+ static_assert(INT_MIN + INT_MAX < 0,
+ "Arithmetic assumption failure");
+ return -((int)err);
+ }
+
+ if (err > INT_MAX) {
+ return PLDM_ERROR;
+ }
+
+ assert(ctx->mode == PLDM_MSGBUF_PLDM_CC);
+ switch (err) {
+ case EINVAL:
+ rc = PLDM_ERROR_INVALID_DATA;
+ break;
+ case EBADMSG:
+ case EOVERFLOW:
+ rc = PLDM_ERROR_INVALID_LENGTH;
+ break;
+ default:
+ assert(false);
+ rc = PLDM_ERROR;
+ break;
+ }
+
+ assert(rc > 0);
+ return rc;
+}
+
/**
* @brief Initialize pldm buf struct for buf extractor
*
@@ -80,36 +129,92 @@
* @param[in] buf - buffer to be extracted
* @param[in] len - size of buffer
*
- * @return PLDM_SUCCESS if all buffer accesses were in-bounds,
- * PLDM_ERROR_INVALID_DATA if pointer parameters are invalid, or
- * PLDM_ERROR_INVALID_LENGTH if length constraints are violated.
+ * @return 0 on success, otherwise an error code appropriate for the current
+ * personality.
*/
__attribute__((always_inline)) static inline int
-pldm_msgbuf_init(struct pldm_msgbuf *ctx, size_t minsize, const void *buf,
- size_t len)
+// NOLINTNEXTLINE(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
+pldm__msgbuf_init(struct pldm_msgbuf *ctx, size_t minsize, const void *buf,
+ size_t len)
{
- if (!ctx || !buf) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+ assert(ctx->mode == PLDM_MSGBUF_PLDM_CC ||
+ ctx->mode == PLDM_MSGBUF_C_ERRNO);
+
+ if (!buf) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
if ((minsize > len)) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
#if INTMAX_MAX < SIZE_MAX
if (len > INTMAX_MAX) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
#endif
if ((uintptr_t)buf + len < len) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->cursor = (uint8_t *)buf;
ctx->remaining = (intmax_t)len;
- return PLDM_SUCCESS;
+ return 0;
+}
+
+/**
+ * @brief Initialise a msgbuf instance to return errors as PLDM completion codes
+ *
+ * @see pldm__msgbuf_init
+ *
+ * @param[out] ctx - pldm_msgbuf context for extractor
+ * @param[in] minsize - The minimum required length of buffer `buf`
+ * @param[in] buf - buffer to be extracted
+ * @param[in] len - size of buffer
+ *
+ * @return PLDM_SUCCESS if the provided buffer region is sensible,
+ * otherwise PLDM_ERROR_INVALID_DATA if pointer parameters are invalid,
+ * or PLDM_ERROR_INVALID_LENGTH if length constraints are violated.
+ */
+__attribute__((always_inline)) static inline int
+pldm_msgbuf_init_cc(struct pldm_msgbuf *ctx, size_t minsize, const void *buf,
+ size_t len)
+{
+ if (!ctx) {
+ return PLDM_ERROR_INVALID_DATA;
+ }
+
+ ctx->mode = PLDM_MSGBUF_PLDM_CC;
+ return pldm__msgbuf_init(ctx, minsize, buf, len);
+}
+
+/**
+ * @brief Initialise a msgbuf instance to return errors as negative errno values
+ *
+ * @see pldm__msgbuf_init
+ *
+ * @param[out] ctx - pldm_msgbuf context for extractor
+ * @param[in] minsize - The minimum required length of buffer `buf`
+ * @param[in] buf - buffer to be extracted
+ * @param[in] len - size of buffer
+ *
+ * @return 0 if the provided buffer region is sensible, otherwise -EINVAL if
+ * pointer parameters are invalid, or -EOVERFLOW if length constraints
+ * are violated.
+ */
+__attribute__((always_inline)) static inline int
+pldm_msgbuf_init_errno(struct pldm_msgbuf *ctx, size_t minsize, const void *buf,
+ size_t len)
+{
+ if (!ctx) {
+ return -EINVAL;
+ }
+
+ ctx->mode = PLDM_MSGBUF_C_ERRNO;
+ return pldm__msgbuf_init(ctx, minsize, buf, len);
}
/**
@@ -126,11 +231,12 @@
__attribute__((always_inline)) static inline int
pldm_msgbuf_validate(struct pldm_msgbuf *ctx)
{
- if (!ctx) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+ if (ctx->remaining < 0) {
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
- return ctx->remaining >= 0 ? PLDM_SUCCESS : PLDM_ERROR_INVALID_LENGTH;
+ return 0;
}
/**
@@ -147,11 +253,12 @@
__attribute__((always_inline)) static inline int
pldm_msgbuf_consumed(struct pldm_msgbuf *ctx)
{
- if (!ctx) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+ if (ctx->remaining != 0) {
+ return pldm_msgbuf_status(ctx, EBADMSG);
}
- return ctx->remaining == 0 ? PLDM_SUCCESS : PLDM_ERROR_INVALID_LENGTH;
+ return 0;
}
/**
@@ -169,10 +276,7 @@
{
int valid;
- if (!ctx) {
- return PLDM_ERROR_INVALID_DATA;
- }
-
+ assert(ctx);
valid = pldm_msgbuf_validate(ctx);
ctx->cursor = NULL;
@@ -197,10 +301,7 @@
{
int consumed;
- if (!ctx) {
- return PLDM_ERROR_INVALID_DATA;
- }
-
+ assert(ctx);
consumed = pldm_msgbuf_consumed(ctx);
ctx->cursor = NULL;
@@ -313,24 +414,26 @@
// NOLINTNEXTLINE(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
pldm__msgbuf_extract_uint8(struct pldm_msgbuf *ctx, void *dst)
{
- if (!ctx || !ctx->cursor || !dst) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !dst) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
if (ctx->remaining == INTMAX_MIN) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(uint8_t);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(dst, ctx->cursor, sizeof(uint8_t));
ctx->cursor++;
- return PLDM_SUCCESS;
+ return 0;
}
#define pldm_msgbuf_extract_int8(ctx, dst) \
@@ -340,23 +443,25 @@
// NOLINTNEXTLINE(bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp)
pldm__msgbuf_extract_int8(struct pldm_msgbuf *ctx, void *dst)
{
- if (!ctx || !ctx->cursor || !dst) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !dst) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
if (ctx->remaining == INTMAX_MIN) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(int8_t);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(dst, ctx->cursor, sizeof(int8_t));
ctx->cursor++;
- return PLDM_SUCCESS;
+ return 0;
}
#define pldm_msgbuf_extract_uint16(ctx, dst) \
@@ -368,8 +473,10 @@
{
uint16_t ldst;
- if (!ctx || !ctx->cursor || !dst) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !dst) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
// Check for underflow while tracking the magnitude of the buffer overflow
@@ -379,7 +486,7 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(ldst)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
// Check for buffer overflow. If we overflow, account for the request as
@@ -392,7 +499,7 @@
// -DNDEBUG by explicitly testing that the access is valid.
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
// Use memcpy() to have the compiler deal with any alignment
@@ -407,7 +514,7 @@
ctx->cursor += sizeof(ldst);
- return PLDM_SUCCESS;
+ return 0;
}
#define pldm_msgbuf_extract_int16(ctx, dst) \
@@ -419,8 +526,10 @@
{
int16_t ldst;
- if (!ctx || !ctx->cursor || !dst) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !dst) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -429,12 +538,12 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(ldst)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(ldst);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(&ldst, ctx->cursor, sizeof(ldst));
@@ -443,7 +552,7 @@
memcpy(dst, &ldst, sizeof(ldst));
ctx->cursor += sizeof(ldst);
- return PLDM_SUCCESS;
+ return 0;
}
#define pldm_msgbuf_extract_uint32(ctx, dst) \
@@ -455,8 +564,10 @@
{
uint32_t ldst;
- if (!ctx || !ctx->cursor || !dst) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !dst) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -465,21 +576,20 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(ldst)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(ldst);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(&ldst, ctx->cursor, sizeof(ldst));
-
ldst = le32toh(ldst);
memcpy(dst, &ldst, sizeof(ldst));
ctx->cursor += sizeof(ldst);
- return PLDM_SUCCESS;
+ return 0;
}
#define pldm_msgbuf_extract_int32(ctx, dst) \
@@ -491,8 +601,10 @@
{
int32_t ldst;
- if (!ctx || !ctx->cursor || !dst) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !dst) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -501,16 +613,15 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(ldst)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(ldst);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(&ldst, ctx->cursor, sizeof(ldst));
-
ldst = le32toh(ldst);
memcpy(dst, &ldst, sizeof(ldst));
ctx->cursor += sizeof(ldst);
@@ -527,11 +638,13 @@
{
uint32_t ldst;
- _Static_assert(sizeof(real32_t) == sizeof(ldst),
- "Mismatched type sizes for dst and ldst");
+ static_assert(sizeof(real32_t) == sizeof(ldst),
+ "Mismatched type sizes for dst and ldst");
- if (!ctx || !ctx->cursor || !dst) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !dst) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -540,12 +653,12 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(ldst)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(ldst);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(&ldst, ctx->cursor, sizeof(ldst));
@@ -553,7 +666,7 @@
memcpy(dst, &ldst, sizeof(ldst));
ctx->cursor += sizeof(ldst);
- return PLDM_SUCCESS;
+ return 0;
}
/**
@@ -598,33 +711,35 @@
pldm_msgbuf_extract_array_uint8(struct pldm_msgbuf *ctx, uint8_t *dst,
size_t count)
{
- if (!ctx || !ctx->cursor || !dst) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !dst) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
if (!count) {
- return PLDM_SUCCESS;
+ return 0;
}
#if INTMAX_MAX < SIZE_MAX
if (count > INTMAX_MAX) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
#endif
if (ctx->remaining < INTMAX_MIN + (intmax_t)count) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= (intmax_t)count;
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(dst, ctx->cursor, count);
ctx->cursor += count;
- return PLDM_SUCCESS;
+ return 0;
}
#define pldm_msgbuf_extract_array(ctx, dst, count) \
@@ -636,8 +751,10 @@
{
uint32_t val = htole32(src);
- if (!ctx || !ctx->cursor) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -646,18 +763,18 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(src)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(src);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(ctx->cursor, &val, sizeof(val));
ctx->cursor += sizeof(src);
- return PLDM_SUCCESS;
+ return 0;
}
__attribute__((always_inline)) static inline int
@@ -665,8 +782,10 @@
{
uint16_t val = htole16(src);
- if (!ctx || !ctx->cursor) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -675,25 +794,27 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(src)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(src);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(ctx->cursor, &val, sizeof(val));
ctx->cursor += sizeof(src);
- return PLDM_SUCCESS;
+ return 0;
}
__attribute__((always_inline)) static inline int
pldm_msgbuf_insert_uint8(struct pldm_msgbuf *ctx, const uint8_t src)
{
- if (!ctx || !ctx->cursor) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -702,18 +823,18 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(src)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(src);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(ctx->cursor, &src, sizeof(src));
ctx->cursor += sizeof(src);
- return PLDM_SUCCESS;
+ return 0;
}
__attribute__((always_inline)) static inline int
@@ -721,8 +842,10 @@
{
int32_t val = htole32(src);
- if (!ctx || !ctx->cursor) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -731,18 +854,18 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(src)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(src);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(ctx->cursor, &val, sizeof(val));
ctx->cursor += sizeof(src);
- return PLDM_SUCCESS;
+ return 0;
}
__attribute__((always_inline)) static inline int
@@ -750,8 +873,10 @@
{
int16_t val = htole16(src);
- if (!ctx || !ctx->cursor) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -760,25 +885,27 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(src)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(src);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(ctx->cursor, &val, sizeof(val));
ctx->cursor += sizeof(src);
- return PLDM_SUCCESS;
+ return 0;
}
__attribute__((always_inline)) static inline int
pldm_msgbuf_insert_int8(struct pldm_msgbuf *ctx, const int8_t src)
{
- if (!ctx || !ctx->cursor) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
static_assert(
@@ -787,18 +914,18 @@
"The following addition may not uphold the runtime assertion");
if (ctx->remaining < INTMAX_MIN + (intmax_t)sizeof(src)) {
assert(ctx->remaining < 0);
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= sizeof(src);
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(ctx->cursor, &src, sizeof(src));
ctx->cursor += sizeof(src);
- return PLDM_SUCCESS;
+ return 0;
}
#define pldm_msgbuf_insert(dst, src) \
@@ -814,33 +941,35 @@
pldm_msgbuf_insert_array_uint8(struct pldm_msgbuf *ctx, const uint8_t *src,
size_t count)
{
- if (!ctx || !ctx->cursor || !src) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !src) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
if (!count) {
- return PLDM_SUCCESS;
+ return 0;
}
#if INTMAX_MAX < SIZE_MAX
if (count > INTMAX_MAX) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
#endif
if (ctx->remaining < INTMAX_MIN + (intmax_t)count) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= (intmax_t)count;
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
memcpy(ctx->cursor, src, count);
ctx->cursor += count;
- return PLDM_SUCCESS;
+ return 0;
}
#define pldm_msgbuf_insert_array(dst, src, count) \
@@ -851,41 +980,45 @@
pldm_msgbuf_span_required(struct pldm_msgbuf *ctx, size_t required,
void **cursor)
{
- if (!ctx || !ctx->cursor || !cursor || *cursor) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !cursor || *cursor) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
#if INTMAX_MAX < SIZE_MAX
if (required > INTMAX_MAX) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
#endif
if (ctx->remaining < INTMAX_MIN + (intmax_t)required) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
ctx->remaining -= (intmax_t)required;
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
*cursor = ctx->cursor;
ctx->cursor += required;
- return PLDM_SUCCESS;
+ return 0;
}
__attribute__((always_inline)) static inline int
pldm_msgbuf_span_remaining(struct pldm_msgbuf *ctx, void **cursor, size_t *len)
{
- if (!ctx || !ctx->cursor || !cursor || *cursor || !len) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(ctx);
+
+ if (!ctx->cursor || !cursor || *cursor || !len) {
+ return pldm_msgbuf_status(ctx, EINVAL);
}
assert(ctx->remaining >= 0);
if (ctx->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(ctx, EOVERFLOW);
}
*cursor = ctx->cursor;
@@ -893,7 +1026,7 @@
*len = ctx->remaining;
ctx->remaining = 0;
- return PLDM_SUCCESS;
+ return 0;
}
/**
@@ -915,42 +1048,47 @@
pldm__msgbuf_copy(struct pldm_msgbuf *dst, struct pldm_msgbuf *src, size_t size,
const char *description)
{
- if (!src || !src->cursor || !dst || !dst->cursor || !description) {
- return PLDM_ERROR_INVALID_DATA;
+ assert(src);
+ assert(dst);
+ assert(src->mode == dst->mode);
+
+ if (!src->cursor || !dst->cursor || !description) {
+ return pldm_msgbuf_status(dst, EINVAL);
}
#if INTMAX_MAX < SIZE_MAX
if (size > INTMAX_MAX) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(dst, EOVERFLOW);
}
#endif
if (src->remaining < INTMAX_MIN + (intmax_t)size) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(dst, EOVERFLOW);
}
if (dst->remaining < INTMAX_MIN + (intmax_t)size) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(dst, EOVERFLOW);
}
src->remaining -= (intmax_t)size;
assert(src->remaining >= 0);
if (src->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(dst, EOVERFLOW);
}
dst->remaining -= (intmax_t)size;
assert(dst->remaining >= 0);
if (dst->remaining < 0) {
- return PLDM_ERROR_INVALID_LENGTH;
+ return pldm_msgbuf_status(dst, EOVERFLOW);
}
memcpy(dst->cursor, src->cursor, size);
src->cursor += size;
dst->cursor += size;
- return PLDM_SUCCESS;
+ return 0;
}
+
#ifdef __cplusplus
}
#endif
diff --git a/src/oem/meta/file_io.c b/src/oem/meta/file_io.c
index 0495ac5..073c446 100644
--- a/src/oem/meta/file_io.c
+++ b/src/oem/meta/file_io.c
@@ -19,9 +19,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- int rc = pldm_msgbuf_init(buf,
- PLDM_OEM_META_DECODE_WRITE_FILE_IO_MIN_SIZE,
- msg->payload, payload_length);
+ int rc = pldm_msgbuf_init_cc(
+ buf, PLDM_OEM_META_DECODE_WRITE_FILE_IO_MIN_SIZE, msg->payload,
+ payload_length);
if (rc) {
return rc;
}
diff --git a/src/platform.c b/src/platform.c
index 7db81b2..79f7c1e 100644
--- a/src/platform.c
+++ b/src/platform.c
@@ -270,8 +270,8 @@
return PLDM_ERROR_INVALID_LENGTH;
}
- rc = pldm_msgbuf_init(buf, PLDM_SET_STATE_EFFECTER_STATES_MIN_SIZE,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_SET_STATE_EFFECTER_STATES_MIN_SIZE,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -311,8 +311,8 @@
return PLDM_ERROR_INVALID_LENGTH;
}
- rc = pldm_msgbuf_init(buf, PLDM_GET_PDR_REQ_BYTES, msg->payload,
- payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_GET_PDR_REQ_BYTES, msg->payload,
+ payload_length);
if (rc) {
return rc;
}
@@ -439,8 +439,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_GET_PDR_REPOSITORY_INFO_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_GET_PDR_REPOSITORY_INFO_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -519,8 +519,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_GET_PDR_MIN_RESP_BYTES, msg->payload,
- payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_GET_PDR_MIN_RESP_BYTES, msg->payload,
+ payload_length);
if (rc) {
return rc;
}
@@ -568,9 +568,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_SET_NUMERIC_EFFECTER_VALUE_MIN_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_SET_NUMERIC_EFFECTER_VALUE_MIN_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -789,9 +789,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_GET_STATE_SENSOR_READINGS_MIN_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_GET_STATE_SENSOR_READINGS_MIN_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -839,8 +839,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_GET_STATE_SENSOR_READINGS_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_GET_STATE_SENSOR_READINGS_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -904,8 +904,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_PLATFORM_EVENT_MESSAGE_MIN_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_PLATFORM_EVENT_MESSAGE_MIN_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -933,9 +933,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -1026,7 +1026,7 @@
return rc;
}
- rc = pldm_msgbuf_init(
+ rc = pldm_msgbuf_init_cc(
buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
msg->payload, payload_length);
if (rc) {
@@ -1130,8 +1130,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_PLATFORM_EVENT_MESSAGE_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_PLATFORM_EVENT_MESSAGE_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -1196,8 +1196,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_EVENT_MESSAGE_BUFFER_SIZE_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_EVENT_MESSAGE_BUFFER_SIZE_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -1268,8 +1268,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_EVENT_MESSAGE_SUPPORTED_MIN_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_EVENT_MESSAGE_SUPPORTED_MIN_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -1324,8 +1325,8 @@
struct pldm_msgbuf *buf = &_buf;
int rc;
- rc = pldm_msgbuf_init(buf, PLDM_SENSOR_EVENT_DATA_MIN_LENGTH,
- event_data, event_data_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_SENSOR_EVENT_DATA_MIN_LENGTH,
+ event_data, event_data_length);
if (rc) {
return rc;
}
@@ -1378,9 +1379,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_SENSOR_EVENT_SENSOR_OP_STATE_DATA_LENGTH,
- sensor_data, sensor_data_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_SENSOR_EVENT_SENSOR_OP_STATE_DATA_LENGTH,
+ sensor_data, sensor_data_length);
if (rc) {
return rc;
}
@@ -1406,9 +1407,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_SENSOR_EVENT_STATE_SENSOR_STATE_DATA_LENGTH,
- sensor_data, sensor_data_length);
+ rc = pldm_msgbuf_init_cc(
+ buf, PLDM_SENSOR_EVENT_STATE_SENSOR_STATE_DATA_LENGTH,
+ sensor_data, sensor_data_length);
if (rc) {
return rc;
}
@@ -1441,7 +1442,7 @@
return PLDM_ERROR_INVALID_LENGTH;
}
- rc = pldm_msgbuf_init(
+ rc = pldm_msgbuf_init_cc(
buf, PLDM_SENSOR_EVENT_NUMERIC_SENSOR_STATE_MIN_DATA_LENGTH,
sensor_data, sensor_data_length);
if (rc) {
@@ -1519,8 +1520,8 @@
struct pldm_msgbuf *buf = &_buf;
int rc;
- rc = pldm_msgbuf_init(buf, PLDM_PDR_NUMERIC_SENSOR_PDR_MIN_LENGTH,
- pdr_data, pdr_data_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_PDR_NUMERIC_SENSOR_PDR_MIN_LENGTH,
+ pdr_data, pdr_data_length);
if (rc) {
return rc;
}
@@ -1732,8 +1733,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_GET_NUMERIC_EFFECTER_VALUE_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_GET_NUMERIC_EFFECTER_VALUE_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -1762,9 +1763,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_GET_NUMERIC_EFFECTER_VALUE_MIN_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_GET_NUMERIC_EFFECTER_VALUE_MIN_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -1884,8 +1885,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_PDR_REPOSITORY_CHG_EVENT_MIN_LENGTH,
- event_data, event_data_size);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_PDR_REPOSITORY_CHG_EVENT_MIN_LENGTH,
+ event_data, event_data_size);
if (rc) {
return rc;
}
@@ -1915,8 +1916,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_MSG_POLL_EVENT_LENGTH, event_data,
- event_data_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_MSG_POLL_EVENT_LENGTH, event_data,
+ event_data_length);
if (rc) {
return rc;
}
@@ -1955,8 +1956,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_MSG_POLL_EVENT_LENGTH, event_data,
- event_data_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_MSG_POLL_EVENT_LENGTH, event_data,
+ event_data_length);
if (rc) {
return rc;
}
@@ -1982,8 +1983,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_PDR_REPOSITORY_CHANGE_RECORD_MIN_LENGTH,
- change_record_data, change_record_data_size);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_PDR_REPOSITORY_CHANGE_RECORD_MIN_LENGTH,
+ change_record_data, change_record_data_size);
if (rc) {
return rc;
}
@@ -2046,8 +2048,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_GET_SENSOR_READING_MIN_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_GET_SENSOR_READING_MIN_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -2166,8 +2168,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_GET_SENSOR_READING_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_GET_SENSOR_READING_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -2236,8 +2238,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_SET_EVENT_RECEIVER_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_SET_EVENT_RECEIVER_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -2266,8 +2268,8 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf, PLDM_SET_EVENT_RECEIVER_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_SET_EVENT_RECEIVER_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -2344,7 +2346,7 @@
return rc;
}
- rc = pldm_msgbuf_init(
+ rc = pldm_msgbuf_init_cc(
buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
msg->payload, payload_length);
if (rc) {
@@ -2379,7 +2381,7 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(
+ rc = pldm_msgbuf_init_cc(
buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
msg->payload, payload_length);
if (rc) {
@@ -2440,8 +2442,8 @@
struct pldm_value_pdr_hdr hdr;
int rc;
- rc = pldm_msgbuf_init(buf, PLDM_PDR_NUMERIC_EFFECTER_PDR_MIN_LENGTH,
- pdr_data, pdr_data_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_PDR_NUMERIC_EFFECTER_PDR_MIN_LENGTH,
+ pdr_data, pdr_data_length);
if (rc) {
return rc;
}
@@ -2546,8 +2548,8 @@
return rc;
}
- rc = pldm_msgbuf_init(buf, PLDM_GET_STATE_EFFECTER_STATES_REQ_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf, PLDM_GET_STATE_EFFECTER_STATES_REQ_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -2570,9 +2572,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_GET_STATE_EFFECTER_STATES_MIN_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_GET_STATE_EFFECTER_STATES_MIN_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -2597,9 +2599,9 @@
return PLDM_ERROR_INVALID_DATA;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_GET_STATE_EFFECTER_STATES_MIN_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_GET_STATE_EFFECTER_STATES_MIN_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
@@ -2668,9 +2670,9 @@
return rc;
}
- rc = pldm_msgbuf_init(buf,
- PLDM_GET_STATE_EFFECTER_STATES_MIN_RESP_BYTES,
- msg->payload, payload_length);
+ rc = pldm_msgbuf_init_cc(buf,
+ PLDM_GET_STATE_EFFECTER_STATES_MIN_RESP_BYTES,
+ msg->payload, payload_length);
if (rc) {
return rc;
}
diff --git a/tests/libpldm_firmware_update_test.cpp b/tests/libpldm_firmware_update_test.cpp
index 76c5814..24bde16 100644
--- a/tests/libpldm_firmware_update_test.cpp
+++ b/tests/libpldm_firmware_update_test.cpp
@@ -1326,8 +1326,8 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf, 0, responseMsg.data() + hdrSize,
- responseMsg.size() - hdrSize);
+ rc = pldm_msgbuf_init_cc(buf, 0, responseMsg.data() + hdrSize,
+ responseMsg.size() - hdrSize);
EXPECT_EQ(rc, PLDM_SUCCESS);
pldm_msgbuf_insert_uint8(buf, completion_code_resp);
@@ -1373,8 +1373,8 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf, 0, responseMsg.data() + hdrSize,
- responseMsg.size() - hdrSize);
+ rc = pldm_msgbuf_init_cc(buf, 0, responseMsg.data() + hdrSize,
+ responseMsg.size() - hdrSize);
EXPECT_EQ(rc, PLDM_SUCCESS);
pldm_msgbuf_insert_uint8(buf, completion_code_resp);
@@ -1414,8 +1414,8 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf, 0, responseMsg.data() + hdrSize,
- responseMsg.size() - hdrSize);
+ rc = pldm_msgbuf_init_cc(buf, 0, responseMsg.data() + hdrSize,
+ responseMsg.size() - hdrSize);
EXPECT_EQ(rc, PLDM_SUCCESS);
pldm_msgbuf_insert_uint8(buf, completion_code_resp);
@@ -1507,8 +1507,8 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf, 0, responseMsg.data() + hdrSize,
- responseMsg.size() - hdrSize);
+ rc = pldm_msgbuf_init_cc(buf, 0, responseMsg.data() + hdrSize,
+ responseMsg.size() - hdrSize);
EXPECT_EQ(rc, PLDM_SUCCESS);
pldm_msgbuf_insert_uint8(buf, complition_code_resp);
@@ -1599,8 +1599,8 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf, 0, responseMsg.data() + hdrSize,
- responseMsg.size() - hdrSize);
+ rc = pldm_msgbuf_init_cc(buf, 0, responseMsg.data() + hdrSize,
+ responseMsg.size() - hdrSize);
EXPECT_EQ(rc, PLDM_SUCCESS);
pldm_msgbuf_insert_uint8(buf, complition_code_resp);
@@ -1662,8 +1662,8 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf, 0, responseMsg.data() + hdrSize,
- responseMsg.size() - hdrSize);
+ rc = pldm_msgbuf_init_cc(buf, 0, responseMsg.data() + hdrSize,
+ responseMsg.size() - hdrSize);
EXPECT_EQ(rc, PLDM_SUCCESS);
pldm_msgbuf_insert_uint8(buf, complition_code_resp);
diff --git a/tests/libpldm_platform_test.cpp b/tests/libpldm_platform_test.cpp
index d5d1f7d..682a922 100644
--- a/tests/libpldm_platform_test.cpp
+++ b/tests/libpldm_platform_test.cpp
@@ -1202,9 +1202,9 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_REQ_BYTES,
- request->payload,
- PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_REQ_BYTES);
+ rc = pldm_msgbuf_init_cc(
+ buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_REQ_BYTES, request->payload,
+ PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_REQ_BYTES);
EXPECT_EQ(rc, PLDM_SUCCESS);
uint8_t retFormatVersion;
@@ -1636,9 +1636,9 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf,
- PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
- response->payload, payloadLength);
+ rc = pldm_msgbuf_init_cc(
+ buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
+ response->payload, payloadLength);
EXPECT_EQ(rc, PLDM_SUCCESS);
uint8_t retCompletionCode;
@@ -1694,9 +1694,9 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf,
- PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
- response->payload, payloadLength);
+ rc = pldm_msgbuf_init_cc(
+ buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
+ response->payload, payloadLength);
EXPECT_EQ(rc, PLDM_SUCCESS);
uint8_t retCompletionCode;
@@ -1733,9 +1733,9 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf,
- PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
- response->payload, payloadLength);
+ rc = pldm_msgbuf_init_cc(
+ buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
+ response->payload, payloadLength);
EXPECT_EQ(rc, PLDM_SUCCESS);
uint8_t retCompletionCode;
@@ -1781,9 +1781,9 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf,
- PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
- response->payload, payloadLength);
+ rc = pldm_msgbuf_init_cc(
+ buf, PLDM_POLL_FOR_PLATFORM_EVENT_MESSAGE_MIN_RESP_BYTES,
+ response->payload, payloadLength);
EXPECT_EQ(rc, PLDM_SUCCESS);
uint8_t retCompletionCode;
@@ -2223,9 +2223,9 @@
struct pldm_msgbuf _buf;
struct pldm_msgbuf* buf = &_buf;
- rc = pldm_msgbuf_init(buf, PLDM_MSG_POLL_EVENT_LENGTH,
- reinterpret_cast<uint8_t*>(eventData.data()),
- eventData.size());
+ rc = pldm_msgbuf_init_cc(buf, PLDM_MSG_POLL_EVENT_LENGTH,
+ reinterpret_cast<uint8_t*>(eventData.data()),
+ eventData.size());
EXPECT_EQ(rc, PLDM_SUCCESS);
uint8_t retFormatVersion;
diff --git a/tests/msgbuf.cpp b/tests/msgbuf.cpp
index cfe7914..9db63f6 100644
--- a/tests/msgbuf.cpp
+++ b/tests/msgbuf.cpp
@@ -13,7 +13,7 @@
TEST(msgbuf, init_bad_ctx)
{
- EXPECT_NE(pldm_msgbuf_init(NULL, 0, NULL, 0), PLDM_SUCCESS);
+ EXPECT_NE(pldm_msgbuf_init_cc(NULL, 0, NULL, 0), PLDM_SUCCESS);
}
TEST(msgbuf, init_bad_minsize)
@@ -22,7 +22,7 @@
struct pldm_msgbuf* ctx = &_ctx;
uint8_t buf[1] = {};
- EXPECT_NE(pldm_msgbuf_init(ctx, sizeof(buf) + 1U, buf, sizeof(buf)),
+ EXPECT_NE(pldm_msgbuf_init_cc(ctx, sizeof(buf) + 1U, buf, sizeof(buf)),
PLDM_SUCCESS);
}
@@ -31,7 +31,7 @@
struct pldm_msgbuf _ctx;
struct pldm_msgbuf* ctx = &_ctx;
- EXPECT_NE(pldm_msgbuf_init(ctx, 0, NULL, 0), PLDM_SUCCESS);
+ EXPECT_NE(pldm_msgbuf_init_cc(ctx, 0, NULL, 0), PLDM_SUCCESS);
}
TEST(msgbuf, init_bad_len)
@@ -40,7 +40,8 @@
struct pldm_msgbuf* ctx = &_ctx;
uint8_t buf[1] = {};
- EXPECT_NE(pldm_msgbuf_init(ctx, sizeof(buf), buf, SIZE_MAX), PLDM_SUCCESS);
+ EXPECT_NE(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, SIZE_MAX),
+ PLDM_SUCCESS);
}
TEST(msgbuf, init_overflow)
@@ -50,7 +51,7 @@
// NOLINTNEXTLINE(performance-no-int-to-ptr)
void* buf = (void*)UINTPTR_MAX;
- EXPECT_NE(pldm_msgbuf_init(ctx, 0, buf, 2), PLDM_SUCCESS);
+ EXPECT_NE(pldm_msgbuf_init_cc(ctx, 0, buf, 2), PLDM_SUCCESS);
}
TEST(msgbuf, init_success)
@@ -59,7 +60,7 @@
struct pldm_msgbuf* ctx = &_ctx;
uint8_t buf[1] = {};
- EXPECT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ EXPECT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
}
@@ -69,7 +70,7 @@
struct pldm_msgbuf* ctx = &_ctx;
uint8_t buf[1] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
}
@@ -81,7 +82,7 @@
uint8_t buf[1] = {0xa5};
uint8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, 0xa5);
@@ -95,7 +96,7 @@
uint8_t buf[1] = {0xa5};
uint8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
ASSERT_EQ(pldm_msgbuf_extract_uint8(ctx, &val), PLDM_SUCCESS);
ASSERT_EQ(val, 0xa5);
@@ -110,7 +111,7 @@
uint8_t buf[2] = {0x5a, 0xa5};
uint8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, 0x5a);
@@ -124,7 +125,7 @@
uint8_t buf[1] = {0xa5};
uint8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, 0xa5);
@@ -138,7 +139,7 @@
uint8_t buf[1] = {};
uint8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_uint8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
}
@@ -151,7 +152,7 @@
uint8_t buf[1] = {};
uint8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN;
EXPECT_NE(pldm_msgbuf_extract_uint8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -164,7 +165,7 @@
int8_t buf[1] = {-1};
int8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_int8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, -1);
@@ -178,7 +179,7 @@
int8_t buf[1] = {};
int8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_int8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
}
@@ -191,7 +192,7 @@
uint8_t buf[1] = {};
int8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN;
EXPECT_NE(pldm_msgbuf_extract_int8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -204,7 +205,7 @@
uint16_t buf[1] = {htole16(0x5aa5)};
uint16_t val = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint16(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, 0x5aa5);
@@ -219,7 +220,7 @@
uint16_t buf[1] = {};
uint16_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_extract_uint16(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -232,7 +233,7 @@
uint16_t buf[1] = {};
uint16_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_uint16(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
}
@@ -244,7 +245,7 @@
int16_t buf[1] = {(int16_t)(htole16((uint16_t)INT16_MIN))};
int16_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_int16(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, INT16_MIN);
@@ -258,7 +259,7 @@
int16_t buf[1] = {};
int16_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_int16(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
}
@@ -271,7 +272,7 @@
int16_t buf[1] = {};
int16_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_extract_int16(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -284,7 +285,7 @@
uint32_t buf[1] = {htole32(0x5a00ffa5)};
uint32_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, 0x5a00ffa5);
@@ -298,7 +299,7 @@
uint32_t buf[1] = {};
uint32_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_uint32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
}
@@ -311,7 +312,7 @@
uint32_t buf[1] = {};
uint32_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_extract_uint32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -324,7 +325,7 @@
int32_t buf[1] = {(int32_t)(htole32((uint32_t)(INT32_MIN)))};
int32_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_int32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, INT32_MIN);
@@ -338,7 +339,7 @@
int32_t buf[1] = {};
int32_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_int32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
}
@@ -351,7 +352,7 @@
int32_t buf[1] = {};
int32_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_extract_int32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -370,7 +371,7 @@
buf[0] = htole32(xform);
val = 0;
- ASSERT_EQ(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_real32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(val, FLT_MAX);
@@ -384,7 +385,7 @@
real32_t buf[1] = {};
real32_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_real32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
}
@@ -397,7 +398,7 @@
real32_t buf[1] = {};
real32_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_extract_real32(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -410,7 +411,7 @@
uint8_t buf[1] = {};
uint8_t arr[1];
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_array_uint8(ctx, arr, 0), PLDM_SUCCESS);
ASSERT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
}
@@ -422,7 +423,7 @@
uint8_t buf[1] = {};
uint8_t arr[1];
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_array_uint8(ctx, arr, sizeof(arr)),
PLDM_SUCCESS);
EXPECT_EQ(arr[0], 0);
@@ -436,7 +437,7 @@
uint8_t buf[1] = {};
uint8_t arr[2];
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_array_uint8(ctx, arr, sizeof(arr)),
PLDM_SUCCESS);
ASSERT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -449,7 +450,7 @@
uint8_t buf[1] = {};
uint8_t arr[1];
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN;
EXPECT_NE(pldm_msgbuf_extract_array_uint8(ctx, arr, 1), PLDM_SUCCESS);
ASSERT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -461,7 +462,7 @@
struct pldm_msgbuf* ctx = &_ctx;
uint8_t buf[1] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy_consumed(ctx), PLDM_ERROR_INVALID_LENGTH);
}
@@ -472,7 +473,7 @@
uint8_t buf[1] = {};
uint8_t val;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint8(ctx, &val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy_consumed(ctx), PLDM_SUCCESS);
}
@@ -484,7 +485,7 @@
uint8_t buf[1] = {};
uint8_t val[2];
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint8(ctx, &val[0]), PLDM_SUCCESS);
EXPECT_NE(pldm_msgbuf_extract_uint8(ctx, &val[1]), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy_consumed(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -498,13 +499,14 @@
int32_t checkVal = 0;
uint8_t buf[sizeof(int32_t)] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_int32(ctx, src), PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_int32(ctxExtract, &checkVal), PLDM_SUCCESS);
EXPECT_EQ(src, checkVal);
@@ -512,15 +514,6 @@
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
}
-TEST(msgbuf, pldm_msgbuf_insert_int32_bad)
-{
- int32_t src = -12345;
-
- auto rc = pldm_msgbuf_insert_int32(NULL, src);
-
- EXPECT_EQ(rc, PLDM_ERROR_INVALID_DATA);
-}
-
TEST(msgbuf, insert_under_int32)
{
struct pldm_msgbuf _ctx;
@@ -529,7 +522,7 @@
int32_t buf[1] = {};
int32_t val = 0;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_insert_int32(ctx, val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -543,13 +536,14 @@
uint32_t checkVal = 0;
uint8_t buf[sizeof(uint32_t)] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_uint32(ctx, src), PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint32(ctxExtract, &checkVal), PLDM_SUCCESS);
EXPECT_EQ(src, checkVal);
@@ -557,15 +551,6 @@
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
}
-TEST(msgbuf, pldm_msgbuf_insert_uint32_bad)
-{
- uint32_t src = 0xf1223344;
-
- auto rc = pldm_msgbuf_insert_uint32(NULL, src);
-
- EXPECT_EQ(rc, PLDM_ERROR_INVALID_DATA);
-}
-
TEST(msgbuf, insert_under_uint32)
{
struct pldm_msgbuf _ctx;
@@ -574,7 +559,7 @@
uint32_t buf[1] = {};
uint32_t val = 0;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_insert_uint32(ctx, val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -588,13 +573,14 @@
uint16_t checkVal = 0;
uint8_t buf[sizeof(uint16_t)] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(uint16_t)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(uint16_t)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_uint16(ctx, src), PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint16(ctxExtract, &checkVal), PLDM_SUCCESS);
EXPECT_EQ(src, checkVal);
@@ -602,15 +588,6 @@
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
}
-TEST(msgbuf, pldm_msgbuf_insert_uint16_bad)
-{
- uint16_t src = 0xf344;
-
- auto rc = pldm_msgbuf_insert_uint16(NULL, src);
-
- EXPECT_EQ(rc, PLDM_ERROR_INVALID_DATA);
-}
-
TEST(msgbuf, insert_under_uint16)
{
struct pldm_msgbuf _ctx;
@@ -619,7 +596,7 @@
uint16_t buf[1] = {};
uint16_t val = 0;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_insert_uint16(ctx, val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -633,13 +610,14 @@
int16_t checkVal = 0;
uint8_t buf[sizeof(int16_t)] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(uint16_t)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(uint16_t)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_int16(ctx, src), PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_int16(ctxExtract, &checkVal), PLDM_SUCCESS);
EXPECT_EQ(src, checkVal);
@@ -647,15 +625,6 @@
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
}
-TEST(msgbuf, pldm_msgbuf_insert_int16_bad)
-{
- int16_t src = -12;
-
- auto rc = pldm_msgbuf_insert_int16(NULL, src);
-
- EXPECT_EQ(rc, PLDM_ERROR_INVALID_DATA);
-}
-
TEST(msgbuf, insert_under_int16)
{
struct pldm_msgbuf _ctx;
@@ -664,7 +633,7 @@
int16_t buf[1] = {};
int16_t val = 0;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_insert_int16(ctx, val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -678,13 +647,14 @@
uint8_t checkVal = 0;
uint8_t buf[sizeof(uint8_t)] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_uint8(ctx, src), PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint8(ctxExtract, &checkVal), PLDM_SUCCESS);
EXPECT_EQ(src, checkVal);
@@ -692,15 +662,6 @@
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
}
-TEST(msgbuf, pldm_msgbuf_insert_uint8_bad)
-{
- uint8_t src = 0xf4;
-
- auto rc = pldm_msgbuf_insert_uint8(NULL, src);
-
- EXPECT_EQ(rc, PLDM_ERROR_INVALID_DATA);
-}
-
TEST(msgbuf, insert_under_uint8)
{
struct pldm_msgbuf _ctx;
@@ -709,7 +670,7 @@
uint8_t buf[1] = {};
uint8_t val = 0;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_insert_uint8(ctx, val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -723,13 +684,14 @@
int8_t checkVal = 0;
uint8_t buf[sizeof(int8_t)] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_int8(ctx, src), PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_int8(ctxExtract, &checkVal), PLDM_SUCCESS);
EXPECT_EQ(src, checkVal);
@@ -737,15 +699,6 @@
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
}
-TEST(msgbuf, pldm_msgbuf_insert_int8_bad)
-{
- int8_t src = -4;
-
- auto rc = pldm_msgbuf_insert_int8(NULL, src);
-
- EXPECT_EQ(rc, PLDM_ERROR_INVALID_DATA);
-}
-
TEST(msgbuf, insert_under_int8)
{
struct pldm_msgbuf _ctx;
@@ -754,7 +707,7 @@
int8_t buf[1] = {};
int8_t val = 0;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_insert_int8(ctx, val), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -768,14 +721,15 @@
uint8_t buf[6] = {};
uint8_t retBuff[6] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_array_uint8(ctx, src, sizeof(src)),
PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(
pldm_msgbuf_extract_array_uint8(ctxExtract, retBuff, sizeof(retBuff)),
PLDM_SUCCESS);
@@ -792,9 +746,7 @@
uint8_t src[6] = {0x11, 0x22, 0x44, 0x55, 0x66, 0x77};
uint8_t buf[6] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
- EXPECT_EQ(pldm_msgbuf_insert_array_uint8(NULL, src, sizeof(src)),
- PLDM_ERROR_INVALID_DATA);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_array_uint8(ctx, NULL, sizeof(src)),
PLDM_ERROR_INVALID_DATA);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
@@ -808,7 +760,7 @@
uint8_t buf[1] = {};
uint8_t val[1] = {0};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN + sizeof(val) - 1;
EXPECT_NE(pldm_msgbuf_insert_array_uint8(ctx, val, sizeof(val)),
PLDM_SUCCESS);
@@ -826,14 +778,15 @@
uint16_t testVal;
uint8_t* retBuff = NULL;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_array_uint8(ctx, src, sizeof(src)),
PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint16(ctxExtract, &testVal), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_span_required(ctxExtract, required, (void**)&retBuff),
PLDM_SUCCESS);
@@ -853,19 +806,18 @@
uint16_t testVal;
[[maybe_unused]] uint8_t* retBuff = NULL;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_array_uint8(ctx, src, sizeof(src)),
PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint16(ctxExtract, &testVal), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_span_required(ctxExtract, required, NULL),
PLDM_ERROR_INVALID_DATA);
- EXPECT_EQ(pldm_msgbuf_span_required(NULL, required, (void**)&retBuff),
- PLDM_ERROR_INVALID_DATA);
EXPECT_EQ(pldm_msgbuf_destroy(ctxExtract), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_SUCCESS);
@@ -879,7 +831,7 @@
uint8_t buf[1] = {};
void* cursor = nullptr;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, 0), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, 0), PLDM_SUCCESS);
ctx->remaining = INTMAX_MIN;
EXPECT_NE(pldm_msgbuf_span_required(ctx, 1, &cursor), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_destroy(ctx), PLDM_ERROR_INVALID_LENGTH);
@@ -896,14 +848,15 @@
size_t remaining;
uint8_t* retBuff = NULL;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_array_uint8(ctx, src, sizeof(src)),
PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint16(ctxExtract, &testVal), PLDM_SUCCESS);
EXPECT_EQ(
pldm_msgbuf_span_remaining(ctxExtract, (void**)&retBuff, &remaining),
@@ -925,17 +878,16 @@
size_t remaining;
uint8_t* retBuff = NULL;
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_insert_array_uint8(ctx, src, sizeof(src)),
PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- ASSERT_EQ(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)),
+ PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint16(ctxExtract, &testVal), PLDM_SUCCESS);
- EXPECT_EQ(pldm_msgbuf_span_remaining(NULL, (void**)&retBuff, &remaining),
- PLDM_ERROR_INVALID_DATA);
EXPECT_EQ(pldm_msgbuf_span_remaining(ctxExtract, NULL, &remaining),
PLDM_ERROR_INVALID_DATA);
EXPECT_EQ(pldm_msgbuf_span_remaining(ctxExtract, (void**)&retBuff, NULL),
@@ -951,7 +903,7 @@
struct pldm_msgbuf* src = &_src;
uint16_t buf[1] = {htole16(0x5aa5)};
- ASSERT_EQ(pldm_msgbuf_init(src, sizeof(buf), buf, sizeof(buf)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(src, sizeof(buf), buf, sizeof(buf)),
PLDM_SUCCESS);
struct pldm_msgbuf _dst;
@@ -959,11 +911,11 @@
uint16_t checkVal = 0;
uint8_t buf1[sizeof(buf)] = {};
- ASSERT_EQ(pldm_msgbuf_init(dst, sizeof(buf1), buf1, sizeof(buf1)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(dst, sizeof(buf1), buf1, sizeof(buf1)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_copy(dst, src, buf[0], name), PLDM_SUCCESS);
- ASSERT_EQ(pldm_msgbuf_init(dst, sizeof(buf1), buf1, sizeof(buf1)),
+ ASSERT_EQ(pldm_msgbuf_init_cc(dst, sizeof(buf1), buf1, sizeof(buf1)),
PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_extract_uint16(dst, &checkVal), PLDM_SUCCESS);
@@ -982,18 +934,13 @@
uint8_t buf1[1] = {sizeof(uint16_t)};
uint16_t value = 8;
- EXPECT_EQ(pldm_msgbuf_copy(dst, NULL, buf[0], name),
- PLDM_ERROR_INVALID_DATA);
- EXPECT_EQ(pldm_msgbuf_copy(NULL, src, buf[0], name),
- PLDM_ERROR_INVALID_DATA);
-
- ASSERT_EQ(pldm_msgbuf_init(src, 0, buf, sizeof(buf)), PLDM_SUCCESS);
- ASSERT_EQ(pldm_msgbuf_init(dst, 0, buf1, sizeof(buf1)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(src, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(dst, 0, buf1, sizeof(buf1)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_copy(dst, src, value, name),
PLDM_ERROR_INVALID_LENGTH);
- ASSERT_EQ(pldm_msgbuf_init(src, 0, buf1, sizeof(buf1)), PLDM_SUCCESS);
- ASSERT_EQ(pldm_msgbuf_init(dst, 0, buf, sizeof(buf)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(src, 0, buf1, sizeof(buf1)), PLDM_SUCCESS);
+ ASSERT_EQ(pldm_msgbuf_init_cc(dst, 0, buf, sizeof(buf)), PLDM_SUCCESS);
EXPECT_EQ(pldm_msgbuf_copy(dst, src, value, name),
PLDM_ERROR_INVALID_LENGTH);
}
diff --git a/tests/msgbuf_generic.c b/tests/msgbuf_generic.c
index 9119273..96b3bb5 100644
--- a/tests/msgbuf_generic.c
+++ b/tests/msgbuf_generic.c
@@ -33,7 +33,7 @@
uint8_t buf[1] = {0xa5};
uint8_t val;
- expect(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)) ==
+ expect(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)) ==
PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctx, val) == PLDM_SUCCESS);
expect(val == 0xa5);
@@ -47,7 +47,7 @@
int8_t buf[1] = {-1};
int8_t val;
- expect(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)) ==
+ expect(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)) ==
PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctx, val) == PLDM_SUCCESS);
expect(val == -1);
@@ -61,7 +61,7 @@
uint16_t buf[1] = {0x5aa5};
uint16_t val;
- expect(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)) ==
+ expect(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)) ==
PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctx, val) == PLDM_SUCCESS);
expect(val == 0x5aa5);
@@ -75,7 +75,7 @@
int16_t buf[1] = {(int16_t)(htole16((uint16_t)INT16_MIN))};
int16_t val;
- expect(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)) ==
+ expect(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)) ==
PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctx, val) == PLDM_SUCCESS);
expect(val == INT16_MIN);
@@ -89,7 +89,7 @@
uint32_t buf[1] = {0x5a00ffa5};
uint32_t val;
- expect(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)) ==
+ expect(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)) ==
PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctx, val) == PLDM_SUCCESS);
expect(val == 0x5a00ffa5);
@@ -103,7 +103,7 @@
int32_t buf[1] = {(int32_t)(htole32((uint32_t)INT32_MIN))};
int32_t val;
- expect(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)) ==
+ expect(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)) ==
PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctx, val) == PLDM_SUCCESS);
expect(val == INT32_MIN);
@@ -123,7 +123,7 @@
buf[0] = htole32(xform);
val = 0;
- expect(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)) ==
+ expect(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)) ==
PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctx, val) == PLDM_SUCCESS);
expect(val == FLT_MAX);
@@ -137,7 +137,7 @@
uint32_t buf[1] = {0};
uint8_t arr[1];
- expect(pldm_msgbuf_init(ctx, sizeof(buf), buf, sizeof(buf)) ==
+ expect(pldm_msgbuf_init_cc(ctx, sizeof(buf), buf, sizeof(buf)) ==
PLDM_SUCCESS);
expect(pldm_msgbuf_extract_array(ctx, arr, 1) == PLDM_SUCCESS);
expect(arr[0] == 0);
@@ -152,13 +152,14 @@
int32_t checkVal = 0;
uint8_t buf[sizeof(int32_t)] = {0};
- expect(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
expect(pldm_msgbuf_insert(ctx, src) == PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- expect(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)) ==
+ PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctxExtract, checkVal) == PLDM_SUCCESS);
expect(src == checkVal);
@@ -174,13 +175,14 @@
uint32_t checkVal = 0;
uint8_t buf[sizeof(uint32_t)] = {0};
- expect(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
expect(pldm_msgbuf_insert(ctx, src) == PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- expect(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)) ==
+ PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctxExtract, checkVal) == PLDM_SUCCESS);
expect(src == checkVal);
@@ -196,13 +198,14 @@
uint16_t checkVal = 0;
uint8_t buf[sizeof(uint16_t)] = {0};
- expect(pldm_msgbuf_init(ctx, 0, buf, sizeof(uint16_t)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(uint16_t)) == PLDM_SUCCESS);
expect(pldm_msgbuf_insert(ctx, src) == PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- expect(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)) ==
+ PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctxExtract, checkVal) == PLDM_SUCCESS);
expect(src == checkVal);
@@ -218,13 +221,14 @@
int16_t checkVal = 0;
uint8_t buf[sizeof(int16_t)] = {0};
- expect(pldm_msgbuf_init(ctx, 0, buf, sizeof(uint16_t)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(uint16_t)) == PLDM_SUCCESS);
expect(pldm_msgbuf_insert(ctx, src) == PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- expect(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)) ==
+ PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctxExtract, checkVal) == PLDM_SUCCESS);
expect(src == checkVal);
@@ -240,13 +244,14 @@
uint8_t checkVal = 0;
uint8_t buf[sizeof(uint8_t)] = {0};
- expect(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
expect(pldm_msgbuf_insert(ctx, src) == PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- expect(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)) ==
+ PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctxExtract, checkVal) == PLDM_SUCCESS);
expect(src == checkVal);
@@ -262,13 +267,14 @@
int8_t checkVal = 0;
uint8_t buf[sizeof(int8_t)] = {0};
- expect(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
expect(pldm_msgbuf_insert(ctx, src) == PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- expect(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)) ==
+ PLDM_SUCCESS);
expect(pldm_msgbuf_extract(ctxExtract, checkVal) == PLDM_SUCCESS);
expect(src == checkVal);
@@ -284,13 +290,14 @@
uint8_t buf[6] = {0};
uint8_t retBuff[6] = {0};
- expect(pldm_msgbuf_init(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctx, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
expect(pldm_msgbuf_insert_array(ctx, src, sizeof(src)) == PLDM_SUCCESS);
struct pldm_msgbuf _ctxExtract;
struct pldm_msgbuf* ctxExtract = &_ctxExtract;
- expect(pldm_msgbuf_init(ctxExtract, 0, buf, sizeof(buf)) == PLDM_SUCCESS);
+ expect(pldm_msgbuf_init_cc(ctxExtract, 0, buf, sizeof(buf)) ==
+ PLDM_SUCCESS);
expect(pldm_msgbuf_extract_array(ctxExtract, retBuff, sizeof(retBuff)) ==
PLDM_SUCCESS);
diff --git a/tests/oem/meta/libpldm_fileio_test.cpp b/tests/oem/meta/libpldm_fileio_test.cpp
index decaa43..da38679 100644
--- a/tests/oem/meta/libpldm_fileio_test.cpp
+++ b/tests/oem/meta/libpldm_fileio_test.cpp
@@ -23,7 +23,7 @@
uint8_t buf[hdrSize + sizeof(uint8_t) + sizeof(int32_t) +
(postCodeSize * sizeof(uint8_t))] = {};
- ASSERT_EQ(pldm_msgbuf_init(ctx, 0, &buf[hdrSize], sizeof(buf) - hdrSize),
+ ASSERT_EQ(pldm_msgbuf_init_cc(ctx, 0, &buf[hdrSize], sizeof(buf) - hdrSize),
0);
pldm_msgbuf_insert_uint8(ctx, fileHandle);