ibm-openbmc / dev

Product Development Project Mgmt and Tracking
16 stars 2 forks source link

Enabling -Dibm-usb-code-update=enabled doesn't work #3617

Closed gtmills closed 1 year ago

gtmills commented 1 year ago

Expected Behavior

I would expect enabling USB code update in bmcweb bbappend would mean USBCodeUpdate shows up in the API under Oem at /redfish/v1/Managers/bmc -Dibm-usb-code-update=enabled \

Actual Behavior

Using the latest 1050 openbmc/openbmc and 1050 bmcweb, and -Dibm-usb-code-update=enabled \ in the bmcweb bbappend I don't see USBCodeUpdate under /redfish/v1/Managers/bmc

Instead I see

  "Model": "6B58",
  "Name": "OpenBmc Manager",
  "NetworkProtocol": {
    "@odata.id": "/redfish/v1/Managers/bmc/NetworkProtocol"
  },
  "Oem": {
    "@odata.id": "/redfish/v1/Managers/bmc#/Oem",
    "@odata.type": "#OemManager.Oem",
    "OpenBmc": {
      "@odata.id": "/redfish/v1/Managers/bmc#/Oem/OpenBmc",
      "@odata.type": "#OemManager.OpenBmc",
      "Certificates": {
        "@odata.id": "/redfish/v1/Managers/bmc/Truststore/Certificates"
      }
    }
  },
  "PartNumber": "02WF452",
  "PowerState": "On",
  "SerialConsole": {

Steps to Reproduce the Problem

  1. Latest 1050 openbmc/openbmc, Latest 1050 bmcweb
  2. -Dibm-usb-code-update=enabled \ in your bmcweb bbappend
  3. Go to /redfish/v1/Managers/bmc

I don't see any errors in the journal.

I tracked it down to this call https://github.com/ibm-openbmc/bmcweb/blob/2c5b246b9aea8f51263d21e3f73747b181f6ccd5/redfish-core/lib/oem/ibm/usb_code_update.hpp#L12It can't seem to find the service

It can't seen to find the service

On 1030/1040

busctl call  xyz.openbmc_project.ObjectMapper /xyz/openbmc_project/object_mapper xyz.openbmc_project.ObjectMapper GetSubTree sias / 0 1  xyz.openbmc_project.Control.Service.Attributes |  grep phosphor_2dusb_2dcode_2dupdate
a{sa{sas}} 7 "/xyz/openbmc_project/control/service/bmcweb" 1 "xyz.openbmc_project.Control.Service.Manager" 2 "xyz.openbmc_project.Control.Service.Attributes" "xyz.openbmc_project.Control.Service.SocketAttributes" "/xyz/openbmc_project/control/service/dropbear" 1 "xyz.openbmc_project.Control.Service.Manager" 2 "xyz.openbmc_project.Control.Service.Attributes" "xyz.openbmc_project.Control.Service.SocketAttributes" "/xyz/openbmc_project/control/service/obmc_2dconsole_40ttyVUART0" 1 "xyz.openbmc_project.Control.Service.Manager" 1 "xyz.openbmc_project.Control.Service.Attributes" "/xyz/openbmc_project/control/service/obmc_2dconsole_40ttyVUART1" 1 "xyz.openbmc_project.Control.Service.Manager" 1 "xyz.openbmc_project.Control.Service.Attributes" "/xyz/openbmc_project/control/service/phosphor_2dipmi_2dnet_40eth0" 1 "xyz.openbmc_project.Control.Service.Manager" 1 "xyz.openbmc_project.Control.Service.Attributes" "/xyz/openbmc_project/control/service/phosphor_2dipmi_2dnet_40eth1" 1 "xyz.openbmc_project.Control.Service.Manager" 1 "xyz.openbmc_project.Control.Service.Attributes" "/xyz/openbmc_project/control/service/phosphor_2dusb_2dcode_2dupdate" 1 "xyz.openbmc_project.Control.Service.Manager" 1 "xyz.openbmc_project.Control.Service.Attributes"

But on 1050

busctl call  xyz.openbmc_project.ObjectMapper /xyz/openbmc_project/object_mapper xyz.openbmc_project.ObjectMapper GetSubTree sias / 0 1  xyz.openbmc_project.Control.Service.Attributes |  grep phosphor_2dusb_2dcode_2dupdate
root@rainxxxbmcc:~# 

Are we missing some commits in service-config-manager 1050 that we had in 1020/1030/1040? https://github.com/ibm-openbmc/service-config-manager/commits/1050 https://github.com/ibm-openbmc/service-config-manager/commits/1030

lxwinspur commented 1 year ago

@ChicagoDuan Please take a look and test this issue, thanks.

ChicagoDuan commented 1 year ago

Done. Please review : https://github.com/ibm-openbmc/bmcweb/pull/585

The dbus path is changed from /xyz/openbmc_project/control/service/phosphor_2dusb_2dcode_2dupdate to /xyz/openbmc_project/control/service/_70hosphor_2dusb_2dcode_2dupdate

lxwinspur commented 1 year ago

@gtmills This issue has been merged into 1050 branch, can we close this issue?

gtmills commented 1 year ago

Closed.