mirror of
https://github.com/torvalds/linux.git
synced 2026-11-07 06:17:02 +01:00
Input: gscps2 - drop busy-wait and manual interrupt pump on transmit
In gscps2_writeb_output(), after writing data to GSC_XMTDATA, the driver explicitly executed mdelay(6) and manually called gscps2_interrupt() as a polling mechanism to accelerate command responses (such as keyboard ACK or LED updates). On PA-RISC, the PS/2 controller asserts a level interrupt to the system ASIC whenever received data arrives in hardware, and the input/serio subsystem handles command responses asynchronously via completions. Busy-waiting for 6 ms on every transmitted byte introduces significant unnecessary latency during multi-byte command sequences and complicates interrupt handler locking. Remove mdelay(6) and the manual invocation of gscps2_interrupt() from gscps2_writeb_output(), relying on normal hardware interrupt delivery. Reported-by: sashiko-bot@kernel.org Assisted-by: LLM Link: https://patch.msgid.link/20260830-gscps2-v1-7-c733d4cae7f9@gmail.com Acked-by: Helge Deller <deller@gmx.de> Tested-by: Helge Deller <deller@gmx.de> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
This commit is contained in:
parent
21f6c39938
commit
daae2ab46e
|
|
@ -356,13 +356,6 @@ static inline int gscps2_writeb_output(struct gscps2port *ps2port, u8 data)
|
|||
scoped_guard(spinlock_irqsave, &ps2port->lock)
|
||||
writeb(data, addr + GSC_XMTDATA);
|
||||
|
||||
/* this is ugly, but due to timing of the port it seems to be necessary. */
|
||||
mdelay(6);
|
||||
|
||||
/* make sure any received data is returned as fast as possible */
|
||||
/* this is important e.g. when we set the LEDs on the keyboard */
|
||||
gscps2_interrupt(0, NULL);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user