]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/x86/kernel/geode_32.c
Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6
[linux-2.6-omap-h63xx.git] / arch / x86 / kernel / geode_32.c
index 9c7f7d3959689af664bd7060b8f5c918a495dd14..9b08e852fd1ae63d3312552dd6898622ee4fd73b 100644 (file)
@@ -161,16 +161,35 @@ void geode_gpio_setup_event(unsigned int gpio, int pair, int pme)
 }
 EXPORT_SYMBOL_GPL(geode_gpio_setup_event);
 
-static int __init geode_southbridge_init(void)
+int geode_has_vsa2(void)
 {
-       int timers;
+       static int has_vsa2 = -1;
+
+       if (has_vsa2 == -1) {
+               u16 val;
+
+               /*
+                * The VSA has virtual registers that we can query for a
+                * signature.
+                */
+               outw(VSA_VR_UNLOCK, VSA_VRC_INDEX);
+               outw(VSA_VR_SIGNATURE, VSA_VRC_INDEX);
+
+               val = inw(VSA_VRC_DATA);
+               has_vsa2 = (val == AMD_VSA_SIG || val == GSW_VSA_SIG);
+       }
 
+       return has_vsa2;
+}
+EXPORT_SYMBOL_GPL(geode_has_vsa2);
+
+static int __init geode_southbridge_init(void)
+{
        if (!is_geode())
                return -ENODEV;
 
        init_lbars();
-       timers = geode_mfgpt_detect();
-       printk(KERN_INFO "geode:  %d MFGPT timers available.\n", timers);
+       (void) mfgpt_timer_setup();
        return 0;
 }