1. 23 Aug, 2006 6 commits
    • Diego Calleja's avatar
      Fix BeFS slab corruption · 2fc58b11
      Diego Calleja authored
      In bugzilla #6941, Jens Kilian reported:
      
      "The function befs_utf2nls (in fs/befs/linuxvfs.c) writes a 0 byte past the
      end of a block of memory allocated via kmalloc(), leading to memory
      corruption.  This happens only for filenames which are pure ASCII and a
      multiple of 4 bytes in length.  [...]
      
      Without DEBUG_SLAB, this leads to further corruption and hard lockups; I
      believe this is the bug which has made kernels later than 2.6.8 unusable
      for me.  (This must be due to changes in memory management, the bug has
      been in the BeFS driver since the time it was introduced (AFAICT).)
      
      Steps to reproduce:
      Create a directory (in BeOS, naturally :-) with files named, e.g.,
      "1", "22", "333", "4444", ...  Mount it in Linux and do an "ls" or "find""
      
      This patch implements the suggested fix. Credits to Jens Kilian for
      debugging the problem and finding the right fix.
      Signed-off-by: default avatarDiego Calleja <diegocg@gmail.com>
      Cc: Jens Kilian <jjk@acm.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      2fc58b11
    • David Miller's avatar
      Fix IFLA_ADDRESS handling · 216cf62f
      David Miller authored
      [RTNETLINK]: Fix IFLA_ADDRESS handling.
      
      The ->set_mac_address handlers expect a pointer to a
      sockaddr which contains the MAC address, whereas
      IFLA_ADDRESS provides just the MAC address itself.
      
      So whip up a sockaddr to wrap around the netlink
      attribute for the ->set_mac_address call.
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      216cf62f
    • Dmitry Mishin's avatar
      Fix timer race in dst GC code · 7e9d4f4f
      Dmitry Mishin authored
      [NET]: add_timer -> mod_timer() in dst_run_gc()
      
      Patch from Dmitry Mishin <dim@openvz.org>:
      
      Replace add_timer() by mod_timer() in dst_run_gc
      in order to avoid BUG message.
      
         CPU1                            CPU2
      dst_run_gc()  entered           dst_run_gc() entered
      spin_lock(&dst_lock)                   .....
      del_timer(&dst_gc_timer)         fail to get lock
         ....                         mod_timer() <--- puts
      					     timer back
      					     to the list
      add_timer(&dst_gc_timer) <--- BUG because timer is in list already.
      
      Found during OpenVZ internal testing.
      
      At first we thought that it is OpenVZ specific as we
      added dst_run_gc(0) call in dst_dev_event(),
      but as Alexey pointed to me it is possible to trigger
      this condition in mainstream kernel.
      
      F.e. timer has fired on CPU2, but the handler was preeempted
      by an irq before dst_lock is tried.
      Meanwhile, someone on CPU1 adds an entry to gc list and
      starts the timer.
      If CPU2 was preempted long enough, this timer can expire
      simultaneously with resuming timer handler on CPU1, arriving
      exactly to the situation described.
      Signed-off-by: default avatarDmitry Mishin <dim@openvz.org>
      Signed-off-by: default avatarKirill Korotaev <dev@openvz.org>
      Signed-off-by: default avatarAlexey Kuznetsov <kuznet@ms2.inr.ac.ru>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      7e9d4f4f
    • Kirill Korotaev's avatar
      Kill HASH_HIGHMEM from route cache hash sizing · b3b3410f
      Kirill Korotaev authored
      [IPV4]: Limit rt cache size properly.
      
      During OpenVZ stress testing we found that UDP traffic with random src
      can generate too much excessive rt hash growing leading finally to OOM
      and kernel panics.
      
      It was found that for 4GB i686 system (having 1048576 total pages and
      225280 normal zone pages) kernel allocates the following route hash:
      syslog: IP route cache hash table entries: 262144 (order: 8, 1048576
      bytes) => ip_rt_max_size = 4194304 entries, i.e.  max rt size is
      4194304 * 256b = 1Gb of RAM > normal_zone
      
      Attached the patch which removes HASH_HIGHMEM flag from
      alloc_large_system_hash() call.
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      b3b3410f
    • Stephen Hemminger's avatar
      sky2: phy power problem on 88e805x · 0ce4f0db
      Stephen Hemminger authored
      On the 88E805X chipsets (used in laptops), the PHY was not getting powered
      out of shutdown properly. The variable reg1 was getting reused incorrectly.
      This is probably the cause of the bug.
      	http://bugzilla.kernel.org/show_bug.cgi?id=6471Signed-off-by: default avatarStephen Hemminger <shemminger@osdl.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      0ce4f0db
    • Eric Sandeen's avatar
      Have ext3 reject file handles with bad inode numbers early · bd2a1e11
      Eric Sandeen authored
      blatantly ripped off from Neil Brown's ext2 patch.
      Signed-off-by: default avatarEric Sandeen <sandeen@sandeen.net>
      Acked-by: default avatar"Theodore Ts'o" <tytso@mit.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      bd2a1e11
  2. 22 Aug, 2006 4 commits
  3. 18 Aug, 2006 2 commits
  4. 07 Aug, 2006 24 commits
  5. 25 Jul, 2006 4 commits