eal: minor changes
authorIntel <intel.com>
Wed, 18 Sep 2013 10:00:00 +0000 (12:00 +0200)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Wed, 9 Oct 2013 13:46:52 +0000 (15:46 +0200)
Signed-off-by: Intel
lib/librte_eal/common/include/rte_hexdump.h [changed mode: 0755->0644]
lib/librte_eal/linuxapp/eal/eal.c
lib/librte_eal/linuxapp/eal/eal_debug.c
lib/librte_eal/linuxapp/eal/eal_interrupts.c

old mode 100755 (executable)
new mode 100644 (file)
index 5a9d7b9..f7fd246 100644 (file)
@@ -337,7 +337,8 @@ eal_usage(const char *prgname)
               "  --"OPT_NO_HUGE"  : use malloc instead of hugetlbfs\n"
               "  --"OPT_NO_PCI"   : disable pci\n"
               "  --"OPT_NO_HPET"  : disable hpet\n"
-              "  --"OPT_NO_SHCONF": no shared config (mmap'd files)\n\n",
+              "  --"OPT_NO_SHCONF": no shared config (mmap'd files)\n"
+              "\n",
               prgname);
        /* Allow the application to print its usage message too if hook is set */
        if ( rte_application_usage_hook ) {
@@ -543,7 +544,6 @@ eal_parse_blacklist_opt(const char *optarg, size_t idx)
        return (idx);
 }
 
-
 /* Parse the argument given in the command line of the application */
 static int
 eal_parse_args(int argc, char **argv)
index ffdcfaa..e91ccd4 100644 (file)
@@ -96,7 +96,8 @@ rte_exit(int exit_code, const char *format, ...)
        rte_log_set_history(0);
 
        if (exit_code != 0)
-               RTE_LOG(CRIT, EAL, "Error - exiting with code: %d\nCause: ", exit_code);
+               RTE_LOG(CRIT, EAL, "Error - exiting with code: %d\n"
+                               "  Cause: ", exit_code);
 
        va_start(ap, format);
        rte_vlog(RTE_LOG_CRIT, RTE_LOGTYPE_EAL, format, ap);
index 78a2e4d..a9b0dcd 100644 (file)
@@ -373,15 +373,13 @@ eal_intr_process_interrupts(struct epoll_event *events, int nfds)
                 */
                bytes_read = read(events[n].data.fd, &buf, bytes_read);
 
-               if (bytes_read < 0) {
-                       RTE_LOG(ERR, EAL, "Error reading from file descriptor"
-                               " %d, error: %d\n", events[n].data.fd, errno);
-               }
-               else if (bytes_read == 0) {
-                       RTE_LOG(ERR, EAL,
-                               "Read nothing from file descriptor %d.\n",
-                                                       events[n].data.fd);
-               }
+               if (bytes_read < 0)
+                       RTE_LOG(ERR, EAL, "Error reading from file "
+                               "descriptor %d: %s\n", events[n].data.fd,
+                                                       strerror(errno));
+               else if (bytes_read == 0)
+                       RTE_LOG(ERR, EAL, "Read nothing from file "
+                               "descriptor %d\n", events[n].data.fd);
 
                /* grab a lock, again to call callbacks and update status. */
                rte_spinlock_lock(&intr_lock);