diff options
author | Frederic Barrat <fbarrat@linux.ibm.com> | 2018-11-14 18:02:48 +0100 |
---|---|---|
committer | Stewart Smith <stewart@linux.ibm.com> | 2018-11-19 16:44:07 +1100 |
commit | 4d28576dffd565b790a9f9332d7094bed4094ddb (patch) | |
tree | f7b4cd24e93fa0ace6e9b71755e163b85ab3a88f | |
parent | 0fa446cc21cba577c120c300c591a84241142d98 (diff) | |
download | skiboot-4d28576dffd565b790a9f9332d7094bed4094ddb.zip skiboot-4d28576dffd565b790a9f9332d7094bed4094ddb.tar.gz skiboot-4d28576dffd565b790a9f9332d7094bed4094ddb.tar.bz2 |
platform/witherspoon: Avoid harmless error message
The I2C read to find out if a device on the GPU slot is an opencapi
adapter or nvidia card is reporting an "arbitration loss" error if no
device is connected on the GPU slot. That I2C read is actually useless
if we already know there's no device connected, so let's skip it. It
will avoid logging an harmless error.
Signed-off-by: Frederic Barrat <fbarrat@linux.ibm.com>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
-rw-r--r-- | platforms/astbmc/witherspoon.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/platforms/astbmc/witherspoon.c b/platforms/astbmc/witherspoon.c index f45f739..772a719 100644 --- a/platforms/astbmc/witherspoon.c +++ b/platforms/astbmc/witherspoon.c @@ -271,6 +271,13 @@ static void witherspoon_npu2_device_detect(struct npu2 *npu) prlog(PR_DEBUG, "PLAT: Chip %d GPU#1 slot present\n", chip->id); } + /* + * The following I2C ops generate errors if no device is + * present on any SXM2 slot. Since it's useless, let's skip it + */ + if (!gpu0_present && !gpu1_present) + return; + /* Set pins to input */ state = 0xff; rc = i2c_request_send(i2c_port_id, |