diff options
author | Frederic Barrat <fbarrat@linux.vnet.ibm.com> | 2018-05-23 19:25:41 +0200 |
---|---|---|
committer | Stewart Smith <stewart@linux.ibm.com> | 2018-06-01 02:07:26 -0500 |
commit | b5c863a86427db83cdb398f227e82745dbe255d0 (patch) | |
tree | 23ab249af5867ddfa77ac2ac82f15dca24fda3ad /include/platform.h | |
parent | 67bdd1668e6a033eb5520105946ebb651f3adff2 (diff) | |
download | skiboot-b5c863a86427db83cdb398f227e82745dbe255d0.zip skiboot-b5c863a86427db83cdb398f227e82745dbe255d0.tar.gz skiboot-b5c863a86427db83cdb398f227e82745dbe255d0.tar.bz2 |
npu2-opencapi: Use presence detection
Presence detection is not part of the opencapi specification. So each
platform may choose to implement it the way it wants.
All current platforms implement it through an i2c device where we can
query a pin to know if a device is connected or not. ZZ and Zaius have
a similar design and even use the same i2c information and pin
numbers.
However, presence detection on older ZZ planar (older than v4) doesn't
work, so we don't activate it for now, until our lab systems are
upgraded and it's better tested.
Presence detection on witherspoon is still being worked on. It's
shaping up to be quite different, so we may have to revisit the topic
in a later patch.
Signed-off-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
Diffstat (limited to 'include/platform.h')
-rw-r--r-- | include/platform.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/platform.h b/include/platform.h index a777644..6fa016c 100644 --- a/include/platform.h +++ b/include/platform.h @@ -51,6 +51,10 @@ struct platform_ocapi { uint32_t i2c_offset[3]; /* Offsets on I2C device */ uint8_t i2c_odl0_data[3]; /* Data to reset ODL0 */ uint8_t i2c_odl1_data[3]; /* Data to reset ODL1 */ + uint8_t i2c_presence_addr; /* I2C address for presence detection */ + uint8_t i2c_presence_odl0; /* I2C mask for detection on ODL0 */ + uint8_t i2c_presence_odl1; /* I2C mask for detection on ODL1 */ + bool force_presence; /* don't use i2c detection */ bool odl_phy_swap; /* Swap ODL1 to use brick 2 rather than * brick 1 lanes */ }; |