parisc: Reduce irq overhead when run in qemu
authorHelge Deller <deller@gmx.de>
Mon, 12 Feb 2018 20:43:55 +0000 (21:43 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 Mar 2018 06:41:04 +0000 (22:41 -0800)
commit47e7fc96cddca4d78498dd0e8da98ca018b2633b
treec42a22f6d6e3124602b2c4322c92f7ec5ed911a7
parent90c3f0d36000dcddc0bf2b1b889784a8795cc4d6
parisc: Reduce irq overhead when run in qemu

commit 636a415bcc7f4fd020ece8fd5fc648c4cef19c34 upstream.

When run under QEMU, calling mfctl(16) creates some overhead because the
qemu timer has to be scaled and moved into the register. This patch
reduces the number of calls to mfctl(16) by moving the calls out of the
loops.

Additionally, increase the minimal time interval to 8000 cycles instead
of 500 to compensate possible QEMU delays when delivering interrupts.

Signed-off-by: Helge Deller <deller@gmx.de>
Cc: stable@vger.kernel.org # 4.14+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/parisc/kernel/time.c