1. 22 Mar, 2012 5 commits
    • Jason Wessel's avatar
      kgdb,debug_core: add the ability to control the reboot notifier · bec4d62e
      Jason Wessel authored
      Sometimes it is desirable to stop the kernel debugger before allowing
      a system to reboot either with kdb or kgdb.  This patch adds the
      ability to turn the reboot notifier on and off or enter the debugger
      and stop kernel execution before rebooting.
      
      It is possible to change the setting after booting the kernel with the
      following:
      
      echo 1 > /sys/module/debug_core/parameters/kgdbreboot
      
      It is also possible to change this setting using kdb / kgdb to
      manipulate the variable directly.
      
      Using KDB:
         mm kgdbreboot 1
      
      Using gdb:
         set kgdbreboot=1
      Reported-by: default avatarJan Kiszka <jan.kiszka@siemens.com>
      Signed-off-by: default avatarJason Wessel <jason.wessel@windriver.com>
      bec4d62e
    • Andrei Warkentin's avatar
      KDB: Fix usability issues relating to the 'enter' key. · 8f30d411
      Andrei Warkentin authored
      This fixes the following problems:
      1) Typematic-repeat of 'enter' gives warning message
         and leaks make/break if KDB exits. Repeats
         look something like 0x1c 0x1c .... 0x9c
      2) Use of 'keypad enter' gives warning message and
         leaks the ENTER break/make code out if KDB exits.
         KP ENTER repeats look someting like 0xe0 0x1c
         0xe0 0x1c ... 0xe0 0x9c.
      3) Lag on the order of seconds between "break" and "make" when
         expecting the enter "break" code. Seen under virtualized
         environments such as VMware ESX.
      
      The existing special enter handler tries to glob the enter break code,
      but this fails if the other (KP) enter was used, or if there was a key
      repeat. It also fails if you mashed some keys along with enter, and
      you ended up with a non-enter make or non-enter break code coming
      after the enter make code. So first, we modify the handler to handle
      these cases. But performing these actions on every enter is annoying
      since now you can't hold ENTER down to scroll <more>d messages in
      KDB. Since this special behaviour is only necessary to handle the
      exiting KDB ('g' + ENTER) without leaking scancodes to the OS.  This
      cleanup needs to get executed anytime the kdb_main loop exits.
      
      Tested on QEMU. Set a bp on atkbd.c to verify no scan code was leaked.
      
      Cc: Andrei Warkentin <andreiw@vmware.com>
      [jason.wessel@windriver.com: move cleanup calls to kdb_main.c]
      Signed-off-by: default avatarAndrei Warkentin <andrey.warkentin@gmail.com>
      Signed-off-by: default avatarJason Wessel <jason.wessel@windriver.com>
      8f30d411
    • Jason Wessel's avatar
      kgdb,debug-core,gdbstub: Hook the reboot notifier for debugger detach · 2366e047
      Jason Wessel authored
      The gdbstub and kdb should get detached if the system is rebooting.
      Calling gdbstub_exit() will set the proper debug core state and send a
      message to any debugger that is connected to correctly detach.
      
      An attached debugger will receive the exit code from
      include/linux/reboot.h based on SYS_HALT, SYS_REBOOT, etc...
      Reported-by: default avatarJan Kiszka <jan.kiszka@siemens.com>
      Signed-off-by: default avatarJason Wessel <jason.wessel@windriver.com>
      2366e047
    • Jan Kiszka's avatar
      kgdb: Respect that flush op is optional · 9fbe465e
      Jan Kiszka authored
      Not all kgdb I/O drivers implement a flush operation. Adjust
      gdbstub_exit accordingly.
      Signed-off-by: default avatarJan Kiszka <jan.kiszka@siemens.com>
      Signed-off-by: default avatarJason Wessel <jason.wessel@windriver.com>
      9fbe465e
    • Jan Kiszka's avatar
      kgdb: x86: Return all segment registers also in 64-bit mode · 639077fb
      Jan Kiszka authored
      Even if the content is always 0, gdb expects us to return also ds,
      es, fs, and gs while in x86-64 mode. Do this to avoid ugly errors on
      "info registers".
      
      [jason.wessel@windriver.com: adjust NUMREGBYTES for two new regs]
      Signed-off-by: default avatarJan Kiszka <jan.kiszka@siemens.com>
      Signed-off-by: default avatarJason Wessel <jason.wessel@windriver.com>
      639077fb
  2. 18 Mar, 2012 3 commits
    • Linus Torvalds's avatar
      Linux 3.3 · c16fa4f2
      Linus Torvalds authored
      c16fa4f2
    • Jason Baron's avatar
      Don't limit non-nested epoll paths · 93dc6107
      Jason Baron authored
      Commit 28d82dc1 ("epoll: limit paths") that I did to limit the
      number of possible wakeup paths in epoll is causing a few applications
      to longer work (dovecot for one).
      
      The original patch is really about limiting the amount of epoll nesting
      (since epoll fds can be attached to other fds). Thus, we probably can
      allow an unlimited number of paths of depth 1. My current patch limits
      it at 1000. And enforce the limits on paths that have a greater depth.
      
      This is captured in: https://bugzilla.redhat.com/show_bug.cgi?id=681578Signed-off-by: default avatarJason Baron <jbaron@redhat.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      93dc6107
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · c579bc7e
      Linus Torvalds authored
      Pull networking changes from David Miller:
       "1) icmp6_dst_alloc() returns NULL instead of ERR_PTR() leading to
           crashes, particularly during shutdown.  Reported by Dave Jones and
           fixed by Eric Dumazet.
      
        2) hyperv and wimax/i2400m return NETDEV_TX_BUSY when they have
           already freed the SKB, which causes crashes as to the caller this
           means requeue the packet.  Fixes from Eric Dumazet.
      
        3) usbnet driver doesn't allocate the right amount of headroom on
           fresh RX SKBs, fix from Eric Dumazet.
      
        4) Fix regression in ip6_mc_find_dev_rcu(), as an RCU lookup it
           abolutely should not take a reference to 'dev', this leads to
           leaks.  Fix from RonQing Li.
      
        5) Fix netfilter ctnetlink race between delete and timeout expiration.
           From Pablo Neira Ayuso.
      
        6) Revert SFQ change which causes regressions, specifically queueing
           to tail can lead to unavoidable flow starvation.  From Eric
           Dumazet.
      
        7) Fix a memory leak and a crash on corrupt firmware files in bnx2x,
           from Michal Schmidt."
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net:
        netfilter: ctnetlink: fix race between delete and timeout expiration
        ipv6: Don't dev_hold(dev) in ip6_mc_find_dev_rcu.
        wimax/i2400m: fix erroneous NETDEV_TX_BUSY use
        net/hyperv: fix erroneous NETDEV_TX_BUSY use
        net/usbnet: reserve headroom on rx skbs
        bnx2x: fix memory leak in bnx2x_init_firmware()
        bnx2x: fix a crash on corrupt firmware file
        sch_sfq: revert dont put new flow at the end of flows
        ipv6: fix icmp6_dst_alloc()
      c579bc7e
  3. 17 Mar, 2012 10 commits
  4. 16 Mar, 2012 22 commits