acpi_os_derive_pci_id_2(rhandle, chandle, id, &is_bridge, &bus_number);
  }
  
 -static void acpi_os_execute_deferred(void *context)
 +static void acpi_os_execute_deferred(struct work_struct *work)
  {
 -      struct acpi_os_dpc *dpc = NULL;
 +      struct acpi_os_dpc *dpc = container_of(work, struct acpi_os_dpc, work);
+ 
 -
 -      dpc = context;
        if (!dpc) {
                printk(KERN_ERR PREFIX "Invalid (NULL) context\n");
                return;
 
                    (reg->space_id != ACPI_ADR_SPACE_FIXED_HARDWARE))
                        continue;
  
 -              cx.address = (reg->space_id == ACPI_ADR_SPACE_FIXED_HARDWARE) ?
 -                  0 : reg->address;
 -
                /* There should be an easy way to extract an integer... */
-               obj = (union acpi_object *)&(element->package.elements[1]);
+               obj = &(element->package.elements[1]);
                if (obj->type != ACPI_TYPE_INTEGER)
                        continue;
  
                cx.type = obj->integer.value;
 -
 -              if ((cx.type != ACPI_STATE_C1) &&
 -                  (reg->space_id != ACPI_ADR_SPACE_SYSTEM_IO))
 -                      continue;
 -
 -              if ((cx.type < ACPI_STATE_C2) || (cx.type > ACPI_STATE_C3))
 -                      continue;
 +              /*
 +               * Some buggy BIOSes won't list C1 in _CST -
 +               * Let acpi_processor_get_power_info_default() handle them later
 +               */
 +              if (i == 1 && cx.type != ACPI_STATE_C1)
 +                      current_count++;
 +
 +              cx.address = reg->address;
 +              cx.index = current_count + 1;
 +
 +              cx.space_id = ACPI_CSTATE_SYSTEMIO;
 +              if (reg->space_id == ACPI_ADR_SPACE_FIXED_HARDWARE) {
 +                      if (acpi_processor_ffh_cstate_probe
 +                                      (pr->id, &cx, reg) == 0) {
 +                              cx.space_id = ACPI_CSTATE_FFH;
 +                      } else if (cx.type != ACPI_STATE_C1) {
 +                              /*
 +                               * C1 is a special case where FIXED_HARDWARE
 +                               * can be handled in non-MWAIT way as well.
 +                               * In that case, save this _CST entry info.
 +                               * That is, we retain space_id of SYSTEM_IO for
 +                               * halt based C1.
 +                               * Otherwise, ignore this info and continue.
 +                               */
 +                              continue;
 +                      }
 +              }
  
-               obj = (union acpi_object *)&(element->package.elements[2]);
+               obj = &(element->package.elements[2]);
                if (obj->type != ACPI_TYPE_INTEGER)
                        continue;