HOTPLUGPCIFORWINDOWS.docx
《HOTPLUGPCIFORWINDOWS.docx》由会员分享,可在线阅读,更多相关《HOTPLUGPCIFORWINDOWS.docx(18页珍藏版)》请在冰豆网上搜索。
HOTPLUGPCIFORWINDOWS
WindowsPlatformDesignNotes
DesignInformationfortheMicrosoft®Windows®FamilyofOperatingSystems
Hot-PlugPCIandWindows
Abstract
Hot-PlugPCIallowsuserstoinstallandremovePCIdeviceswhilethecomputerisrunning.Microsoft®Windows® 2000,Windows XP,andtheWindowsServer 2003familysupportHot-PlugPCIthroughACPI.
TotakeadvantageofHot-PlugPCIsupportonWindowsoperatingsystems,manufacturersofhot-pluggablePCIdevicesandHot-PlugPCIcontrollersshoulddevelopstandardPlugandPlaydriversfortheirdevices,andimplementinsertionandremovalnotificationsasdefinedinACPI 1.0b.Hot-PlugPCIcontrollersshouldalsoimplementthe_HPPobjectasdefinedinACPI2.0forWindows XPandtheWindowsServer 2003family,andfollowstandardrulesforimplementingACPIeventswhenconnectingtoGeneralPurposeEvents(GPEs),asdescribedinthisarticle.
SupportforStandardHotPlugController(SHPC)asdefinedinPCIStandardHot-PlugControllerandSubsystemSpecification,Revision1.0,isplannedforthenextversionofWindows,codenamedWindows"Longhorn."
ManufacturesofSHPCsshouldensurethattheirdevicescomplywiththespecification,andwithMicrosoftWindowsLogoProgramrequirements,asdescribedinthispaper.Windows"Longhorn"willincludein-boxsupportthroughasingleSHPCdriver.ThisdriverwillsupportallSHPCsthataredesignedtotheserequirements.SHPCimplementationswillnotrequireACPIinsertionandremovalnotifications.
Version1.5–January21,1003
Contents
WindowsHot-PlugPCIRoadmap1
PreparingDriversforHot-PlugPCI3
ImplementingACPI-basedHot-PlugPCIinSystems4
ExampleNamespaceforHot-PlugPCI4
ConnectingGeneralPurposeEvents6
WindowsLogoProgramTimeline8
CalltoAction8
RelatedInformation9
MicrosoftCorporationmayhavepatentsorpendingpatentapplications,trademarks,copyrights,orotherintellectualpropertyrightscoveringsubjectmatterinthisdocument.Thefurnishingofthisdocumentdoesnotgiveyouanylicensetothepatents,trademarks,copyrights,orotherintellectualpropertyrightsexceptasexpresslyprovidedinanywrittenlicenseagreementfromMicrosoftCorporation.
Portionsofthisdocumentspecifysoftwarethatisstillindevelopment.Someoftheinformationinthisdocumentationmaybeinaccurateormaynotbeanaccuraterepresentationofthefunctionalityoffinaldocumentationorsoftware.Microsoftassumesnoresponsibilityforanydamagesthatmightoccurdirectlyorindirectlyfromtheseinaccuracies.
Microsoftdoesnotmakeanyrepresentationorwarrantyregardingspecificationsinthisdocumentoranyproductoritemdevelopedbasedonthesespecifications.ThisdocumentisprovidedtoyouonanASISbasis.Microsoftdisclaimsallexpressandimpliedwarranties,includingbutnotlimitedtotheimpliedwarrantiesormerchantability,fitnessforaparticularpurposeandfreedomfrominfringement.Withoutlimitingthegeneralityoftheforegoing,Microsoftdoesnotmakeanywarrantyofanykindthatanyitemdevelopedbasedonthesespecifications,oranyportionofaspecification,willnotinfringeanycopyright,patent,tradesecretorotherintellectualpropertyrightofanypersonorentityinanycountry.Itisyourresponsibilitytoseeklicensesforsuchintellectualpropertyrightswhereappropriate.Microsoftshallnotbeliableforanydamagesofanykindarisingoutoforinconnectionwiththeuseofthesespecifications,includingwithoutlimitation,anydirect,indirect,incidental,consequential(includinganylostprofits),punitiveorspecialdamages,whetherornotMicrosofthasbeenadvisedofsuchdamages..Somestatesdonotallowtheexclusionorlimitationofliabilityorconsequentialorincidentaldamages;theabovelimitationmaynotapplytoyou.
TheinformationcontainedinthisdocumentrepresentsthecurrentviewofMicrosoftCorporationontheissuesdiscussedasofthedateofpublication.BecauseMicrosoftmustrespondtochangingmarketconditions,itshouldnotbeinterpretedtobeacommitmentonthepartofMicrosoft,andMicrosoftcannotguaranteetheaccuracyofanyinformationpresented.Thisdocumentisforinformationalpurposesonly.MICROSOFTMAKESNOWARRANTIES,EXPRESSORIMPLIED,INTHISDOCUMENT.
Microsoft,Windows,andWindowsNTaretrademarksorregisteredtrademarksofMicrosoftCorporationintheUnitedStatesand/orothercountries.Otherproductandcompanynamesmentionedhereinmaybethetrademarksoftheirrespectiveowners.
©2003MicrosoftCorporation.Allrightsreserved.
WindowsHot-PlugPCIRoadmap
Hot-PlugPCIreferstothetechnologythatallowsuserstoinstallandremovePCIdeviceswhilethecomputerisrunning.Hot-PlugPCIshouldnotbeconfusedwithfail-overfunctionalitythatallowsautomaticswitchingtoaredundantdeviceinthecaseofafailure.Hot-PlugPCIinthispaperrefersstrictlytoinsertingandremovingPCIdevicesinarunningsystem.TheinformationinthispaperdoesnotapplytoCompactPCI,whichisadifferenthardwaretechnologythatalsoprovideshot-plugandfail-overfunctionality.
ThePCIHot-PlugSpecificationdescribesthehardwarerequirementsandinterfacestousewhendesigningHot-PlugPCIdevices.ThisspecificationispublishedbythePCISpecialInterestGroup(PCISIG)andisavailableonlineat
AlthoughthePCIHot-PlugSpecificationdescribeshardwarerequirements,itcurrentlydoesnotdefineacompletesoftwareinterfaceforhandlinginsertionandremovalevents.Therefore,thesoftwareinterfaceWindows 2000supportsforHot-PlugPCI istheAdvancedConfigurationandPowerInterface(ACPI)specification,Revision1.0b.ThesoftwareinterfacethatWindows XPsupportsisACPI 1.0balongwithoneadditionalobjectintroducedinACPI2.0(the_HPPobject).Allinsert,eject,andremovaleventscanbehandledthroughACPI 1.0bonWindows 2000andWindows XPsystems.NotethatthesearethesamemechanismsWindows 2000andWindows XPuseforsupportinghot-dockingofmobilePCs.Hardwaremanufacturerswhoarefamiliarwithhot-dockingcanusetheirknowledgetoimplementHot-PlugPCI.TheACPIspecificationisavailableathttp:
//www.acpi.info/
ThePCIStandardHot-PlugControllerandSubsystemSpecification,Revision1.0,definesstandardhot-pluginterfacessothatallSHPCscanuseasingledriverandusagemodel.Thisspecificationisavailableat.
TherestofthissectiondescribesnativeHot-PlugPCIsupportimplementedinWindows 2000,Windows XP,andtheWindowsServer 2003family,anditdescribesplannedsupportforSHPCinWindows"Longhorn."
Windows 2000 Hot-PlugPCIsupportinWindows 2000consistsofthefollowing:
∙InsertionandremovalnotificationsasdefinedintheACPIspecification,Revision1.0b
∙Single-levelresourcere-allocation
Theoperatingsystemcanre-allocatehardwareresources(I/Oandmemoryapertures)atruntimeonasinglebussegmentonly.Theoperatingsystemcanstartadevicethatishot-pluggedbehindabridgeonlyiftheresourcesallocatedtothebridgearesufficienttoaccommodatethenewdevice.Ifresourcesallocatedtothebridgearenotsufficienttoaccommodatethenewdevice,theoperatingsystemcannotreconfigurePCI-to-PCIbridgesatruntimetoaddressthedeviceresourcerequirements.
ForinformationaboutmemoryandI/OresourceallocationsforPCI-to-PCIbridges,seetheresourceslistedattheendofthisarticle.
∙Optionalvendor-suppliedfilterdriver
Hardwaremanufacturerscansupplyanoptionalfilterdrivertosupporthot-plugfeaturesofadevice,suchasaproprietaryLEDdisplayforprovidingoutputtousers.
Windows XPACPIhot-plugsupportprovidedinWindows XPisanincrementalimprovementoverWindows 2000.Thefollowinghot-plugsupportisincludedinWindows XP(andtheWindowsServer 2003family):
∙InsertionandremovalnotificationsasdefinedintheACPIspecification,Revision1.0b
SameasinWindows 2000
∙Single-levelresourcere-allocation
SameasinWindows 2000
∙Optionalvendor-suppliedfilterdriver
SameasWindows 2000
∙New_HPPobjectdefinedintheACPI 2.0specification
Thisobjectimprovestheoperatingsystem’sabilitytooptimallyconfiguredevicesinsertedintohot-plugslots.
The_HPPobjectintheACPIBIOSmustbeassociatedwithaPCI-PCIbridge.Theobjectinformstheoperatingsystemofthedefaultsettingsthatshouldbeusedforadd-incardsinsertedintohot-plugslotslocatedbehindthebridge.Theseparameterswillalsobeusedbytheoperatingsystemtoprogramhot-pluggeddevicesanddevicesthatareinsertedbeforesystembootbutnotconfiguredbytheBIOS.Thedefaultsettingsaddressedbythe_HPPobjectare:
Cache-linesizeconfigurationregister
Latencytimerconfigurationregister
SERRENABLEbitinthePCIconfigurationcommandregister
PARITYERRORRESPONSEbitinthePCIconfigurationcommandregister
AlthoughWindows XPsupportsthe_HPPobjectfromACPI 2.0,itisnotconsideredanACPI 2.0-compliantoperatingsystembecauseitdoesnotsupportallACPI 2.0enhancements.Forexample,Windows XPdoesnotsupporttheneweventnotificationsdefinedintheACPI 2.0Specification.
ACPIhot-plugsupportisconsistentforboth32-bitand64-bitversionsofWindows XP.
FutureSupportMicrosoftisinvestigatingthefollowingnativesupportforHot-PlugPCIinafutureversionoftheoperatingsystem,codenamedWindows"Longhorn":
∙OperatingsystemsupportforSHPC
ForWindows"Longhorn,"SHPCsmustbedesignedtoconformtotheguidelineslistedinPCIStandardHot-PlugControllerandSubsystemSpecification,Revision1.0,andtheWindowsLogoProgramrequirementsfortheSHPCdriver.SHPCsthathavebeendesignedtomeetthe