Merge tag 'tty-4.11-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty
Pull tty/serial driver fixes from Greg KH: "Here are some tty and serial driver fixes for 4.11-rc4. One of these fix a long-standing issue in the ldisc code that was found by Dmitry Vyukov with his great fuzzing work. The other fixes resolve other reported issues, and there is one revert of a patch in 4.11-rc1 that wasn't correct. All of these have been in linux-next for a while with no reported issues" * tag 'tty-4.11-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: tty: fix data race in tty_ldisc_ref_wait() tty: don't panic on OOM in tty_set_ldisc() Revert "tty: serial: pl011: add ttyAMA for matching pl011 console" tty: acpi/spcr: QDF2400 E44 checks for wrong OEM revision serial: 8250_dw: Fix breakage when HAVE_CLK=n serial: 8250_dw: Honor clk_round_rate errors in dw8250_set_termios
This commit is contained in:
@@ -257,7 +257,7 @@ static void dw8250_set_termios(struct uart_port *p, struct ktermios *termios,
|
||||
{
|
||||
unsigned int baud = tty_termios_baud_rate(termios);
|
||||
struct dw8250_data *d = p->private_data;
|
||||
unsigned int rate;
|
||||
long rate;
|
||||
int ret;
|
||||
|
||||
if (IS_ERR(d->clk) || !old)
|
||||
@@ -265,7 +265,12 @@ static void dw8250_set_termios(struct uart_port *p, struct ktermios *termios,
|
||||
|
||||
clk_disable_unprepare(d->clk);
|
||||
rate = clk_round_rate(d->clk, baud * 16);
|
||||
ret = clk_set_rate(d->clk, rate);
|
||||
if (rate < 0)
|
||||
ret = rate;
|
||||
else if (rate == 0)
|
||||
ret = -ENOENT;
|
||||
else
|
||||
ret = clk_set_rate(d->clk, rate);
|
||||
clk_prepare_enable(d->clk);
|
||||
|
||||
if (!ret)
|
||||
|
@@ -2373,7 +2373,7 @@ static int __init pl011_console_match(struct console *co, char *name, int idx,
|
||||
if (strcmp(name, "qdf2400_e44") == 0) {
|
||||
pr_info_once("UART: Working around QDF2400 SoC erratum 44");
|
||||
qdf2400_e44_present = true;
|
||||
} else if (strcmp(name, "pl011") != 0 || strcmp(name, "ttyAMA") != 0) {
|
||||
} else if (strcmp(name, "pl011") != 0) {
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user