Pull osi into release branch
authorLen Brown <len.brown@intel.com>
Sun, 22 Jul 2007 06:29:41 +0000 (02:29 -0400)
committerLen Brown <len.brown@intel.com>
Sun, 22 Jul 2007 06:29:41 +0000 (02:29 -0400)
1  2 
drivers/acpi/osl.c

diff --combined drivers/acpi/osl.c
index 00d53c2fd1e823bbf088863d3ae6577ef1da0606,5cfb7b5cc0b813130371a0daf9bf65cf811709cf..12c09fafce9a29de915966be172e96a94eef79a1
@@@ -77,13 -77,7 +77,7 @@@ static struct workqueue_struct *kacpi_n
  #define       OSI_STRING_LENGTH_MAX 64        /* arbitrary */
  static char osi_additional_string[OSI_STRING_LENGTH_MAX];
  
- #define OSI_LINUX_ENABLED
- #ifdef        OSI_LINUX_ENABLED
- int osi_linux = 1;    /* enable _OSI(Linux) by default */
- #else
- int osi_linux;                /* disable _OSI(Linux) by default */
- #endif
+ static int osi_linux;         /* disable _OSI(Linux) by default */
  
  #ifdef CONFIG_DMI
  static struct __initdata dmi_system_id acpi_osl_dmi_table[];
@@@ -999,11 -993,11 +993,11 @@@ static int __init acpi_osi_setup(char *
        if (str == NULL || *str == '\0') {
                printk(KERN_INFO PREFIX "_OSI method disabled\n");
                acpi_gbl_create_osi_method = FALSE;
 +      } else if (!strcmp("!Linux", str)) {
 +              enable_osi_linux(0);
        } else if (*str == '!') {
                if (acpi_osi_invalidate(++str) == AE_OK)
                        printk(KERN_INFO PREFIX "Deleted _OSI(%s)\n", str);
 -      } else if (!strcmp("!Linux", str)) {
 -              enable_osi_linux(0);
        } else if (!strcmp("Linux", str)) {
                enable_osi_linux(1);
        } else if (*osi_additional_string == '\0') {
@@@ -1098,7 -1092,7 +1092,7 @@@ void acpi_os_release_lock(acpi_spinloc
  acpi_status
  acpi_os_create_cache(char *name, u16 size, u16 depth, acpi_cache_t ** cache)
  {
 -      *cache = kmem_cache_create(name, size, 0, 0, NULL, NULL);
 +      *cache = kmem_cache_create(name, size, 0, 0, NULL);
        if (*cache == NULL)
                return AE_ERROR;
        else
@@@ -1183,17 -1177,10 +1177,10 @@@ acpi_os_validate_interface (char *inter
        if (!strcmp("Linux", interface)) {
                printk(KERN_WARNING PREFIX
                        "System BIOS is requesting _OSI(Linux)\n");
- #ifdef        OSI_LINUX_ENABLED
-               printk(KERN_WARNING PREFIX
-                       "Please test with \"acpi_osi=!Linux\"\n"
-                       "Please send dmidecode "
-                       "to linux-acpi@vger.kernel.org\n");
- #else
                printk(KERN_WARNING PREFIX
                        "If \"acpi_osi=Linux\" works better,\n"
                        "Please send dmidecode "
                        "to linux-acpi@vger.kernel.org\n");
- #endif
                if(osi_linux)
                        return AE_OK;
        }
@@@ -1227,36 -1214,14 +1214,14 @@@ acpi_os_validate_address 
  }
  
  #ifdef CONFIG_DMI
- #ifdef        OSI_LINUX_ENABLED
- static int dmi_osi_not_linux(struct dmi_system_id *d)
- {
-       printk(KERN_NOTICE "%s detected: requires not _OSI(Linux)\n", d->ident);
-       enable_osi_linux(0);
-       return 0;
- }
- #else
  static int dmi_osi_linux(struct dmi_system_id *d)
  {
-       printk(KERN_NOTICE "%s detected: requires _OSI(Linux)\n", d->ident);
+       printk(KERN_NOTICE "%s detected: enabling _OSI(Linux)\n", d->ident);
        enable_osi_linux(1);
        return 0;
  }
- #endif
  
  static struct dmi_system_id acpi_osl_dmi_table[] __initdata = {
- #ifdef        OSI_LINUX_ENABLED
-       /*
-        * Boxes that need NOT _OSI(Linux)
-        */
-       {
-        .callback = dmi_osi_not_linux,
-        .ident = "Toshiba Satellite P100",
-        .matches = {
-                    DMI_MATCH(DMI_BOARD_VENDOR, "TOSHIBA"),
-                    DMI_MATCH(DMI_BOARD_NAME, "Satellite P100"),
-                    },
-        },
- #else
        /*
         * Boxes that need _OSI(Linux)
         */
                     DMI_MATCH(DMI_BOARD_NAME, "MPAD-MSAE Customer Reference Boards"),
                     },
         },
- #endif
        {}
  };
  #endif /* CONFIG_DMI */