11 Oct, 2007

6 commits

  • Since hardware header operations are part of the protocol class
    not the device instance, make them into a separate object and
    save memory.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: David S. Miller

    Stephen Hemminger
     
  • Add inline for common usage of hardware header creation, and
    fix bug in IPV6 mcast where the assumption about negative return is
    an errno. Negative return from hard_header means not enough space
    was available,(ie -N bytes).

    Signed-off-by: Stephen Hemminger
    Signed-off-by: David S. Miller

    Stephen Hemminger
     
  • This is nicer than the MAC_FMT stuff.

    Signed-off-by: Joe Perches
    Signed-off-by: David S. Miller

    Joe Perches
     
  • Every user of the network device notifiers is either a protocol
    stack or a pseudo device. If a protocol stack that does not have
    support for multiple network namespaces receives an event for a
    device that is not in the initial network namespace it quite possibly
    can get confused and do the wrong thing.

    To avoid problems until all of the protocol stacks are converted
    this patch modifies all netdev event handlers to ignore events on
    devices that are not in the initial network namespace.

    As the rest of the code is made network namespace aware these
    checks can be removed.

    Signed-off-by: Eric W. Biederman
    Signed-off-by: David S. Miller

    Eric W. Biederman
     
  • This patch modifies every packet receive function
    registered with dev_add_pack() to drop packets if they
    are not from the initial network namespace.

    This should ensure that the various network stacks do
    not receive packets in a anything but the initial network
    namespace until the code has been converted and is ready
    for them.

    Signed-off-by: Eric W. Biederman
    Signed-off-by: David S. Miller

    Eric W. Biederman
     
  • This patch makes /proc/net per network namespace. It modifies the global
    variables proc_net and proc_net_stat to be per network namespace.
    The proc_net file helpers are modified to take a network namespace argument,
    and all of their callers are fixed to pass &init_net for that argument.
    This ensures that all of the /proc/net files are only visible and
    usable in the initial network namespace until the code behind them
    has been updated to be handle multiple network namespaces.

    Making /proc/net per namespace is necessary as at least some files
    in /proc/net depend upon the set of network devices which is per
    network namespace, and even more files in /proc/net have contents
    that are relevant to a single network namespace.

    Signed-off-by: Eric W. Biederman
    Signed-off-by: David S. Miller

    Eric W. Biederman
     

01 Aug, 2007

1 commit

  • The rcu_dereference() primitive needs to be applied to an l-value in order to
    ensure that compiler writers don't get an opportunity to apply reordering
    optimizations that could result in multiple fetches or in other misbehavior.
    This patch pulls the rcu_dereference() calls in bpq_seq_next() up to the point
    at which the fetched pointers are still l-values, rather than after
    list_entry() has transformed them into r-values.

    Signed-off-by: Paul E. McKenney
    Cc: Jeff Garzik
    Cc: Ralf Baechle
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paul E. McKenney
     

26 Apr, 2007

1 commit

  • For the common, open coded 'skb->nh.raw = skb->data' operation, so that we can
    later turn skb->nh.raw into a offset, reducing the size of struct sk_buff in
    64bit land while possibly keeping it as a pointer on 32bit.

    This one touches just the most simple case, next will handle the slightly more
    "complex" cases.

    Signed-off-by: Arnaldo Carvalho de Melo
    Signed-off-by: David S. Miller

    Arnaldo Carvalho de Melo
     

13 Feb, 2007

1 commit

  • Many struct file_operations in the kernel can be "const". Marking them const
    moves these to the .rodata section, which avoids false sharing with potential
    dirty data. In addition it'll catch accidental writes at compile time to
    these shared resources.

    Signed-off-by: Arjan van de Ven
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Arjan van de Ven
     

09 Dec, 2006

1 commit

  • Only the callsign but not the SSID part of an AX.25 address is ASCII
    based but Linux by initializes the SSID which should be just a 4-bit
    number from ASCII anyway.

    Fix that and convert the code to use a shared constant for both default
    addresses. While at it, use the same style for null_ax25_address also.

    Signed-off-by: Ralf Baechle
    Signed-off-by: David S. Miller

    Ralf Baechle
     

11 Jul, 2006

1 commit

  • Bpqether is encapsulating AX.25 frames into ethernet frames. There is a
    virtual bpqether device paired with each ethernet devices, so it's normal
    to pass through dev_queue_xmit twice for each frame which triggers the
    locking detector.

    Signed-off-by: Ralf Baechle
    Signed-off-by: David S. Miller

    Ralf Baechle
     

01 Jul, 2006

1 commit


19 Oct, 2005

1 commit

  • From Suzanne Wood :

    Clarify RCU implementation in bpqether.c.

    Because bpq_new_device() calls list_add_rcu() and bpq_free_device() calls
    list_del_rcu(), substitute list_for_each_entry_rcu() for
    list_for_each_entry() in bpq_get_ax25_dev() and in bpq_seq_start().

    Add rcu dereference protection in bpq_seq_next().

    The rcu_read_lock()/unlock() in bpq_device_event() are removed because
    netdev event handlers are called with RTNL locking in place.

    FYI: bpq_free_device() calls list_del_rcu() which, per list.h, requires
    synchronize_rcu() which can block or call_rcu() or call_rcu_bh() which
    cannot block. Herbert Xu notes that synchronization is done here by
    unregister_netdevice(). This calls synchronize_net() which in turn uses
    synchronize_rcu().

    Signed-off-by: Ralf Baechle DL5RB
    Signed-off-by: Jeff Garzik

    Ralf Baechle
     

13 Sep, 2005

1 commit


30 Aug, 2005

1 commit

  • Bonding just wants the device before the skb_bond()
    decapsulation occurs, so simply pass that original
    device into packet_type->func() as an argument.

    It remains to be seen whether we can use this same
    exact thing to get rid of skb->input_dev as well.

    Signed-off-by: David S. Miller

    David S. Miller
     

25 Apr, 2005

1 commit


17 Apr, 2005

1 commit

  • Initial git repository build. I'm not bothering with the full history,
    even though we have it. We can create a separate "historical" git
    archive of that later if we want to, and in the meantime it's about
    3.2GB when imported into git - space that would just make the early
    git days unnecessarily complicated, when we don't have a lot of good
    infrastructure for it.

    Let it rip!

    Linus Torvalds