* [PATCH phosphor-host-ipmid] Fix minor fw revision to be BCD encoded
@ 2016-06-22 22:00 OpenBMC Patches
2016-06-22 22:00 ` OpenBMC Patches
0 siblings, 1 reply; 3+ messages in thread
From: OpenBMC Patches @ 2016-06-22 22:00 UTC (permalink / raw)
To: openbmc; +Cc: Adriana Kobylak
The IPMI spec requires the minor version revision to be BCD encoded.
Currently the hex value was returned.
Fixes https://github.com/openbmc/phosphor-host-ipmid
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/openbmc/phosphor-host-ipmid/94)
<!-- Reviewable:end -->
https://github.com/openbmc/phosphor-host-ipmid/pull/94
Adriana Kobylak (1):
Fix minor fw revision to be BCD encoded
apphandler.C | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
--
2.9.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH phosphor-host-ipmid] Fix minor fw revision to be BCD encoded
2016-06-22 22:00 [PATCH phosphor-host-ipmid] Fix minor fw revision to be BCD encoded OpenBMC Patches
@ 2016-06-22 22:00 ` OpenBMC Patches
2016-06-22 22:09 ` Patrick Williams
0 siblings, 1 reply; 3+ messages in thread
From: OpenBMC Patches @ 2016-06-22 22:00 UTC (permalink / raw)
To: openbmc; +Cc: Adriana Kobylak
From: Adriana Kobylak <anoo@us.ibm.com>
The IPMI spec requires the minor version revision to be BCD encoded.
Currently the hex value was returned.
Fixes https://github.com/openbmc/phosphor-host-ipmid
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
---
apphandler.C | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/apphandler.C b/apphandler.C
index 71dba66..d014f5b 100644
--- a/apphandler.C
+++ b/apphandler.C
@@ -187,7 +187,9 @@ ipmi_ret_t ipmi_app_get_device_id(ipmi_netfn_t netfn, ipmi_cmd_t cmd,
if( r >= 0 ) {
// bit7 identifies state of SDR repository, hence the mask
dev_id[DEVICE_FW1] |= 0x7F & rev.major;
- dev_id[DEVICE_FW2] = rev.minor;
+
+ rev.minor = (rev.minor > 99 ? 99 : rev.minor);
+ dev_id[DEVICE_FW2] = rev.minor % 10 + (rev.minor / 10) * 16;
memcpy(&dev_id[DEVICE_AUX], rev.d, 4);
}
}
--
2.9.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH phosphor-host-ipmid] Fix minor fw revision to be BCD encoded
2016-06-22 22:00 ` OpenBMC Patches
@ 2016-06-22 22:09 ` Patrick Williams
0 siblings, 0 replies; 3+ messages in thread
From: Patrick Williams @ 2016-06-22 22:09 UTC (permalink / raw)
To: OpenBMC Patches; +Cc: openbmc, Adriana Kobylak
[-- Attachment #1: Type: text/plain, Size: 775 bytes --]
On Wed, Jun 22, 2016 at 05:00:51PM -0500, OpenBMC Patches wrote:
> From: Adriana Kobylak <anoo@us.ibm.com>
>
> The IPMI spec requires the minor version revision to be BCD encoded.
> Currently the hex value was returned.
Might want to say "The IPMI 2.0 spec requires the minor version revision
to be BCD encoded, but the current implementation uses a binary
encoding."
It isn't really a "hex value" or anything else. Hex vs decimal are just
a human way of looking at the data.
> Fixes https://github.com/openbmc/phosphor-host-ipmid
This should be 'Fixes openbmc/phosphor-host-ipmid#89'.
> Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
> ---
> apphandler.C | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
--
Patrick Williams
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-06-22 22:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-22 22:00 [PATCH phosphor-host-ipmid] Fix minor fw revision to be BCD encoded OpenBMC Patches
2016-06-22 22:00 ` OpenBMC Patches
2016-06-22 22:09 ` Patrick Williams
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.