event: Handling pldmPDRRepositoryChgEvent
Added a handler to react to the "pldmPDRRepositoryChgEvent" event and
extract the data. If the eventDataFormat is "formatIsPDRHandles" then
the changeRecords are further extracted. If the eventDataOperation is
"recordAdded" then the PDRHandles are extracted from the changeEntry
data and stored in the "pdrRecordHandle" vector.
"decode_pldm_pdr_repository_chg_event_data" function will extract the
eventData and changeRecord from the pldmPDRRepositoryChgEvent class
while the "decode_pldm_pdr_repository_change_record_data" will extract
the changeEntries data from the changeRecord. Unit tests for the above
decode functions have been added.
Extracted PDR handles are used to fetch PDRs corresponding to the same
from the host.
Signed-off-by: Zahed Hossain <zahzahed@in.ibm.com>
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
Change-Id: I32e8745e04ac82393e067c0f0ab48802809495a6
diff --git a/libpldmresponder/meson.build b/libpldmresponder/meson.build
index bb0d10c..0275e94 100644
--- a/libpldmresponder/meson.build
+++ b/libpldmresponder/meson.build
@@ -1,6 +1,7 @@
deps = [
dependency('phosphor-dbus-interfaces'),
dependency('sdbusplus'),
+ dependency('sdeventplus'),
libpldm,
libpldmutils
]
@@ -18,7 +19,8 @@
'pdr.cpp',
'platform.cpp',
'fru_parser.cpp',
- 'fru.cpp'
+ 'fru.cpp',
+ '../host_pdr_handler.cpp'
]
if get_option('oem-ibm').enabled()