16 Apr, 2008

8 commits


14 Apr, 2008

1 commit


05 Apr, 2008

1 commit

  • These entries are allocated in vlan_dev_set_egress_priority,
    but are never released and leaks on vlan device removal.

    Drop these in vlan's ->uninit callback - after the device is
    brought down and everyone is notified about it is going to
    be unregistered.

    Found during testing vlan netnsization patchset.

    Signed-off-by: Pavel Emelyanov
    Acked-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Pavel Emelyanov
     

03 Apr, 2008

1 commit


02 Apr, 2008

1 commit


28 Mar, 2008

1 commit


27 Mar, 2008

1 commit

  • Currently each vlan_groupd contains 8 pointers on arrays with 512
    pointers on struct net_device each :) Such a construction "in many
    cases ... wastes memory".

    My proposal is to allow for some of these arrays pointers be NULL,
    meaning that there are no devices in it. When a new device is added
    to the vlan_group, the appropriate array is allocated.

    The check in vlan_group_get_device's is safe, since the pointer
    vg->vlan_devices_arrays[x] can only switch from NULL to not-NULL.
    The vlan_group_prealloc_vid() is guarded with rtnl lock and is
    also safe.

    I've checked (I hope that) all the places, that use these arrays
    and found, that the register_vlan_dev is the only place, that can
    put a vlan device on an empty vlan_group.

    Rough calculations shows, that after the patch a setup with a
    single vlan dev (or up to 512 vlans with sequential vids) will
    occupy approximately 8 times less memory.

    The question I have is - does this patch makes sense, or a totally
    new structures are required to store the vlan_devs?

    Signed-off-by: Pavel Emelyanov
    Signed-off-by: Patrick McHardy

    Pavel Emelyanov
     

26 Mar, 2008

2 commits


18 Mar, 2008

2 commits


06 Mar, 2008

1 commit


29 Feb, 2008

1 commit


24 Feb, 2008

1 commit

  • MAC_FMT had only one user and we tried to get rid of
    that, but this created more problems than it solved.

    As a result, this reverts three commits:

    235365f3aaaa10b7056293877c0ead50425f25c7 ("net/8021q/vlan_dev.c: Use
    print_mac."), fea5fa875eb235dc186b1f5184eb36abc63e26cc ("[NET]: Remove
    MAC_FMT"), and 8f789c48448aed74fe1c07af76de8f04adacec7d ("[NET]:
    Elminate spurious print_mac() calls.")

    Signed-off-by: David S. Miller

    David S. Miller
     

18 Feb, 2008

1 commit


01 Feb, 2008

1 commit

  • Reuse the existing logic for multicast list synchronization for the
    unicast address list. The core of dev_mc_sync/unsync are split out as
    __dev_addr_sync/unsync and moved from dev_mcast.c to dev.c. These are
    then used to implement dev_unicast_sync/unsync as well.

    I'm working on cleaning up Intel's FCoE stack, which generates new MAC
    addresses from the fibre channel device id assigned by the fabric as
    per the current draft specification in T11. When using such a
    protocol in a VLAN environment it would be nice to not always be
    forced into promiscuous mode, assuming the underlying Ethernet driver
    supports multiple unicast addresses as well.

    Signed-off-by: Chris Leech
    Signed-off-by: Patrick McHardy

    Chris Leech
     

29 Jan, 2008

15 commits


11 Jan, 2008

1 commit


11 Dec, 2007

1 commit

  • The vlan module cleanup function starts with

    vlan_netlink_fini();
    vlan_ioctl_set(NULL);

    The first call removes all the vlan devices and
    the second one closes the vlan ioctl.

    AFAIS there's a tiny race window between these two
    calls - after rtnl unregistered all the vlans, but
    the ioctl handler isn't set to NULL yet, user can
    manage to call this ioctl and create one vlan device,
    and that this function will later BUG_ON seeing
    non-emply hashes.

    I think, that we must first close the vlan ioctl
    and only after this remove all the vlans with the
    vlan_netlink_fini() call.

    Signed-off-by: Pavel Emelyanov
    Acked-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Pavel Emelyanov