@@ -8,7 +8,7 @@
#include <of.h>
#include <net/if.h>
#include <sys/ioctl.h>
-#include <error.h>
+#include <err.h>
#include <net/if_arp.h>
#include <assert.h>
#include <unistd.h>
@@ -89,7 +89,7 @@ netcfg_acquire(void)
*/
skfd = socket(AF_PACKET, SOCK_RAW, 0);
if (unlikely(skfd < 0)) {
- error(0, errno, "%s(): open(SOCK_RAW)", __func__);
+ warn("%s(): open(SOCK_RAW)", __func__);
return NULL;
}
@@ -40,7 +40,7 @@ static int fsl_bman_portal_init(uint32_t idx, int is_shared)
ret = pthread_getaffinity_np(pthread_self(), sizeof(cpu_set_t),
&cpuset);
if (ret) {
- error(0, ret, "pthread_getaffinity_np()");
+ warn("pthread_getaffinity_np()");
return ret;
}
pcfg.cpu = -1;
@@ -60,7 +60,7 @@ static int fsl_bman_portal_init(uint32_t idx, int is_shared)
map.index = idx;
ret = process_portal_map(&map);
if (ret) {
- error(0, ret, "process_portal_map()");
+ warn("process_portal_map()");
return ret;
}
/* Make the portal's cache-[enabled|inhibited] regions */
@@ -105,7 +105,7 @@ static int fsl_bman_portal_finish(void)
DPAA_BUG_ON(cfg != &pcfg);
ret = process_portal_unmap(&map.addr);
if (ret)
- error(0, ret, "process_portal_unmap()");
+ warn("process_portal_unmap()");
return ret;
}
@@ -41,7 +41,7 @@ static int fsl_qman_portal_init(uint32_t index, int is_shared)
ret = pthread_getaffinity_np(pthread_self(), sizeof(cpu_set_t),
&cpuset);
if (ret) {
- error(0, ret, "pthread_getaffinity_np()");
+ warn("pthread_getaffinity_np()");
return ret;
}
qpcfg.cpu = -1;
@@ -62,7 +62,7 @@ static int fsl_qman_portal_init(uint32_t index, int is_shared)
map.index = index;
ret = process_portal_map(&map);
if (ret) {
- error(0, ret, "process_portal_map()");
+ warn("process_portal_map()");
return ret;
}
qpcfg.channel = map.channel;
@@ -109,7 +109,7 @@ static int fsl_qman_portal_finish(void)
DPAA_BUG_ON(cfg != &qpcfg);
ret = process_portal_unmap(&map.addr);
if (ret)
- error(0, ret, "process_portal_unmap()");
+ warn("process_portal_unmap()");
return ret;
}
@@ -156,7 +156,7 @@ struct qman_portal *fsl_qman_portal_create(void)
q_pcfg = kzalloc((sizeof(struct qm_portal_config)), 0);
if (!q_pcfg) {
- error(0, -1, "q_pcfg kzalloc failed");
+ warn("q_pcfg kzalloc failed");
return NULL;
}
@@ -164,7 +164,7 @@ struct qman_portal *fsl_qman_portal_create(void)
ret = pthread_getaffinity_np(pthread_self(), sizeof(cpu_set_t),
&cpuset);
if (ret) {
- error(0, ret, "pthread_getaffinity_np()");
+ warn("pthread_getaffinity_np()");
kfree(q_pcfg);
return NULL;
}
@@ -190,7 +190,7 @@ struct qman_portal *fsl_qman_portal_create(void)
q_map.index = QBMAN_ANY_PORTAL_IDX;
ret = process_portal_map(&q_map);
if (ret) {
- error(0, ret, "process_portal_map()");
+ warn("process_portal_map()");
kfree(q_pcfg);
return NULL;
}
@@ -33,7 +33,7 @@
#include <assert.h>
#include <dirent.h>
#include <inttypes.h>
-#include <error.h>
+#include <err.h>
#include <rte_byteorder.h>
#include <rte_atomic.h>
#include <rte_spinlock.h>