Commit 3981514
regmap: Account for register length when chunking
Currently, when regmap_raw_write() splits the data, it uses the
max_raw_write value defined for the bus. For any bus that includes
the target register address in the max_raw_write value, the chunked
transmission will always exceed the maximum transmission length.
To avoid this problem, subtract the length of the register and the
padding from the maximum transmission.
Signed-off-by: Jim Wylder <jwylder@google.com
Link: https://lore.kernel.org/r/20230517152444.3690870-2-jwylder@google.com
Signed-off-by: Mark Brown <broonie@kernel.org1 parent 70a640c commit 3981514
1 file changed
Lines changed: 4 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2082 | 2082 | | |
2083 | 2083 | | |
2084 | 2084 | | |
| 2085 | + | |
| 2086 | + | |
2085 | 2087 | | |
2086 | 2088 | | |
2087 | 2089 | | |
2088 | 2090 | | |
2089 | 2091 | | |
2090 | 2092 | | |
2091 | 2093 | | |
2092 | | - | |
2093 | | - | |
| 2094 | + | |
| 2095 | + | |
2094 | 2096 | | |
2095 | 2097 | | |
2096 | 2098 | | |
| |||
0 commit comments