* Re: [PATCH] tty: fix tty_ldisc_receive_buf() documentation
From: Sebastian Reichel @ 2017-11-06 13:39 UTC (permalink / raw)
To: Johan Hovold; +Cc: Greg Kroah-Hartman, Jiri Slaby, linux-kernel, linux-serial
In-Reply-To: <20171103141805.20292-1-johan@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 1130 bytes --]
Hi,
On Fri, Nov 03, 2017 at 03:18:05PM +0100, Johan Hovold wrote:
> The tty_ldisc_receive_buf() helper returns the number of bytes
> processed so drop the bogus "not" from the kernel doc comment.
>
> Fixes: 8d082cd300ab ("tty: Unify receive_buf() code paths")
> Signed-off-by: Johan Hovold <johan@kernel.org>
> ---
Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
-- Sebastian
> drivers/tty/tty_buffer.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/tty/tty_buffer.c b/drivers/tty/tty_buffer.c
> index f8eba1c5412f..677fa99b7747 100644
> --- a/drivers/tty/tty_buffer.c
> +++ b/drivers/tty/tty_buffer.c
> @@ -446,7 +446,7 @@ EXPORT_SYMBOL_GPL(tty_prepare_flip_string);
> * Callers other than flush_to_ldisc() need to exclude the kworker
> * from concurrent use of the line discipline, see paste_selection().
> *
> - * Returns the number of bytes not processed
> + * Returns the number of bytes processed
> */
> int tty_ldisc_receive_buf(struct tty_ldisc *ld, const unsigned char *p,
> char *f, int count)
> --
> 2.15.0
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply
* Re: [PATCH 0/5] TTY/JSM coding style fixes
From: Guilherme G. Piccoli @ 2017-11-06 13:16 UTC (permalink / raw)
To: Gimcuan Hui; +Cc: Greg Kroah-Hartman, Jiri Slaby, linux-serial, linux-kernel
In-Reply-To: <cover.1509853735.git.gimcuan@gmail.com>
On 11/05/2017 03:06 AM, Gimcuan Hui wrote:
> This patch set fixes several warnings and errors reported
> by checkpatch.pl.
>
> Gimcuan Hui (5):
> tty: serial: jsm: change the type of local variable
> tty: serial: jsm: add blank line after declarations
> tty: serial: jsm: delete space between function name and '('
> tty: serial: jsm: fix coding style
> tty: serial: jsm: add space before the open parenthesis '('
>
> drivers/tty/serial/jsm/jsm_tty.c | 12 ++++++------
> 1 file changed, 6 insertions(+), 6 deletions(-)
>
Thanks for the fixes Gimcuan!
For the entire series:
Acked-by: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com>
^ permalink raw reply
* [PATCH 2/2] serial: 8250_fintek: Disable delays for ports != 0
From: Ricardo Ribalda Delgado @ 2017-11-06 10:49 UTC (permalink / raw)
To: Greg Kroah-Hartman, Jiri Slaby, Ji-Ze Hong (Peter Hong),
Lukas Wunner, linux-serial, linux-kernel
Cc: Ricardo Ribalda Delgado
In-Reply-To: <20171106104913.2553-1-ricardo.ribalda@gmail.com>
According to the datasheet, only the first port supports delay before
send and delay after send.
Reported-by: "Ji-Ze Hong (Peter Hong)" <hpeter@gmail.com>
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/tty/serial/8250/8250_fintek.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/tty/serial/8250/8250_fintek.c b/drivers/tty/serial/8250/8250_fintek.c
index ca7e96f9f080..61745d4bea31 100644
--- a/drivers/tty/serial/8250/8250_fintek.c
+++ b/drivers/tty/serial/8250/8250_fintek.c
@@ -216,6 +216,12 @@ static int fintek_8250_rs485_config(struct uart_port *port,
rs485->flags &= SER_RS485_ENABLED | SER_RS485_RTS_ON_SEND |
SER_RS485_RTS_AFTER_SEND;
+ /* Only the first port supports delays */
+ if (pdata->index) {
+ rs485->delay_rts_before_send = 0;
+ rs485->delay_rts_after_send = 0;
+ }
+
if (rs485->delay_rts_before_send) {
rs485->delay_rts_before_send = 1;
config |= TXW4C_IRA;
--
2.14.2
^ permalink raw reply related
* [PATCH 1/2] serial: 8250_fintek: Return -EINVAL on invalid configuration
From: Ricardo Ribalda Delgado @ 2017-11-06 10:49 UTC (permalink / raw)
To: Greg Kroah-Hartman, Jiri Slaby, Ji-Ze Hong (Peter Hong),
Lukas Wunner, linux-serial, linux-kernel
Cc: Ricardo Ribalda Delgado
Hardware does not support having the same RTS level during RX and TX
when RS485 mode is on (URA in Fintek terminology).
The manufacturer has also confirmed that the delays are not enabled if
the RS485 mode is not enabled.
Therefore we should return -EINVAL if the user wants to have the same
value for RTS_ON_SEND and RTS_AFTER_SEND.
Cc: "Ji-Ze Hong (Peter Hong)" <hpeter@gmail.com>
Cc: Lukas Wunner <lukas@wunner.de>
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/tty/serial/8250/8250_fintek.c | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/drivers/tty/serial/8250/8250_fintek.c b/drivers/tty/serial/8250/8250_fintek.c
index c41cbb52f1fe..ca7e96f9f080 100644
--- a/drivers/tty/serial/8250/8250_fintek.c
+++ b/drivers/tty/serial/8250/8250_fintek.c
@@ -201,10 +201,17 @@ static int fintek_8250_rs485_config(struct uart_port *port,
if (!pdata)
return -EINVAL;
- if (rs485->flags & SER_RS485_ENABLED)
+ /* Hardware do not support same RTS level on send and receive */
+ if (!(rs485->flags & SER_RS485_RTS_ON_SEND) ==
+ !(rs485->flags & SER_RS485_RTS_AFTER_SEND))
+ return -EINVAL;
+
+ if (rs485->flags & SER_RS485_ENABLED) {
memset(rs485->padding, 0, sizeof(rs485->padding));
- else
+ config |= RS485_URA;
+ } else {
memset(rs485, 0, sizeof(*rs485));
+ }
rs485->flags &= SER_RS485_ENABLED | SER_RS485_RTS_ON_SEND |
SER_RS485_RTS_AFTER_SEND;
@@ -219,12 +226,6 @@ static int fintek_8250_rs485_config(struct uart_port *port,
config |= RXW4C_IRA;
}
- if ((!!(rs485->flags & SER_RS485_RTS_ON_SEND)) ==
- (!!(rs485->flags & SER_RS485_RTS_AFTER_SEND)))
- rs485->flags &= ~SER_RS485_ENABLED;
- else
- config |= RS485_URA;
-
if (rs485->flags & SER_RS485_RTS_ON_SEND)
config |= RTS_INVERT;
--
2.14.2
^ permalink raw reply related
* Re: [v11,1/4] drivers: jtag: Add JTAG core driver
From: Chip Bilbrey @ 2017-11-05 22:32 UTC (permalink / raw)
To: Oleksandr Shamray
Cc: gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r, arnd-r2nGTMty4D4,
linux-kernel-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, openbmc-uLR06cmDAlY/bJ5BZ2RsiQ,
joel-U3u1mxZcP9KHXe+LvDLADg, jiri-rHqAuBHg3fBzbRFIqnYvSA,
tklauser-93Khv+1bN0NyDzI6CaY1VQ,
linux-serial-u79uwXL29TY76Z2rM5mHXA, mec-WqBc5aa1uDFeoWH0uzbU5w,
vadimp-VPRAkNaXOzVWk0Htik3J/w,
system-sw-low-level-VPRAkNaXOzVWk0Htik3J/w,
robh+dt-DgEjT+Ai2ygdnm+yROfE0A,
openocd-devel-owner-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f,
linux-api-u79uwXL29TY76Z2rM5mHXA, davem-fT/PcQaiUtIeIZ0/mPfg9Q,
mchehab-DgEjT+Ai2ygdnm+yROfE0A, Jiri Pirko
In-Reply-To: <1509724449-26221-2-git-send-email-oleksandrs-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
Oleksandr Shamray writes:
> diff --git a/include/uapi/linux/jtag.h b/include/uapi/linux/jtag.h
> new file mode 100644
> index 0000000..0b25a83
> --- /dev/null
> +++ b/include/uapi/linux/jtag.h
> [...]
> +/**
> + * enum jtag_xfer_mode:
> + *
> + * @JTAG_XFER_HW_MODE: hardware mode transfer
> + * @JTAG_XFER_SW_MODE: software mode transfer
> + */
> +enum jtag_xfer_mode {
> + JTAG_XFER_HW_MODE,
> + JTAG_XFER_SW_MODE,
> +};
Is this essentially selecting between bit-bang mode or not? Is there a
generally applicable reason to select SW mode over HW (or vice versa)?
This sounds like it's tied to device-specific capability which shouldn't
be exposed in a generic user API.
> +/**
> + * struct jtag_xfer - jtag xfer:
> + *
> + * @mode: access mode
> + * @type: transfer type
> + * @direction: xfer direction
> + * @length: xfer bits len
> + * @tdio : xfer data array
> + * @endir: xfer end state
> + *
> + * Structure represents interface to Aspeed JTAG device for jtag sdr xfer
> + * execution.
Probably should remove the reference to Aspeed here.
> +/* ioctl interface */
> +#define __JTAG_IOCTL_MAGIC 0xb2
> +
> +#define JTAG_IOCRUNTEST _IOW(__JTAG_IOCTL_MAGIC, 0,\
> + struct jtag_run_test_idle)
> +#define JTAG_SIOCFREQ _IOW(__JTAG_IOCTL_MAGIC, 1, unsigned int)
> +#define JTAG_GIOCFREQ _IOR(__JTAG_IOCTL_MAGIC, 2, unsigned int)
> +#define JTAG_IOCXFER _IOWR(__JTAG_IOCTL_MAGIC, 3, struct jtag_xfer)
> +#define JTAG_GIOCSTATUS _IOWR(__JTAG_IOCTL_MAGIC, 4, enum jtag_endstate)
I notice the single-open()-per-device lock was dropped by request in an
earlier revision of your patches, but multiple processes trying to drive
a single JTAG master could wreak serious havoc if transactions get
interleaved. Would something like an added JTAG_LOCKCHAIN/UNLOCKCHAIN
ioctl() for exclusive client access be reasonable to prevent this?
-Chip
^ permalink raw reply
* Re: [PATCH v10 2/5] serdev: Introduce devm_serdev_device_open()
From: Andrey Smirnov @ 2017-11-05 22:19 UTC (permalink / raw)
To: Johan Hovold
Cc: linux-kernel, linux-serial, Rob Herring, Chris Healy,
Guenter Roeck, Lucas Stach, Nikita Yushchenko, Lee Jones,
Greg Kroah-Hartman, Pavel Machek, Andy Shevchenko,
Sebastian Reichel
In-Reply-To: <20171105153857.GC13118@localhost>
On Sun, Nov 5, 2017 at 7:38 AM, Johan Hovold <johan@kernel.org> wrote:
> On Tue, Oct 31, 2017 at 09:36:53AM -0700, Andrey Smirnov wrote:
>> Add code implementing managed version of serdev_device_open() for
>> serdev device drivers that "open" the device during driver's lifecycle
>> only once (e.g. opened in .probe() and closed in .remove()).
>>
>> Cc: linux-kernel@vger.kernel.org
>> Cc: linux-serial@vger.kernel.org
>> Cc: Rob Herring <robh@kernel.org>
>> Cc: cphealy@gmail.com
>> Cc: Guenter Roeck <linux@roeck-us.net>
>> Cc: Lucas Stach <l.stach@pengutronix.de>
>> Cc: Nikita Yushchenko <nikita.yoush@cogentembedded.com>
>> Cc: Lee Jones <lee.jones@linaro.org>
>> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>> Cc: Pavel Machek <pavel@ucw.cz>
>> Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
>> Cc: Johan Hovold <johan@kernel.org>
>> Cc: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
>> Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
>> Reviewed-by: Guenter Roeck <linux@roeck-us.net>
>> Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com>
>> ---
>> Documentation/driver-model/devres.txt | 3 +++
>> drivers/tty/serdev/core.c | 27 +++++++++++++++++++++++++++
>> include/linux/serdev.h | 1 +
>> 3 files changed, 31 insertions(+)
>
>> +int devm_serdev_device_open(struct device *dev, struct serdev_device *serdev)
>> +{
>> + struct serdev_device **dr;
>> + int ret;
>> +
>> + dr = devres_alloc(devm_serdev_device_release, sizeof(*dr), GFP_KERNEL);
>> + if (!dr)
>> + return -ENOMEM;
>> +
>> + ret = serdev_device_open(serdev);
>> + if (ret) {
>> + devres_free(dr);
>> + return ret;
>> + }
>> +
>> + *dr = serdev;
>> + devres_add(dev, dr);
>> +
>> + return ret;
>
> This would be more readable as return 0.
Sure, I'll change that in v11.
Thanks,
Andrey Smrinov
^ permalink raw reply
* [PATCH v5] tty: serial: meson: allow baud-rates lower than 9600
From: Thomas Rohloff @ 2017-11-05 19:36 UTC (permalink / raw)
To: linux-serial
Cc: Greg Kroah-Hartman, Jiri Slaby, Carlo Caione, Kevin Hilman,
linux-amlogic, linux-arm-kernel, linux-kernel
Devices like DCF77 receivers need the baud-rate to be as low as 50.
I have tested this on a Meson GXL device with uart_A.
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Jiri Slaby <jslaby@suse.com>
Cc: Carlo Caione <carlo@caione.org>
Cc: Kevin Hilman <khilman@baylibre.com>
Cc: linux-amlogic@lists.infradead.org
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Thomas Rohloff <v10lator@myway.de>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
---
drivers/tty/serial/meson_uart.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/tty/serial/meson_uart.c b/drivers/tty/serial/meson_uart.c
index 07c0f98be3ac..e281ce5d101d 100644
--- a/drivers/tty/serial/meson_uart.c
+++ b/drivers/tty/serial/meson_uart.c
@@ -362,7 +362,7 @@ static void meson_uart_set_termios(struct uart_port *port,
writel(val, port->membase + AML_UART_CONTROL);
- baud = uart_get_baud_rate(port, termios, old, 9600, 4000000);
+ baud = uart_get_baud_rate(port, termios, old, 50, 4000000);
meson_uart_change_speed(port, baud);
port->read_status_mask = AML_UART_TX_FIFO_WERR;
--
2.13.6
^ permalink raw reply related
* [PATCH] tty: serial: meson: allow baud-rates lower than 9600
From: Thomas Rohloff @ 2017-11-05 19:35 UTC (permalink / raw)
To: linux-serial
Cc: Greg Kroah-Hartman, Jiri Slaby, Carlo Caione, Kevin Hilman,
linux-amlogic, linux-arm-kernel, linux-kernel
Devices like DCF77 receivers need the baud-rate to be as low as 50.
I have tested this on a Meson GXL device with uart_A.
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Jiri Slaby <jslaby@suse.com>
Cc: Carlo Caione <carlo@caione.org>
Cc: Kevin Hilman <khilman@baylibre.com>
Cc: linux-amlogic@lists.infradead.org
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Thomas Rohloff <v10lator@myway.de>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
---
drivers/tty/serial/meson_uart.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/tty/serial/meson_uart.c b/drivers/tty/serial/meson_uart.c
index 07c0f98be3ac..e281ce5d101d 100644
--- a/drivers/tty/serial/meson_uart.c
+++ b/drivers/tty/serial/meson_uart.c
@@ -362,7 +362,7 @@ static void meson_uart_set_termios(struct uart_port *port,
writel(val, port->membase + AML_UART_CONTROL);
- baud = uart_get_baud_rate(port, termios, old, 9600, 4000000);
+ baud = uart_get_baud_rate(port, termios, old, 50, 4000000);
meson_uart_change_speed(port, baud);
port->read_status_mask = AML_UART_TX_FIFO_WERR;
--
2.13.6
^ permalink raw reply related
* Re: [PATCH v4] tty: serial: meson: allow baud-rates lower than 9600
From: V10lator @ 2017-11-05 19:34 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: linux-serial, Jiri Slaby, Carlo Caione, Kevin Hilman,
linux-amlogic, linux-arm-kernel, linux-kernel
In-Reply-To: <20171105141206.GA31306@kroah.com>
Am Sonntag, 5. November 2017 15:12:06 CET schrieb Greg Kroah-Hartman:
> On Sun, Nov 05, 2017 at 05:29:30AM +0100, Thomas Rohloff wrote:
>> Devices like DCF77 receivers need the baud-rate to be as low as 50.
>>
>> I have tested this on a Meson GXL device with uart_A.
>>
>> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>> Cc: Jiri Slaby <jslaby@suse.com>
>> Cc: Carlo Caione <carlo@caione.org> ...
>
> This is line-wrapped and can not be applied :(
>
> It's your email client, look at this setting:
> Content-Type: text/plain; charset=utf-8; format=flowed
>
> format=flowed does not work for kernel patches, it corruptes and edits
> them as it thinks this is just a conversation, not a machine-readable
> format.
>
> 5th try? :)
>
> thanks,
>
> greg k-h
Thanks for explaining. I'll try a v5. :)
^ permalink raw reply
* Re: [PATCH v3] dt-bindings: mvebu-uart: update documentation with extended UART
From: Miquel RAYNAL @ 2017-11-05 16:47 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Rob Herring, Mark Rutland, Antoine Tenart, Thomas Petazzoni,
Nadav Haklai, Wilson Ding, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-serial-u79uwXL29TY76Z2rM5mHXA
In-Reply-To: <20171104111435.GB17605-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
Hi Greg,
> On Mon, Oct 30, 2017 at 03:21:51PM +0100, Miquel Raynal wrote:
> > Update the device tree binding documentation for the Marvell EBU
> > UART, in order to allow describing the extended UART IP block, in
> > addition to the already supported standard UART IP. This requires
> > adding a new compatible string, the introduction of a clocks
> > property, and extensions to the interrupts property.
> >
> > Signed-off-by: Miquel Raynal <miquel.raynal-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
> > Reviewed-by: Gregory CLEMENT <gregory.clement-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
> > Acked-by: Rob Herring <robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
> > ---
>
> Doesn't apply to my tree :(
You are right, I completely apologize: I should have added the mvebu
maintainers and asked them to take this patch otherwise it would have
conflicted with a previous DT change that also updated the documentation.
I will resend with them in copy.
Thank you,
Miquèl
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply
* Re: [PATCH v10 2/5] serdev: Introduce devm_serdev_device_open()
From: Johan Hovold @ 2017-11-05 15:38 UTC (permalink / raw)
To: Andrey Smirnov
Cc: linux-kernel, linux-serial, Rob Herring, cphealy, Guenter Roeck,
Lucas Stach, Nikita Yushchenko, Lee Jones, Greg Kroah-Hartman,
Pavel Machek, Andy Shevchenko, Johan Hovold, Sebastian Reichel
In-Reply-To: <20171031163656.24552-3-andrew.smirnov@gmail.com>
On Tue, Oct 31, 2017 at 09:36:53AM -0700, Andrey Smirnov wrote:
> Add code implementing managed version of serdev_device_open() for
> serdev device drivers that "open" the device during driver's lifecycle
> only once (e.g. opened in .probe() and closed in .remove()).
>
> Cc: linux-kernel@vger.kernel.org
> Cc: linux-serial@vger.kernel.org
> Cc: Rob Herring <robh@kernel.org>
> Cc: cphealy@gmail.com
> Cc: Guenter Roeck <linux@roeck-us.net>
> Cc: Lucas Stach <l.stach@pengutronix.de>
> Cc: Nikita Yushchenko <nikita.yoush@cogentembedded.com>
> Cc: Lee Jones <lee.jones@linaro.org>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: Pavel Machek <pavel@ucw.cz>
> Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
> Cc: Johan Hovold <johan@kernel.org>
> Cc: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
> Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
> Reviewed-by: Guenter Roeck <linux@roeck-us.net>
> Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com>
> ---
> Documentation/driver-model/devres.txt | 3 +++
> drivers/tty/serdev/core.c | 27 +++++++++++++++++++++++++++
> include/linux/serdev.h | 1 +
> 3 files changed, 31 insertions(+)
> +int devm_serdev_device_open(struct device *dev, struct serdev_device *serdev)
> +{
> + struct serdev_device **dr;
> + int ret;
> +
> + dr = devres_alloc(devm_serdev_device_release, sizeof(*dr), GFP_KERNEL);
> + if (!dr)
> + return -ENOMEM;
> +
> + ret = serdev_device_open(serdev);
> + if (ret) {
> + devres_free(dr);
> + return ret;
> + }
> +
> + *dr = serdev;
> + devres_add(dev, dr);
> +
> + return ret;
This would be more readable as return 0.
> +}
> +EXPORT_SYMBOL_GPL(devm_serdev_device_open);
Johan
^ permalink raw reply
* Re: [PATCH v4] tty: serial: meson: allow baud-rates lower than 9600
From: Martin Blumenstingl @ 2017-11-05 15:02 UTC (permalink / raw)
To: Thomas Rohloff
Cc: Kevin Hilman, Greg Kroah-Hartman, linux-kernel, linux-serial,
Jiri Slaby, Carlo Caione, linux-amlogic, linux-arm-kernel
In-Reply-To: <20171105141206.GA31306@kroah.com>
Hi Thomas,
thank you for this patch!
On Sun, Nov 5, 2017 at 3:12 PM, Greg Kroah-Hartman
<gregkh@linuxfoundation.org> wrote:
> On Sun, Nov 05, 2017 at 05:29:30AM +0100, Thomas Rohloff wrote:
>> Devices like DCF77 receivers need the baud-rate to be as low as 50.
>>
>> I have tested this on a Meson GXL device with uart_A.
>>
>> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>> Cc: Jiri Slaby <jslaby@suse.com>
>> Cc: Carlo Caione <carlo@caione.org>
>> Cc: Kevin Hilman <khilman@baylibre.com>
>> Cc: linux-amlogic@lists.infradead.org
>> Cc: linux-arm-kernel@lists.infradead.org
>> Cc: linux-kernel@vger.kernel.org
>> Signed-off-by: Thomas Rohloff <v10lator@myway.de>
>> ---
>> drivers/tty/serial/meson_uart.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/tty/serial/meson_uart.c
>> b/drivers/tty/serial/meson_uart.c
>> index 07c0f98be3ac..e281ce5d101d 100644
>> --- a/drivers/tty/serial/meson_uart.c
>> +++ b/drivers/tty/serial/meson_uart.c
>> @@ -362,7 +362,7 @@ static void meson_uart_set_termios(struct uart_port
>> *port,
>
> This is line-wrapped and can not be applied :(
>
> It's your email client, look at this setting:
> Content-Type: text/plain; charset=utf-8; format=flowed
>
> format=flowed does not work for kernel patches, it corruptes and edits
> them as it thinks this is just a conversation, not a machine-readable
> format.
>
> 5th try? :)
if you send a 5th version, please also include Neil's "Reviewed-by"
just below your Signed-off-by:
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
you can do this by running git commit --amend - this lets you edit the
existing commit message so you can append that
Regards,
Martin
^ permalink raw reply
* Re: [PATCH v4] tty: serial: meson: allow baud-rates lower than 9600
From: Greg Kroah-Hartman @ 2017-11-05 14:12 UTC (permalink / raw)
To: Thomas Rohloff
Cc: linux-serial, Jiri Slaby, Carlo Caione, Kevin Hilman,
linux-amlogic, linux-arm-kernel, linux-kernel
In-Reply-To: <bb0a70cc-6cc1-46d2-aa04-046a37c9f516@myway.de>
On Sun, Nov 05, 2017 at 05:29:30AM +0100, Thomas Rohloff wrote:
> Devices like DCF77 receivers need the baud-rate to be as low as 50.
>
> I have tested this on a Meson GXL device with uart_A.
>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: Jiri Slaby <jslaby@suse.com>
> Cc: Carlo Caione <carlo@caione.org>
> Cc: Kevin Hilman <khilman@baylibre.com>
> Cc: linux-amlogic@lists.infradead.org
> Cc: linux-arm-kernel@lists.infradead.org
> Cc: linux-kernel@vger.kernel.org
> Signed-off-by: Thomas Rohloff <v10lator@myway.de>
> ---
> drivers/tty/serial/meson_uart.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/tty/serial/meson_uart.c
> b/drivers/tty/serial/meson_uart.c
> index 07c0f98be3ac..e281ce5d101d 100644
> --- a/drivers/tty/serial/meson_uart.c
> +++ b/drivers/tty/serial/meson_uart.c
> @@ -362,7 +362,7 @@ static void meson_uart_set_termios(struct uart_port
> *port,
This is line-wrapped and can not be applied :(
It's your email client, look at this setting:
Content-Type: text/plain; charset=utf-8; format=flowed
format=flowed does not work for kernel patches, it corruptes and edits
them as it thinks this is just a conversation, not a machine-readable
format.
5th try? :)
thanks,
greg k-h
^ permalink raw reply
* Re: [PATCH v3] tty: serial: meson: allow baud-rates lower than 9600
From: Greg Kroah-Hartman @ 2017-11-05 7:21 UTC (permalink / raw)
To: V10lator
Cc: Kevin Hilman, linux-kernel, linux-serial, Jiri Slaby,
Carlo Caione, linux-amlogic, linux-arm-kernel
In-Reply-To: <bef0434b-fa23-464e-8c6c-d1f7dc678767@myway.de>
On Sun, Nov 05, 2017 at 05:26:59AM +0100, V10lator wrote:
> Am Samstag, 4. November 2017 14:13:52 CET schrieb Greg Kroah-Hartman:
> > What changed from v2?
>
> Nothing. I just re-based the patch on a fresh git clone as you couldn't
> merge v2.
Then you need to say so somewhere otherwise I, and everyone else, has no
idea what changed.
Remember, I get thousands of patches a week to review, and have the
short-term memory of a squirrel :(
thanks,
greg k-h
^ permalink raw reply
* [PATCH 5/5] tty: serial: jsm: add space before the open parenthesis '('
From: Gimcuan Hui @ 2017-11-05 5:06 UTC (permalink / raw)
To: Guilherme G. Piccoli, Greg Kroah-Hartman, Jiri Slaby
Cc: linux-serial, linux-kernel
In-Reply-To: <cover.1509853735.git.gimcuan@gmail.com>
This patch fixes the checkpatch.pl complains:
space required before the open parenthesis '('.
Signed-off-by: Gimcuan Hui <gimcuan@gmail.com>
---
drivers/tty/serial/jsm/jsm_tty.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/tty/serial/jsm/jsm_tty.c b/drivers/tty/serial/jsm/jsm_tty.c
index 3853bfa5aa46..cbbadafe61fb 100644
--- a/drivers/tty/serial/jsm/jsm_tty.c
+++ b/drivers/tty/serial/jsm/jsm_tty.c
@@ -541,7 +541,7 @@ void jsm_input(struct jsm_channel *ch)
tp = port->tty;
bd = ch->ch_bd;
- if(!bd)
+ if (!bd)
return;
spin_lock_irqsave(&ch->ch_lock, lock_flags);
@@ -781,7 +781,7 @@ void jsm_check_queue_flow_control(struct jsm_channel *ch)
if (qleft < 256) {
/* HWFLOW */
if (ch->ch_c_cflag & CRTSCTS) {
- if(!(ch->ch_flags & CH_RECEIVER_OFF)) {
+ if (!(ch->ch_flags & CH_RECEIVER_OFF)) {
bd_ops->disable_receiver(ch);
ch->ch_flags |= (CH_RECEIVER_OFF);
jsm_dbg(READ, &ch->ch_bd->pci_dev,
--
2.11.0
^ permalink raw reply related
* [PATCH 4/5] tty: serial: jsm: fix coding style
From: Gimcuan Hui @ 2017-11-05 5:06 UTC (permalink / raw)
To: Guilherme G. Piccoli, Greg Kroah-Hartman, Jiri Slaby
Cc: linux-serial, linux-kernel
In-Reply-To: <cover.1509853735.git.gimcuan@gmail.com>
This patch fixes the checkpatch.pl complain:
ERROR: else should follow close brace '}'.
Signed-off-by: Gimcuan Hui <gimcuan@gmail.com>
---
drivers/tty/serial/jsm/jsm_tty.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/tty/serial/jsm/jsm_tty.c b/drivers/tty/serial/jsm/jsm_tty.c
index 53c3f53da241..3853bfa5aa46 100644
--- a/drivers/tty/serial/jsm/jsm_tty.c
+++ b/drivers/tty/serial/jsm/jsm_tty.c
@@ -478,8 +478,7 @@ int jsm_uart_port_init(struct jsm_board *brd)
if (rc) {
printk(KERN_INFO "jsm: Port %d failed. Aborting...\n", i);
return rc;
- }
- else
+ } else
printk(KERN_INFO "jsm: Port %d added\n", i);
}
--
2.11.0
^ permalink raw reply related
* [PATCH 3/5] tty: serial: jsm: delete space between function name and '('
From: Gimcuan Hui @ 2017-11-05 5:06 UTC (permalink / raw)
To: Guilherme G. Piccoli, Greg Kroah-Hartman, Jiri Slaby
Cc: linux-serial, linux-kernel
In-Reply-To: <cover.1509853735.git.gimcuan@gmail.com>
This patch fixes checkpatch.pl warning:
space prohibited between function name and open parenthesis '('.
Signed-off-by: Gimcuan Hui <gimcuan@gmail.com>
---
drivers/tty/serial/jsm/jsm_tty.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/tty/serial/jsm/jsm_tty.c b/drivers/tty/serial/jsm/jsm_tty.c
index ed58dfc3d40e..53c3f53da241 100644
--- a/drivers/tty/serial/jsm/jsm_tty.c
+++ b/drivers/tty/serial/jsm/jsm_tty.c
@@ -474,7 +474,7 @@ int jsm_uart_port_init(struct jsm_board *brd)
} else
set_bit(line, linemap);
brd->channels[i]->uart_port.line = line;
- rc = uart_add_one_port (&jsm_uart_driver, &brd->channels[i]->uart_port);
+ rc = uart_add_one_port(&jsm_uart_driver, &brd->channels[i]->uart_port);
if (rc) {
printk(KERN_INFO "jsm: Port %d failed. Aborting...\n", i);
return rc;
--
2.11.0
^ permalink raw reply related
* [PATCH 2/5] tty: serial: jsm: add blank line after declarations
From: Gimcuan Hui @ 2017-11-05 5:06 UTC (permalink / raw)
To: Guilherme G. Piccoli, Greg Kroah-Hartman, Jiri Slaby
Cc: linux-serial, linux-kernel
In-Reply-To: <cover.1509853735.git.gimcuan@gmail.com>
This patch fixes checkpatch.pl warning:
Missing a blank line after declarations.
Signed-off-by: Gimcuan Hui <gimcuan@gmail.com>
---
drivers/tty/serial/jsm/jsm_tty.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/tty/serial/jsm/jsm_tty.c b/drivers/tty/serial/jsm/jsm_tty.c
index 729d2a083a74..ed58dfc3d40e 100644
--- a/drivers/tty/serial/jsm/jsm_tty.c
+++ b/drivers/tty/serial/jsm/jsm_tty.c
@@ -124,6 +124,7 @@ static void jsm_tty_set_mctrl(struct uart_port *port, unsigned int mctrl)
static void jsm_tty_write(struct uart_port *port)
{
struct jsm_channel *channel;
+
channel = container_of(port, struct jsm_channel, uart_port);
channel->ch_bd->bd_ops->copy_data_from_queue_to_uart(channel);
}
--
2.11.0
^ permalink raw reply related
* [PATCH 1/5] tty: serial: jsm: change the type of local variable
From: Gimcuan Hui @ 2017-11-05 5:06 UTC (permalink / raw)
To: Guilherme G. Piccoli, Greg Kroah-Hartman, Jiri Slaby
Cc: linux-serial, linux-kernel
In-Reply-To: <cover.1509853735.git.gimcuan@gmail.com>
The return type of jsm_get_mstat was int, and the local var result
was for the return should be int, make the change.
This patch fixes the checkpatch.pl warning:
Prefer 'unsigned int' to bare use of 'unsigned'.
Signed-off-by: Gimcuan Hui <gimcuan@gmail.com>
---
drivers/tty/serial/jsm/jsm_tty.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/tty/serial/jsm/jsm_tty.c b/drivers/tty/serial/jsm/jsm_tty.c
index e69227cc3827..729d2a083a74 100644
--- a/drivers/tty/serial/jsm/jsm_tty.c
+++ b/drivers/tty/serial/jsm/jsm_tty.c
@@ -36,7 +36,7 @@ static void jsm_carrier(struct jsm_channel *ch);
static inline int jsm_get_mstat(struct jsm_channel *ch)
{
unsigned char mstat;
- unsigned result;
+ int result;
jsm_dbg(IOCTL, &ch->ch_bd->pci_dev, "start\n");
--
2.11.0
^ permalink raw reply related
* [PATCH 0/5] TTY/JSM coding style fixes
From: Gimcuan Hui @ 2017-11-05 5:06 UTC (permalink / raw)
To: Guilherme G. Piccoli, Greg Kroah-Hartman, Jiri Slaby
Cc: linux-serial, linux-kernel
This patch set fixes several warnings and errors reported
by checkpatch.pl.
Gimcuan Hui (5):
tty: serial: jsm: change the type of local variable
tty: serial: jsm: add blank line after declarations
tty: serial: jsm: delete space between function name and '('
tty: serial: jsm: fix coding style
tty: serial: jsm: add space before the open parenthesis '('
drivers/tty/serial/jsm/jsm_tty.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
--
2.11.0
^ permalink raw reply
* [PATCH v4] tty: serial: meson: allow baud-rates lower than 9600
From: Thomas Rohloff @ 2017-11-05 4:29 UTC (permalink / raw)
To: linux-serial
Cc: Greg Kroah-Hartman, Jiri Slaby, Carlo Caione, Kevin Hilman,
linux-amlogic, linux-arm-kernel, linux-kernel
Devices like DCF77 receivers need the baud-rate to be as low as 50.
I have tested this on a Meson GXL device with uart_A.
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Jiri Slaby <jslaby@suse.com>
Cc: Carlo Caione <carlo@caione.org>
Cc: Kevin Hilman <khilman@baylibre.com>
Cc: linux-amlogic@lists.infradead.org
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Thomas Rohloff <v10lator@myway.de>
---
drivers/tty/serial/meson_uart.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/tty/serial/meson_uart.c
b/drivers/tty/serial/meson_uart.c
index 07c0f98be3ac..e281ce5d101d 100644
--- a/drivers/tty/serial/meson_uart.c
+++ b/drivers/tty/serial/meson_uart.c
@@ -362,7 +362,7 @@ static void meson_uart_set_termios(struct uart_port
*port,
writel(val, port->membase + AML_UART_CONTROL);
- baud = uart_get_baud_rate(port, termios, old, 9600, 4000000);
+ baud = uart_get_baud_rate(port, termios, old, 50, 4000000);
meson_uart_change_speed(port, baud);
port->read_status_mask = AML_UART_TX_FIFO_WERR;
--
2.13.6
^ permalink raw reply related
* Re: [PATCH v3] tty: serial: meson: allow baud-rates lower than 9600
From: V10lator @ 2017-11-05 4:26 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Kevin Hilman, linux-kernel, linux-serial, Jiri Slaby,
Carlo Caione, linux-amlogic, linux-arm-kernel
In-Reply-To: <20171104131352.GA9271@kroah.com>
Am Samstag, 4. November 2017 14:13:52 CET schrieb Greg Kroah-Hartman:
> What changed from v2?
Nothing. I just re-based the patch on a fresh git clone as you couldn't
merge v2.
> And I need a real name as the author of the patch :(
Damn, sorry about that. Will do a v4.
^ permalink raw reply
* Re: [PATCH v10 1/5] serdev: Make .remove in struct serdev_device_driver optional
From: Sebastian Reichel @ 2017-11-04 17:05 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Andrey Smirnov, linux-kernel, linux-serial, Rob Herring, cphealy,
Guenter Roeck, Lucas Stach, Nikita Yushchenko, Lee Jones,
Pavel Machek, Andy Shevchenko, Johan Hovold
In-Reply-To: <20171104112431.GA24583@kroah.com>
[-- Attachment #1: Type: text/plain, Size: 906 bytes --]
Hi Greg,
On Sat, Nov 04, 2017 at 12:24:31PM +0100, Greg Kroah-Hartman wrote:
> On Tue, Oct 31, 2017 at 09:36:52AM -0700, Andrey Smirnov wrote:
> > Using devres infrastructure it is possible to write a serdev driver
> > that doesn't have any code that needs to be called as a part of
> > .remove. Add code to make .remove optional.
>
> What about manual unbind from userspace through sysfs? You need to have
> a remove function. All drivers need that, to not have it is pretty lazy :)
Resources,that have been requested via devres are free'd by the
devres framework after the driver specific remove function. This
also works for manual unbind.
If *all* driver resources are allocated using devres, you will end
up with an empty remove function. In that case it makes sense to
remove it completly. This is what quite a few (mainline) i2c and
spi drivers actually do.
-- Sebastian
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply
* Re: [PATCH v3] tty: serial: meson: allow baud-rates lower than 9600
From: Neil Armstrong @ 2017-11-04 16:44 UTC (permalink / raw)
To: Greg Kroah-Hartman, V10lator
Cc: Kevin Hilman, linux-kernel, linux-serial, Jiri Slaby,
Carlo Caione, linux-amlogic, linux-arm-kernel
In-Reply-To: <20171104131352.GA9271@kroah.com>
Le 04/11/2017 14:13, Greg Kroah-Hartman a écrit :
> On Sat, Nov 04, 2017 at 02:00:00PM +0100, V10lator wrote:
>> Devices like DCF77 receivers need the baud-rate to be as low as 50.
>>
>> I have tested this on a Meson GXL device with uart_A.
>>
>> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>> Cc: Jiri Slaby <jslaby@suse.com>
>> Cc: Carlo Caione <carlo@caione.org>
>> Cc: Kevin Hilman <khilman@baylibre.com>
>> Cc: linux-amlogic@lists.infradead.org
>> Cc: linux-arm-kernel@lists.infradead.org
>> Cc: linux-kernel@vger.kernel.org
>> Signed-off-by: Thomas Rohloff <v10lator@myway.de>
>> ---
>> drivers/tty/serial/meson_uart.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> What changed from v2?
>
> And I need a real name as the author of the patch :(
>
>
> _______________________________________________
> linux-amlogic mailing list
> linux-amlogic@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-amlogic
>
Hi Thomas,
Make sure the "From" header of your mail matches the Signed-off-by tag, overwise use the --from option with "git send-email" to be sure, or generate the patch with the "git format-patch" with the "--from" option.
Anyway :
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
^ permalink raw reply
* Re: [PATCH v3] tty: serial: meson: allow baud-rates lower than 9600
From: Greg Kroah-Hartman @ 2017-11-04 13:13 UTC (permalink / raw)
To: V10lator
Cc: linux-serial, Jiri Slaby, Carlo Caione, Kevin Hilman,
linux-amlogic, linux-arm-kernel, linux-kernel
In-Reply-To: <19343ad6-75de-4059-825a-98ed40ecf423@myway.de>
On Sat, Nov 04, 2017 at 02:00:00PM +0100, V10lator wrote:
> Devices like DCF77 receivers need the baud-rate to be as low as 50.
>
> I have tested this on a Meson GXL device with uart_A.
>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: Jiri Slaby <jslaby@suse.com>
> Cc: Carlo Caione <carlo@caione.org>
> Cc: Kevin Hilman <khilman@baylibre.com>
> Cc: linux-amlogic@lists.infradead.org
> Cc: linux-arm-kernel@lists.infradead.org
> Cc: linux-kernel@vger.kernel.org
> Signed-off-by: Thomas Rohloff <v10lator@myway.de>
> ---
> drivers/tty/serial/meson_uart.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
What changed from v2?
And I need a real name as the author of the patch :(
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox