#define PM_AWKD                        0x50
 #define PM_SSC                 0x54
 
-/* VSA2 magic values */
-
-#define VSA_VRC_INDEX          0xAC1C
-#define VSA_VRC_DATA           0xAC1E
-#define VSA_VR_UNLOCK          0xFC53  /* unlock virtual register */
-#define VSA_VR_SIGNATURE       0x0003
-#define VSA_VR_MEM_SIZE                0x0200
-#define AMD_VSA_SIG            0x4132  /* signature is ascii 'VSA2' */
-#define GSW_VSA_SIG            0x534d  /* General Software signature */
-
 static inline u32 geode_gpio(unsigned int nr)
 {
        BUG_ON(nr > 28);
        return (is_geode_gx() || is_geode_lx());
 }
 
-#ifdef CONFIG_MGEODE_LX
-extern int geode_has_vsa2(void);
-#else
-static inline int geode_has_vsa2(void)
-{
-       return 0;
-}
-#endif
-
 static inline void geode_mfgpt_write(int timer, u16 reg, u16 value)
 {
        u32 base = geode_get_dev_base(GEODE_DEV_MFGPT);
 
 }
 EXPORT_SYMBOL_GPL(geode_gpio_setup_event);
 
-int geode_has_vsa2(void)
-{
-       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())
 
        unsigned char *romsig;
 
        /* The ioremap check is dangerous; limit what we run it on */
-       if (!is_geode() || geode_has_vsa2())
+       if (!is_geode() || cs5535_has_vsa2())
                return 0;
 
        spin_lock_init(&ec_lock);
                        (unsigned char *) &olpc_platform_info.ecver, 1);
 
        /* check to see if the VSA exists */
-       if (geode_has_vsa2())
+       if (cs5535_has_vsa2())
                olpc_platform_info.flags |= OLPC_F_VSA;
 
        printk(KERN_INFO "OLPC board revision %s%X (EC=%x)\n",
 
 {
        unsigned int val;
 
-       if (!geode_has_vsa2()) {
+       if (!cs5535_has_vsa2()) {
                uint32_t hi, lo;
 
                /* The number of pages is (PMAX - PMIN)+1 */
 
 {
        unsigned int val;
 
-       if (!geode_has_vsa2()) {
+       if (!cs5535_has_vsa2()) {
                uint32_t hi, lo;
 
                /* The number of pages is (PMAX - PMIN)+1 */
 
 #define LBAR_ACPI_SIZE         0x40
 #define LBAR_PMS_SIZE          0x80
 
+/* VSA2 magic values */
+#define VSA_VRC_INDEX          0xAC1C
+#define VSA_VRC_DATA           0xAC1E
+#define VSA_VR_UNLOCK          0xFC53  /* unlock virtual register */
+#define VSA_VR_SIGNATURE       0x0003
+#define VSA_VR_MEM_SIZE                0x0200
+#define AMD_VSA_SIG            0x4132  /* signature is ascii 'VSA2' */
+#define GSW_VSA_SIG            0x534d  /* General Software signature */
+
+#include <linux/io.h>
+
+static inline int cs5535_has_vsa2(void)
+{
+       static int has_vsa2 = -1;
+
+       if (has_vsa2 == -1) {
+               uint16_t 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;
+}
+
 /* GPIOs */
 #define GPIO_OUTPUT_VAL                0x00
 #define GPIO_OUTPUT_ENABLE     0x04