Skip to content
Commit f102aa14 authored by Axel Lin's avatar Axel Lin Committed by Mark Brown
Browse files

ASoC: max98088: Get rid of max98088_access table



The max98088_access table is used for look up readable/writable/volatile
attributes of registers. The readable/writable/volatile registers are
mostly in continuous ranges, so we can replace the max98088_access table
entirely by using case range.

Below is a summary of the readable/writeable/volatile registers:

readable registers:
        0x00 ~ 0xC9, 0xFF
writeable registers:
        0x03 ~ 0xC9
volatile registers:
        0x00 ~ 0x03, 0xFF

Note, 0x00 should be read-only according to the datasheet.

This patch reworks the implement for .readable and .volatile and also add
implementation for .writable callback.

Signed-off-by: default avatarAxel Lin <axel.lin@ingics.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent b650247d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment