16 Oct, 2007

2 commits


11 Oct, 2007

8 commits


11 Jul, 2007

2 commits


26 Apr, 2007

4 commits

  • To clearly state the intent of copying to linear sk_buffs, _offset being a
    overly long variant but interesting for the sake of saving some bytes.

    Signed-off-by: Arnaldo Carvalho de Melo

    Arnaldo Carvalho de Melo
     
  • The error pointer argument in netlink message handlers is used
    to signal the special case where processing has to be interrupted
    because a dump was started but no error happened. Instead it is
    simpler and more clear to return -EINTR and have netlink_run_queue()
    deal with getting the queue right.

    nfnetlink passed on this error pointer to its subsystem handlers
    but only uses it to signal the start of a netlink dump. Therefore
    it can be removed there as well.

    This patch also cleans up the error handling in the affected
    message handlers to be consistent since it had to be touched anyway.

    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
     
  • We currently use a special structure (struct skb_timeval) and plain
    'struct timeval' to store packet timestamps in sk_buffs and struct
    sock.

    This has some drawbacks :
    - Fixed resolution of micro second.
    - Waste of space on 64bit platforms where sizeof(struct timeval)=16

    I suggest using ktime_t that is a nice abstraction of high resolution
    time services, currently capable of nanosecond resolution.

    As sizeof(ktime_t) is 8 bytes, using ktime_t in 'struct sock' permits
    a 8 byte shrink of this structure on 64bit architectures. Some other
    structures also benefit from this size reduction (struct ipq in
    ipv4/ip_fragment.c, struct frag_queue in ipv6/reassembly.c, ...)

    Once this ktime infrastructure adopted, we can more easily provide
    nanosecond resolution on top of it. (ioctl SIOCGSTAMPNS and/or
    SO_TIMESTAMPNS/SCM_TIMESTAMPNS)

    Note : this patch includes a bug correction in
    compat_sock_get_timestamp() where a "err = 0;" was missing (so this
    syscall returned -ENOENT instead of 0)

    Signed-off-by: Eric Dumazet
    CC: Stephen Hemminger
    CC: John find
    Signed-off-by: David S. Miller

    Eric Dumazet
     

13 Feb, 2007

2 commits


03 Dec, 2006

3 commits


16 Nov, 2006

1 commit

  • Based on patch by James D. Nurmi:

    I've got some code very dependant on nfnetlink_queue, and turned up a
    large number of warns coming from skb_trim. While it's quite possibly
    my code, having not seen it on older kernels made me a bit suspect.

    Anyhow, based on some googling I turned up this thread:
    http://lkml.org/lkml/2006/8/13/56

    And believe the issue to be related, so attached is a small patch to
    the kernel -- not sure if this is completely correct, but for anyone
    else hitting the WARN_ON(1) in skbuff.h, it might be helpful..

    Signed-off-by: James D. Nurmi

    Ported to ip6_queue and nfnetlink_queue and added return value
    checks.

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

    Patrick McHardy
     

06 Nov, 2006

1 commit


23 Sep, 2006

2 commits


30 Jun, 2006

1 commit


10 Apr, 2006

1 commit


29 Mar, 2006

1 commit

  • Every netfilter module uses `init' for its module_init() function and
    `fini' or `cleanup' for its module_exit() function.

    Problem is, this creates uninformative initcall_debug output and makes
    ctags rather useless.

    So go through and rename them all to $(filename)_init and
    $(filename)_fini.

    Signed-off-by: Andrew Morton
    Signed-off-by: David S. Miller

    Andrew Morton
     

23 Mar, 2006

1 commit


13 Mar, 2006

1 commit


05 Feb, 2006

1 commit


06 Jan, 2006

1 commit


05 Jan, 2006

1 commit


15 Nov, 2005

1 commit

  • This patch unconditionally requires CAP_NET_ADMIN for all nfnetlink
    messages. It also removes the per-message cap_required field, since all
    existing subsystems use CAP_NET_ADMIN for all their messages anyway.

    Patrick McHardy owes me a beer if we ever need to re-introduce this.

    Signed-off-by: Harald Welte
    Signed-off-by: David S. Miller

    Harald Welte
     

06 Nov, 2005

1 commit


04 Oct, 2005

1 commit

  • I've found the problem in general. It affects any 64-bit
    architecture. The problem occurs when you change the system time.

    Suppose that when you boot your system clock is forward by a day.
    This gets recorded down in skb_tv_base. You then wind the clock back
    by a day. From that point onwards the offset will be negative which
    essentially overflows the 32-bit variables they're stored in.

    In fact, why don't we just store the real time stamp in those 32-bit
    variables? After all, we're not going to overflow for quite a while
    yet.

    When we do overflow, we'll need a better solution of course.

    Signed-off-by: Herbert Xu
    Signed-off-by: David S. Miller

    Herbert Xu
     

07 Sep, 2005

1 commit


06 Sep, 2005

2 commits


30 Aug, 2005

1 commit