Skip to content
Snippets Groups Projects
  1. Nov 10, 2008
    • Wang Chen's avatar
      netdevice libertas: Fix directly reference of netdev->priv · 4ceb7b6a
      Wang Chen authored
      
      We have some reasons to kill netdev->priv:
      1. netdev->priv is equal to netdev_priv().
      2. netdev_priv() wraps the calculation of netdev->priv's offset, obviously
         netdev_priv() is more flexible than netdev->priv.
      But we cann't kill netdev->priv, because so many drivers reference to it
      directly.
      
      OK, becasue Dave S. Miller said, "every direct netdev->priv usage is a bug",
      and I want to kill netdev->priv later, I decided to convert all the direct
      reference of netdev->priv first.
      
      Different to readonly reference of netdev->priv, in this driver, netdev->priv
      was changed. I use netdev->ml_priv to replace netdev->priv.
      
      Signed-off-by: default avatarWang Chen <wangchen@cn.fujitsu.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      4ceb7b6a
  2. Nov 07, 2008
    • Thomas Graf's avatar
      pkt_sched: Control group classifier · f4009237
      Thomas Graf authored
      
      The classifier should cover the most common use case and will work
      without any special configuration.
      
      The principle of the classifier is to directly access the
      task_struct via get_current(). In order for this to work,
      classification requests from softirqs must be ignored. This is
      not a problem because the vast majority of packets in softirq
      context are not assigned to a task anyway. For this to work, a
      mechanism is needed to trace softirq context. 
      
      This repost goes back to the method of relying on the number of
      nested bh disable calls for the sake of not adding too much
      complexity and the option to come up with something more reliable
      if actually needed.
      
      Signed-off-by: default avatarThomas Graf <tgraf@suug.ch>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f4009237
    • Eric W. Biederman's avatar
      net: Guaranetee the proper ordering of the loopback device. v2 · 505d4f73
      Eric W. Biederman authored
      
      I was recently hunting a bug that occurred in network namespace
      cleanup.  In looking at the code it became apparrent that we have
      and will continue to have cases where if we have anything going
      on in a network namespace there will be assumptions that the
      loopback device is present.   Things like sending igmp unsubscribe
      messages when we bring down network devices invokes the routing
      code which assumes that at least the loopback driver is present.
      
      Therefore to avoid magic initcall ordering hackery that is hard
      to follow and hard to get right insert a call to register the
      loopback device directly from net_dev_init().    This guarantes
      that the loopback device is the first device registered and
      the last network device to go away.
      
      But do it carefully so we register the loopback device after
      we clear dev_boot_phase.
      
      Signed-off-by: default avatarEric W. Biederman <ebiederm@maxwell.aristanetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      505d4f73
    • Eric W. Biederman's avatar
      net: fib_rules ordering fixes. · 5d6d4809
      Eric W. Biederman authored
      
      We need to setup the network namespace state before we register
      the notifier.  Otherwise if a network device is already registered
      we get a nasty NULL pointer dereference.
      
      Signed-off-by: default avatarEric W. Biederman <ebiederm@maxwell.aristanetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5d6d4809
    • David S. Miller's avatar
      3d8160b1
    • David S. Miller's avatar
    • Komuro's avatar
      fmvj18x_cs: write interrupt ack bit for lan and modem to work simultaneously. · a8272061
      Komuro authored
      
      Write interrupt ack bit in fjn_interrupt for lan and modem to work
      simultaneously.
      
      Signed-off-by: default avatarKomuro <komurojun-mbn@nifty.com>
      Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
      a8272061
    • Harvey Harrison's avatar
      phonet: sparse annotations of protocol, remove forward declaration · 5c7f0333
      Harvey Harrison authored
      
      net/phonet/af_phonet.c:38:36: error: marked inline, but without a definition
      net/phonet/pep-gprs.c:63:10: warning: incorrect type in return expression (different base types)
      net/phonet/pep-gprs.c:63:10:    expected int
      net/phonet/pep-gprs.c:63:10:    got restricted __be16 [usertype] <noident>
      net/phonet/pep-gprs.c:65:10: warning: incorrect type in return expression (different base types)
      net/phonet/pep-gprs.c:65:10:    expected int
      net/phonet/pep-gprs.c:65:10:    got restricted __be16 [usertype] <noident>
      net/phonet/pep-gprs.c:124:16: warning: incorrect type in assignment (different base types)
      net/phonet/pep-gprs.c:124:16:    expected restricted __be16 [usertype] protocol
      net/phonet/pep-gprs.c:124:16:    got unsigned short [unsigned] [usertype] protocol
      
      Signed-off-by: default avatarHarvey Harrison <harvey.harrison@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5c7f0333
    • Harvey Harrison's avatar
      ipvs: oldlen, newlen should be be16, not be32 · ca62059b
      Harvey Harrison authored
      
      Noticed by sparse:
      net/netfilter/ipvs/ip_vs_proto_tcp.c:195:6: warning: incorrect type in argument 5 (different base types)
      net/netfilter/ipvs/ip_vs_proto_tcp.c:195:6:    expected restricted __be16 [usertype] oldlen
      net/netfilter/ipvs/ip_vs_proto_tcp.c:195:6:    got restricted __be32 [usertype] <noident>
      net/netfilter/ipvs/ip_vs_proto_tcp.c:196:6: warning: incorrect type in argument 6 (different base types)
      net/netfilter/ipvs/ip_vs_proto_tcp.c:196:6:    expected restricted __be16 [usertype] newlen
      net/netfilter/ipvs/ip_vs_proto_tcp.c:196:6:    got restricted __be32 [usertype] <noident>
      net/netfilter/ipvs/ip_vs_proto_tcp.c:270:6: warning: incorrect type in argument 5 (different base types)
      net/netfilter/ipvs/ip_vs_proto_tcp.c:270:6:    expected restricted __be16 [usertype] oldlen
      net/netfilter/ipvs/ip_vs_proto_tcp.c:270:6:    got restricted __be32 [usertype] <noident>
      net/netfilter/ipvs/ip_vs_proto_tcp.c:271:6: warning: incorrect type in argument 6 (different base types)
      net/netfilter/ipvs/ip_vs_proto_tcp.c:271:6:    expected restricted __be16 [usertype] newlen
      net/netfilter/ipvs/ip_vs_proto_tcp.c:271:6:    got restricted __be32 [usertype] <noident>
      net/netfilter/ipvs/ip_vs_proto_udp.c:206:6: warning: incorrect type in argument 5 (different base types)
      net/netfilter/ipvs/ip_vs_proto_udp.c:206:6:    expected restricted __be16 [usertype] oldlen
      net/netfilter/ipvs/ip_vs_proto_udp.c:206:6:    got restricted __be32 [usertype] <noident>
      net/netfilter/ipvs/ip_vs_proto_udp.c:207:6: warning: incorrect type in argument 6 (different base types)
      net/netfilter/ipvs/ip_vs_proto_udp.c:207:6:    expected restricted __be16 [usertype] newlen
      net/netfilter/ipvs/ip_vs_proto_udp.c:207:6:    got restricted __be32 [usertype] <noident>
      net/netfilter/ipvs/ip_vs_proto_udp.c:282:6: warning: incorrect type in argument 5 (different base types)
      net/netfilter/ipvs/ip_vs_proto_udp.c:282:6:    expected restricted __be16 [usertype] oldlen
      net/netfilter/ipvs/ip_vs_proto_udp.c:282:6:    got restricted __be32 [usertype] <noident>
      net/netfilter/ipvs/ip_vs_proto_udp.c:283:6: warning: incorrect type in argument 6 (different base types)
      net/netfilter/ipvs/ip_vs_proto_udp.c:283:6:    expected restricted __be16 [usertype] newlen
      net/netfilter/ipvs/ip_vs_proto_udp.c:283:6:    got restricted __be32 [usertype] <noident>
      
      Signed-off-by: default avatarHarvey Harrison <harvey.harrison@gmail.com>
      Acked-by: default avatarSimon Horman <horms@verge.net.au>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ca62059b
    • Alexey Dobriyan's avatar
      net: mark flow_cache_cpu_prepare() as __init · 76acfdb9
      Alexey Dobriyan authored
      
      It's called from __init code only. And__devinit in generic networking code
      is pretty strange :^)
      
      Signed-off-by: default avatarAlexey Dobriyan <adobriyan@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      76acfdb9
  3. Nov 06, 2008
Loading