[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZDfEDOihHTIDlbx+@hovoldconsulting.com>
Date: Thu, 13 Apr 2023 10:57:48 +0200
From: Johan Hovold <johan@...nel.org>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: Jarkko Sonninen <kasper@....fi>, linux-usb@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3] USB: serial: xr: Add TIOCGRS485 and TIOCSRS485 ioctls
On Tue, Mar 14, 2023 at 08:37:30AM +0100, Greg Kroah-Hartman wrote:
> On Tue, Mar 14, 2023 at 09:00:01AM +0200, Jarkko Sonninen wrote:
> > Add support for RS-485 in Exar USB adapters.
> > RS-485 mode is controlled by TIOCGRS485 and TIOCSRS485 ioctls.
> > Gpio mode register is set to enable RS-485.
> >
> > Signed-off-by: Jarkko Sonninen <kasper@....fi>
> > ---
> > @@ -237,6 +238,7 @@ static const struct xr_type xr_types[] = {
> > struct xr_data {
> > const struct xr_type *type;
> > u8 channel; /* zero-based index or interface number */
> > + u32 rs485_flags;
>
> Nit, you might want to move this up above channel as you now have a hole
> in this structure. Not like it's that big of a deal so if you don't
> have to respin this no need to change.
Generally, it's better to keep related fields together than worry about
holes so the above is just fine.
Johan
Powered by blists - more mailing lists