[CPUFREQ] Use swap() in longhaul.c
authorDave Jones <davej@redhat.com>
Wed, 4 Feb 2009 20:28:54 +0000 (15:28 -0500)
committerDave Jones <davej@redhat.com>
Wed, 25 Feb 2009 03:47:31 +0000 (22:47 -0500)
Remove hand-coded implementation of swap()

Signed-off-by: Dave Jones <davej@redhat.com>
arch/x86/kernel/cpu/cpufreq/longhaul.c

index dc03622a83a043831d71e4e5cb3a751a7786b8af..f1c51aea064df73fb28c3793da94c080703d4580 100644 (file)
@@ -511,13 +511,10 @@ static int __init longhaul_get_ranges(void)
                        }
                }
                if (min_i != j) {
-                       unsigned int temp;
-                       temp = longhaul_table[j].frequency;
-                       longhaul_table[j].frequency = longhaul_table[min_i].frequency;
-                       longhaul_table[min_i].frequency = temp;
-                       temp = longhaul_table[j].index;
-                       longhaul_table[j].index = longhaul_table[min_i].index;
-                       longhaul_table[min_i].index = temp;
+                       swap(longhaul_table[j].frequency,
+                            longhaul_table[min_i].frequency);
+                       swap(longhaul_table[j].index,
+                            longhaul_table[min_i].index);
                }
        }