]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
macintosh/adb-iop: Send correct poll command
authorFinn Thain <fthain@telegraphics.com.au>
Fri, 20 Nov 2020 04:39:56 +0000 (15:39 +1100)
committerPaolo Pisati <paolo.pisati@canonical.com>
Mon, 4 Jan 2021 15:37:20 +0000 (16:37 +0100)
commit2721d3036605b92a9f4b8c2c2e7bb228a12cc289
treeade67260afa84642a1b3d978495e4517173da302
parenteb6af391e847013908eaa24f44cf6616b5109f53
macintosh/adb-iop: Send correct poll command

BugLink: https://bugs.launchpad.net/bugs/1910111
[ Upstream commit 10199e90ee20e68859f8128331ec8d85b036d349 ]

The behaviour of the IOP firmware is not well documented but we do know
that IOP message reply data can be used to issue new ADB commands.
Use the message reply to better control autopoll behaviour by sending
a Talk Register 0 command after every ADB response, not unlike the
algorithm in the via-macii driver. This poll command is addressed to
that device which last received a Talk command (explicit or otherwise).

Cc: Joshua Thompson <funaho@jurai.org>
Fixes: 32226e817043 ("macintosh/adb-iop: Implement idle -> sending state transition")
Tested-by: Stan Johnson <userm57@yahoo.com>
Signed-off-by: Finn Thain <fthain@telegraphics.com.au>
Link: https://lore.kernel.org/r/58bba4310da4c29b068345a4b36af8a531397ff7.1605847196.git.fthain@telegraphics.com.au
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
drivers/macintosh/adb-iop.c