diff options
author | HuyLe <hule@amperecomputing.com> | 2022-09-05 07:25:42 +0300 |
---|---|---|
committer | Thang Q. Nguyen <thang@os.amperecomputing.com> | 2022-09-20 08:24:50 +0300 |
commit | bb8f0657781d78264d08d324853f94bd1abc8efa (patch) | |
tree | 15e1e732a57e1517bf1a11445a5c860e6f89f21f | |
parent | ebff85d320dc2e99c5c682b678a6ae0ea291c043 (diff) | |
download | openbmc-bb8f0657781d78264d08d324853f94bd1abc8efa.tar.xz |
meta-ampere: mtjade: handle UID button via phosphor-buttons
Replace Ampere implementation for UID button by the use of
phosphor-button.
Tested:
1. By default, the UID LED status is OFF.
- Press UID button and check if the UID LED is ON
- Press UID button again and check if the UID LED is OFF
2. Turn on the UID LED via ipmi command
$ ipmitool chassis identify
3. Turn Lit/Blinking/Off UID LED via Redfish:
$ curl -X PATCH --user root:0penBmc -H "Content-Type: application/json"
-H "If-Match: *" --insecure https://<bmc_ip>/redfish/v1/Systems/system
-d '{"IndicatorLED": "Lit|Blinking|Off"}'
--> check if the UID LED is ON, blinking or OFF, respectively
Signed-off-by: HuyLe <hule@amperecomputing.com>
Change-Id: I912e26be827167a201dad5d81be6728101405521
4 files changed, 5 insertions, 17 deletions
diff --git a/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling.bb b/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling.bb index 62b25b1f12..2889517c43 100644 --- a/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling.bb +++ b/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling.bb @@ -28,7 +28,6 @@ AMPERE_MONITOR_INSTANCES = " \ SYSTEMD_ENVIRONMENT_FILE:${PN} +=" \ obmc/gpio/reboot_ack \ obmc/gpio/shutdown_ack \ - obmc/gpio/id_button \ obmc/gpio/S0_scp_auth_failure \ obmc/gpio/S0_overtemp \ obmc/gpio/S0_hightemp_start \ @@ -57,7 +56,6 @@ SYSTEMD_SERVICE:${PN} += " \ ampere_fault_led_start@.service \ ampere_fault_led_stop@.service \ psu_hotswap_reset@.service \ - id-button-pressed.service \ ampere_scp_failover.service \ " SYSTEMD_LINK:${PN} += "${@compose_list(d, 'FMT', 'AMPERE_MONITOR_INSTANCES')}" diff --git a/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling/id-button-pressed.service b/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling/id-button-pressed.service deleted file mode 100644 index f633fc3076..0000000000 --- a/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling/id-button-pressed.service +++ /dev/null @@ -1,10 +0,0 @@ -[Unit] -Description=ID Button Pressed Service -Wants=mapper-wait@-xyz-openbmc_project-led-groups.service -After=mapper-wait@-xyz-openbmc_project-led-groups.service -StartLimitIntervalSec=0 - -[Service] -Type=oneshot -ExecStart=/usr/bin/env toggle_identify_led.sh -SyslogIdentifier=id-button diff --git a/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling/obmc/gpio/id_button b/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling/obmc/gpio/id_button deleted file mode 100644 index 70e2b585b2..0000000000 --- a/meta-ampere/meta-jade/recipes-phosphor/gpio/ampere-gpio-handling/obmc/gpio/id_button +++ /dev/null @@ -1,5 +0,0 @@ -DEVPATH=/dev/input/by-path/platform-gpio-keys-event -KEY=133 -POLARITY=1 -TARGET=id-button-pressed.service -EXTRA_ARGS=--continue diff --git a/meta-ampere/meta-jade/recipes-phosphor/skeleton/obmc-libobmc-intf/gpio_defs.json b/meta-ampere/meta-jade/recipes-phosphor/skeleton/obmc-libobmc-intf/gpio_defs.json index 0b6ad45afc..009defda1e 100644 --- a/meta-ampere/meta-jade/recipes-phosphor/skeleton/obmc-libobmc-intf/gpio_defs.json +++ b/meta-ampere/meta-jade/recipes-phosphor/skeleton/obmc-libobmc-intf/gpio_defs.json @@ -49,6 +49,11 @@ "name": "RESET_BUTTON", "pin": "R5", "direction": "both" + }, + { + "name": "ID_BTN", + "pin": "Q5", + "direction": "both" } ] } |