1. 26 Mar, 2007 13 commits
    • Patrick McHardy's avatar
      [NET_SCHED]: cls_basic: fix NULL pointer dereference · d3fa76ee
      Patrick McHardy authored
      cls_basic doesn't allocate tp->root before it is linked into the
      active classifier list, resulting in a NULL pointer dereference
      when packets hit the classifier before its ->change function is
      called.
      
      Reported by Chris Madden <chris@reflexsecurity.com>
      Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d3fa76ee
    • Adrian Bunk's avatar
      [DCCP]: make dccp_write_xmit_timer() static again · c93a882e
      Adrian Bunk authored
      dccp_write_xmit_timer() needlessly became global.
      Signed-off-by: default avatarAdrian Bunk <bunk@stusta.de>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c93a882e
    • Michael Chan's avatar
      [TG3]: Update version and reldate. · 20bd7dd4
      Michael Chan authored
      Update version to 3.75.
      Signed-off-by: default avatarMichael Chan <mchan@broadcom.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      20bd7dd4
    • Michael Chan's avatar
      [TG3]: Exit irq handler during chip reset. · d18edcb2
      Michael Chan authored
      On most tg3 chips, the memory enable bit in the PCI command register
      gets cleared during chip reset and must be restored before accessing
      PCI registers using memory cycles.  The chip does not generate
      interrupt during chip reset, but the irq handler can still be called
      because of irq sharing or irqpoll.  Reading a register in the irq
      handler can cause a master abort in this scenario and may result in a
      crash on some architectures.
      
      Use the TG3_FLAG_CHIP_RESETTING flag to tell the irq handler to exit
      without touching any registers.  The checking of the flag is in the
      "slow" path of the irq handler and will not affect normal performance.
      The msi handler is not shared and therefore does not require checking
      the flag.
      
      Thanks to Bernhard Walle <bwalle@suse.de> for reporting the problem.
      Signed-off-by: default avatarMichael Chan <mchan@broadcom.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d18edcb2
    • Michael Chan's avatar
      [TG3]: Eliminate the unused TG3_FLAG_SPLIT_MODE flag. · 1c46ae05
      Michael Chan authored
      This flag to support multiple PCIX split completions was never used
      because of hardware bugs.  This will make room for a new flag.
      Signed-off-by: default avatarMichael Chan <mchan@broadcom.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1c46ae05
    • David S. Miller's avatar
      [IPV6]: Fix routing round-robin locking. · f11e6659
      David S. Miller authored
      As per RFC2461, section 6.3.6, item #2, when no routers on the
      matching list are known to be reachable or probably reachable we
      do round robin on those available routes so that we make sure
      to probe as many of them as possible to detect when one becomes
      reachable faster.
      
      Each routing table has a rwlock protecting the tree and the linked
      list of routes at each leaf.  The round robin code executes during
      lookup and thus with the rwlock taken as a reader.  A small local
      spinlock tries to provide protection but this does not work at all
      for two reasons:
      
      1) The round-robin list manipulation, as coded, goes like this (with
         read lock held):
      
      	walk routes finding head and tail
      
      	spin_lock();
      	rotate list using head and tail
      	spin_unlock();
      
         While one thread is rotating the list, another thread can
         end up with stale values of head and tail and then proceed
         to corrupt the list when it gets the lock.  This ends up causing
         the OOPS in fib6_add() later onthat many people have been hitting.
      
      2) All the other code paths that run with the rwlock held as
         a reader do not expect the list to change on them, they
         expect it to remain completely fixed while they hold the
         lock in that way.
      
      So, simply stated, it is impossible to implement this correctly using
      a manipulation of the list without violating the rwlock locking
      semantics.
      
      Reimplement using a per-fib6_node round-robin pointer.  This way we
      don't need to manipulate the list at all, and since the round-robin
      pointer can only ever point to real existing entries we don't need
      to perform any locking on the changing of the round-robin pointer
      itself.  We only need to reset the round-robin pointer to NULL when
      the entry it is pointing to is removed.
      
      The idea is from Thomas Graf and it is very similar to how this
      was implemented before the advanced router selection code when in.
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f11e6659
    • Thomas Graf's avatar
      [DECNet] fib: Fix out of bound access of dn_fib_props[] · a9791011
      Thomas Graf authored
      Fixes a typo which caused fib_props[] to have the wrong size
      and makes sure the value used to index the array which is
      provided by userspace via netlink is checked to avoid out of
      bound access.
      Signed-off-by: default avatarThomas Graf <tgraf@suug.ch>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a9791011
    • Thomas Graf's avatar
      [IPv4] fib: Fix out of bound access of fib_props[] · a0ee18b9
      Thomas Graf authored
      Fixes a typo which caused fib_props[] to have the wrong size
      and makes sure the value used to index the array which is
      provided by userspace via netlink is checked to avoid out of
      bound access.
      Signed-off-by: default avatarThomas Graf <tgraf@suug.ch>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a0ee18b9
    • Ralf Baechle's avatar
      [NET] AX.25 Kconfig and docs updates and fixes · 954b2e7f
      Ralf Baechle authored
       o The AX.25 Howto is unmaintained since several years.  I've replaced it
         with a wiki at http://www.linux-ax25.org which provides more uptodate
         information.
       o Change default for AX25_DAMA_SLAVE to Y.  AX25_DAMA_SLAVE only compiles
         in support for DAMA but doesn't activate it.  I hope this gets Linux
         distributions to ship their AX.25 kernels with AX25_DAMA_SLAVE enabled.
         The price for this would be very small.
       o Delete historic changelog from comments, that's what SCM systems are
         meant to do.
       o ---help--- in Kconfig looks so yellingly eye insulting.  Use just help.
       o Rewrite the commented out piece of old Linux 2.4 configuration language
         to Kconfig for consistency.
       o Fixup dependencies.
      Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      954b2e7f
    • Alexey Kuznetsov's avatar
      [NET]: Fix neighbour destructor handling. · ecbb4169
      Alexey Kuznetsov authored
      ->neigh_destructor() is killed (not used), replaced with
      ->neigh_cleanup(), which is called when neighbor entry goes to dead
      state. At this point everything is still valid: neigh->dev,
      neigh->parms etc.
      
      The device should guarantee that dead neighbor entries (neigh->dead !=
      0) do not get private part initialized, otherwise nobody will cleanup
      it.
      
      I think this is enough for ipoib which is the only user of this thing.
      Initialization private part of neighbor entries happens in ipib
      start_xmit routine, which is not reached when device is down.  But it
      would be better to add explicit test for neigh->dead in any case.
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ecbb4169
    • Thomas Graf's avatar
      [NET]: Fix fib_rules compatibility breakage · e1701c68
      Thomas Graf authored
      Based upon a patch from Patrick McHardy.
      
      The fib_rules netlink attribute policy introduced in 2.6.19 broke
      userspace compatibilty. When specifying a rule with "from all"
      or "to all", iproute adds a zero byte long netlink attribute,
      but the policy requires all addresses to have a size equal to
      sizeof(struct in_addr)/sizeof(struct in6_addr), resulting in a
      validation error.
      
      Check attribute length of FRA_SRC/FRA_DST in the generic framework
      by letting the family specific rules implementation provide the
      length of an address. Report an error if address length is non
      zero but no address attribute is provided. Fix actual bug by
      checking address length for non-zero instead of relying on
      availability of attribute.
      Signed-off-by: default avatarThomas Graf <tgraf@suug.ch>
      Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e1701c68
    • Sridhar Samudrala's avatar
      [SCTP]: Update SCTP Maintainers entry · 5f85813c
      Sridhar Samudrala authored
      Add Vlad Yasevich as the primary maintainer of SCTP and add a
      link to the project website.
      Signed-off-by: default avatarSridhar Samudrala <sri@us.ibm.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5f85813c
    • Robert P. J. Day's avatar
      [NET]: remove unused header file: drivers/net/wan/lmc/lmc_media.h · ea3d0d77
      Robert P. J. Day authored
      Signed-off-by: default avatarRobert P. J. Day <rpjday@mindspring.com>
      Cc: Krzysztof Halasa <khc@pm.waw.pl>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ea3d0d77
  2. 25 Mar, 2007 4 commits
  3. 24 Mar, 2007 15 commits
  4. 23 Mar, 2007 8 commits
    • Roland McGrath's avatar
      [PATCH] i386: clear segment register padding in core dumps · 6ea65ff7
      Roland McGrath authored
      The segment register slots in struct pt_regs are padded to 32 bits.
      Some of these are stored with instructions like "pushl %es", which
      leaves the high 16 bits as they were.  So the high bits of these
      fields in struct pt_regs contain kernel stack garbage.  These bits are
      ignored by everything and never leak to user space, except in core
      dumps.  The user struct pt_regs is always at the base of the thread's
      kernel stack and so it seems unlikely the information that leaks from
      here is ever worthwhile so as to be a security concern, but I'm not
      sure about that.  It has been this way for ages; userland consumers of
      core dumps all mask off these high bits themselves.  So it is not urgent.
      
      This change masks off the padding bits of the segment register slots
      in core dumps.  ptrace already masks off these high bits, so this
      makes the values in core dumps consistent with what ptrace would
      report just before the process died.
      
      As I read the processor manuals, the cs and ss values will always be
      padded with zero bits rather than stack garbage.  But unlike "pushl %es",
      this is not simple to test with a userland program.  So I added the two
      instructions rather than wonder if they are really never necessary.
      
      I think that x86_64 does not have this problem (for either 32-bit or
      64-bit processes).  It only uses "mov" instructions from segment
      registers, which zero-extend.
      Signed-off-by: default avatarRoland McGrath <roland@redhat.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6ea65ff7
    • Linus Torvalds's avatar
      x86-64: add "local_apic_timer_c2_ok" here too · 2e7c2838
      Linus Torvalds authored
      Needed for any architecture that claims ARCH_APICTIMER_STOPS_ON_C3,
      not just i386.
      
      I'm hoping Thomas will clean this up a bit later..
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      2e7c2838
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6 · cad6a84a
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6:
        ieee1394: fix oops on "modprobe -r ohci1394" after network class_device conversion
      cad6a84a
    • Linus Torvalds's avatar
      Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6 · 0ab602e5
      Linus Torvalds authored
      * 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6:
        [netdrvr] ewrk3: correct card detection bug
        cxgb3 - fix white spaces in drivers/net/Kconfig
        myri10ge: update driver version to 1.3.0-1.226
        myri10ge: fix management of >4kB allocated pages
        myri10ge: update wcfifo and intr_coal_delay default values
        myri10ge: Serverworks HT2100 provides aligned PCIe completion
        mv643xx_eth: add mv643xx_eth_shutdown function
        SAA9730: Fix large pile of warnings
        Revert "ucc_geth: returns NETDEV_TX_BUSY when BD ring is full"
        cxgb3 - T3B2 pcie config space
        cxgb3 - Fix potential MAC hang
        cxgb3 - Auto-load FW if mismatch detected
        cxgb3 - fix ethtool cmd on multiple queues port
        Fix return code in pci-skeleton.c
        skge: use per-port phy locking
        skge: mask irqs when device down
        skge: deadlock on tx timeout
        [PATCH] airo: Fix an error path memory leak
        [PATCH] bcm43xx: MANUALWLAN fixes
      0ab602e5
    • Andrew Morton's avatar
      [PATCH] "ext[34]: EA block reference count racing fix" performance fix · 105fd108
      Andrew Morton authored
      A little mistake in 8a2bfdcb is making all
      transactions synchronous, which reduces ext3 performance to comical levels.
      
      Cc: Mingming Cao <cmm@us.ibm.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      105fd108
    • Guido Guenther's avatar
      [PATCH] rivafb: fix initial brightness · cee9e8c5
      Guido Guenther authored
      This is the rivafb equivalent of 238576e1.
      It fixes rivafb having a default backlight brightness of 0 (no picture at
      all) on a PBook 6,1.
      Signed-off-by: default avatarGuido Guenther <agx@sigxcpu.org>
      Cc: "Antonino A. Daplas" <adaplas@pol.net>
      Acked-by: default avatarRichard Purdie <rpurdie@rpsys.net>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      cee9e8c5
    • Danny Kukawka's avatar
      [PATCH] add Fujitsu Siemens Tablet PC devices to 8250_pnp.c · 6149dd5c
      Danny Kukawka authored
      Adds device ids of two Fujitsu Siemens Tablet PCs to pnp_dev_table
      Signed-off-by: default avatarDanny Kukawka <dkukawka@suse.de>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6149dd5c
    • David Howells's avatar
      [PATCH] FDPIC: fix the /proc/pid/stat representation of executable boundaries · aa289b47
      David Howells authored
      Fix the /proc/pid/stat representation of executable boundaries.  It should
      show the bounds of the executable, but instead shows the bounds of the
      loader.
      
      Before the patch is applied, the bug can be seen by examining, say, inetd:
      
      	# ps | grep inetd
      	  610         root          0   S   /usr/sbin/inetd -i
      	# cat /proc/610/maps
      	c0bb0000-c0bba788 r-xs 00000000 00:0b 14582157  /lib/ld-uClibc-0.9.28.so
      	c3180000-c31dede4 r-xs 00000000 00:0b 14582179  /lib/libuClibc-0.9.28.so
      	c328c000-c328ea00 rw-p 00008000 00:0b 14582157  /lib/ld-uClibc-0.9.28.so
      	c3290000-c329b6c0 rw-p 00000000 00:00 0
      	c32a0000-c32c0000 rwxp 00000000 00:00 0
      	c32d4000-c32d8000 rw-p 00000000 00:00 0
      	c3394000-c3398000 rw-p 00000000 00:00 0
      	c3458000-c345f464 r-xs 00000000 00:0b 16384612  /usr/sbin/inetd
      	c3470000-c34748f8 rw-p 00004000 00:0b 16384612  /usr/sbin/inetd
      	c34cc000-c34d0000 rw-p 00000000 00:00 0
      	c34d4000-c34d8000 rw-p 00000000 00:00 0
      	c34d8000-c34dc000 rw-p 00000000 00:00 0
      	# cat /proc/610/stat
      	610 (inetd) S 1 610 610 0 -1 256 0 0 0 0 0 8 0 0 19 0 1 0 94392000718
      	950272 0 4294967295 3233480704 3233523592 3274440352 3274439976
       	3273467584 0 0 4096 90115 3221712796 0 0 17 0 0 0 0
      
      The code boundaries are 3233480704 to 3233523592, which are:
      
      	(gdb) p/x 3233480704
      	$1 = 0xc0bb0000
      	(gdb) p/x 3233523592
      	$2 = 0xc0bba788
      
      Which corresponds to this line in the maps file:
      
      	c0bb0000-c0bba788 r-xs 00000000 00:0b 14582157  /lib/ld-uClibc-0.9.28.so
      
      Which is wrong.  After the patch is applied, the maps file is pretty much
      identical (there's some minor shuffling of the location of some of the
      anonymous VMAs), but the stat file is now:
      
      	# cat /proc/610/stat
      	610 (inetd) S 1 610 610 0 -1 256 0 0 0 0 0 7 0 0 18 0 1 0 94392000722
      	950272 0 4294967295 3276111872 3276141668 3274440352 3274439976
      	3273467584 0 0 4096 90115 3221712796 0 0 17 0 0 0 0
      
      The code boundaries are then 3276111872 to 3276141668, which are:
      
      	(gdb) p/x 3276111872
      	$1 = 0xc3458000
      	(gdb) p/x 3276141668
      	$2 = 0xc345f464
      
      And these correspond to this line in the maps file instead:
      
      	c3458000-c345f464 r-xs 00000000 00:0b 16384612  /usr/sbin/inetd
      
      Which is now correct.
      Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      aa289b47