#
ae933cc2 |
| 21-Feb-2024 |
Manojkiran Eda <manojkiran.eda@gmail.com> |
Add support for Previous State in Sensor events
Previously, the sensor events generated by the PLDM stack only included the current state of the sensor without any reference to the previous state.
Add support for Previous State in Sensor events
Previously, the sensor events generated by the PLDM stack only included the current state of the sensor without any reference to the previous state.
This commit introduces a new feature to address this limitation by caching the previous states of all sensors.
The enhancement ensures that platform event messages(sensor events) now contain the correct previous state information alongside the current state.
Behavior Model: 1. Upon the initial occurrence of a sensor event, both the current state and the previous state are identical, adhering to the specification. 2. Subsequently, when the PLDM stack sends out sensor events, it retrieves the previous state from its cache and populates it accordingly.
Testing: 1. Example: Change the value of a sensor, such as dimm8 identify, to false using busctl. Tx: 81 02 0a 01 00 00 4d 00 01 00 [ 01 01 ] - Note: Initially, both the event state and the previous state are 01.
2. Change the value of dimm8 identify to true. Tx: 81 02 0a 01 00 00 4d 00 01 00 [ 02 01 ] - Result: Event state: 02, Previous state: 01.
3. Change the value of dimm8 identify back to false. Tx: 81 02 0a 01 00 00 4d 00 01 00 [ 01 02 ] - Result: Event state: 01, Previous state: 02.
4. Similar results can be obtained using the getStateSensorReadings command for the same sensor at respective times.
Change-Id: Ic93a55e61fd5128cecc698b3555a6639876882ed Signed-off-by: Manojkiran Eda <manojkiran.eda@gmail.com>
show more ...
|
#
2abbce76 |
| 17-Oct-2023 |
Andrew Jeffery <andrew@codeconstruct.com.au> |
InstanceIdDb: Move header from pldmd/ to common/
The header is used across all executables produced by the project, which makes it "common".
Change-Id: I022b179fad1de8dba2ef39fd33bc240ec73a2d33 Sig
InstanceIdDb: Move header from pldmd/ to common/
The header is used across all executables produced by the project, which makes it "common".
Change-Id: I022b179fad1de8dba2ef39fd33bc240ec73a2d33 Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>
show more ...
|
#
a330b2f0 |
| 04-May-2023 |
Andrew Jeffery <andrew@aj.id.au> |
pldmd: Migrate instance ID allocation to pldm::InstanceIdDb
This removes use of `pldm::dbus_api::Requester` from around the code-base. This makes progress towards removing the DBus API entirely once
pldmd: Migrate instance ID allocation to pldm::InstanceIdDb
This removes use of `pldm::dbus_api::Requester` from around the code-base. This makes progress towards removing the DBus API entirely once all its consumers are converted to the libpldm instance ID APIs.
There was never a good reason for the code using the class to have knowledge that it was related to DBus anyway, so this is, in-effect, a double clean up improving separation of concerns.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I2d9397cae1b3c8c251c32e36ca520aad9c9b8cf6
show more ...
|
#
c453e164 |
| 21-Dec-2022 |
George Liu <liuxiwei@inspur.com> |
libpldm: Correct reference to libpldm header files
When relying on header files from external libraries, #include<> should be used instead of #include "" to avoid ambiguity.
Tested: Built pldm succ
libpldm: Correct reference to libpldm header files
When relying on header files from external libraries, #include<> should be used instead of #include "" to avoid ambiguity.
Tested: Built pldm successfully after enabling ibm-oem
Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: Ia1997de7e0f61564055bbd837f4e24c8f14e55a5
show more ...
|
#
84b790cb |
| 22-Jul-2022 |
Patrick Williams <patrick@stwcx.xyz> |
sdbusplus: use shorter type aliases
The sdbusplus headers provide shortened aliases for many types. Switch to using them to provide better code clarity and shorter lines. Possible replacements are
sdbusplus: use shorter type aliases
The sdbusplus headers provide shortened aliases for many types. Switch to using them to provide better code clarity and shorter lines. Possible replacements are for: * bus_t * exception_t * manager_t * match_t * message_t * object_t * slot_t
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I8e2242adb79be342562c9b7f3d2153dfdf578085
show more ...
|
#
5079ac4a |
| 19-Aug-2021 |
Brad Bishop <bradleyb@fuzziesquirrel.com> |
treewide: remove 'using namespace' from headers Using namespace at global scope in a header file violates the cpp core guidelines. Quoting the guidelines: "Doing so takes awa
treewide: remove 'using namespace' from headers Using namespace at global scope in a header file violates the cpp core guidelines. Quoting the guidelines: "Doing so takes away an #includer’s ability to effectively disambiguate and to use alternatives. It also makes #included headers order-dependent as they might have different meaning when included in different orders." For further reading: https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rs-using-directive The guidelines don't call out using using namespace from namespace scope, but it is only marginally less problematic and still unexpected, so this patch removes those as well. The process used to do the update is roughly: 1 - git grep 'using namespace' **.hpp 2 - For each instance, remove the offending 'using namespace' line 3 - build 4 - add 'using namespace' to cpp files or fully resolve types in hpp files until the project builds again. Further cleanup is possible - for example cpp files could be scrubbed for unnecessary namespace qualification - this was not done here to make review as simple as possible. Change-Id: I4931f5e78a1b5b74b4a4774c035a549f4d59b91a Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
show more ...
|
#
c0c79481 |
| 02-Jun-2021 |
Sampa Misra <sampmisr@in.ibm.com> |
implement async handlers for all requester commands this commit makes use of 74f27c730ef3925a0f2a3adfaa04f8790f931372 to convert the existing blocking requester commands in pldm to async
implement async handlers for all requester commands this commit makes use of 74f27c730ef3925a0f2a3adfaa04f8790f931372 to convert the existing blocking requester commands in pldm to async ones. this is tested with Host code and seems to work fine Change-Id: I8d4762c3cd5bce49f854b30f8325bfcd1dcb4ff9 Signed-off-by: Sampa Misra <sampmisr@in.ibm.com>
show more ...
|
#
cae1866f |
| 14-May-2020 |
George Liu <liuxiwei@inspur.com> |
send PLDM event msg when state sensor changes Add the D-Bus to event handler interface to listen all of the state sensor PDRs and pldm should be able to send up a PLDM event msg when a
send PLDM event msg when state sensor changes Add the D-Bus to event handler interface to listen all of the state sensor PDRs and pldm should be able to send up a PLDM event msg when a D-Bus property changes. the PlatformEventMessage command format is defined in Table 15 in DSP0248 v1.2.0. Tested: test with JSON https://gist.github.com/lxwinspur/6a40abea7330c25e4d49826e890c4be9 The sendEventMsg method is successfully called and the corresponding message is successfully sent when the D-Bus property value of the sensor status changes. print requestMsg Data: 80 02 0a 01 00 00 01 00 01 00 00 00(when calling sendEventMsg method) Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: I9b6d5c1403bfcaa00dbbf478f7d797cc4a40f20d
show more ...
|