Re: [PATCH 1/2] regmap: teach regmap to use raw spinlocks if requested in the config

From: Mark Brown
Date: Mon Aug 30 2021 - 08:42:51 EST


On Mon, Aug 30, 2021 at 01:02:33PM +0200, Rasmus Villemoes wrote:

> i.e. the regmap code can actually do allocations under whatever internal
> lock it uses. So ISTM that any regmap that uses a raw_spinlock (whether
> unconditionally or via Vladimir's opt-in) cannot be used with
> regmap_bulk_write().

No, anything that's using a spinlock already needs to avoid any
allocations - ensuring that either there's no cache or that the
cache is fully initialized with defaults. The only non-cache
allocations that might be done are only used by buses that sleep
anyway.

Attachment: signature.asc
Description: PGP signature