cleaned up error message
diff --git a/objects/chassis_identify_obj.c b/objects/chassis_identify_obj.c
index 4a66515..4a0ecb8 100644
--- a/objects/chassis_identify_obj.c
+++ b/objects/chassis_identify_obj.c
@@ -1,4 +1,5 @@
#include "interfaces/openbmc_intf.h"
+#include <stdio.h>
#include "openbmc.h"
#include "gpio.h"
@@ -15,7 +16,7 @@
GDBusMethodInvocation *invocation,
gpointer user_data)
{
- g_print("Turn on chassis identify led\n");
+ printf("Turn on chassis identify led\n");
led_complete_set_on(led,invocation);
int rc = GPIO_OK;
do {
@@ -27,7 +28,7 @@
gpio_close(&led_gpio);
if (rc != GPIO_OK)
{
- g_print("GPIO Error: %d\n",rc);
+ printf("ERROR ChassisIdentify: GPIO error %s (rc=%d)\n",led_gpio.name,rc);
}
return TRUE;
@@ -51,7 +52,7 @@
gpio_close(&led_gpio);
if (rc != GPIO_OK)
{
- g_print("GPIO Error: %d\n",rc);
+ printf("ERROR ChassisIdentify: GPIO error %s (rc=%d)\n",led_gpio.name,rc);
}
return TRUE;
}
diff --git a/objects/pcie_slot_present_obj.c b/objects/pcie_slot_present_obj.c
index 8105f6f..64b30f5 100644
--- a/objects/pcie_slot_present_obj.c
+++ b/objects/pcie_slot_present_obj.c
@@ -1,5 +1,6 @@
#include "interfaces/openbmc_intf.h"
#include "openbmc.h"
+#include <stdio.h>
#include "gpio.h"
#define NUM_SLOTS 8
GPIO slots[NUM_SLOTS] = {
@@ -23,7 +24,7 @@
/* ---------------------------------------------------------------------------------------------------- */
int get_object(GDBusProxy *proxy, GPIO* gpio, object_info* obj_info)
{
- g_print("Here: %s\n",gpio->name);
+ g_print("Checking Presence: %s\n",gpio->name);
GError *error;
GVariant *parm;
GVariant *result;
@@ -83,7 +84,7 @@
} while(0);
if (rc != GPIO_OK)
{
- g_print("ERROR: gpio error %s\n",gpio->name);
+ printf("ERROR pcie_slot_present: GPIO error %s (rc=%d)\n",gpio->name,rc);
}
return rc;
}
diff --git a/objects/power_control_obj.c b/objects/power_control_obj.c
index ab4f5d1..6e54787 100644
--- a/objects/power_control_obj.c
+++ b/objects/power_control_obj.c
@@ -21,10 +21,9 @@
static GDBusObjectManagerServer *manager = NULL;
-//guint tmp_pgood = 0;
-//guint last_pgood = 0;
time_t pgood_timeout_start = 0;
+// TODO: Change to interrupt driven instead of polling
static gboolean poll_pgood(gpointer user_data)
{
ControlPower *control_power = object_get_control_power((Object*)user_data);