In commit 1ddda5cd364 we meant to set MSSD=3, but due
to a typo we ended setting MSSD=0. Convert the two other
NATJ and MSSP keys to use hexadecimal notation to avoid
similar copy/paste typos.
Cc: qemu-stable@nongnu.org
Fixes: 1ddda5cd364 ("AppleSMC device emulation")
Reported-by: Matthew Jackson <matthew@pq.io>
Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
---
hw/misc/applesmc.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/hw/misc/applesmc.c b/hw/misc/applesmc.c
index fd96f5f245f..d004e8b4431 100644
--- a/hw/misc/applesmc.c
+++ b/hw/misc/applesmc.c
@@ -333,9 +333,9 @@ static void applesmc_isa_realize(DeviceState *dev, Error **errp)
applesmc_add_key(s, "REV ", 6, "\x01\x13\x0f\x00\x00\x03");
applesmc_add_key(s, "OSK0", 32, s->osk);
applesmc_add_key(s, "OSK1", 32, s->osk + 32);
- applesmc_add_key(s, "NATJ", 1, "\0");
- applesmc_add_key(s, "MSSP", 1, "\0");
- applesmc_add_key(s, "MSSD", 1, "\0x3");
+ applesmc_add_key(s, "NATJ", 1, "\x00");
+ applesmc_add_key(s, "MSSP", 1, "\x00");
+ applesmc_add_key(s, "MSSD", 1, "\x03");
}
static void applesmc_unrealize(DeviceState *dev)
--
2.53.0
On 20/7/26 13:53, Philippe Mathieu-Daudé wrote:
> In commit 1ddda5cd364 we meant to set MSSD=3, but due
> to a typo we ended setting MSSD=0. Convert the two other
> NATJ and MSSP keys to use hexadecimal notation to avoid
> similar copy/paste typos.
>
> Cc: qemu-stable@nongnu.org
> Fixes: 1ddda5cd364 ("AppleSMC device emulation")
> Reported-by: Matthew Jackson <matthew@pq.io>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
> ---
> hw/misc/applesmc.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
Patch queued, thanks.
On 7/20/2026 4:53 AM, Philippe Mathieu-Daudé wrote:
> In commit 1ddda5cd364 we meant to set MSSD=3, but due
> to a typo we ended setting MSSD=0. Convert the two other
> NATJ and MSSP keys to use hexadecimal notation to avoid
> similar copy/paste typos.
>
> Cc: qemu-stable@nongnu.org
> Fixes: 1ddda5cd364 ("AppleSMC device emulation")
> Reported-by: Matthew Jackson <matthew@pq.io>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
> ---
> hw/misc/applesmc.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@oss.qualcomm.com>
On 20.07.26 13:53, Philippe Mathieu-Daudé wrote:
> In commit 1ddda5cd364 we meant to set MSSD=3, but due
> to a typo we ended setting MSSD=0. Convert the two other
> NATJ and MSSP keys to use hexadecimal notation to avoid
> similar copy/paste typos.
>
> Cc: qemu-stable@nongnu.org
> Fixes: 1ddda5cd364 ("AppleSMC device emulation")
> Reported-by: Matthew Jackson <matthew@pq.io>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
Funny :)
Reviewed-by: Alexander Graf <agraf@csgraf.de>
Alex
© 2016 - 2026 Red Hat, Inc.