OSDN Git Service

m68k: mac: Fix VIA timer counter accesses
authorFinn Thain <fthain@telegraphics.com.au>
Sat, 1 Dec 2018 00:53:10 +0000 (11:53 +1100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 29 Jan 2020 09:21:41 +0000 (10:21 +0100)
commit1f4738fa3e743a3bb29d64efbb8f428b1720c145
tree96ce36f7e8d417ac9451f59d53ad48dc7a6a30a8
parent6427ae06e4026d1e7dc75d8bc1c211f75b3ca0fc
m68k: mac: Fix VIA timer counter accesses

[ Upstream commit 0ca7ce7db771580433bf24454f7a1542bd326078 ]

This resolves some bugs that affect VIA timer counter accesses.
Avoid lost interrupts caused by reading the counter low byte register.
Make allowance for the fact that the counter will be decremented to
0xFFFF before being reloaded.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Finn Thain <fthain@telegraphics.com.au>
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
arch/m68k/mac/via.c