Filter based on REDFISH_SUPPORT_TRANS_STATE for x86 for redfish path

REDFISH_SUPPORT_TRANS_STATE is still a development variable which
will be eventually auto populated when the firmware and test is ready
to run is to run in Redfish mode ONLY.

User can force test to run ONLY redfish mode using this varaible
    -v REDFISH_SUPPORT_TRANS_STATE:1

Change-Id: I64cebc635845376a7564c5b537aa44495c890666
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/lib/state.py b/lib/state.py
index c715ba0..ea45dd2 100755
--- a/lib/state.py
+++ b/lib/state.py
@@ -261,19 +261,22 @@
 
 # Filter the states based on platform type.
 if platform_arch_type == "x86":
-    default_req_states.remove("operating_system")
+
+    if not redfish_support_trans_state:
+        default_req_states.remove("operating_system")
+        valid_req_states.remove("operating_system")
+        del default_state["operating_system"]
+        del standby_match_state["operating_system"]
+        del os_running_match_state["operating_system"]
+        del master_os_up_match["operating_system"]
+        del invalid_state_match["operating_system"]
+
     default_req_states.remove("boot_progress")
-    valid_req_states.remove("operating_system")
     valid_req_states.remove("boot_progress")
-    del default_state["operating_system"]
     del default_state["boot_progress"]
-    del standby_match_state["operating_system"]
     del standby_match_state["boot_progress"]
-    del os_running_match_state["operating_system"]
     del os_running_match_state["boot_progress"]
-    del master_os_up_match["operating_system"]
     del master_os_up_match["boot_progress"]
-    del invalid_state_match["operating_system"]
     del invalid_state_match["boot_progress"]
 
 
@@ -747,9 +750,10 @@
 
             if int(state['redfish']):
                 state['chassis'] = ret_values['chassis']
-                state['boot_progress'] = ret_values['boot_progress']
                 state['host'] = ret_values['host']
                 state['bmc'] = ret_values['bmc']
+                if platform_arch_type != "x86":
+                    state['boot_progress'] = ret_values['boot_progress']
 
     for sub_state in req_states:
         if sub_state in state: