]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - drivers/staging/speakup/fakekey.c
Merge tag 'v2.6.38' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
[mv-sheeva.git] / drivers / staging / speakup / fakekey.c
index 65b231178f0580d30a4233e17bf31eb73c7df6f7..1b34a87716418b8af6248d0540d9958f2b0cbd2e 100644 (file)
@@ -78,10 +78,10 @@ void speakup_fake_down_arrow(void)
        /* don't change CPU */
        preempt_disable();
 
-       __get_cpu_var(reporting_keystroke) = true;
+       __this_cpu_write(reporting_keystroke, true);
        input_report_key(virt_keyboard, KEY_DOWN, PRESSED);
        input_report_key(virt_keyboard, KEY_DOWN, RELEASED);
-       __get_cpu_var(reporting_keystroke) = false;
+       __this_cpu_write(reporting_keystroke, false);
 
        /* reenable preemption */
        preempt_enable();
@@ -95,10 +95,5 @@ void speakup_fake_down_arrow(void)
         */
 bool speakup_fake_key_pressed(void)
 {
-       bool is_pressed;
-
-       is_pressed = get_cpu_var(reporting_keystroke);
-       put_cpu_var(reporting_keystroke);
-
-       return is_pressed;
+       return this_cpu_read(reporting_keystroke);
 }