Ignore:
Timestamp:
Apr 3, 2013, 11:13:13 PM (12 years ago)
Author:
David Azarewicz
Message:

Makefile updates
Debug output improvements
Support for ACPI suspend/resume added

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/os2ahci/os2ahci.c

    r152 r153  
    121121u16             ad_ignore;         /* bitmap with adapter indexes to ignore */
    122122int             init_complete;     /* if != 0, initialization has completed */
     123int             suspended;
    123124
    124125/* apapter/port-specific options saved when parsing the command line */
     
    163164  case CMDINPUT:
    164165    rc = char_dev_input((RP_RWV _far *) req);
     166    break;
     167
     168  case CMDSaveRestore:
     169    rc = sr_drv(((RPSAVERESTORE _far *) req)->FuncCode);
    165170    break;
    166171
     
    203208  }
    204209  init_drv_called = 1;
     210  suspended = 0;
    205211
    206212  /* set device helper entry point */
     
    373379    trace_init();
    374380  }
     381  dprintf("BldLevel: %s\n", BldLevel);
     382  dprintf("CmdLine: %Fs\n", cmd_line);
    375383
    376384  /* scan PCI bus for supported devices */
     
    518526
    519527  apm_suspend();
     528  return(STDON);
     529}
     530
     531/******************************************************************************
     532 * Device driver suspend/resume handler. This handler is called when ACPI is
     533 * executing a suspend or resume.
     534 */
     535USHORT sr_drv(int func)
     536{
     537  dprintf("sr_drv(%d) called\n", func);
     538
     539  if (func) apm_resume();
     540  else apm_suspend();
     541
    520542  return(STDON);
    521543}
Note: See TracChangeset for help on using the changeset viewer.