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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230401145121.1a64a113@jic23-huawei>
Date:   Sat, 1 Apr 2023 14:51:21 +0100
From:   Jonathan Cameron <jic23@...nel.org>
To:     Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc:     William Breathitt Gray <william.gray@...aro.org>,
        Lars-Peter Clausen <lars@...afoo.de>,
        linux-iio@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3 1/2] iio: addac: stx104: Migrate to the regmap API


> 
> > +		do {
> > +			err = regmap_read(priv->aio_ctl_map, STX104_ADC_STATUS, &adc_status);
> > +			if (err)
> > +				return err;
> > +		} while (u8_get_bits(adc_status, STX104_CNV));  
> 
> Hmm... Isn't it a potential infinite loop (e.g., ther hardware / firmware
> is broken)?
> 
> Why not using regmap_read_poll_timeout() (or its atomic variant, depends on
> the case)?

Just to shortcut things as I'm looking at this.
That's currently handled in patch 2.  Argument being this is a direct conversion
of existing code, whereas changing to xxx_poll_timeout() is an improvement.

I'm fine with it just being rolled into first patch with a note in the patch
description though if that works better.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ