Fixes -Wpendantic warnings in rest of plugins.
Signed-off-by: Eero Tamminen <eero.t.tamminen@intel.com>
} /* void add_metric */
static int dcpmm_read(__attribute__((unused)) user_data_t *ud) {
- DEBUG(PLUGIN_NAME ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PLUGIN_NAME ": %s:%d", __func__, __LINE__);
int i, ret = 0;
char dimm_num[16];
} /* int dcpmm_read */
static int dcpmm_stop(void) {
- DEBUG(PLUGIN_NAME ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PLUGIN_NAME ": %s:%d", __func__, __LINE__);
int ret = 0;
if (skip_stop) {
- DEBUG(PLUGIN_NAME ": %s:%d skipping stop function", __FUNCTION__, __LINE__);
+ DEBUG(PLUGIN_NAME ": %s:%d skipping stop function", __func__, __LINE__);
return ret;
}
} /* int dcpmm_stop */
static int dcpmm_shutdown(void) {
- DEBUG(PLUGIN_NAME ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PLUGIN_NAME ": %s:%d", __func__, __LINE__);
int ret = 0;
} /* int dcpmm_shutdown */
static int dcpmm_init(void) {
- DEBUG(PLUGIN_NAME ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PLUGIN_NAME ": %s:%d", __func__, __LINE__);
int ret = 0;
} /* int dcpmm_init */
static int dcpmm_config(oconfig_item_t *ci) {
- DEBUG(PLUGIN_NAME ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PLUGIN_NAME ": %s:%d", __func__, __LINE__);
int ret = 0;
static int pmu_config(oconfig_item_t *ci) {
- DEBUG(PMU_PLUGIN ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PMU_PLUGIN ": %s:%d", __func__, __LINE__);
for (int i = 0; i < ci->children_num; i++) {
int ret = 0;
}
if (ret != 0) {
- DEBUG(PMU_PLUGIN ": %s:%d ret=%d", __FUNCTION__, __LINE__, ret);
+ DEBUG(PMU_PLUGIN ": %s:%d ret=%d", __func__, __LINE__, ret);
return ret;
}
}
static int pmu_read(user_data_t *ud) {
if (ud == NULL) {
- ERROR(PMU_PLUGIN ": ud is NULL! %s:%d", __FUNCTION__, __LINE__);
+ ERROR(PMU_PLUGIN ": ud is NULL! %s:%d", __func__, __LINE__);
return -1;
}
if (ud->data == NULL) {
- ERROR(PMU_PLUGIN ": ud->data is NULL! %s:%d", __FUNCTION__, __LINE__);
+ ERROR(PMU_PLUGIN ": ud->data is NULL! %s:%d", __func__, __LINE__);
return -1;
}
intel_pmu_entity_t *ent = (intel_pmu_entity_t *)ud->data;
int ret;
struct event *e;
- DEBUG(PMU_PLUGIN ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PMU_PLUGIN ": %s:%d", __func__, __LINE__);
/* read all events only for configured cores */
for (e = ent->event_list->eventlist; e; e = e->next) {
static int pmu_init(void) {
int ret;
- DEBUG(PMU_PLUGIN ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PMU_PLUGIN ": %s:%d", __func__, __LINE__);
if (g_ctx.entl == NULL) {
ERROR(PMU_PLUGIN ": No events were setup in configuration.");
static int pmu_shutdown(void) {
- DEBUG(PMU_PLUGIN ": %s:%d", __FUNCTION__, __LINE__);
+ DEBUG(PMU_PLUGIN ": %s:%d", __func__, __LINE__);
for (intel_pmu_entity_t *ent = g_ctx.entl; ent != NULL;) {
intel_pmu_entity_t *tmp = ent;
unsigned int type = ipmi_event_get_type(event);
ipmi_domain_t *domain = cb_data;
- DEBUG("%s: Event received: type %u", __FUNCTION__, type);
+ DEBUG("%s: Event received: type %u", __func__, type);
if (type != 0x02)
/* It's not a standard IPMI event. */
static void mcelog_dispatch_notification(notification_t *n) {
if (!n) {
- ERROR(MCELOG_PLUGIN ": %s: NULL pointer", __FUNCTION__);
+ ERROR(MCELOG_PLUGIN ": %s: NULL pointer", __func__);
return;
}
static int mcelog_submit(const mcelog_memory_rec_t *mr) {
if (!mr) {
- ERROR(MCELOG_PLUGIN ": %s: NULL pointer", __FUNCTION__);
+ ERROR(MCELOG_PLUGIN ": %s: NULL pointer", __func__);
return -1;
}
}
static int mcelog_read(__attribute__((unused)) user_data_t *ud) {
- DEBUG(MCELOG_PLUGIN ": %s", __FUNCTION__);
+ DEBUG(MCELOG_PLUGIN ": %s", __func__);
if (get_memory_machine_checks() != 0)
ERROR(MCELOG_PLUGIN ": MACHINE CHECK INFO NOT AVAILABLE");
#define DAEMON_NAME "mdadm"
#define MD_EVENTS_ERROR(err_msg, ...) \
- ERROR(MD_EVENTS_PLUGIN ": %s: " err_msg, __FUNCTION__, ##__VA_ARGS__)
+ ERROR(MD_EVENTS_PLUGIN ": %s: " err_msg, __func__, ##__VA_ARGS__)
// Syslog can be located under different paths on various linux distros;
// The following two cover the debian-based and redhat distros