Added Power Supply Redundancy Sensor support for Witherspoon

Change-Id: Ie007597516d9da00b6bbe6be56084bf4ac790a19
Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
diff --git a/configs/Witherspoon.py b/configs/Witherspoon.py
index cb68e06..a1ee566 100644
--- a/configs/Witherspoon.py
+++ b/configs/Witherspoon.py
@@ -292,6 +292,7 @@
         0x06 : '/org/openbmc/sensors/host/powercap',
         0x02 : '/org/openbmc/sensors/host/OperatingSystemStatus',
         0x04 : '<inventory_root>/system/chassis/motherboard/pcielink',
+        0xD8 : '/org/openbmc/sensors/host/PowerSupplyRedundancy',
     },
     'GPIO_PRESENT' : {}
 }
@@ -491,6 +492,8 @@
     0x02 : { 'class' : 'OperatingSystemStatusSensor' },
     0x06 : { 'class' : 'PowerCap',
         'os_path' : '/sys/class/hwmon/hwmon3/user_powercap' },
+    # Garrison value is used, need to get from P9 XML.
+    0xD8 : { 'class' : 'PowerSupplyRedundancySensor'},
 }
 
 # vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4
diff --git a/pystatemgr/discover_system_state.py b/pystatemgr/discover_system_state.py
index e52017a..e25e66e 100644
--- a/pystatemgr/discover_system_state.py
+++ b/pystatemgr/discover_system_state.py
@@ -39,6 +39,11 @@
         'object_name': '/org/openbmc/managers/System',
         'interface_name': 'org.freedesktop.DBus.Properties'
     },
+    'powersupplyredundancy': {
+        'bus_name': 'org.openbmc.Sensors',
+        'object_name': '/org/openbmc/sensors/host/PowerSupplyRedundancy',
+        'interface_name': 'org.freedesktop.DBus.Properties'
+    },
 }