All of lore.kernel.org
 help / color / mirror / Atom feed
From: Parker Newman <parker@finest.io>
To: Jiri Slaby <jirislaby@kernel.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org,
	Parker Newman <pnewman@connecttech.com>
Subject: Re: [PATCH v1 3/4] serial: exar: remove unneeded parenthesis
Date: Fri, 19 Apr 2024 08:50:18 -0400	[thread overview]
Message-ID: <20240419085018.5a5c5826@SWDEV2.connecttech.local> (raw)
In-Reply-To: <4a7a1c35-f1f6-4ed3-ad57-d71891220219@kernel.org>

On Fri, 19 Apr 2024 09:01:22 +0200
Jiri Slaby <jirislaby@kernel.org> wrote:

> On 19. 04. 24, 8:58, Greg Kroah-Hartman wrote:
> > On Thu, Apr 18, 2024 at 11:36:30AM -0400, Parker Newman wrote:
> >> From: Parker Newman <pnewman@connecttech.com>
> >>
> >> Remove unneeded parenthesis from several locations.
> >>
> >> Based on feedback from:
> >> Link: https://lore.kernel.org/linux-serial/f2353b8c-2079-b895-2707-f6be83161288@linux.intel.com
> >>
> >> Signed-off-by: Parker Newman <pnewman@connecttech.com>
> >> ---
> >>   drivers/tty/serial/8250/8250_exar.c | 28 ++++++++++++++--------------
> >>   1 file changed, 14 insertions(+), 14 deletions(-)
> >>
> >> diff --git a/drivers/tty/serial/8250/8250_exar.c b/drivers/tty/serial/8250/8250_exar.c
> >> index 01748ddbf729..10725ad0f3ef 100644
> >> --- a/drivers/tty/serial/8250/8250_exar.c
> >> +++ b/drivers/tty/serial/8250/8250_exar.c
> >> @@ -317,7 +317,7 @@ static inline u8 exar_ee_read_bit(struct exar8250 *priv)
> >>
> >>   	regb = exar_read_reg(priv, UART_EXAR_REGB);
> >>
> >> -	return (regb & UART_EXAR_REGB_EEDO ? 1 : 0);
> >> +	return regb & UART_EXAR_REGB_EEDO ? 1 : 0;
> >
> > Again, spell out the ? : stuff here please.  Using () isn't the problem :)
>
> Could this in fact be inline bool exar_is_ee_set() (or alike) and return
> that regb & UART_EXAR_REGB_EEDO directly (w/o using ternary at all)?
>
> thanks,

That would work. I will update.
Thanks,
Parker

  reply	other threads:[~2024-04-19 12:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-18 15:36 [PATCH v1 0/4] serial: exar: fix kbuild warnings and code style Parker Newman
2024-04-18 15:36 ` [PATCH v1 1/4] serial: exar: add missing kernel doc function parameters Parker Newman
2024-04-18 15:36 ` [PATCH v1 2/4] serial: exar: use return dev_err_probe instead of returning error code Parker Newman
2024-04-18 15:36 ` [PATCH v1 3/4] serial: exar: remove unneeded parenthesis Parker Newman
2024-04-19  6:58   ` Greg Kroah-Hartman
2024-04-19  7:01     ` Jiri Slaby
2024-04-19 12:50       ` Parker Newman [this message]
2024-04-18 15:36 ` [PATCH v1 4/4] serial: exar: change port_type ternary line wrapping Parker Newman
2024-04-19  6:07   ` Jiri Slaby
2024-04-19 12:17     ` Parker Newman
2024-04-19  6:57   ` Greg Kroah-Hartman

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=20240419085018.5a5c5826@SWDEV2.connecttech.local \
    --to=parker@finest.io \
    --cc=gregkh@linuxfoundation.org \
    --cc=jirislaby@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=pnewman@connecttech.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.