11 Oct, 2007

1 commit

  • As discussed before, this patch provides userland with a way to access
    relevant options in Router Advertisements, after they are processed
    and validated by the kernel. Extra options are processed in a generic
    way; this patch only exports RDNSS options described in RFC5006, but
    support to control which options are exported could be easily added.

    A new rtnetlink message type is defined, to transport Neighbor
    Discovery options, along with optional context information. At the
    moment only the address of the router sending an RDNSS option is
    included, but additional attributes may be later defined, if needed by
    new use cases.

    Signed-off-by: Pierre Ynard
    Signed-off-by: David S. Miller

    Pierre Ynard
     

31 Aug, 2007

1 commit


11 Jul, 2007

3 commits

  • Sent the wrong patch previously.

    Signed-off-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Patrick McHardy
     
  • Add a nested compat attribute type that can be used to convert
    attributes that contain a structure to nested attributes in a
    backwards compatible way.

    The attribute looks like this:

    struct {
    [ compat contents ]
    struct rtattr {
    .rta_len = total size,
    .rta_type = type,
    } rta;
    struct old_structure struct;

    [ nested top-level attribute ]
    struct rtattr {
    .rta_len = nest size,
    .rta_type = type,
    } nest_attr;

    [ optional 0 .. n nested attributes ]
    struct rtattr {
    .rta_len = private attribute len,
    .rta_type = private attribute typ,
    } nested_attr;
    struct nested_data data;
    };

    Since both userspace and kernel deal correctly with attributes that are
    larger than expected old versions will just parse the compat part and
    ignore the rest.

    Signed-off-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Patrick McHardy
     
  • With help from Chris Wedgwood.

    Signed-off-by: David S. Miller

    David S. Miller
     

26 Apr, 2007

2 commits

  • This patch adds a new interface to register rtnetlink message
    handlers replacing the exported rtnl_links[] array which
    required many message handlers to be exported unnecessarly.

    Signed-off-by: Thomas Graf
    Signed-off-by: David S. Miller

    Thomas Graf
     
  • So that it is also an offset from skb->head, reduces its size from 8 to 4 bytes
    on 64bit architectures, allowing us to combine the 4 bytes hole left by the
    layer headers conversion, reducing struct sk_buff size to 256 bytes, i.e. 4
    64byte cachelines, and since the sk_buff slab cache is SLAB_HWCACHE_ALIGN...
    :-)

    Many calculations that previously required that skb->{transport,network,
    mac}_header be first converted to a pointer now can be done directly, being
    meaningful as offsets or pointers.

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

    Arnaldo Carvalho de Melo
     

09 Dec, 2006

1 commit


03 Dec, 2006

2 commits


29 Sep, 2006

1 commit


23 Sep, 2006

11 commits


26 Apr, 2006

1 commit


23 Mar, 2006

1 commit

  • To really make sense of route notifications in the presence of
    multiple tables, userspace also needs to be notified about routing
    rule updates. Notifications are sent to the so far unused
    RTNLGRP_NOP1 (now RTNLGRP_RULE) group.

    Signed-off-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Patrick McHardy
     

21 Mar, 2006

3 commits

  • The Netsukuku daemon is using the same number to mark its routes, you
    can see it here:
    http://hinezumilabs.org/cgi-bin/viewcvs.cgi/netsukuku/src/krnl_route.h?rev=HEAD&content-type=text/vnd.viewcvs-markup

    Signed-off-by: David S. Miller

    Alpt
     
  • This patch turns the RTNL from a semaphore to a new 2.6.16 mutex and
    gets rid of some of the leftover legacy.

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

    Stephen Hemminger
     
  • this patch adds a dormant flag to network devices, RFC2863 operstate derived
    from these flags and possibility for userspace interaction. It allows drivers
    to signal that a device is unusable for user traffic without disabling
    queueing (and therefore the possibility for protocol establishment traffic to
    flow) and a userspace supplicant (WPA, 802.1X) to mark a device unusable
    without changes to the driver.

    It is the result of our long discussion. However I must admit that it
    represents what Jamal and I agreed on with compromises towards Krzysztof, but
    Thomas and Krzysztof still disagree with some parts. Anyway I think it should
    be applied.

    Signed-off-by: Stefan Rompf
    Signed-off-by: David S. Miller

    Stefan Rompf
     

20 Dec, 2005

1 commit

  • I reported a problem and gave hints to the solution, but nobody seemed
    to react. So I prepared a patch against 2.6.14.4.

    Tested on 2.6.14.4 with "ip monitor addr" and with the program
    attached, while adding and removing IPv6 address. Both programs didn't
    receive any messages. Tested 2.6.14.4 + this patch, and both programs
    received add and remove messages.

    Signed-off-by: Kristian Slavov
    Acked-by: Jamal Hadi salim
    ACKed-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Kristian Slavov
     

30 Aug, 2005

1 commit


29 Jun, 2005

2 commits


24 Jun, 2005

1 commit


19 Jun, 2005

4 commits

  • Signed-off-by: Thomas Graf
    Signed-off-by: David S. Miller

    Thomas Graf
     
  • Only skb_trim() if 'start' is non-NULL.

    Signed-off-by: Thomas Graf
    Signed-off-by: David S. Miller

    Thomas Graf
     
  • To retrieve the neighbour tables send RTM_GETNEIGHTBL with the
    NLM_F_DUMP flag set. Every neighbour table configuration is
    spread over multiple messages to avoid running into message
    size limits on systems with many interfaces. The first message
    in the sequence transports all not device specific data such as
    statistics, configuration, and the default parameter set.
    This message is followed by 0..n messages carrying device
    specific parameter sets.

    Although the ordering should be sufficient, NDTA_NAME can be
    used to identify sequences. The initial message can be identified
    by checking for NDTA_CONFIG. The device specific messages do
    not contain this TLV but have NDTPA_IFINDEX set to the
    corresponding interface index.

    To change neighbour table attributes, send RTM_SETNEIGHTBL
    with NDTA_NAME set. Changeable attribute include NDTA_THRESH[1-3],
    NDTA_GC_INTERVAL, and all TLVs in NDTA_PARMS unless marked
    otherwise. Device specific parameter sets can be changed by
    setting NDTPA_IFINDEX to the interface index of the corresponding
    device.

    Signed-off-by: Thomas Graf
    Signed-off-by: David S. Miller

    Thomas Graf
     
  • RTA_GET_U(32|64)(tlv)
    Assumes TLV is a u32/u64 field and returns its value.

    RTA_GET_[M]SECS(tlv)
    Assumes TLV is a u64 and transports jiffies converted
    to seconds or milliseconds and returns its value.

    RTA_PUT_U(32|64)(skb, type, value)
    Appends %value as fixed u32/u64 to %skb as TLV %type.

    RTA_PUT_[M]SECS(skb, type, jiffies)
    Converts %jiffies to secs/msecs and appends it as u64
    to %skb as TLV %type.

    RTA_PUT_STRING(skb, type, string)
    Appends %NUL terminated %string to %skb as TLV %type.

    RTA_NEST(skb, type)
    Starts a nested TLV %type and returns the nesting handle.

    RTA_NEST_END(skb, nesting_handle)
    Finishes the nested TLV %nesting_handle, must be called
    symmetric to RTA_NEST(). Returns skb->len

    RTA_NEST_CANCEL(skb, nesting_handle)
    Cancel the nested TLV %nesting_handle and trim nested TLV
    from skb again, returns -1.

    Signed-off-by: Thomas Graf
    Signed-off-by: David S. Miller

    Thomas Graf
     

04 May, 2005

3 commits

  • Converts remaining rtnetlink_link tables to use c99 designated
    initializers to make greping a little bit easier.

    Signed-off-by: Thomas Graf
    Signed-off-by: David S. Miller

    Thomas Graf
     
  • Converts rtm_min and rtm_max arrays to use c99 designated
    initializers for easier insertion of new message families.
    RTM_GETMULTICAST and RTM_GETANYCAST did not have the minimal
    message size specified which means that the netlink message
    was parsed for routing attributes starting from the header.
    Adds the proper minimal message sizes for these messages
    (netlink header + common rtnetlink header) to fix this issue.

    Signed-off-by: Thomas Graf
    Signed-off-by: David S. Miller

    Thomas Graf
     
  • RTM_MAX is currently set to the maximum reserverd message type plus one
    thus being the cause of two bugs for new types being assigned a) given the
    new family registers only the NEW command in its reserved block the array
    size for per family entries is calculated one entry short and b) given the
    new family registers all commands RTM_MAX would point to the first entry
    of the block following this one and the rtnetlink receive path would accept
    a message type for a nonexisting family.

    This patch changes RTM_MAX to point to the maximum valid message type
    by aligning it to the start of the next block and subtracting one.

    Signed-off-by: Thomas Graf
    Signed-off-by: David S. Miller

    Thomas Graf
     

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