]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
media: allegro: rework read/write to mailbox
authorMichael Tretter <m.tretter@pengutronix.de>
Mon, 13 Jul 2020 14:42:19 +0000 (16:42 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Sun, 19 Jul 2020 12:00:31 +0000 (14:00 +0200)
commite561f8e24c5ade18f97970c3034ac0f965370c3f
treedc78e3c9a846fb558c2415beb055350a37554063
parent94dc765602618fdab8bc4eaa96e3053929d8ff8f
media: allegro: rework read/write to mailbox

Rework the functions that read and write the SRAM that is used to
communicate with the MCU.

As the functions will not operate on structs but on prepared binary
buffers, make the buffer stride more explicit. Also, avoid any uses of
struct mcu_msg_header to analyze messages in memory, because the header
will be made independent of the binary representation in the mailbox.
Instead explicitly access the mail size field in the mailbox.

As at it, further reduce the dependency between the mailboxes and struct
allegro_dev.

Signed-off-by: Michael Tretter <m.tretter@pengutronix.de>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/staging/media/allegro-dvt/allegro-core.c