<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/tty/serial, branch v4.4</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v4.4</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.4'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2015-12-25T21:15:23Z</updated>
<entry>
<title>Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc</title>
<updated>2015-12-25T21:15:23Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2015-12-25T21:15:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=682cb0cd82d526b5d1e8ceaccda4d9b7795db553'/>
<id>urn:sha1:682cb0cd82d526b5d1e8ceaccda4d9b7795db553</id>
<content type='text'>
Pull sparc fixes from David Miller:

 1) Finally make perf stack backtraces stable on sparc, several problems
    (mostly due to the context in which the user copies from the stack
    are done) contributed to this.

    From Rob Gardner.

 2) Export ADI capability if the cpu supports it.

 3) Hook up userfaultfd system call.

 4) When faults happen during user copies we really have to clean up and
    restore the FPU state fully.  Also from Rob Gardner

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc:
  tty/serial: Skip 'NULL' char after console break when sysrq enabled
  sparc64: fix FP corruption in user copy functions
  sparc64: Perf should save/restore fault info
  sparc64: Ensure perf can access user stacks
  sparc64: Don't set %pil in rtrap_nmi too early
  sparc64: Add ADI capability to cpu capabilities
  tty: serial: constify sunhv_ops structs
  sparc: Hook up userfaultfd system call
</content>
</entry>
<entry>
<title>tty/serial: Skip 'NULL' char after console break when sysrq enabled</title>
<updated>2015-12-24T17:13:37Z</updated>
<author>
<name>Vijay Kumar</name>
<email>vijay.ac.kumar@oracle.com</email>
</author>
<published>2015-12-23T18:55:33Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=079317a65d05ce52b69b7d47fe1fb419d40a4395'/>
<id>urn:sha1:079317a65d05ce52b69b7d47fe1fb419d40a4395</id>
<content type='text'>
When sysrq is triggered from console, serial driver for SUN hypervisor
console receives a console break and enables the sysrq. It expects a valid
sysrq char following with break. Meanwhile if driver receives 'NULL'
ASCII char then it disables sysrq and sysrq handler will never be invoked.

This fix skips calling uart sysrq handler when 'NULL' is received while
sysrq is enabled.

Signed-off-by: Vijay Kumar &lt;vijay.ac.kumar@oracle.com&gt;
Acked-by: Karl Volz &lt;karl.volz@oracle.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>tty: serial: constify sunhv_ops structs</title>
<updated>2015-12-24T17:04:18Z</updated>
<author>
<name>Aya Mahfouz</name>
<email>mahfouz.saif.elyazal@gmail.com</email>
</author>
<published>2015-12-14T23:37:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=01fd3c2744540ae7554bf098a9615a8310c6fc13'/>
<id>urn:sha1:01fd3c2744540ae7554bf098a9615a8310c6fc13</id>
<content type='text'>
Constifies sunhv_ops structures in tty's serial
driver since they are not modified after their
initialization.

Detected and found using Coccinelle.

Suggested-by: Julia Lawall &lt;Julia.Lawall@lip6.fr&gt;
Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>serial: earlycon: Add missing spinlock initialization</title>
<updated>2015-12-13T07:05:28Z</updated>
<author>
<name>Geert Uytterhoeven</name>
<email>geert+renesas@glider.be</email>
</author>
<published>2015-11-27T10:13:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e1dd3bef6d03c908b173259229b96074d57fccc8'/>
<id>urn:sha1:e1dd3bef6d03c908b173259229b96074d57fccc8</id>
<content type='text'>
If an earlycon console driver needs to acquire the uart_port.lock
spinlock for serial console output, and CONFIG_DEBUG_SPINLOCK=y:

    BUG: spinlock bad magic on CPU#0, swapper/0
     lock: sci_ports+0x0/0x3480, .magic: 00000000, .owner: &lt;none&gt;/-1, .owner_cpu: 0
    CPU: 0 PID: 0 Comm: swapper Not tainted 4.4.0-rc2-koelsch-g62ea5edf143bb1d0-dirty #2083
    Hardware name: Generic R8A7791 (Flattened Device Tree)
    [&lt;c00173a0&gt;] (unwind_backtrace) from [&lt;c0013094&gt;] (show_stack+0x10/0x14)
    [&lt;c0013094&gt;] (show_stack) from [&lt;c01f2338&gt;] (dump_stack+0x70/0x8c)
    [&lt;c01f2338&gt;] (dump_stack) from [&lt;c00702d8&gt;] (do_raw_spin_lock+0x20/0x190)
    [&lt;c00702d8&gt;] (do_raw_spin_lock) from [&lt;c0267590&gt;] (serial_console_write+0x4c/0x130)
    [&lt;c0267590&gt;] (serial_console_write) from [&lt;c00734c4&gt;] (call_console_drivers.constprop.13+0xc8/0xec)
    [&lt;c00734c4&gt;] (call_console_drivers.constprop.13) from [&lt;c0074ef0&gt;] (console_unlock+0x354/0x440)
    [&lt;c0074ef0&gt;] (console_unlock) from [&lt;c0075bb4&gt;] (register_console+0x2a0/0x394)
    [&lt;c0075bb4&gt;] (register_console) from [&lt;c06cb750&gt;] (of_setup_earlycon+0x90/0xa4)
    [&lt;c06cb750&gt;] (of_setup_earlycon) from [&lt;c06cfb60&gt;] (setup_of_earlycon+0x118/0x13c)
    [&lt;c06cfb60&gt;] (setup_of_earlycon) from [&lt;c06b34ac&gt;] (do_early_param+0x64/0xb4)
    [&lt;c06b34ac&gt;] (do_early_param) from [&lt;c00472c0&gt;] (parse_args+0x254/0x350)
    [&lt;c00472c0&gt;] (parse_args) from [&lt;c06b3860&gt;] (parse_early_options+0x2c/0x3c)
    [&lt;c06b3860&gt;] (parse_early_options) from [&lt;c06b389c&gt;] (parse_early_param+0x2c/0x40)
    [&lt;c06b389c&gt;] (parse_early_param) from [&lt;c06b5b08&gt;] (setup_arch+0x520/0xaf0)
    [&lt;c06b5b08&gt;] (setup_arch) from [&lt;c06b3948&gt;] (start_kernel+0x94/0x370)
    [&lt;c06b3948&gt;] (start_kernel) from [&lt;40008090&gt;] (0x40008090)

Initialize the spinlock in of_setup_earlycon() and register_earlycon(),
to fix this for both DT-based and legacy earlycon.  If the driver would
reinitialize the spinlock again, this is harmless, as it's allowed to
reinitialize an unlocked spinlock.

Alternatives are:
  - Drivers having an early_serial_console_write() that only performs
    the core functionality of serial_console_write(), without acquiring
    the lock (which may be unsafe, depending on the hardware),
  - Drivers initializing the spinlock in their private earlycon setup
    functions.

As uart_port is owned by generic serial_core, and uart_port.lock is
initialized by uart_add_one_port() for the normal case, this can better
be handled in the earlycon core.

Signed-off-by: Geert Uytterhoeven &lt;geert+renesas@glider.be&gt;
Reviewed-by: Peter Hurley &lt;peter@hurleysoftware.com&gt;
Reported-by: Bjorn Andersson &lt;bjorn.andersson@sonymobile.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>serial: sh-sci: Fix length of scatterlist</title>
<updated>2015-12-13T05:42:31Z</updated>
<author>
<name>Yoshihiro Shimoda</name>
<email>yoshihiro.shimoda.uh@renesas.com</email>
</author>
<published>2015-12-04T14:21:19Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d09959e7529451a1c302197fb1396ed5b835f6d3'/>
<id>urn:sha1:d09959e7529451a1c302197fb1396ed5b835f6d3</id>
<content type='text'>
This patch fixes an issue that the "length" of scatterlist should be
set using sg_dma_len(). Otherwise, a dmaengine driver cannot work
correctly if CONFIG_NEED_SG_DMA_LENGTH=y.

Fixes: 7b39d90184 (serial: sh-sci: Fix NULL pointer dereference if HIGHMEM is enabled)
Signed-off-by: Yoshihiro Shimoda &lt;yoshihiro.shimoda.uh@renesas.com&gt;
Signed-off-by: Geert Uytterhoeven &lt;geert+renesas@glider.be&gt;
Acked-by: Simon Horman &lt;horms+renesas@verge.net.au&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>serial: 8250_uniphier: fix dl_read and dl_write functions</title>
<updated>2015-12-13T05:42:31Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2015-10-19T04:37:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7be047e035dc4fb1536f1694cbb932f881533ab2'/>
<id>urn:sha1:7be047e035dc4fb1536f1694cbb932f881533ab2</id>
<content type='text'>
The register offset must be shifted by regshift, otherwise the
baudrate is not set.  I missed the issue probably because the
divisor register was already set by the boot loader.

Fixes: 1a8d2903cb6a ("serial: 8250_uniphier: add UniPhier serial driver")
Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>serial: export fsl8250_handle_irq</title>
<updated>2015-11-21T00:19:54Z</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2015-11-16T15:48:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bd63acf9e9a6b48e9c6c15f0f413f85a481cb5ef'/>
<id>urn:sha1:bd63acf9e9a6b48e9c6c15f0f413f85a481cb5ef</id>
<content type='text'>
fsl8250_handle_irq is now used by the of_serial driver, and that fails
if it is a loadable module:

ERROR: "fsl8250_handle_irq" [drivers/tty/serial/of_serial.ko] undefined!

This exports the symbol to avoid randconfig errors.

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Fixes: d43b54d269d2 ("serial: Enable Freescale 16550 workaround on arm")
Cc: Scott Wood &lt;scottwood@freescale.com&gt;
Signed-off-by: Jeff Mahoney &lt;jeffm@suse.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>serial: 8250_mid: Add missing dependency</title>
<updated>2015-11-21T00:19:54Z</updated>
<author>
<name>Heikki Krogerus</name>
<email>heikki.krogerus@linux.intel.com</email>
</author>
<published>2015-11-12T13:21:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fa70045e9df47d2e7a698e5f7a0d21423a58cdaa'/>
<id>urn:sha1:fa70045e9df47d2e7a698e5f7a0d21423a58cdaa</id>
<content type='text'>
8250_mid uses rational_best_approximation() function, so the
driver needs to select CONFIG_RATIONAL option.

This fixes build error when CONFIG_RATIONAL is not enabled:

drivers/built-in.o: In function `mid8250_set_termios':
8250_mid.c:(.text+0x10169a): undefined reference to `rational_best_approximation'

Reported-by: Randy Dunlap &lt;rdunlap@infradead.org&gt;
Signed-off-by: Heikki Krogerus &lt;heikki.krogerus@linux.intel.com&gt;
Acked-by: Andy Shevchenko &lt;andy.shevchenko@gmail.com&gt;
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>serial: etraxfs-uart: Fix crash</title>
<updated>2015-11-21T00:19:54Z</updated>
<author>
<name>Guenter Roeck</name>
<email>linux@roeck-us.net</email>
</author>
<published>2015-11-02T02:32:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f356d7a7ddb5ea545e81c84eecfdf1b5ab4647fc'/>
<id>urn:sha1:f356d7a7ddb5ea545e81c84eecfdf1b5ab4647fc</id>
<content type='text'>
Since commit 7d8c70d8048c ("serial: mctrl-gpio: rename init function"),
crisv32 either do not build or crash as follows.

Unable to handle kernel NULL pointer dereference
Linux 4.3.0-rc7-next-20151101 #1 Sun Nov 1 11:41:28 PST 2015
...
Call Trace: [&lt;c0004a0e&gt;] show_stack+0x0/0x9e
[&lt;c004c0c0&gt;] printk+0x0/0x2c
[&lt;c00059d4&gt;] show_registers+0x14a/0x1c2
[&lt;c004c0c0&gt;] printk+0x0/0x2c
[&lt;c0004b52&gt;] die_if_kernel+0x7c/0x9e
[&lt;c0005346&gt;] do_page_fault+0x32e/0x3e6
[&lt;c01dc59c&gt;] of_get_property+0x0/0x2c
[&lt;c01e0558&gt;] of_irq_parse_raw+0x12a/0x376
[&lt;c01dc59c&gt;] of_get_property+0x0/0x2c
[&lt;c0053aca&gt;] get_page_from_freelist+0x73e/0x856
[&lt;c01dc59c&gt;] of_get_property+0x0/0x2c
[&lt;c0008912&gt;] d_mmu_refill+0x10a/0x112
[&lt;c01b488c&gt;] devm_kmalloc+0x40/0x56
[&lt;c01b47d0&gt;] add_dr+0xc/0x1c
[&lt;c01b4800&gt;] devm_add_action+0x2/0x4e
[&lt;c01abdbc&gt;] mctrl_gpio_init_noauto+0x1c/0x76
[&lt;c01abf9e&gt;] mctrl_gpio_init+0x22/0x110

The function call in the etraxfs-uart driver was not renamed,
possibly due to interference with commit 7b9c5162c182 ("serial:
etraxfs-uart: use mctrl_gpio helpers for handling modem signals").

Fixes: 7d8c70d8048c ("serial: mctrl-gpio: rename init function")
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Acked-by: Uwe Kleine-König &lt;u.kleine-koenig@pengutronix.de&gt;
Acked-by: Niklas Cassel &lt;nks@flawful.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>serial: fsl_lpuart: Fix earlycon support</title>
<updated>2015-11-21T00:19:54Z</updated>
<author>
<name>Peter Hurley</name>
<email>peter@hurleysoftware.com</email>
</author>
<published>2015-10-20T13:55:21Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bec8bf61dc911ebe04a7997db2c44ed51d8ade9d'/>
<id>urn:sha1:bec8bf61dc911ebe04a7997db2c44ed51d8ade9d</id>
<content type='text'>
Earlycon support for Freescale lpuart should only be enabled when
console support is enabled.

Fixes: 1d59b382f1c4 ("serial: fsl_lpuart: add earlycon support")
Acked-by: Stefan Agner &lt;stefan@agner.ch&gt;
Signed-off-by: Peter Hurley &lt;peter@hurleysoftware.com&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
</feed>
