ap_power: Check for GPIO_GET_CONFIG option
ap_power: Check for GPIO_GET_CONFIG option

Use CONFIG_GPIO_GET_CONFIG as a guard for calling
gpio_pin_get_config_dt() to get the output pin value.
Some platforms use ioexpanders that do not support this API call.

There is a possibility but not using this call that the wrong
value will be retrieved if the output pin is open drain, and the
actual voltage on the pin is below the threshold of detecting a
high state, but the ioexpander pins should not be in this situation.

BUG=b:243309500
TEST=./twister -T zephyr/test/{ap_power,drivers}
BRANCH=none

Signed-off-by: Andrew McRae <44ad1424cfc8411c96d9181798ca41ae55709dfb@google.com>
Change-Id: Ieae25aaf5549eb9c7ec5dd46ef25e03b2fd207a2
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3844247
Code-Coverage: Zoss <345cf107e82c70959d46f59d98bddc98ce458aff@prod.google.com>
Reviewed-by: Peter Marheine <ef0b2c492edde94778d7465bfbaeed52c5be6858@chromium.org>

coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec