Re: [PATCH 1/2] zram: Move lockmap to be per-zram instead per table

From: Sergey Senozhatsky

Date: Thu Jul 23 2026 - 23:28:13 EST


On (26/07/14 16:12), Sebastian Andrzej Siewior wrote:
> The zram object contains an array zram_table_entry. Each one has a
> `lock' variable and each has a matching struct lockdep_map. This mimics
> a struct mutex.
>
> It uses always the same key for all lockdep_map instances. This makes it
> look like the same lock to lockdep. Therefore it could be reduced to
> have one lockdep_map per struct zram.
>
> Use only one struct lockdep_map per struct zram.
>
> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@xxxxxxxxxxxxx>

Reviewed-by: Sergey Senozhatsky <senozhatsky@xxxxxxxxxxxx>
Tested-by: Sergey Senozhatsky <senozhatsky@xxxxxxxxxxxx>