Fix DBUS Name For BootSource Cd
Commit 9f16b2c1b6b6884482bca304fcaa573caf91d0d6
changed the mapping for redfish boot source 'Cd' to
'xyz.openbmc_project.Control.Boot.Source.Sources.DVD'.
However, that mapping does not match what we have in
phosphor-dbus-interfaces:
'xyz.openbmc_project.Control.Boot.Source.Sources.ExternalMedia'
This commit reverts that mapping back to ExternalMedia.
Tested:
-- Ran redfish service validator - no errors seen.
-- Tested PATCH on BootSourceOverrideTarget with value "Cd"
curl -k -H "X-Auth-Token: $bmc_token" -X PATCH
https://${bmc}:${port}/redfish/v1/Systems/system -d '{"Boot":
{"BootSourceOverrideEnabled": "Continuous", "BootSourceOverrideTarget": "Cd"}}'
{
"@Message.ExtendedInfo": [
{
"@odata.type": "/redfish/v1/$metadata#Message.v1_0_0.Message",
"Message": "Successfully Completed Request",
"MessageArgs": [],
"MessageId": "Base.1.4.0.Success",
"Resolution": "None",
"Severity": "OK"
}
]
curl -k -H "X-Auth-Token: $bmc_token" -X GET
https://${bmc}:${port}/redfish/v1/Systems/system
{
"@odata.context": "/redfish/v1/$metadata#ComputerSystem.ComputerSystem",
"@odata.id": "/redfish/v1/Systems/system",
....
....
....
"Boot": {
"BootSourceOverrideEnabled": "Continuous",
"BootSourceOverrideMode": "Legacy",
"BootSourceOverrideTarget": "Cd",
"BootSourceOverrideTarget@Redfish.AllowableValues": [
"None",
"Pxe",
"Hdd",
"Cd",
"Diags",
"BiosSetup"
]
},
Change-Id: Ibd1fe3bc2c98dc97422b8dd71f9f95f6e9e25285
Signed-off-by: Santosh Puranik <santosh.puranik@in.ibm.com>
diff --git a/redfish-core/lib/systems.hpp b/redfish-core/lib/systems.hpp
index 70e9dac..4544af6 100644
--- a/redfish-core/lib/systems.hpp
+++ b/redfish-core/lib/systems.hpp
@@ -468,7 +468,7 @@
return "Hdd";
}
else if (dbusSource ==
- "xyz.openbmc_project.Control.Boot.Source.Sources.DVD")
+ "xyz.openbmc_project.Control.Boot.Source.Sources.ExternalMedia")
{
return "Cd";
}
@@ -536,7 +536,7 @@
}
else if (rfSource == "Cd")
{
- return "xyz.openbmc_project.Control.Boot.Source.Sources.DVD";
+ return "xyz.openbmc_project.Control.Boot.Source.Sources.ExternalMedia";
}
else if (rfSource == "Pxe")
{