From: Vincent Bernat Date: Sun, 26 Oct 2014 10:31:34 +0000 (+0100) Subject: interfaces: bond listening was broken only for old kernels X-Git-Tag: 0.7.12~18 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=148a1efedcdfde013488998581f3325dc432461e;p=thirdparty%2Flldpd.git interfaces: bond listening was broken only for old kernels With a recent kernel, we can listen to individual member. lldpd is still listening on master to keep compatibility with older kernels and because it is difficult to detect if the kernel gives us this ability or not. We can't rely on version numbers as some kernels have backported features (like 2.6.18 from RHEL 5). --- diff --git a/NEWS b/NEWS index 6879aa7a..a1af833a 100644 --- a/NEWS +++ b/NEWS @@ -1,7 +1,7 @@ lldpd (0.7.12) * Fix: + Don't complain when parsing a commented line. - + Fix listening on bond devices. + + Fix listening on bond devices for old kernels (< 2.6.27). lldpd (0.7.11) * Features: diff --git a/src/daemon/interfaces-linux.c b/src/daemon/interfaces-linux.c index 85d8f986..df90455b 100644 --- a/src/daemon/interfaces-linux.c +++ b/src/daemon/interfaces-linux.c @@ -446,6 +446,8 @@ iface_bond_init(struct lldpd *cfg, struct lldpd_hardware *hardware) interfaces_setup_multicast(cfg, hardware->h_ifname, 0); /* Then, we open a raw interface for the master */ + log_debug("interfaces", "bonded device %s has master %s(%d)", + hardware->h_ifname, master->name, master->index); if ((fd = priv_iface_init(master->index, master->name)) == -1) { close(hardware->h_sendfd); return -1;