+ Add support for "team" driver (alternative to bond devices).
+ Preliminary support for DTrace/systemtap.
+ Preliminary support for seccomp (for monitor process).
- + Setup chroot inside lldpd instead of relying on init script.
+ + Set up chroot inside lldpd instead of relying on init script.
* Fixes:
+ Various bugs related to fixed point number handling (for
coordinates in LLDP-MED)
(!strcmp(action, "asset") &&
(lldpctl_atom_set_str(chassis, lldpctl_k_chassis_med_inventory_asset,
cmdenv_get(env, "asset")) == NULL))) {
- log_warnx("lldpctl", "Unable to setup inventory. %s",
+ log_warnx("lldpctl", "Unable to set up inventory. %s",
lldpctl_last_strerror(conn));
lldpctl_atom_dec_ref(chassis);
return 0;
/* snmp_select_info() can be tricky to understand. We set `block` to
1 to means that we don't request a timeout. snmp_select_info()
- will reset `block` to 0 if it wants us to setup a timeout. In
+ will reset `block` to 0 if it wants us to set up a timeout. In
this timeout, `snmp_timeout()` should be invoked.
Each FD in `fdset` will need to be watched for reading. If one of
static void
levent_init(struct lldpd *cfg)
{
- /* Setup libevent */
+ /* Set up libevent */
log_debug("event", "initialize libevent");
event_set_log_callback(levent_log_cb);
if (!(cfg->g_base = event_base_new()))
log_info("event", "libevent %s initialized with %s method", event_get_version(),
event_base_get_method(cfg->g_base));
- /* Setup SNMP */
+ /* Set up SNMP */
#ifdef USE_SNMP
if (cfg->g_snmp) {
agent_init(cfg, cfg->g_snmp_agentx);
fatalx("event", "unable to setup main timer");
event_active(cfg->g_main_loop, EV_TIMEOUT, 1);
- /* Setup unix socket */
+ /* Set up unix socket */
struct event *ctl_event;
log_debug("event", "register Unix socket");
TAILQ_INIT(&lldpd_clients);
}
buffer->len = ETHER_MAX_LEN + BPF_WORDALIGN(sizeof(struct bpf_hdr));
- /* Setup multicast */
+ /* Set up multicast */
interfaces_setup_multicast(cfg, hardware->h_ifname, 0);
hardware->h_sendfd = fd; /* Send */
*/
/**
- * Setup log handlers.
+ * Set up log handlers.
*
* By default, liblldpctl will log to stderr. The following function will
* register another callback for this purpose. Messages logged through this
void lldpctl_log_callback(void (*cb)(int severity, const char *msg));
/**
- * Setup log level.
+ * Set up log level.
*
* By default, liblldpctl will only log warnings. The following function allows
* to increase verbosity. This function has no effect if callbacks are
with self.namespaces[ns]:
mount_proc()
mount_sys()
- # Also setup the "namespace-dependant" directory
+ # Also set up the "namespace-dependant" directory
self.tmpdir.join("ns").ensure(dir=True)
mount_tmpfs(str(self.tmpdir.join("ns")), private=True)
t.join(1)
def setup_namespace(self, name):
- # Setup privsep. While not enforced, we assume we are running in a
+ # Set up privsep. While not enforced, we assume we are running in a
# throwaway mount namespace.
tmpdir = self.tmpdir
if self.config.lldpd.privsep.enabled:
@pytest.mark.skipif("'Dot3' not in config.lldpd.features", reason="Dot3 not supported")
class TestLldpDot3(object):
def test_aggregate(self, lldpd1, lldpd, lldpcli, namespaces, links):
- links(namespaces(3), namespaces(2)) # Another link to setup a bond
+ links(namespaces(3), namespaces(2)) # Another link to set up a bond
with namespaces(2):
idx = links.bond("bond42", "eth1", "eth3")
lldpd()
def test_remove_bridge(lldpd, lldpcli, namespaces, links):
links(namespaces(1), namespaces(2))
- links(namespaces(3), namespaces(1)) # Another link to setup a bridge
+ links(namespaces(3), namespaces(1)) # Another link to set up a bridge
with namespaces(1):
links.bridge("br42", "eth0", "eth3")
lldpd("-r")
@pytest.mark.skipif("'Dot1' not in config.lldpd.features", reason="Dot1 not supported")
@pytest.mark.parametrize("when", ["before", "after"])
def test_bridge_with_vlan(lldpd1, lldpd, lldpcli, namespaces, links, when):
- links(namespaces(3), namespaces(2)) # Another link to setup a bridge
+ links(namespaces(3), namespaces(2)) # Another link to set up a bridge
with namespaces(2):
if when == "after":
lldpd()
@pytest.mark.skipif("'Dot1' not in config.lldpd.features", reason="Dot1 not supported")
@pytest.mark.parametrize("when", ["before", "after"])
def test_vlan_aware_bridge_with_vlan(lldpd1, lldpd, lldpcli, namespaces, links, when):
- links(namespaces(3), namespaces(2)) # Another link to setup a bridge
+ links(namespaces(3), namespaces(2)) # Another link to set up a bridge
with namespaces(3):
lldpd()
with namespaces(2):
def test_vlan_aware_bridge_filtering(
lldpd1, lldpd, lldpcli, namespaces, links, filtering
):
- links(namespaces(3), namespaces(2)) # Another link to setup a bridge
+ links(namespaces(3), namespaces(2)) # Another link to set up a bridge
with namespaces(2):
links.bridge("br42", "eth1", "eth3", filtering=filtering)
links.bridge_vlan("eth1", 100, pvid=True)
@pytest.mark.skipif("'Dot3' not in config.lldpd.features", reason="Dot3 not supported")
@pytest.mark.parametrize("when", ["before", "after"])
def test_bond(lldpd1, lldpd, lldpcli, namespaces, links, when):
- links(namespaces(3), namespaces(2)) # Another link to setup a bond
+ links(namespaces(3), namespaces(2)) # Another link to set up a bond
with namespaces(2):
if when == "after":
lldpd()
)
@pytest.mark.parametrize("when", ["before", "after"])
def test_team(lldpd1, lldpd, lldpcli, namespaces, links, when):
- links(namespaces(3), namespaces(2)) # Another link to setup a bond
+ links(namespaces(3), namespaces(2)) # Another link to set up a bond
with namespaces(2):
if when == "after":
lldpd()
@pytest.mark.skipif("'Dot1' not in config.lldpd.features", reason="Dot1 not supported")
@pytest.mark.parametrize("when", ["before", "after"])
def test_bond_with_vlan(lldpd1, lldpd, lldpcli, namespaces, links, when):
- links(namespaces(3), namespaces(2)) # Another link to setup a bond
+ links(namespaces(3), namespaces(2)) # Another link to set up a bond
with namespaces(2):
if when == "after":
lldpd()