1. 16 11月, 2011 5 次提交
  2. 07 11月, 2011 2 次提交
  3. 02 11月, 2011 1 次提交
  4. 01 11月, 2011 2 次提交
  5. 25 10月, 2011 1 次提交
  6. 20 10月, 2011 1 次提交
    • D
      TTY: serial_core: Fix crash if DCD drop during suspend · d208a3bf
      Doug Anderson 提交于
      This crash was showing up 100% of the time on Tegra CPUs when an
      agetty was running on the serial port and the console was not running
      on the serial port.  The reason the Tegra saw it so reliably is that
      the Tegra CPU internally ties DTR to DCD/DSR.  That means when we
      dropped DTR during suspend we would get always get an immediate DCD
      drop.
      
      The specific order of operations that were running:
      * uart_suspend_port() would be called to put the uart in suspend mode
      * we'd drop DTR (ops->set_mctrl(uport, 0)).
      * the DTR drop would be looped back in the CPU to be a DCD drop.
      * the DCD drop would look to the serial driver as a hangup
      * the hangup would call uart_shutdown()
      * ... suspend / resume happens ...
      * uart_resume_port() would be called and run the code in the
        (port->flags & ASYNC_SUSPENDED) block, which would startup the port
        (and enable tx again).
      * Since the UART would be available for tx, we'd immediately get
        an interrupt, eventually calling transmit_chars()
      * The transmit_chars() function would crash.  The first crash would
        be a dereference of a NULL tty member, but since the port has been
        shutdown that was just a symptom.
      
      I have proposed a patch that would fix the Tegra CPUs here (see
      https://lkml.org/lkml/2011/10/11/444 - tty/serial: Prevent drop of DCD
      on suspend for Tegra UARTs).  However, even with that fix it is still
      possible for systems that have an externally visible DCD line to see a
      crash if the DCD drops at just the right time during suspend: thus
      this patch is still useful.
      Signed-off-by: NDoug Anderson <dianders@chromium.org>
      Acked-by: NAlan Cox <alan@linux.intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      d208a3bf
  7. 19 10月, 2011 13 次提交
  8. 17 10月, 2011 1 次提交
    • H
      PM / VT: Cleanup #if defined uglyness and fix compile error · 37cce26b
      H Hartley Sweeten 提交于
      Introduce the config option CONFIG_VT_CONSOLE_SLEEP in order to cleanup
      the #if defined ugliness for the vt suspend support functions. Note that
      CONFIG_VT_CONSOLE is already dependant on CONFIG_VT.
      
      The function pm_set_vt_switch is actually dependant on CONFIG_VT and not
      CONFIG_PM_SLEEP. This fixes a compile error when CONFIG_PM_SLEEP is
      not set:
      
      drivers/tty/vt/vt_ioctl.c:1794: error: redefinition of 'pm_set_vt_switch'
      include/linux/suspend.h:17: error: previous definition of 'pm_set_vt_switch' was here
      
      Also, remove the incorrect path from the comment in console.c.
      
      [rjw: Replaced #if defined() with #ifdef in suspend.h.]
      Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com>
      Acked-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      37cce26b
  9. 13 10月, 2011 1 次提交
  10. 06 10月, 2011 1 次提交
    • G
      devicetree: fix build error on drivers/tty/serial/altera_jtaguart.c · 6b3754d6
      Grant Likely 提交于
      This patch fixes the following build error caused by commit
      85888069 ("tty: use of_match_ptr() for of_match_table entry").
      The problem was a missing #include <linux/of.h> which is where
      of_match_ptr() is defined.
      
      drivers/tty/serial/altera_jtaguart.c:483:3: error: implicit declaration of function 'of_match_ptr' [-Werror=implicit-function-declaration]
      drivers/tty/serial/altera_jtaguart.c:483:34: error: 'altera_jtaguart_match' undeclared here (not in a function)
      Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
      Cc: Ben Dooks <ben-linux@fluff.org>
      Cc: Tobias Klauser <tklauser@distanz.ch> (maintainer:ALTERA UART/JTAG...)
      Cc: Alan Cox <alan@linux.intel.com> (maintainer:SERIAL DRIVERS)
      6b3754d6
  11. 30 9月, 2011 2 次提交
  12. 27 9月, 2011 7 次提交
  13. 23 9月, 2011 3 次提交
    • Y
      TTY: irq: Remove IRQF_DISABLED · 9cfb5c05
      Yong Zhang 提交于
      Since commit [e58aa3d2: genirq: Run irq handlers with interrupts disabled],
      We run all interrupt handlers with interrupts disabled
      and we even check and yell when an interrupt handler
      returns with interrupts enabled (see commit [b738a50a:
      genirq: Warn when handler enables interrupts]).
      
      So now this flag is a NOOP and can be removed.
      Signed-off-by: NYong Zhang <yong.zhang0@gmail.com>
      Acked-by: NTobias Klauser <tklauser@distanz.ch>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      9cfb5c05
    • N
      serial-core: power up uart port early before we do set_termios when resuming · 94abc56f
      Ning Jiang 提交于
      The following patch removed uart_change_pm() in uart_resume_port():
      
      commit 5933a161
      Author: Yin Kangkai <kangkai.yin@linux.intel.com>
          serial-core: reset the console speed on resume
      
      It will break the pxa serial driver when the system resumes from suspend mode
      as it will try to set baud rate divider register in set_termios but with
      clock off. The register value can not be set correctly on some platform if
      the clock is disabled. The pxa driver will check the value and report the
      following warning:
      
      ------------[ cut here ]------------
      WARNING: at drivers/tty/serial/pxa.c:545 serial_pxa_set_termios+0x1dc/0x250()
      Modules linked in:
      [<c0281f30>] (unwind_backtrace+0x0/0xf0) from [<c029341c>] (warn_slowpath_common+0x4c/0x64)
      [<c029341c>] (warn_slowpath_common+0x4c/0x64) from [<c029344c>] (warn_slowpath_null+0x18/0x1c)
      [<c029344c>] (warn_slowpath_null+0x18/0x1c) from [<c044b1e4>] (serial_pxa_set_termios+0x1dc/0x250)
      [<c044b1e4>] (serial_pxa_set_termios+0x1dc/0x250) from [<c044a840>] (uart_resume_port+0x128/0x2dc)
      [<c044a840>] (uart_resume_port+0x128/0x2dc) from [<c044bbe0>] (serial_pxa_resume+0x18/0x24)
      [<c044bbe0>] (serial_pxa_resume+0x18/0x24) from [<c0454d34>] (platform_pm_resume+0x40/0x4c)
      [<c0454d34>] (platform_pm_resume+0x40/0x4c) from [<c0457ebc>] (pm_op+0x68/0xb4)
      [<c0457ebc>] (pm_op+0x68/0xb4) from [<c0458368>] (device_resume+0xb0/0xec)
      [<c0458368>] (device_resume+0xb0/0xec) from [<c04584c8>] (dpm_resume+0xe0/0x194)
      [<c04584c8>] (dpm_resume+0xe0/0x194) from [<c0458588>] (dpm_resume_end+0xc/0x18)
      [<c0458588>] (dpm_resume_end+0xc/0x18) from [<c02c518c>] (suspend_devices_and_enter+0x16c/0x1ac)
      [<c02c518c>] (suspend_devices_and_enter+0x16c/0x1ac) from [<c02c5278>] (enter_state+0xac/0xdc)
      [<c02c5278>] (enter_state+0xac/0xdc) from [<c02c48ec>] (state_store+0xa0/0xbc)
      [<c02c48ec>] (state_store+0xa0/0xbc) from [<c0408f7c>] (kobj_attr_store+0x18/0x1c)
      [<c0408f7c>] (kobj_attr_store+0x18/0x1c) from [<c034a6a4>] (sysfs_write_file+0x108/0x140)
      [<c034a6a4>] (sysfs_write_file+0x108/0x140) from [<c02fb798>] (vfs_write+0xac/0x134)
      [<c02fb798>] (vfs_write+0xac/0x134) from [<c02fb8cc>] (sys_write+0x3c/0x68)
      [<c02fb8cc>] (sys_write+0x3c/0x68) from [<c027c700>] (ret_fast_syscall+0x0/0x2c)
      ---[ end trace 88289eceb4675b04 ]---
      
      This patch fix the problem by adding the power on opertion back for uart
      console when console_suspend_enabled is true.
      Signed-off-by: NNing Jiang <ning.jiang@marvell.com>
      Tested-by: NMayank Rana <mrana@codeaurora.org>
      Cc: stable <stable@kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      94abc56f
    • A
      serial: mfd: Initconst section fixes · 153d3d9b
      Andi Kleen 提交于
      Cc: gregkh@suse.de
      Signed-off-by: NAndi Kleen <ak@linux.intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      153d3d9b