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: <CACRpkdbw3BkpzPQp2PdV8M61V2XXaLcmuOpGTsxSoiQTH7wZXw@mail.gmail.com>
Date: Fri, 28 Feb 2025 09:52:15 +0100
From: Linus Walleij <linus.walleij@...aro.org>
To: David Lechner <dlechner@...libre.com>
Cc: Jonathan Santos <Jonathan.Santos@...log.com>, linux-iio@...r.kernel.org, 
	devicetree@...r.kernel.org, linux-kernel@...r.kernel.org, 
	Sergiu Cuciurean <sergiu.cuciurean@...log.com>, lars@...afoo.de, Michael.Hennerich@...log.com, 
	marcelo.schmitt@...log.com, jic23@...nel.org, robh@...nel.org, 
	krzk+dt@...nel.org, conor+dt@...nel.org, jonath4nns@...il.com, 
	marcelo.schmitt1@...il.com
Subject: Re: [PATCH RESEND v3 12/17] iio: adc: ad7768-1: Add GPIO controller support

On Thu, Feb 20, 2025 at 11:27 PM David Lechner <dlechner@...libre.com> wrote:
> On 2/19/25 2:34 PM, Linus Walleij wrote:

> > Is it not possible to use the gpio regmap library in this driver
> > like we do in drivers/iio/addac/stx104.c?
> >
> > It cuts down the code size of simple GPIO chips on random
> > chips quite a lot.
>
> I think the answer is "no" since we need to hold a conditional lock
> while accessing registers. Namely: iio_device_claim_direct_mode()/
> iio_device_release_direct_mode().

Sorry for potentially dumb question, but if this is required to access
the registers, why is it not done in the regmap abstraction itself?
It's kind of that stuff regmap is supposed to hide.

Yours,
Linus Walleij

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ