lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Fri, 19 Apr 2024 09:01:22 +0200
From: Jiri Slaby <jirislaby@...nel.org>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
 Parker Newman <parker@...est.io>
Cc: linux-kernel@...r.kernel.org, linux-serial@...r.kernel.org,
 Parker Newman <pnewman@...necttech.com>
Subject: Re: [PATCH v1 3/4] serial: exar: remove unneeded parenthesis

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@...necttech.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@...necttech.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,
-- 
js
suse labs


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ