[PATCH 1/3] Check for ARPHRD_ETHER and ARPHRD_SLIP types in getDevices (#596826)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In the getDevices() function in isys, we check the type of the device
during discovery to see if the type is ARPHRD_ETHER.  If it isn't, we
skip that device when gathering network devices.  This filters out lo,
sit0, and other devices we don't want in the network device list.  But,
it does skip over one ethernet device type that is initialized as
ARPHRD_SLIP on s390.
---
 isys/devices.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/isys/devices.c b/isys/devices.c
index 854017d..2a77ce4 100644
--- a/isys/devices.c
+++ b/isys/devices.c
@@ -30,6 +30,7 @@
 #include <unistd.h>
 #include <sys/types.h>
 #include <limits.h>
+#include <net/if_arp.h>
 
 #include "devices.h"
 
@@ -171,7 +172,7 @@ storagedone:
                 return NULL;
             }
 
-            if (type != 1)
+            if (type != ARPHRD_ETHER && type != ARPHRD_SLIP)
                 continue;
 
             new = calloc(1, sizeof(struct device));
-- 
1.7.3.2

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux