diff options
author | Frank Schaefer <fschaefer.oss@googlemail.com> | 2017-04-16 20:41:52 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2017-04-17 23:29:51 +0300 |
commit | 4d58443696a8e2a4bcae3fc6d32b0bee71ad9fa1 (patch) | |
tree | 6681476d6b0059959209face2f786e29bb6b84b7 /tools/perf/scripts/python/call-graph-from-postgresql.py | |
parent | e7080d4471d805d921a9ea21b32f911a91e248cb (diff) | |
download | linux-4d58443696a8e2a4bcae3fc6d32b0bee71ad9fa1.tar.xz |
[media] em28xx: simplify ID-reading from Micron sensors
Use i2c_smbus_read_word_data() instead of i2c_master_send() and
i2c_master_recv() for reading the ID of Micorn sensors.
i2c_smbus_read_word_data() assumes that byes are in little-endian,
so, it uses:
data->word = msgbuf1[0] | (msgbuf1[1] << 8);
However, Micron datasheet describes the ID as if they were read
in big-endian. So, we need to change the byte order in order to
match the ID number as described on their datasheets.
Signed-off-by: Frank Schäfer <fschaefer.oss@googlemail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions