mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
macintosh/via-macii: Access autopoll_devs when inside lock
[ Upstream commit 59ea38f6b3af5636edf541768a1ed721eeaca99e ]
The interrupt handler should be excluded when accessing the autopoll_devs
variable.
Fixes: d95fd5fce8 ("m68k: Mac II ADB fixes") # v5.0+
Signed-off-by: Finn Thain <[email protected]>
Tested-by: Stan Johnson <[email protected]>
Signed-off-by: Michael Ellerman <[email protected]>
Link: https://lore.kernel.org/r/5952dd8a9bc9de90f1acc4790c51dd42b4c98065.1593318192.git.fthain@telegraphics.com.au
Signed-off-by: Sasha Levin <[email protected]>
This commit is contained in:
parent
a88f86763c
commit
8456017563
1 changed files with 3 additions and 6 deletions
|
|
@ -270,15 +270,12 @@ static int macii_autopoll(int devs)
|
|||
unsigned long flags;
|
||||
int err = 0;
|
||||
|
||||
local_irq_save(flags);
|
||||
|
||||
/* bit 1 == device 1, and so on. */
|
||||
autopoll_devs = devs & 0xFFFE;
|
||||
|
||||
if (!autopoll_devs)
|
||||
return 0;
|
||||
|
||||
local_irq_save(flags);
|
||||
|
||||
if (current_req == NULL) {
|
||||
if (autopoll_devs && !current_req) {
|
||||
/* Send a Talk Reg 0. The controller will repeatedly transmit
|
||||
* this as long as it is idle.
|
||||
*/
|
||||
|
|
|
|||
Loading…
Reference in a new issue