aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorLars-Peter Clausen <[email protected]>2015-01-23 12:52:24 -0300
committerMauro Carvalho Chehab <[email protected]>2015-02-02 11:40:14 -0200
commit3999e5d01da74f1a22afbb0b61b3992fea301478 (patch)
tree3be79b327c87cc90a3a7ca14a3eea497ac8ccf57 /tools/perf/scripts/python
parent029d61779189a488d5649dab43c83cc6497e8843 (diff)
[media] adv7180: Do implicit register paging
The ad7180 has multiple register pages which can be switched between by writing to a register. Currently the driver manually switches between pages whenever a register outside of the default register map is accessed and switches back after it has been accessed. This is a bit tedious and also potential source for bugs. This patch adds two helper functions that take care of switching between pages and reading/writing the register. The register numbers for registers are updated to encode both the page (in the upper 8-bits) and the register (in the lower 8-bits) numbers. Having multiple pages means that a register access is not a single atomic i2c_smbus_write_byte_data() or i2c_smbus_read_byte_data() call and we need to make sure that concurrent register access does not race against each other. Signed-off-by: Lars-Peter Clausen <[email protected]> Acked-by: Federico Vaga <[email protected]> Acked-by: Hans Verkuil <[email protected]> Signed-off-by: Hans Verkuil <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions