kernel/debug/debug_core.c: more properly delay for secondary CPUs
[firefly-linux-kernel-4.4.55.git] / kernel / debug / debug_core.c
index 0874e2edd2756bcbe5542a496fb6b131b092b3ea..79517e5549f119aff663ff5572507c70671a2b41 100644 (file)
@@ -598,11 +598,11 @@ return_normal:
        /*
         * Wait for the other CPUs to be notified and be waiting for us:
         */
-       time_left = loops_per_jiffy * HZ;
+       time_left = MSEC_PER_SEC;
        while (kgdb_do_roundup && --time_left &&
               (atomic_read(&masters_in_kgdb) + atomic_read(&slaves_in_kgdb)) !=
                   online_cpus)
-               cpu_relax();
+               udelay(1000);
        if (!time_left)
                pr_crit("Timed out waiting for secondary CPUs.\n");