VOL-538: asfvolt16: driver should be able to direct log messages to syslog
Change-Id: Idf008aa264ae19f2dee58599bf89248b3a47855c
diff --git a/src/bal_tmqueue_hdlr.c b/src/bal_tmqueue_hdlr.c
index 75f26ce..0e7e03b 100755
--- a/src/bal_tmqueue_hdlr.c
+++ b/src/bal_tmqueue_hdlr.c
@@ -43,29 +43,29 @@
}
else
{
- ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to configure the tm queue cfg(OLT): Missing Key values\
- Recevied key values Id(%d), Sched-Dir(%d), Sched-Id(%d) \n",
+ ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to configure the tm queue cfg(OLT): Missing Key values "
+ "Received key values Id(%d), Sched-Dir(%d), Sched-Id(%d)",
tm_queue_cfg->key->sched_id, tm_queue_cfg->key->sched_dir, tm_queue_cfg->key->id);
return BAL_ERRNO__BAL_ERR_NOENT;
}
- ASFVOLT_LOG(ASFVOLT_DEBUG, "Configuration of OLT(tm Queue) starts\n");
+ ASFVOLT_LOG(ASFVOLT_DEBUG, "Configuration of OLT(tm Queue) starts");
/* init the API struct */
BCMBAL_CFG_INIT(&tm_queue_obj, tm_queue, key);
/* decode API parameters from GRPC */
- ASFVOLT_CFG_PROP_SET(tm_queue_obj, tm_queue, priority,
- tm_queue_cfg->data->has_priority,
+ ASFVOLT_CFG_PROP_SET(tm_queue_obj, tm_queue, priority,
+ tm_queue_cfg->data->has_priority,
tm_queue_cfg->data->priority);
- ASFVOLT_CFG_PROP_SET(tm_queue_obj, tm_queue, weight,
- tm_queue_cfg->data->has_weight,
+ ASFVOLT_CFG_PROP_SET(tm_queue_obj, tm_queue, weight,
+ tm_queue_cfg->data->has_weight,
tm_queue_cfg->data->weight);
- ASFVOLT_CFG_PROP_SET(tm_queue_obj, tm_queue, creation_mode,
- tm_queue_cfg->data->has_creation_mode,
+ ASFVOLT_CFG_PROP_SET(tm_queue_obj, tm_queue, creation_mode,
+ tm_queue_cfg->data->has_creation_mode,
tm_queue_cfg->data->creation_mode);
- ASFVOLT_CFG_PROP_SET(tm_queue_obj, tm_queue, ref_count,
- tm_queue_cfg->data->has_ref_count,
+ ASFVOLT_CFG_PROP_SET(tm_queue_obj, tm_queue, ref_count,
+ tm_queue_cfg->data->has_ref_count,
tm_queue_cfg->data->ref_count);
/* rating/shaping */
@@ -165,12 +165,12 @@
if(BCM_ERR_OK != err)
{
- ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to configure the tm Queue Cfg(OLT)\n");
+ ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to configure the tm Queue Cfg(OLT)");
return err;
}
- ASFVOLT_LOG(ASFVOLT_INFO, "\nSet tm Queue configuration sent to OLT. \
- Queue ID(%d) Sched ID(%d) Sched Dir(%d)\n",
+ ASFVOLT_LOG(ASFVOLT_INFO, "Set tm Queue configuration sent to OLT. "
+ "Queue ID(%d) Sched ID(%d) Sched Dir(%d)",
key.id, key.sched_id, key.sched_dir );
return err;
}
@@ -186,7 +186,7 @@
bcmos_errno err = BCM_ERR_OK;
bcmbal_tm_queue_cfg tm_queue_obj; /**< declare main API struct */
bcmbal_tm_queue_key key = { }; /**< declare key */
-
+
if((tm_queue_key->has_id) && (tm_queue_key->has_sched_id) && (tm_queue_key->has_sched_dir))
{
key.id = tm_queue_key->id;
@@ -195,13 +195,13 @@
}
else
{
- ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to clear the tm queue cfg(OLT): Missing Key values\
- Recevied key values Id(%d), Sched-Dir(%d), Sched-Id(%d) \n",
+ ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to clear the tm queue cfg(OLT): Missing Key values "
+ "Received key values Id(%d), Sched-Dir(%d), Sched-Id(%d) ",
tm_queue_key->sched_id, tm_queue_key->sched_dir, tm_queue_key->id);
return BAL_ERRNO__BAL_ERR_NOENT;
}
- ASFVOLT_LOG(ASFVOLT_DEBUG, "Clearing of OLT(tm Queue) starts\n");
+ ASFVOLT_LOG(ASFVOLT_DEBUG, "Clearing of OLT(tm Queue) starts");
/* init the API struct */
BCMBAL_CFG_INIT(&tm_queue_obj, tm_queue, key);
@@ -210,12 +210,12 @@
if(BCM_ERR_OK != err)
{
- ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to clear the tm Queue Cfg(OLT)\n");
+ ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to clear the tm Queue Cfg(OLT)");
return err;
}
- ASFVOLT_LOG(ASFVOLT_INFO, "\nClear tm Queue sent to OLT. \
- Queue ID(%d) Sched ID(%d) Sched Dir(%d)\n",
+ ASFVOLT_LOG(ASFVOLT_INFO, "Clear tm Queue sent to OLT. "
+ "Queue ID(%d) Sched ID(%d) Sched Dir(%d)",
key.id, key.sched_id, key.sched_dir );
return err;
}
@@ -231,7 +231,7 @@
bcmos_errno err = BCM_ERR_OK;
bcmbal_tm_queue_cfg tm_queue_obj; /**< declare main API struct */
bcmbal_tm_queue_key key = { }; /**< declare key */
-
+
if((tm_queue_key->has_id) && (tm_queue_key->has_sched_id) && (tm_queue_key->has_sched_dir))
{
key.id = tm_queue_key->id;
@@ -240,13 +240,13 @@
}
else
{
- ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to get the tm queue cfg(OLT): Missing Key values\
- Recevied key values Id(%d), Sched-Dir(%d), Sched-Id(%d) \n",
+ ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to get the tm queue cfg(OLT): Missing Key values "
+ "Received key values Id(%d), Sched-Dir(%d), Sched-Id(%d)",
tm_queue_key->sched_id, tm_queue_key->sched_dir, tm_queue_key->id);
return BAL_ERRNO__BAL_ERR_NOENT;
}
- ASFVOLT_LOG(ASFVOLT_DEBUG, "Get tm queue cfg(for OLT) starts\n");
+ ASFVOLT_LOG(ASFVOLT_DEBUG, "Get tm queue cfg(for OLT) starts");
/* init the API struct */
BCMBAL_CFG_INIT(&tm_queue_obj, tm_queue, key);
@@ -258,12 +258,12 @@
if(BCM_ERR_OK != err)
{
- ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to get the tm Queue Cfg(OLT)\n");
+ ASFVOLT_LOG(ASFVOLT_ERROR, "Failed to get the tm Queue Cfg(OLT)");
return err;
}
- ASFVOLT_LOG(ASFVOLT_INFO, "\nGet tm Queue sent to OLT. \
- Queue ID(%d) Sched ID(%d) Sched Dir(%d)\n",
+ ASFVOLT_LOG(ASFVOLT_INFO, "Get tm Queue sent to OLT. "
+ "Queue ID(%d) Sched ID(%d) Sched Dir(%d)",
key.id, key.sched_id, key.sched_dir );
return err;
}
@@ -277,11 +277,9 @@
bcmos_errno bal_tm_queue_cfg_indication_cb(bcmbal_obj *obj)
{
bcmos_errno result = BCM_ERR_OK;
- ASFVOLT_LOG(ASFVOLT_INFO, "Processing API \'%s\' IND callback (status is %s)\n",
+ ASFVOLT_LOG(ASFVOLT_INFO, "Processing API \'%s\' IND callback (status is %s)",
bcmbal_objtype_str(obj->obj_type),
bcmos_strerror(obj->status));
-
+
return result;
}
-
-