Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also .

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also .
  • 9 commits
  • 6 files changed
  • 0 comments
  • 3 contributors
Commits on Jul 31, 2017
fixes issue #29
Commits on Aug 07, 2017
Commits on Jan 24, 2018
Commits on Feb 10, 2018
Fixes: #30
Commits on Mar 11, 2018
Add more MAU types
Initialize allocated pci_access structure
Commits on Mar 12, 2018
bump version to 1.1.2
Showing with 30 additions and 9 deletions.
  1. +1 −1 configure.ac
  2. +1 −1 rpm/ladvd.spec
  3. +15 −6 src/netif_bsd.c
  4. +1 −1 src/netif_linux.c
  5. +3 −0 src/parent.c
  6. +9 −0 src/proto/lldp.h
@@ -3,7 +3,7 @@

AC_PREREQ([2.61])

AC_INIT([ladvd], [1.1.1], [sten@blinkenlights.nl])
AC_INIT([ladvd], [1.1.2], [sten@blinkenlights.nl])
AC_CANONICAL_TARGET
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_SRCDIR([src/config.h.in])
@@ -46,7 +46,7 @@ Requires(post): chkconfig
Requires(preun): chkconfig
%endif

Version: 1.1.1
Version: 1.1.2
Release: 1%{?dist}
License: ISC
URL: http://github.com/sspans/ladvd/
@@ -142,19 +142,13 @@ static int netif_type(int sockfd, uint32_t index,
return(NETIF_REGULAR);

// bridge
#ifdef IFT_BRIDGE
} else if (if_data->ifi_type == IFT_BRIDGE) {
return(NETIF_BRIDGE);
#endif
#ifdef IFT_IEEE8023ADLAG
// trunk ports have a special type
} else if (if_data->ifi_type == IFT_IEEE8023ADLAG) {
return(NETIF_REGULAR);
#endif
#ifdef IFT_L2VLAN
} else if (if_data->ifi_type == IFT_L2VLAN) {
return(NETIF_VLAN);
#endif
}

// we don't want the rest
@@ -634,6 +628,21 @@ static int netif_physical(int sockfd, struct netif *netif) {
case IFM_10G_T:
netif->mau = LLDP_MAU_TYPE_10GBASE_T;
break;
#endif
#ifdef IFM_40G_CR4
case IFM_40G_CR4:
netif->mau = LLDP_MAU_TYPE_40GBASE_CR4;
break;
#endif
#ifdef IFM_40G_SR4
case IFM_40G_SR4:
netif->mau = LLDP_MAU_TYPE_40GBASE_SR4;
break;
#endif
#ifdef IFM_40G_LR4
case IFM_40G_LR4:
netif->mau = LLDP_MAU_TYPE_40GBASE_LR4;
break;
#endif
}

@@ -123,7 +123,7 @@ static int netif_type(int sockfd, uint32_t index,
} else if (strcmp(dname, "802.1Q VLAN Support") == 0) {
return(NETIF_VLAN);
// handle tun/tap
} else if (strcmp(dname, "tun") == 0) {
} else if (strcmp(dname, "tun") == 0 || strcmp(dname, "veth") == 0) {
return(NETIF_TAP);
}

@@ -563,6 +563,9 @@ ssize_t parent_device_id(struct parent_req *mreq) {

if (!pacc) {
pacc = pci_alloc();
if (!pacc)
return(0);
pci_init(pacc);
}

ret = snprintf(path, SYSFS_PATH_MAX,
@@ -158,6 +158,15 @@
#define LLDP_MAU_TYPE_10GBASE_PR_D3 67
#define LLDP_MAU_TYPE_10GBASE_PR_U1 68
#define LLDP_MAU_TYPE_10GBASE_PR_U3 69
#define LLDP_MAU_TYPE_40GBASE_KR4 70
#define LLDP_MAU_TYPE_40GBASE_CR4 71
#define LLDP_MAU_TYPE_40GBASE_SR4 72
#define LLDP_MAU_TYPE_40GBASE_FR 73
#define LLDP_MAU_TYPE_40GBASE_LR4 74
#define LLDP_MAU_TYPE_100GBASE_CR10 75
#define LLDP_MAU_TYPE_100GBASE_SR10 76
#define LLDP_MAU_TYPE_100GBASE_LR4 77
#define LLDP_MAU_TYPE_100GBASE_ER4 78

// From RFC 3636 - ifMauAutoNegCapAdvertisedBits
#define LLDP_MAU_PMD_OTHER (1 << 15)

No commit comments for this range