OSDN Git Service

parisc: Reorder TLB flush timing calculation
authorJohn David Anglin <dave.anglin@bell.net>
Wed, 17 Oct 2018 00:49:56 +0000 (20:49 -0400)
committerHelge Deller <deller@gmx.de>
Wed, 17 Oct 2018 06:18:00 +0000 (08:18 +0200)
commita886c9791aed64d73f8c0038cc1506741ba216fa
treefce68683084a6861c96f13e030f2eaec9cb0e853
parent7c4ba3d38a3b013b79c3c07a639504cdc68fefdf
parisc: Reorder TLB flush timing calculation

On boot (mostly reboot), my c8000 sometimes crashes after it prints the
TLB flush threshold.  The lockup is hard.  The front LED flashes red and
the box must be unplugged to reset the error.

I noticed that when the crash occurs the TLB flush threshold is about
one quarter what it is on a successful boot.  If I disabled the
calculation, the crash didn't occur.  There also seemed to be a timing
dependency affecting the crash.  I finally realized that the
flush_tlb_all() timing test runs just after the secondary CPUs are
started.  There seems to be a problem with running flush_tlb_all() too
soon after the CPUs are started.

The timing for the range test always seemed okay.  So, I reversed the
order of the two timing tests and I haven't had a crash at this point so
far.

I added a couple of information messages which I have left to help with
diagnosis if the problem should appear on another machine.

This version reduces the minimum TLB flush threshold to 16 KiB.

Signed-off-by: John David Anglin <dave.anglin@bell.net>
Signed-off-by: Helge Deller <deller@gmx.de>
arch/parisc/kernel/cache.c