summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Hsu <Daniel-Hsu@quantatw.com>2024-04-23 11:09:17 +0300
committerPatrick Williams <patrick@stwcx.xyz>2024-04-30 21:04:45 +0300
commit86c3eb304fd469a1c60eafb633da36a263a4cc6f (patch)
treeeec1e91fbc9086ca51f8a95ef6e06376e465b6a7
parenteb0e473f6e0486def495a35a1abb8a17b14200c5 (diff)
downloadopenbmc-86c3eb304fd469a1c60eafb633da36a263a4cc6f.tar.xz
meta-facebook: harma: add gpio presence monitoring
add gpio presence monitoring Testing: systemctl status phosphor-multi-gpio-presence.service ● phosphor-multi-gpio-presence.service - Phosphor Multi GPIO presence Loaded: loaded (/usr/lib/systemd/system/ phosphor-multi-gpio-presence.service; enabled; preset: enabled) Active: active (running) since Sun 2024-04-21 23:51:56 PDT; 3h 21min ago Main PID: 470 (phosphor-multi-) CPU: 49ms CGroup: /system.slice/phosphor-multi-gpio-presence.service └─470 /usr/bin/phosphor-multi-gpio-presence --config /usr/share/phosphor-gpio-monitor/ phosphor-multi-gpio-presence.json root@bmc:~# busctl tree xyz.openbmc_project.Inventory.Manager └─ /xyz └─ /... └─ /.../inventory └─ /.../inventory/system └─ /.../inventory/system/board └─ /.../inventory/system/board/Harma_MB ├─ /.../inventory/system/board/Harma_MB/presence_asic_modules_0 ├─ /.../inventory/system/board/Harma_MB/presence_asic_modules_1 ├─ /.../inventory/system/board/Harma_MB/presence_e1s_0 ├─ /.../inventory/system/board/Harma_MB/presence_e1s_1 └─ /.../inventory/system/board/Harma_MB/presence_ocp_0 Change-Id: I10c432c11415869ee8167fd07e7ec0b6105520be Signed-off-by: Daniel Hsu <Daniel-Hsu@quantatw.com>
-rw-r--r--meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor/plat-phosphor-multi-gpio-presence.json37
-rw-r--r--meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor_%.bbappend3
-rw-r--r--meta-facebook/meta-harma/recipes-phosphor/images/fb-harma-phosphor-image.inc5
3 files changed, 45 insertions, 0 deletions
diff --git a/meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor/plat-phosphor-multi-gpio-presence.json b/meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor/plat-phosphor-multi-gpio-presence.json
new file mode 100644
index 0000000000..d406147211
--- /dev/null
+++ b/meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor/plat-phosphor-multi-gpio-presence.json
@@ -0,0 +1,37 @@
+[
+ {
+ "Name": "presence-ocp-0",
+ "LineName": "reset-control-pcie-expansion-0",
+ "ActiveLow": true,
+ "Bias": "DISABLE",
+ "Inventory": "/system/board/Harma_MB/presence_ocp_0"
+ },
+ {
+ "Name": "presence-e1s-0",
+ "LineName": "presence-e1s-0",
+ "ActiveLow": true,
+ "Bias": "DISABLE",
+ "Inventory": "/system/board/Harma_MB/presence_e1s_0"
+ },
+ {
+ "Name": "presence-e1s-1",
+ "LineName": "presence-e1s-1",
+ "ActiveLow": true,
+ "Bias": "DISABLE",
+ "Inventory": "/system/board/Harma_MB/presence_e1s_1"
+ },
+ {
+ "Name": "presence-asic-modules-0",
+ "LineName": "presence-asic-modules-0",
+ "ActiveLow": true,
+ "Bias": "DISABLE",
+ "Inventory": "/system/board/Harma_MB/presence_asic_modules_0"
+ },
+ {
+ "Name": "presence-asic-modules-1",
+ "LineName": "presence-asic-modules-1",
+ "ActiveLow": true,
+ "Bias": "DISABLE",
+ "Inventory": "/system/board/Harma_MB/presence_asic_modules_1"
+ }
+] \ No newline at end of file
diff --git a/meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor_%.bbappend b/meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor_%.bbappend
index 2eeee68c74..46b9d2d4c7 100644
--- a/meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor_%.bbappend
+++ b/meta-facebook/meta-harma/recipes-phosphor/gpio/phosphor-gpio-monitor_%.bbappend
@@ -3,6 +3,7 @@ FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
inherit obmc-phosphor-systemd systemd
SRC_URI += "file://plat-phosphor-multi-gpio-monitor.json \
+ file://plat-phosphor-multi-gpio-presence.json \
file://assert-reset-button.service \
file://assert-power-good.service \
file://assert-post-end.service \
@@ -42,6 +43,8 @@ do_install:append:() {
install -d ${D}${datadir}/phosphor-gpio-monitor
install -m 0644 ${WORKDIR}/plat-phosphor-multi-gpio-monitor.json \
${D}${datadir}/phosphor-gpio-monitor/phosphor-multi-gpio-monitor.json
+ install -m 0644 ${WORKDIR}/plat-phosphor-multi-gpio-presence.json \
+ ${D}${datadir}/phosphor-gpio-monitor/phosphor-multi-gpio-presence.json
install -d ${D}${systemd_system_unitdir}/
install -m 0644 ${WORKDIR}/*.service ${D}${systemd_system_unitdir}/
diff --git a/meta-facebook/meta-harma/recipes-phosphor/images/fb-harma-phosphor-image.inc b/meta-facebook/meta-harma/recipes-phosphor/images/fb-harma-phosphor-image.inc
index 851d964e5d..2f63dba18c 100644
--- a/meta-facebook/meta-harma/recipes-phosphor/images/fb-harma-phosphor-image.inc
+++ b/meta-facebook/meta-harma/recipes-phosphor/images/fb-harma-phosphor-image.inc
@@ -20,3 +20,8 @@ OBMC_IMAGE_EXTRA_INSTALL:append = " \
obmc-phosphor-buttons-signals \
obmc-phosphor-buttons-handler \
"
+
+# Monitor gpio status
+OBMC_IMAGE_EXTRA_INSTALL:append = " \
+ phosphor-gpio-monitor-presence \
+" \ No newline at end of file