ipmi: sensor config yaml updates

When marking a unit as functional both functional state
and presence need to be checked to avoid marking
non-present units as functional.

There was a change in yaml structure for accomodating
fix for marking non-present units as functional.
All these yamls are not sorted by sensor id, so it will
easier for a future script based change.

Change-Id: I122d652de32ba4f323ee7b31a59078d86e158246
Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
diff --git a/meta-zaius/recipes-phosphor/ipmi/phosphor-ipmi-sensor-inventory%/config.yaml b/meta-zaius/recipes-phosphor/ipmi/phosphor-ipmi-sensor-inventory%/config.yaml
index 05f725b..4057194 100755
--- a/meta-zaius/recipes-phosphor/ipmi/phosphor-ipmi-sensor-inventory%/config.yaml
+++ b/meta-zaius/recipes-phosphor/ipmi/phosphor-ipmi-sensor-inventory%/config.yaml
@@ -1,65 +1,94 @@
 0x03:
+  sensorType: 0x0F
+  path: /xyz/openbmc_project/state/host0
+  sensorReadingType: 0x6F
+  serviceInterface: org.freedesktop.DBus.Properties
+  readingType: eventdata2
   interfaces:
     xyz.openbmc_project.State.Boot.Progress:
       BootProgress:
-        0x00:
-          set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.Unspecified
-          type: string
-        0x01:
-          set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.MemoryInit
-          type: string
-        0x03:
-          set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.SecondaryProcInit
-          type: string
-        0x13:
-          set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.OSStart
-          type: string
-        0x14:
-          set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.MotherboardInit
-          type: string
-  path: /xyz/openbmc_project/state/host0
-  readingType: eventdata2
-  sensorReadingType: 0x6F
-  sensorType: 0x0F
-  serviceInterface: org.freedesktop.DBus.Properties
+        Offsets:
+          0x13:
+            type: string
+            set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.OSStart
+          0x00:
+            type: string
+            set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.Unspecified
+          0x01:
+            type: string
+            set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.MemoryInit
+          0x14:
+            type: string
+            set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.MotherboardInit
+          0x03:
+            type: string
+            set: xyz.openbmc_project.State.Boot.Progress.ProgressStages.SecondaryProcInit
 0x05:
+  sensorType: 0x1F
+  path: /xyz/openbmc_project/state/host0
+  sensorReadingType: 0x6F
+  serviceInterface: org.freedesktop.DBus.Properties
+  readingType: assertion
   interfaces:
     xyz.openbmc_project.State.OperatingSystem.Status:
       OperatingSystemState:
-        0x01:
-          assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.CBoot
-          type: string
-        0x02:
-          assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.PXEBoot
-          type: string
-        0x03:
-          assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.DiagBoot
-          type: string
-        0x04:
-          assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.CDROMBoot
-          type: string
-        0x05:
-          assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.ROMBoot
-          type: string
-        0x06:
-          assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.BootComplete
-          type: string
-  path: /xyz/openbmc_project/state/host0
-  readingType: assertion
-  sensorReadingType: 0x6F
-  sensorType: 0x1F
-  serviceInterface: org.freedesktop.DBus.Properties
+        Offsets:
+          0x02:
+            assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.PXEBoot
+            type: string
+          0x06:
+            assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.BootComplete
+            type: string
+          0x04:
+            assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.CDROMBoot
+            type: string
+          0x01:
+            assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.CBoot
+            type: string
+          0x03:
+            assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.DiagBoot
+            type: string
+          0x05:
+            assert: xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.ROMBoot
+            type: string
 0x07:
+  sensorType: 0xC3
+  path: /xyz/openbmc_project/state/host0
+  sensorReadingType: 0x6F
+  serviceInterface: org.freedesktop.DBus.Properties
+  readingType: readingAssertion
   interfaces:
     xyz.openbmc_project.Control.Boot.RebootAttempts:
       AttemptsLeft:
-        0xFF:
-          type: uint32_t
-  path: /xyz/openbmc_project/state/host0
-  readingType: readingAssertion
+        Offsets:
+          0xFF:
+            type: uint32_t
+0x21:
+  sensorType: 0x07
+  path: /system/chassis/motherboard/cpu0
   sensorReadingType: 0x6F
-  sensorType: 0xC3
-  serviceInterface: org.freedesktop.DBus.Properties
+  serviceInterface: xyz.openbmc_project.Inventory.Manager
+  readingType: assertion
+  interfaces:
+    xyz.openbmc_project.State.Decorator.OperationalStatus:
+      Functional:
+        Prereqs:
+          0x07:
+            assert: true
+            deassert: false
+            type: bool
+        Offsets:
+          0x08:
+            assert: false
+            deassert: true
+            type: bool
+    xyz.openbmc_project.Inventory.Item:
+      Present:
+        Offsets:
+          0x07:
+            assert: true
+            deassert: false
+            type: bool
 0x6A:
   sensorType: 0x07
   path: /org/open_power/control/occ0
@@ -69,6 +98,7 @@
   interfaces:
     org.open_power.OCC.Status:
       OccActive:
+        Offsets:
           0x00:
             assert: false
             deassert: true
@@ -77,6 +107,32 @@
             assert: true
             deassert: false
             type: bool
+0x71:
+  sensorType: 0x07
+  path: /system/chassis/motherboard/cpu1
+  sensorReadingType: 0x6F
+  serviceInterface: xyz.openbmc_project.Inventory.Manager
+  readingType: assertion
+  interfaces:
+    xyz.openbmc_project.State.Decorator.OperationalStatus:
+      Functional:
+        Prereqs:
+          0x07:
+            assert: true
+            deassert: false
+            type: bool
+        Offsets:
+          0x08:
+            assert: false
+            deassert: true
+            type: bool
+    xyz.openbmc_project.Inventory.Item:
+      Present:
+        Offsets:
+          0x07:
+            assert: true
+            deassert: false
+            type: bool
 0xBA:
   sensorType: 0x07
   path: /org/open_power/control/occ1
@@ -86,6 +142,7 @@
   interfaces:
     org.open_power.OCC.Status:
       OccActive:
+        Offsets:
           0x00:
             assert: false
             deassert: true
@@ -94,41 +151,3 @@
             assert: true
             deassert: false
             type: bool
-0x21:
-  sensorType: 0x07
-  path: /system/chassis/motherboard/cpu0
-  sensorReadingType: 0x6F
-  serviceInterface: xyz.openbmc_project.Inventory.Manager
-  readingType: assertion
-  interfaces:
-    xyz.openbmc_project.State.Decorator.OperationalStatus:
-      Functional:
-        0x08:
-          deassert: true
-          assert: false
-          type: bool
-    xyz.openbmc_project.Inventory.Item:
-      Present:
-        0x07:
-          deassert: false
-          assert: true
-          type: bool
-0x71:
-  sensorType: 0x07
-  path: /system/chassis/motherboard/cpu1
-  sensorReadingType: 0x6F
-  serviceInterface: xyz.openbmc_project.Inventory.Manager
-  readingType: assertion
-  interfaces:
-    xyz.openbmc_project.State.Decorator.OperationalStatus:
-      Functional:
-        0x08:
-          deassert: true
-          assert: false
-          type: bool
-    xyz.openbmc_project.Inventory.Item:
-      Present:
-        0x07:
-          deassert: false
-          assert: true
-          type: bool