From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
Cc: linux-serial@vger.kernel.org,
"Greg KH" <gregkh@linuxfoundation.org>,
"Jiri Slaby" <jirislaby@kernel.org>,
"Vladimir Zapolskiy" <vz@mleia.com>,
"Russell King" <linux@armlinux.org.uk>,
"Richard Genoud" <richard.genoud@gmail.com>,
"Nicolas Ferre" <nicolas.ferre@microchip.com>,
"Alexandre Belloni" <alexandre.belloni@bootlin.com>,
"Claudiu Beznea" <claudiu.beznea@microchip.com>,
"Shawn Guo" <shawnguo@kernel.org>,
"Sascha Hauer" <s.hauer@pengutronix.de>,
"Pengutronix Kernel Team" <kernel@pengutronix.de>,
"Fabio Estevam" <festevam@gmail.com>,
"NXP Linux Team" <linux-imx@nxp.com>,
"Maxime Coquelin" <mcoquelin.stm32@gmail.com>,
"Alexandre Torgue" <alexandre.torgue@foss.st.com>,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-stm32@st-md-mailman.stormreply.com,
"Lukas Wunner" <lukas@wunner.de>,
"Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>,
"Lino Sanfilippo" <LinoSanfilippo@gmx.de>
Subject: Re: [PATCH v7 4/6] serial: take termios_rwsem for .rs485_config() & pass termios as param
Date: Wed, 15 Jun 2022 17:05:29 +0300 [thread overview]
Message-ID: <YqnnKQYAnqORpdBJ@smile.fi.intel.com> (raw)
In-Reply-To: <20220615124829.34516-5-ilpo.jarvinen@linux.intel.com>
On Wed, Jun 15, 2022 at 03:48:27PM +0300, Ilpo Järvinen wrote:
> To be able to alter ADDRB within .rs485_config(), take termios_rwsem
> before calling .rs485_config() and pass termios.
I would use ->rs485_config() as a reference to the callback.
...
> - ret = port->rs485_config(port, rs485);
> + ret = port->rs485_config(port, rs485, NULL);
> +
Stray change?
> if (ret)
> memset(rs485, 0, sizeof(*rs485));
...
> void (*handle_break)(struct uart_port *);
> int (*rs485_config)(struct uart_port *,
> - struct serial_rs485 *rs485);
> + struct serial_rs485 *rs485,
> + struct ktermios *termios);
Dunno if termios has to be second parameter. The idea is to pass input data
followed by (auxiliary) output as usual pattern.
> int (*iso7816_config)(struct uart_port *,
> struct serial_iso7816 *iso7816);
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2022-06-15 14:06 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20220615124829.34516-1-ilpo.jarvinen@linux.intel.com>
2022-06-15 12:48 ` [PATCH v7 1/6] serial: 8250: make saved LSR larger Ilpo Järvinen
2022-06-15 14:00 ` Andy Shevchenko
2022-06-15 12:48 ` [PATCH v7 2/6] serial: 8250: create lsr_save_mask Ilpo Järvinen
2022-06-15 14:01 ` Andy Shevchenko
2022-06-15 12:48 ` [PATCH v7 3/6] serial: 8250_lpss: Use 32-bit reads Ilpo Järvinen
2022-06-15 12:48 ` [PATCH v7 4/6] serial: take termios_rwsem for .rs485_config() & pass termios as param Ilpo Järvinen
2022-06-15 14:05 ` Andy Shevchenko [this message]
2022-06-16 5:15 ` Ilpo Järvinen
2022-06-15 12:48 ` [PATCH v7 5/6] serial: Support for RS-485 multipoint addresses Ilpo Järvinen
2022-06-15 14:13 ` Andy Shevchenko
2022-06-16 5:04 ` Ilpo Järvinen
2022-06-16 5:48 ` Jiri Slaby
2022-06-16 7:53 ` Ilpo Järvinen
2022-06-15 12:48 ` [PATCH v7 6/6] serial: 8250_dwlib: Support for 9th bit multipoint addressing Ilpo Järvinen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YqnnKQYAnqORpdBJ@smile.fi.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=LinoSanfilippo@gmx.de \
--cc=alexandre.belloni@bootlin.com \
--cc=alexandre.torgue@foss.st.com \
--cc=claudiu.beznea@microchip.com \
--cc=festevam@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=ilpo.jarvinen@linux.intel.com \
--cc=jirislaby@kernel.org \
--cc=kernel@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-imx@nxp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=linux@armlinux.org.uk \
--cc=lukas@wunner.de \
--cc=mcoquelin.stm32@gmail.com \
--cc=nicolas.ferre@microchip.com \
--cc=richard.genoud@gmail.com \
--cc=s.hauer@pengutronix.de \
--cc=shawnguo@kernel.org \
--cc=u.kleine-koenig@pengutronix.de \
--cc=vz@mleia.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox