ibm: Use the generic fan-presence I2C paths

The fan presence detect application uses I2C device paths in its config
files to address the IO expanders that IBM systems use to monitor fan
presence detects.

Use the /sys/bus/i2c/devices/... paths in these config files instead of
the absolute paths.  These new paths are links to the actual paths, and
shouldn't change even if some internal kernel change drives an actual
device path change.  There are other config files today that do this the
same way.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I39ed9d703cf6bdc821a54c6d5d087f7fc080705b
diff --git a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/everest/config.json b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/everest/config.json
index 439aedc..928eca2 100644
--- a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/everest/config.json
+++ b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/everest/config.json
@@ -6,7 +6,7 @@
          {
             "type": "gpio",
             "key": 15,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a780.i2c-bus/i2c-14/i2c-30/30-0061",
+            "physpath": "/sys/bus/i2c/devices/30-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -28,7 +28,7 @@
          {
             "type": "gpio",
             "key": 14,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a780.i2c-bus/i2c-14/i2c-30/30-0061",
+            "physpath": "/sys/bus/i2c/devices/30-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -50,7 +50,7 @@
          {
             "type": "gpio",
             "key": 13,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a780.i2c-bus/i2c-14/i2c-30/30-0061",
+            "physpath": "/sys/bus/i2c/devices/30-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -72,7 +72,7 @@
          {
             "type": "gpio",
             "key": 12,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a780.i2c-bus/i2c-14/i2c-30/30-0061",
+            "physpath": "/sys/bus/i2c/devices/30-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
diff --git a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-1s4u/config.json b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-1s4u/config.json
index 5bcda88..65697e5 100644
--- a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-1s4u/config.json
+++ b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-1s4u/config.json
@@ -6,7 +6,7 @@
          {
             "type": "gpio",
             "key": 6,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -27,7 +27,7 @@
          {
             "type": "gpio",
             "key": 7,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -48,7 +48,7 @@
          {
             "type": "gpio",
             "key": 8,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -69,7 +69,7 @@
          {
             "type": "gpio",
             "key": 10,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
diff --git a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-2u/config.json b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-2u/config.json
index 7264510..a5cc1bf 100644
--- a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-2u/config.json
+++ b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-2u/config.json
@@ -6,7 +6,7 @@
          {
             "type": "gpio",
             "key": 6,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -28,7 +28,7 @@
          {
             "type": "gpio",
             "key": 7,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -50,7 +50,7 @@
          {
             "type": "gpio",
             "key": 8,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -72,7 +72,7 @@
          {
             "type": "gpio",
             "key": 9,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -94,7 +94,7 @@
          {
             "type": "gpio",
             "key": 10,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -116,7 +116,7 @@
          {
             "type": "gpio",
             "key": 11,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
diff --git a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-4u/config.json b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-4u/config.json
index 94e7e69..620a329 100644
--- a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-4u/config.json
+++ b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/p10bmc/rainier-4u/config.json
@@ -6,7 +6,7 @@
          {
             "type": "gpio",
             "key": 6,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -27,7 +27,7 @@
          {
             "type": "gpio",
             "key": 7,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -48,7 +48,7 @@
          {
             "type": "gpio",
             "key": 8,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -69,7 +69,7 @@
          {
             "type": "gpio",
             "key": 9,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -90,7 +90,7 @@
          {
             "type": "gpio",
             "key": 10,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -111,7 +111,7 @@
          {
             "type": "gpio",
             "key": 11,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a400.i2c-bus/i2c-7/7-0061",
+            "physpath": "/sys/bus/i2c/devices/7-0061",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
diff --git a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/witherspoon/config.json b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/witherspoon/config.json
index 36cdae8..52262fe 100644
--- a/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/witherspoon/config.json
+++ b/meta-ibm/recipes-phosphor/fans/phosphor-fan-presence-config/witherspoon/config.json
@@ -6,7 +6,7 @@
          {
             "type": "gpio",
             "key": 4,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a100.i2c-bus/i2c-3/3-0060",
+            "physpath": "/sys/bus/i2c/devices/3-0060",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -28,7 +28,7 @@
          {
             "type": "gpio",
             "key": 5,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a100.i2c-bus/i2c-3/3-0060",
+            "physpath": "/sys/bus/i2c/devices/3-0060",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -50,7 +50,7 @@
          {
             "type": "gpio",
             "key": 6,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a100.i2c-bus/i2c-3/3-0060",
+            "physpath": "/sys/bus/i2c/devices/3-0060",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {
@@ -72,7 +72,7 @@
          {
             "type": "gpio",
             "key": 7,
-            "physpath": "/sys/devices/platform/ahb/ahb:apb/ahb:apb:bus@1e78a000/1e78a100.i2c-bus/i2c-3/3-0060",
+            "physpath": "/sys/bus/i2c/devices/3-0060",
             "devpath": "/dev/input/by-path/platform-gpio-keys-polled-event"
          },
          {