File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -141,6 +141,15 @@ jobs:
141141 LDFLAGS="-L${{ steps.wolfssl.outputs.prefix }}/lib"
142142 make -j"$(nproc)"
143143
144+ - name : Reset TPM before detect (shared GPIO 4 reset line)
145+ if : steps.health.outcome == 'success'
146+ run : |
147+ # Mirror spdm_test.sh gpio_reset(): both vendors share this reset line.
148+ # Without this, caps sees a chip left in SPDM-locked state or stale TIS
149+ # from a prior run and returns all-zero vendor/device IDs.
150+ gpioset gpiochip0 4=0 2>/dev/null && sleep 0.1 && gpioset gpiochip0 4=1 2>/dev/null || true
151+ sleep 2
152+
144153 - name : Detect ${{ matrix.vendor }} TPM on SPI CS ${{ matrix.spi_cs }}
145154 id : detect
146155 if : steps.health.outcome == 'success'
@@ -175,7 +184,7 @@ jobs:
175184 done
176185
177186 - name : Post-job cleanup
178- if : always() && steps.health.outcome == 'success' && steps.detect.outputs.present == 'true'
187+ if : always() && steps.health.outcome == 'success'
179188 env :
180189 LD_LIBRARY_PATH : ${{ steps.wolfssl.outputs.prefix }}/lib
181190 run : |
@@ -184,6 +193,7 @@ jobs:
184193 sleep 1
185194 gpioset gpiochip0 4=0 2>/dev/null && sleep 0.1 && gpioset gpiochip0 4=1 2>/dev/null || true
186195 sleep 2
196+ # unlock/flush only meaningful if the chip was detected; ignore errors otherwise
187197 ./examples/spdm/spdm_ctrl --connect --unlock 2>/dev/null || true
188198 ./examples/management/flush 2>/dev/null || true
189199 echo "[cleanup] done"
You can’t perform that action at this time.
0 commit comments