mpi2_cnfg.h 145 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494
  1. /*
  2. * Copyright 2000-2015 Avago Technologies. All rights reserved.
  3. *
  4. *
  5. * Name: mpi2_cnfg.h
  6. * Title: MPI Configuration messages and pages
  7. * Creation Date: November 10, 2006
  8. *
  9. * mpi2_cnfg.h Version: 02.00.35
  10. *
  11. * NOTE: Names (typedefs, defines, etc.) beginning with an MPI25 or Mpi25
  12. * prefix are for use only on MPI v2.5 products, and must not be used
  13. * with MPI v2.0 products. Unless otherwise noted, names beginning with
  14. * MPI2 or Mpi2 are for use with both MPI v2.0 and MPI v2.5 products.
  15. *
  16. * Version History
  17. * ---------------
  18. *
  19. * Date Version Description
  20. * -------- -------- ------------------------------------------------------
  21. * 04-30-07 02.00.00 Corresponds to Fusion-MPT MPI Specification Rev A.
  22. * 06-04-07 02.00.01 Added defines for SAS IO Unit Page 2 PhyFlags.
  23. * Added Manufacturing Page 11.
  24. * Added MPI2_SAS_EXPANDER0_FLAGS_CONNECTOR_END_DEVICE
  25. * define.
  26. * 06-26-07 02.00.02 Adding generic structure for product-specific
  27. * Manufacturing pages: MPI2_CONFIG_PAGE_MANUFACTURING_PS.
  28. * Rework of BIOS Page 2 configuration page.
  29. * Fixed MPI2_BIOSPAGE2_BOOT_DEVICE to be a union of the
  30. * forms.
  31. * Added configuration pages IOC Page 8 and Driver
  32. * Persistent Mapping Page 0.
  33. * 08-31-07 02.00.03 Modified configuration pages dealing with Integrated
  34. * RAID (Manufacturing Page 4, RAID Volume Pages 0 and 1,
  35. * RAID Physical Disk Pages 0 and 1, RAID Configuration
  36. * Page 0).
  37. * Added new value for AccessStatus field of SAS Device
  38. * Page 0 (_SATA_NEEDS_INITIALIZATION).
  39. * 10-31-07 02.00.04 Added missing SEPDevHandle field to
  40. * MPI2_CONFIG_PAGE_SAS_ENCLOSURE_0.
  41. * 12-18-07 02.00.05 Modified IO Unit Page 0 to use 32-bit version fields for
  42. * NVDATA.
  43. * Modified IOC Page 7 to use masks and added field for
  44. * SASBroadcastPrimitiveMasks.
  45. * Added MPI2_CONFIG_PAGE_BIOS_4.
  46. * Added MPI2_CONFIG_PAGE_LOG_0.
  47. * 02-29-08 02.00.06 Modified various names to make them 32-character unique.
  48. * Added SAS Device IDs.
  49. * Updated Integrated RAID configuration pages including
  50. * Manufacturing Page 4, IOC Page 6, and RAID Configuration
  51. * Page 0.
  52. * 05-21-08 02.00.07 Added define MPI2_MANPAGE4_MIX_SSD_SAS_SATA.
  53. * Added define MPI2_MANPAGE4_PHYSDISK_128MB_COERCION.
  54. * Fixed define MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING.
  55. * Added missing MaxNumRoutedSasAddresses field to
  56. * MPI2_CONFIG_PAGE_EXPANDER_0.
  57. * Added SAS Port Page 0.
  58. * Modified structure layout for
  59. * MPI2_CONFIG_PAGE_DRIVER_MAPPING_0.
  60. * 06-27-08 02.00.08 Changed MPI2_CONFIG_PAGE_RD_PDISK_1 to use
  61. * MPI2_RAID_PHYS_DISK1_PATH_MAX to size the array.
  62. * 10-02-08 02.00.09 Changed MPI2_RAID_PGAD_CONFIGNUM_MASK from 0x0000FFFF
  63. * to 0x000000FF.
  64. * Added two new values for the Physical Disk Coercion Size
  65. * bits in the Flags field of Manufacturing Page 4.
  66. * Added product-specific Manufacturing pages 16 to 31.
  67. * Modified Flags bits for controlling write cache on SATA
  68. * drives in IO Unit Page 1.
  69. * Added new bit to AdditionalControlFlags of SAS IO Unit
  70. * Page 1 to control Invalid Topology Correction.
  71. * Added additional defines for RAID Volume Page 0
  72. * VolumeStatusFlags field.
  73. * Modified meaning of RAID Volume Page 0 VolumeSettings
  74. * define for auto-configure of hot-swap drives.
  75. * Added SupportedPhysDisks field to RAID Volume Page 1 and
  76. * added related defines.
  77. * Added PhysDiskAttributes field (and related defines) to
  78. * RAID Physical Disk Page 0.
  79. * Added MPI2_SAS_PHYINFO_PHY_VACANT define.
  80. * Added three new DiscoveryStatus bits for SAS IO Unit
  81. * Page 0 and SAS Expander Page 0.
  82. * Removed multiplexing information from SAS IO Unit pages.
  83. * Added BootDeviceWaitTime field to SAS IO Unit Page 4.
  84. * Removed Zone Address Resolved bit from PhyInfo and from
  85. * Expander Page 0 Flags field.
  86. * Added two new AccessStatus values to SAS Device Page 0
  87. * for indicating routing problems. Added 3 reserved words
  88. * to this page.
  89. * 01-19-09 02.00.10 Fixed defines for GPIOVal field of IO Unit Page 3.
  90. * Inserted missing reserved field into structure for IOC
  91. * Page 6.
  92. * Added more pending task bits to RAID Volume Page 0
  93. * VolumeStatusFlags defines.
  94. * Added MPI2_PHYSDISK0_STATUS_FLAG_NOT_CERTIFIED define.
  95. * Added a new DiscoveryStatus bit for SAS IO Unit Page 0
  96. * and SAS Expander Page 0 to flag a downstream initiator
  97. * when in simplified routing mode.
  98. * Removed SATA Init Failure defines for DiscoveryStatus
  99. * fields of SAS IO Unit Page 0 and SAS Expander Page 0.
  100. * Added MPI2_SAS_DEVICE0_ASTATUS_DEVICE_BLOCKED define.
  101. * Added PortGroups, DmaGroup, and ControlGroup fields to
  102. * SAS Device Page 0.
  103. * 05-06-09 02.00.11 Added structures and defines for IO Unit Page 5 and IO
  104. * Unit Page 6.
  105. * Added expander reduced functionality data to SAS
  106. * Expander Page 0.
  107. * Added SAS PHY Page 2 and SAS PHY Page 3.
  108. * 07-30-09 02.00.12 Added IO Unit Page 7.
  109. * Added new device ids.
  110. * Added SAS IO Unit Page 5.
  111. * Added partial and slumber power management capable flags
  112. * to SAS Device Page 0 Flags field.
  113. * Added PhyInfo defines for power condition.
  114. * Added Ethernet configuration pages.
  115. * 10-28-09 02.00.13 Added MPI2_IOUNITPAGE1_ENABLE_HOST_BASED_DISCOVERY.
  116. * Added SAS PHY Page 4 structure and defines.
  117. * 02-10-10 02.00.14 Modified the comments for the configuration page
  118. * structures that contain an array of data. The host
  119. * should use the "count" field in the page data (e.g. the
  120. * NumPhys field) to determine the number of valid elements
  121. * in the array.
  122. * Added/modified some MPI2_MFGPAGE_DEVID_SAS defines.
  123. * Added PowerManagementCapabilities to IO Unit Page 7.
  124. * Added PortWidthModGroup field to
  125. * MPI2_SAS_IO_UNIT5_PHY_PM_SETTINGS.
  126. * Added MPI2_CONFIG_PAGE_SASIOUNIT_6 and related defines.
  127. * Added MPI2_CONFIG_PAGE_SASIOUNIT_7 and related defines.
  128. * Added MPI2_CONFIG_PAGE_SASIOUNIT_8 and related defines.
  129. * 05-12-10 02.00.15 Added MPI2_RAIDVOL0_STATUS_FLAG_VOL_NOT_CONSISTENT
  130. * define.
  131. * Added MPI2_PHYSDISK0_INCOMPATIBLE_MEDIA_TYPE define.
  132. * Added MPI2_SAS_NEG_LINK_RATE_UNSUPPORTED_PHY define.
  133. * 08-11-10 02.00.16 Removed IO Unit Page 1 device path (multi-pathing)
  134. * defines.
  135. * 11-10-10 02.00.17 Added ReceptacleID field (replacing Reserved1) to
  136. * MPI2_MANPAGE7_CONNECTOR_INFO and reworked defines for
  137. * the Pinout field.
  138. * Added BoardTemperature and BoardTemperatureUnits fields
  139. * to MPI2_CONFIG_PAGE_IO_UNIT_7.
  140. * Added MPI2_CONFIG_EXTPAGETYPE_EXT_MANUFACTURING define
  141. * and MPI2_CONFIG_PAGE_EXT_MAN_PS structure.
  142. * 02-23-11 02.00.18 Added ProxyVF_ID field to MPI2_CONFIG_REQUEST.
  143. * Added IO Unit Page 8, IO Unit Page 9,
  144. * and IO Unit Page 10.
  145. * Added SASNotifyPrimitiveMasks field to
  146. * MPI2_CONFIG_PAGE_IOC_7.
  147. * 03-09-11 02.00.19 Fixed IO Unit Page 10 (to match the spec).
  148. * 05-25-11 02.00.20 Cleaned up a few comments.
  149. * 08-24-11 02.00.21 Marked the IO Unit Page 7 PowerManagementCapabilities
  150. * for PCIe link as obsolete.
  151. * Added SpinupFlags field containing a Disable Spin-up bit
  152. * to the MPI2_SAS_IOUNIT4_SPINUP_GROUP fields of SAS IO
  153. * Unit Page 4.
  154. * 11-18-11 02.00.22 Added define MPI2_IOCPAGE6_CAP_FLAGS_4K_SECTORS_SUPPORT.
  155. * Added UEFIVersion field to BIOS Page 1 and defined new
  156. * BiosOptions bits.
  157. * Incorporating additions for MPI v2.5.
  158. * 11-27-12 02.00.23 Added MPI2_MANPAGE7_FLAG_EVENTREPLAY_SLOT_ORDER.
  159. * Added MPI2_BIOSPAGE1_OPTIONS_MASK_OEM_ID.
  160. * 12-20-12 02.00.24 Marked MPI2_SASIOUNIT1_CONTROL_CLEAR_AFFILIATION as
  161. * obsolete for MPI v2.5 and later.
  162. * Added some defines for 12G SAS speeds.
  163. * 04-09-13 02.00.25 Added MPI2_IOUNITPAGE1_ATA_SECURITY_FREEZE_LOCK.
  164. * Fixed MPI2_IOUNITPAGE5_DMA_CAP_MASK_MAX_REQUESTS to
  165. * match the specification.
  166. * 08-19-13 02.00.26 Added reserved words to MPI2_CONFIG_PAGE_IO_UNIT_7 for
  167. * future use.
  168. * 12-05-13 02.00.27 Added MPI2_MANPAGE7_FLAG_BASE_ENCLOSURE_LEVEL for
  169. * MPI2_CONFIG_PAGE_MAN_7.
  170. * Added EnclosureLevel and ConnectorName fields to
  171. * MPI2_CONFIG_PAGE_SAS_DEV_0.
  172. * Added MPI2_SAS_DEVICE0_FLAGS_ENCL_LEVEL_VALID for
  173. * MPI2_CONFIG_PAGE_SAS_DEV_0.
  174. * Added EnclosureLevel field to
  175. * MPI2_CONFIG_PAGE_SAS_ENCLOSURE_0.
  176. * Added MPI2_SAS_ENCLS0_FLAGS_ENCL_LEVEL_VALID for
  177. * MPI2_CONFIG_PAGE_SAS_ENCLOSURE_0.
  178. * 01-08-14 02.00.28 Added more defines for the BiosOptions field of
  179. * MPI2_CONFIG_PAGE_BIOS_1.
  180. * 06-13-14 02.00.29 Added SSUTimeout field to MPI2_CONFIG_PAGE_BIOS_1, and
  181. * more defines for the BiosOptions field.
  182. * 11-18-14 02.00.30 Updated copyright information.
  183. * Added MPI2_BIOSPAGE1_OPTIONS_ADVANCED_CONFIG.
  184. * Added AdapterOrderAux fields to BIOS Page 3.
  185. * 03-16-15 02.00.31 Updated for MPI v2.6.
  186. * Added Flags field to IO Unit Page 7.
  187. * Added new SAS Phy Event codes
  188. * 05-25-15 02.00.33 Added more defines for the BiosOptions field of
  189. * MPI2_CONFIG_PAGE_BIOS_1.
  190. * 08-25-15 02.00.34 Bumped Header Version.
  191. * 12-18-15 02.00.35 Added SATADeviceWaitTime to SAS IO Unit Page 4.
  192. * --------------------------------------------------------------------------
  193. */
  194. #ifndef MPI2_CNFG_H
  195. #define MPI2_CNFG_H
  196. /*****************************************************************************
  197. * Configuration Page Header and defines
  198. *****************************************************************************/
  199. /*Config Page Header */
  200. typedef struct _MPI2_CONFIG_PAGE_HEADER {
  201. U8 PageVersion; /*0x00 */
  202. U8 PageLength; /*0x01 */
  203. U8 PageNumber; /*0x02 */
  204. U8 PageType; /*0x03 */
  205. } MPI2_CONFIG_PAGE_HEADER, *PTR_MPI2_CONFIG_PAGE_HEADER,
  206. Mpi2ConfigPageHeader_t, *pMpi2ConfigPageHeader_t;
  207. typedef union _MPI2_CONFIG_PAGE_HEADER_UNION {
  208. MPI2_CONFIG_PAGE_HEADER Struct;
  209. U8 Bytes[4];
  210. U16 Word16[2];
  211. U32 Word32;
  212. } MPI2_CONFIG_PAGE_HEADER_UNION, *PTR_MPI2_CONFIG_PAGE_HEADER_UNION,
  213. Mpi2ConfigPageHeaderUnion, *pMpi2ConfigPageHeaderUnion;
  214. /*Extended Config Page Header */
  215. typedef struct _MPI2_CONFIG_EXTENDED_PAGE_HEADER {
  216. U8 PageVersion; /*0x00 */
  217. U8 Reserved1; /*0x01 */
  218. U8 PageNumber; /*0x02 */
  219. U8 PageType; /*0x03 */
  220. U16 ExtPageLength; /*0x04 */
  221. U8 ExtPageType; /*0x06 */
  222. U8 Reserved2; /*0x07 */
  223. } MPI2_CONFIG_EXTENDED_PAGE_HEADER,
  224. *PTR_MPI2_CONFIG_EXTENDED_PAGE_HEADER,
  225. Mpi2ConfigExtendedPageHeader_t,
  226. *pMpi2ConfigExtendedPageHeader_t;
  227. typedef union _MPI2_CONFIG_EXT_PAGE_HEADER_UNION {
  228. MPI2_CONFIG_PAGE_HEADER Struct;
  229. MPI2_CONFIG_EXTENDED_PAGE_HEADER Ext;
  230. U8 Bytes[8];
  231. U16 Word16[4];
  232. U32 Word32[2];
  233. } MPI2_CONFIG_EXT_PAGE_HEADER_UNION,
  234. *PTR_MPI2_CONFIG_EXT_PAGE_HEADER_UNION,
  235. Mpi2ConfigPageExtendedHeaderUnion,
  236. *pMpi2ConfigPageExtendedHeaderUnion;
  237. /*PageType field values */
  238. #define MPI2_CONFIG_PAGEATTR_READ_ONLY (0x00)
  239. #define MPI2_CONFIG_PAGEATTR_CHANGEABLE (0x10)
  240. #define MPI2_CONFIG_PAGEATTR_PERSISTENT (0x20)
  241. #define MPI2_CONFIG_PAGEATTR_MASK (0xF0)
  242. #define MPI2_CONFIG_PAGETYPE_IO_UNIT (0x00)
  243. #define MPI2_CONFIG_PAGETYPE_IOC (0x01)
  244. #define MPI2_CONFIG_PAGETYPE_BIOS (0x02)
  245. #define MPI2_CONFIG_PAGETYPE_RAID_VOLUME (0x08)
  246. #define MPI2_CONFIG_PAGETYPE_MANUFACTURING (0x09)
  247. #define MPI2_CONFIG_PAGETYPE_RAID_PHYSDISK (0x0A)
  248. #define MPI2_CONFIG_PAGETYPE_EXTENDED (0x0F)
  249. #define MPI2_CONFIG_PAGETYPE_MASK (0x0F)
  250. #define MPI2_CONFIG_TYPENUM_MASK (0x0FFF)
  251. /*ExtPageType field values */
  252. #define MPI2_CONFIG_EXTPAGETYPE_SAS_IO_UNIT (0x10)
  253. #define MPI2_CONFIG_EXTPAGETYPE_SAS_EXPANDER (0x11)
  254. #define MPI2_CONFIG_EXTPAGETYPE_SAS_DEVICE (0x12)
  255. #define MPI2_CONFIG_EXTPAGETYPE_SAS_PHY (0x13)
  256. #define MPI2_CONFIG_EXTPAGETYPE_LOG (0x14)
  257. #define MPI2_CONFIG_EXTPAGETYPE_ENCLOSURE (0x15)
  258. #define MPI2_CONFIG_EXTPAGETYPE_RAID_CONFIG (0x16)
  259. #define MPI2_CONFIG_EXTPAGETYPE_DRIVER_MAPPING (0x17)
  260. #define MPI2_CONFIG_EXTPAGETYPE_SAS_PORT (0x18)
  261. #define MPI2_CONFIG_EXTPAGETYPE_ETHERNET (0x19)
  262. #define MPI2_CONFIG_EXTPAGETYPE_EXT_MANUFACTURING (0x1A)
  263. /*****************************************************************************
  264. * PageAddress defines
  265. *****************************************************************************/
  266. /*RAID Volume PageAddress format */
  267. #define MPI2_RAID_VOLUME_PGAD_FORM_MASK (0xF0000000)
  268. #define MPI2_RAID_VOLUME_PGAD_FORM_GET_NEXT_HANDLE (0x00000000)
  269. #define MPI2_RAID_VOLUME_PGAD_FORM_HANDLE (0x10000000)
  270. #define MPI2_RAID_VOLUME_PGAD_HANDLE_MASK (0x0000FFFF)
  271. /*RAID Physical Disk PageAddress format */
  272. #define MPI2_PHYSDISK_PGAD_FORM_MASK (0xF0000000)
  273. #define MPI2_PHYSDISK_PGAD_FORM_GET_NEXT_PHYSDISKNUM (0x00000000)
  274. #define MPI2_PHYSDISK_PGAD_FORM_PHYSDISKNUM (0x10000000)
  275. #define MPI2_PHYSDISK_PGAD_FORM_DEVHANDLE (0x20000000)
  276. #define MPI2_PHYSDISK_PGAD_PHYSDISKNUM_MASK (0x000000FF)
  277. #define MPI2_PHYSDISK_PGAD_DEVHANDLE_MASK (0x0000FFFF)
  278. /*SAS Expander PageAddress format */
  279. #define MPI2_SAS_EXPAND_PGAD_FORM_MASK (0xF0000000)
  280. #define MPI2_SAS_EXPAND_PGAD_FORM_GET_NEXT_HNDL (0x00000000)
  281. #define MPI2_SAS_EXPAND_PGAD_FORM_HNDL_PHY_NUM (0x10000000)
  282. #define MPI2_SAS_EXPAND_PGAD_FORM_HNDL (0x20000000)
  283. #define MPI2_SAS_EXPAND_PGAD_HANDLE_MASK (0x0000FFFF)
  284. #define MPI2_SAS_EXPAND_PGAD_PHYNUM_MASK (0x00FF0000)
  285. #define MPI2_SAS_EXPAND_PGAD_PHYNUM_SHIFT (16)
  286. /*SAS Device PageAddress format */
  287. #define MPI2_SAS_DEVICE_PGAD_FORM_MASK (0xF0000000)
  288. #define MPI2_SAS_DEVICE_PGAD_FORM_GET_NEXT_HANDLE (0x00000000)
  289. #define MPI2_SAS_DEVICE_PGAD_FORM_HANDLE (0x20000000)
  290. #define MPI2_SAS_DEVICE_PGAD_HANDLE_MASK (0x0000FFFF)
  291. /*SAS PHY PageAddress format */
  292. #define MPI2_SAS_PHY_PGAD_FORM_MASK (0xF0000000)
  293. #define MPI2_SAS_PHY_PGAD_FORM_PHY_NUMBER (0x00000000)
  294. #define MPI2_SAS_PHY_PGAD_FORM_PHY_TBL_INDEX (0x10000000)
  295. #define MPI2_SAS_PHY_PGAD_PHY_NUMBER_MASK (0x000000FF)
  296. #define MPI2_SAS_PHY_PGAD_PHY_TBL_INDEX_MASK (0x0000FFFF)
  297. /*SAS Port PageAddress format */
  298. #define MPI2_SASPORT_PGAD_FORM_MASK (0xF0000000)
  299. #define MPI2_SASPORT_PGAD_FORM_GET_NEXT_PORT (0x00000000)
  300. #define MPI2_SASPORT_PGAD_FORM_PORT_NUM (0x10000000)
  301. #define MPI2_SASPORT_PGAD_PORTNUMBER_MASK (0x00000FFF)
  302. /*SAS Enclosure PageAddress format */
  303. #define MPI2_SAS_ENCLOS_PGAD_FORM_MASK (0xF0000000)
  304. #define MPI2_SAS_ENCLOS_PGAD_FORM_GET_NEXT_HANDLE (0x00000000)
  305. #define MPI2_SAS_ENCLOS_PGAD_FORM_HANDLE (0x10000000)
  306. #define MPI2_SAS_ENCLOS_PGAD_HANDLE_MASK (0x0000FFFF)
  307. /*RAID Configuration PageAddress format */
  308. #define MPI2_RAID_PGAD_FORM_MASK (0xF0000000)
  309. #define MPI2_RAID_PGAD_FORM_GET_NEXT_CONFIGNUM (0x00000000)
  310. #define MPI2_RAID_PGAD_FORM_CONFIGNUM (0x10000000)
  311. #define MPI2_RAID_PGAD_FORM_ACTIVE_CONFIG (0x20000000)
  312. #define MPI2_RAID_PGAD_CONFIGNUM_MASK (0x000000FF)
  313. /*Driver Persistent Mapping PageAddress format */
  314. #define MPI2_DPM_PGAD_FORM_MASK (0xF0000000)
  315. #define MPI2_DPM_PGAD_FORM_ENTRY_RANGE (0x00000000)
  316. #define MPI2_DPM_PGAD_ENTRY_COUNT_MASK (0x0FFF0000)
  317. #define MPI2_DPM_PGAD_ENTRY_COUNT_SHIFT (16)
  318. #define MPI2_DPM_PGAD_START_ENTRY_MASK (0x0000FFFF)
  319. /*Ethernet PageAddress format */
  320. #define MPI2_ETHERNET_PGAD_FORM_MASK (0xF0000000)
  321. #define MPI2_ETHERNET_PGAD_FORM_IF_NUM (0x00000000)
  322. #define MPI2_ETHERNET_PGAD_IF_NUMBER_MASK (0x000000FF)
  323. /****************************************************************************
  324. * Configuration messages
  325. ****************************************************************************/
  326. /*Configuration Request Message */
  327. typedef struct _MPI2_CONFIG_REQUEST {
  328. U8 Action; /*0x00 */
  329. U8 SGLFlags; /*0x01 */
  330. U8 ChainOffset; /*0x02 */
  331. U8 Function; /*0x03 */
  332. U16 ExtPageLength; /*0x04 */
  333. U8 ExtPageType; /*0x06 */
  334. U8 MsgFlags; /*0x07 */
  335. U8 VP_ID; /*0x08 */
  336. U8 VF_ID; /*0x09 */
  337. U16 Reserved1; /*0x0A */
  338. U8 Reserved2; /*0x0C */
  339. U8 ProxyVF_ID; /*0x0D */
  340. U16 Reserved4; /*0x0E */
  341. U32 Reserved3; /*0x10 */
  342. MPI2_CONFIG_PAGE_HEADER Header; /*0x14 */
  343. U32 PageAddress; /*0x18 */
  344. MPI2_SGE_IO_UNION PageBufferSGE; /*0x1C */
  345. } MPI2_CONFIG_REQUEST, *PTR_MPI2_CONFIG_REQUEST,
  346. Mpi2ConfigRequest_t, *pMpi2ConfigRequest_t;
  347. /*values for the Action field */
  348. #define MPI2_CONFIG_ACTION_PAGE_HEADER (0x00)
  349. #define MPI2_CONFIG_ACTION_PAGE_READ_CURRENT (0x01)
  350. #define MPI2_CONFIG_ACTION_PAGE_WRITE_CURRENT (0x02)
  351. #define MPI2_CONFIG_ACTION_PAGE_DEFAULT (0x03)
  352. #define MPI2_CONFIG_ACTION_PAGE_WRITE_NVRAM (0x04)
  353. #define MPI2_CONFIG_ACTION_PAGE_READ_DEFAULT (0x05)
  354. #define MPI2_CONFIG_ACTION_PAGE_READ_NVRAM (0x06)
  355. #define MPI2_CONFIG_ACTION_PAGE_GET_CHANGEABLE (0x07)
  356. /*use MPI2_SGLFLAGS_ defines from mpi2.h for the SGLFlags field */
  357. /*Config Reply Message */
  358. typedef struct _MPI2_CONFIG_REPLY {
  359. U8 Action; /*0x00 */
  360. U8 SGLFlags; /*0x01 */
  361. U8 MsgLength; /*0x02 */
  362. U8 Function; /*0x03 */
  363. U16 ExtPageLength; /*0x04 */
  364. U8 ExtPageType; /*0x06 */
  365. U8 MsgFlags; /*0x07 */
  366. U8 VP_ID; /*0x08 */
  367. U8 VF_ID; /*0x09 */
  368. U16 Reserved1; /*0x0A */
  369. U16 Reserved2; /*0x0C */
  370. U16 IOCStatus; /*0x0E */
  371. U32 IOCLogInfo; /*0x10 */
  372. MPI2_CONFIG_PAGE_HEADER Header; /*0x14 */
  373. } MPI2_CONFIG_REPLY, *PTR_MPI2_CONFIG_REPLY,
  374. Mpi2ConfigReply_t, *pMpi2ConfigReply_t;
  375. /*****************************************************************************
  376. *
  377. * C o n f i g u r a t i o n P a g e s
  378. *
  379. *****************************************************************************/
  380. /****************************************************************************
  381. * Manufacturing Config pages
  382. ****************************************************************************/
  383. #define MPI2_MFGPAGE_VENDORID_LSI (0x1000)
  384. /*MPI v2.0 SAS products */
  385. #define MPI2_MFGPAGE_DEVID_SAS2004 (0x0070)
  386. #define MPI2_MFGPAGE_DEVID_SAS2008 (0x0072)
  387. #define MPI2_MFGPAGE_DEVID_SAS2108_1 (0x0074)
  388. #define MPI2_MFGPAGE_DEVID_SAS2108_2 (0x0076)
  389. #define MPI2_MFGPAGE_DEVID_SAS2108_3 (0x0077)
  390. #define MPI2_MFGPAGE_DEVID_SAS2116_1 (0x0064)
  391. #define MPI2_MFGPAGE_DEVID_SAS2116_2 (0x0065)
  392. #define MPI2_MFGPAGE_DEVID_SSS6200 (0x007E)
  393. #define MPI2_MFGPAGE_DEVID_SAS2208_1 (0x0080)
  394. #define MPI2_MFGPAGE_DEVID_SAS2208_2 (0x0081)
  395. #define MPI2_MFGPAGE_DEVID_SAS2208_3 (0x0082)
  396. #define MPI2_MFGPAGE_DEVID_SAS2208_4 (0x0083)
  397. #define MPI2_MFGPAGE_DEVID_SAS2208_5 (0x0084)
  398. #define MPI2_MFGPAGE_DEVID_SAS2208_6 (0x0085)
  399. #define MPI2_MFGPAGE_DEVID_SAS2308_1 (0x0086)
  400. #define MPI2_MFGPAGE_DEVID_SAS2308_2 (0x0087)
  401. #define MPI2_MFGPAGE_DEVID_SAS2308_3 (0x006E)
  402. /*MPI v2.5 SAS products */
  403. #define MPI25_MFGPAGE_DEVID_SAS3004 (0x0096)
  404. #define MPI25_MFGPAGE_DEVID_SAS3008 (0x0097)
  405. #define MPI25_MFGPAGE_DEVID_SAS3108_1 (0x0090)
  406. #define MPI25_MFGPAGE_DEVID_SAS3108_2 (0x0091)
  407. #define MPI25_MFGPAGE_DEVID_SAS3108_5 (0x0094)
  408. #define MPI25_MFGPAGE_DEVID_SAS3108_6 (0x0095)
  409. /* MPI v2.6 SAS Products */
  410. #define MPI26_MFGPAGE_DEVID_SAS3216 (0x00C9)
  411. #define MPI26_MFGPAGE_DEVID_SAS3224 (0x00C4)
  412. #define MPI26_MFGPAGE_DEVID_SAS3316_1 (0x00C5)
  413. #define MPI26_MFGPAGE_DEVID_SAS3316_2 (0x00C6)
  414. #define MPI26_MFGPAGE_DEVID_SAS3316_3 (0x00C7)
  415. #define MPI26_MFGPAGE_DEVID_SAS3316_4 (0x00C8)
  416. #define MPI26_MFGPAGE_DEVID_SAS3324_1 (0x00C0)
  417. #define MPI26_MFGPAGE_DEVID_SAS3324_2 (0x00C1)
  418. #define MPI26_MFGPAGE_DEVID_SAS3324_3 (0x00C2)
  419. #define MPI26_MFGPAGE_DEVID_SAS3324_4 (0x00C3)
  420. /*Manufacturing Page 0 */
  421. typedef struct _MPI2_CONFIG_PAGE_MAN_0 {
  422. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  423. U8 ChipName[16]; /*0x04 */
  424. U8 ChipRevision[8]; /*0x14 */
  425. U8 BoardName[16]; /*0x1C */
  426. U8 BoardAssembly[16]; /*0x2C */
  427. U8 BoardTracerNumber[16]; /*0x3C */
  428. } MPI2_CONFIG_PAGE_MAN_0,
  429. *PTR_MPI2_CONFIG_PAGE_MAN_0,
  430. Mpi2ManufacturingPage0_t,
  431. *pMpi2ManufacturingPage0_t;
  432. #define MPI2_MANUFACTURING0_PAGEVERSION (0x00)
  433. /*Manufacturing Page 1 */
  434. typedef struct _MPI2_CONFIG_PAGE_MAN_1 {
  435. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  436. U8 VPD[256]; /*0x04 */
  437. } MPI2_CONFIG_PAGE_MAN_1,
  438. *PTR_MPI2_CONFIG_PAGE_MAN_1,
  439. Mpi2ManufacturingPage1_t,
  440. *pMpi2ManufacturingPage1_t;
  441. #define MPI2_MANUFACTURING1_PAGEVERSION (0x00)
  442. typedef struct _MPI2_CHIP_REVISION_ID {
  443. U16 DeviceID; /*0x00 */
  444. U8 PCIRevisionID; /*0x02 */
  445. U8 Reserved; /*0x03 */
  446. } MPI2_CHIP_REVISION_ID, *PTR_MPI2_CHIP_REVISION_ID,
  447. Mpi2ChipRevisionId_t, *pMpi2ChipRevisionId_t;
  448. /*Manufacturing Page 2 */
  449. /*
  450. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  451. *one and check Header.PageLength at runtime.
  452. */
  453. #ifndef MPI2_MAN_PAGE_2_HW_SETTINGS_WORDS
  454. #define MPI2_MAN_PAGE_2_HW_SETTINGS_WORDS (1)
  455. #endif
  456. typedef struct _MPI2_CONFIG_PAGE_MAN_2 {
  457. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  458. MPI2_CHIP_REVISION_ID ChipId; /*0x04 */
  459. U32
  460. HwSettings[MPI2_MAN_PAGE_2_HW_SETTINGS_WORDS];/*0x08 */
  461. } MPI2_CONFIG_PAGE_MAN_2,
  462. *PTR_MPI2_CONFIG_PAGE_MAN_2,
  463. Mpi2ManufacturingPage2_t,
  464. *pMpi2ManufacturingPage2_t;
  465. #define MPI2_MANUFACTURING2_PAGEVERSION (0x00)
  466. /*Manufacturing Page 3 */
  467. /*
  468. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  469. *one and check Header.PageLength at runtime.
  470. */
  471. #ifndef MPI2_MAN_PAGE_3_INFO_WORDS
  472. #define MPI2_MAN_PAGE_3_INFO_WORDS (1)
  473. #endif
  474. typedef struct _MPI2_CONFIG_PAGE_MAN_3 {
  475. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  476. MPI2_CHIP_REVISION_ID ChipId; /*0x04 */
  477. U32
  478. Info[MPI2_MAN_PAGE_3_INFO_WORDS];/*0x08 */
  479. } MPI2_CONFIG_PAGE_MAN_3,
  480. *PTR_MPI2_CONFIG_PAGE_MAN_3,
  481. Mpi2ManufacturingPage3_t,
  482. *pMpi2ManufacturingPage3_t;
  483. #define MPI2_MANUFACTURING3_PAGEVERSION (0x00)
  484. /*Manufacturing Page 4 */
  485. typedef struct _MPI2_MANPAGE4_PWR_SAVE_SETTINGS {
  486. U8 PowerSaveFlags; /*0x00 */
  487. U8 InternalOperationsSleepTime; /*0x01 */
  488. U8 InternalOperationsRunTime; /*0x02 */
  489. U8 HostIdleTime; /*0x03 */
  490. } MPI2_MANPAGE4_PWR_SAVE_SETTINGS,
  491. *PTR_MPI2_MANPAGE4_PWR_SAVE_SETTINGS,
  492. Mpi2ManPage4PwrSaveSettings_t,
  493. *pMpi2ManPage4PwrSaveSettings_t;
  494. /*defines for the PowerSaveFlags field */
  495. #define MPI2_MANPAGE4_MASK_POWERSAVE_MODE (0x03)
  496. #define MPI2_MANPAGE4_POWERSAVE_MODE_DISABLED (0x00)
  497. #define MPI2_MANPAGE4_CUSTOM_POWERSAVE_MODE (0x01)
  498. #define MPI2_MANPAGE4_FULL_POWERSAVE_MODE (0x02)
  499. typedef struct _MPI2_CONFIG_PAGE_MAN_4 {
  500. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  501. U32 Reserved1; /*0x04 */
  502. U32 Flags; /*0x08 */
  503. U8 InquirySize; /*0x0C */
  504. U8 Reserved2; /*0x0D */
  505. U16 Reserved3; /*0x0E */
  506. U8 InquiryData[56]; /*0x10 */
  507. U32 RAID0VolumeSettings; /*0x48 */
  508. U32 RAID1EVolumeSettings; /*0x4C */
  509. U32 RAID1VolumeSettings; /*0x50 */
  510. U32 RAID10VolumeSettings; /*0x54 */
  511. U32 Reserved4; /*0x58 */
  512. U32 Reserved5; /*0x5C */
  513. MPI2_MANPAGE4_PWR_SAVE_SETTINGS PowerSaveSettings; /*0x60 */
  514. U8 MaxOCEDisks; /*0x64 */
  515. U8 ResyncRate; /*0x65 */
  516. U16 DataScrubDuration; /*0x66 */
  517. U8 MaxHotSpares; /*0x68 */
  518. U8 MaxPhysDisksPerVol; /*0x69 */
  519. U8 MaxPhysDisks; /*0x6A */
  520. U8 MaxVolumes; /*0x6B */
  521. } MPI2_CONFIG_PAGE_MAN_4,
  522. *PTR_MPI2_CONFIG_PAGE_MAN_4,
  523. Mpi2ManufacturingPage4_t,
  524. *pMpi2ManufacturingPage4_t;
  525. #define MPI2_MANUFACTURING4_PAGEVERSION (0x0A)
  526. /*Manufacturing Page 4 Flags field */
  527. #define MPI2_MANPAGE4_METADATA_SIZE_MASK (0x00030000)
  528. #define MPI2_MANPAGE4_METADATA_512MB (0x00000000)
  529. #define MPI2_MANPAGE4_MIX_SSD_SAS_SATA (0x00008000)
  530. #define MPI2_MANPAGE4_MIX_SSD_AND_NON_SSD (0x00004000)
  531. #define MPI2_MANPAGE4_HIDE_PHYSDISK_NON_IR (0x00002000)
  532. #define MPI2_MANPAGE4_MASK_PHYSDISK_COERCION (0x00001C00)
  533. #define MPI2_MANPAGE4_PHYSDISK_COERCION_1GB (0x00000000)
  534. #define MPI2_MANPAGE4_PHYSDISK_128MB_COERCION (0x00000400)
  535. #define MPI2_MANPAGE4_PHYSDISK_ADAPTIVE_COERCION (0x00000800)
  536. #define MPI2_MANPAGE4_PHYSDISK_ZERO_COERCION (0x00000C00)
  537. #define MPI2_MANPAGE4_MASK_BAD_BLOCK_MARKING (0x00000300)
  538. #define MPI2_MANPAGE4_DEFAULT_BAD_BLOCK_MARKING (0x00000000)
  539. #define MPI2_MANPAGE4_TABLE_BAD_BLOCK_MARKING (0x00000100)
  540. #define MPI2_MANPAGE4_WRITE_LONG_BAD_BLOCK_MARKING (0x00000200)
  541. #define MPI2_MANPAGE4_FORCE_OFFLINE_FAILOVER (0x00000080)
  542. #define MPI2_MANPAGE4_RAID10_DISABLE (0x00000040)
  543. #define MPI2_MANPAGE4_RAID1E_DISABLE (0x00000020)
  544. #define MPI2_MANPAGE4_RAID1_DISABLE (0x00000010)
  545. #define MPI2_MANPAGE4_RAID0_DISABLE (0x00000008)
  546. #define MPI2_MANPAGE4_IR_MODEPAGE8_DISABLE (0x00000004)
  547. #define MPI2_MANPAGE4_IM_RESYNC_CACHE_ENABLE (0x00000002)
  548. #define MPI2_MANPAGE4_IR_NO_MIX_SAS_SATA (0x00000001)
  549. /*Manufacturing Page 5 */
  550. /*
  551. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  552. *one and check the value returned for NumPhys at runtime.
  553. */
  554. #ifndef MPI2_MAN_PAGE_5_PHY_ENTRIES
  555. #define MPI2_MAN_PAGE_5_PHY_ENTRIES (1)
  556. #endif
  557. typedef struct _MPI2_MANUFACTURING5_ENTRY {
  558. U64 WWID; /*0x00 */
  559. U64 DeviceName; /*0x08 */
  560. } MPI2_MANUFACTURING5_ENTRY,
  561. *PTR_MPI2_MANUFACTURING5_ENTRY,
  562. Mpi2Manufacturing5Entry_t,
  563. *pMpi2Manufacturing5Entry_t;
  564. typedef struct _MPI2_CONFIG_PAGE_MAN_5 {
  565. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  566. U8 NumPhys; /*0x04 */
  567. U8 Reserved1; /*0x05 */
  568. U16 Reserved2; /*0x06 */
  569. U32 Reserved3; /*0x08 */
  570. U32 Reserved4; /*0x0C */
  571. MPI2_MANUFACTURING5_ENTRY
  572. Phy[MPI2_MAN_PAGE_5_PHY_ENTRIES];/*0x08 */
  573. } MPI2_CONFIG_PAGE_MAN_5,
  574. *PTR_MPI2_CONFIG_PAGE_MAN_5,
  575. Mpi2ManufacturingPage5_t,
  576. *pMpi2ManufacturingPage5_t;
  577. #define MPI2_MANUFACTURING5_PAGEVERSION (0x03)
  578. /*Manufacturing Page 6 */
  579. typedef struct _MPI2_CONFIG_PAGE_MAN_6 {
  580. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  581. U32 ProductSpecificInfo;/*0x04 */
  582. } MPI2_CONFIG_PAGE_MAN_6,
  583. *PTR_MPI2_CONFIG_PAGE_MAN_6,
  584. Mpi2ManufacturingPage6_t,
  585. *pMpi2ManufacturingPage6_t;
  586. #define MPI2_MANUFACTURING6_PAGEVERSION (0x00)
  587. /*Manufacturing Page 7 */
  588. typedef struct _MPI2_MANPAGE7_CONNECTOR_INFO {
  589. U32 Pinout; /*0x00 */
  590. U8 Connector[16]; /*0x04 */
  591. U8 Location; /*0x14 */
  592. U8 ReceptacleID; /*0x15 */
  593. U16 Slot; /*0x16 */
  594. U32 Reserved2; /*0x18 */
  595. } MPI2_MANPAGE7_CONNECTOR_INFO,
  596. *PTR_MPI2_MANPAGE7_CONNECTOR_INFO,
  597. Mpi2ManPage7ConnectorInfo_t,
  598. *pMpi2ManPage7ConnectorInfo_t;
  599. /*defines for the Pinout field */
  600. #define MPI2_MANPAGE7_PINOUT_LANE_MASK (0x0000FF00)
  601. #define MPI2_MANPAGE7_PINOUT_LANE_SHIFT (8)
  602. #define MPI2_MANPAGE7_PINOUT_TYPE_MASK (0x000000FF)
  603. #define MPI2_MANPAGE7_PINOUT_TYPE_UNKNOWN (0x00)
  604. #define MPI2_MANPAGE7_PINOUT_SATA_SINGLE (0x01)
  605. #define MPI2_MANPAGE7_PINOUT_SFF_8482 (0x02)
  606. #define MPI2_MANPAGE7_PINOUT_SFF_8486 (0x03)
  607. #define MPI2_MANPAGE7_PINOUT_SFF_8484 (0x04)
  608. #define MPI2_MANPAGE7_PINOUT_SFF_8087 (0x05)
  609. #define MPI2_MANPAGE7_PINOUT_SFF_8643_4I (0x06)
  610. #define MPI2_MANPAGE7_PINOUT_SFF_8643_8I (0x07)
  611. #define MPI2_MANPAGE7_PINOUT_SFF_8470 (0x08)
  612. #define MPI2_MANPAGE7_PINOUT_SFF_8088 (0x09)
  613. #define MPI2_MANPAGE7_PINOUT_SFF_8644_4X (0x0A)
  614. #define MPI2_MANPAGE7_PINOUT_SFF_8644_8X (0x0B)
  615. #define MPI2_MANPAGE7_PINOUT_SFF_8644_16X (0x0C)
  616. #define MPI2_MANPAGE7_PINOUT_SFF_8436 (0x0D)
  617. /*defines for the Location field */
  618. #define MPI2_MANPAGE7_LOCATION_UNKNOWN (0x01)
  619. #define MPI2_MANPAGE7_LOCATION_INTERNAL (0x02)
  620. #define MPI2_MANPAGE7_LOCATION_EXTERNAL (0x04)
  621. #define MPI2_MANPAGE7_LOCATION_SWITCHABLE (0x08)
  622. #define MPI2_MANPAGE7_LOCATION_AUTO (0x10)
  623. #define MPI2_MANPAGE7_LOCATION_NOT_PRESENT (0x20)
  624. #define MPI2_MANPAGE7_LOCATION_NOT_CONNECTED (0x80)
  625. /*
  626. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  627. *one and check the value returned for NumPhys at runtime.
  628. */
  629. #ifndef MPI2_MANPAGE7_CONNECTOR_INFO_MAX
  630. #define MPI2_MANPAGE7_CONNECTOR_INFO_MAX (1)
  631. #endif
  632. typedef struct _MPI2_CONFIG_PAGE_MAN_7 {
  633. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  634. U32 Reserved1; /*0x04 */
  635. U32 Reserved2; /*0x08 */
  636. U32 Flags; /*0x0C */
  637. U8 EnclosureName[16]; /*0x10 */
  638. U8 NumPhys; /*0x20 */
  639. U8 Reserved3; /*0x21 */
  640. U16 Reserved4; /*0x22 */
  641. MPI2_MANPAGE7_CONNECTOR_INFO
  642. ConnectorInfo[MPI2_MANPAGE7_CONNECTOR_INFO_MAX]; /*0x24 */
  643. } MPI2_CONFIG_PAGE_MAN_7,
  644. *PTR_MPI2_CONFIG_PAGE_MAN_7,
  645. Mpi2ManufacturingPage7_t,
  646. *pMpi2ManufacturingPage7_t;
  647. #define MPI2_MANUFACTURING7_PAGEVERSION (0x01)
  648. /*defines for the Flags field */
  649. #define MPI2_MANPAGE7_FLAG_BASE_ENCLOSURE_LEVEL (0x00000008)
  650. #define MPI2_MANPAGE7_FLAG_EVENTREPLAY_SLOT_ORDER (0x00000002)
  651. #define MPI2_MANPAGE7_FLAG_USE_SLOT_INFO (0x00000001)
  652. /*
  653. *Generic structure to use for product-specific manufacturing pages
  654. *(currently Manufacturing Page 8 through Manufacturing Page 31).
  655. */
  656. typedef struct _MPI2_CONFIG_PAGE_MAN_PS {
  657. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  658. U32 ProductSpecificInfo;/*0x04 */
  659. } MPI2_CONFIG_PAGE_MAN_PS,
  660. *PTR_MPI2_CONFIG_PAGE_MAN_PS,
  661. Mpi2ManufacturingPagePS_t,
  662. *pMpi2ManufacturingPagePS_t;
  663. #define MPI2_MANUFACTURING8_PAGEVERSION (0x00)
  664. #define MPI2_MANUFACTURING9_PAGEVERSION (0x00)
  665. #define MPI2_MANUFACTURING10_PAGEVERSION (0x00)
  666. #define MPI2_MANUFACTURING11_PAGEVERSION (0x00)
  667. #define MPI2_MANUFACTURING12_PAGEVERSION (0x00)
  668. #define MPI2_MANUFACTURING13_PAGEVERSION (0x00)
  669. #define MPI2_MANUFACTURING14_PAGEVERSION (0x00)
  670. #define MPI2_MANUFACTURING15_PAGEVERSION (0x00)
  671. #define MPI2_MANUFACTURING16_PAGEVERSION (0x00)
  672. #define MPI2_MANUFACTURING17_PAGEVERSION (0x00)
  673. #define MPI2_MANUFACTURING18_PAGEVERSION (0x00)
  674. #define MPI2_MANUFACTURING19_PAGEVERSION (0x00)
  675. #define MPI2_MANUFACTURING20_PAGEVERSION (0x00)
  676. #define MPI2_MANUFACTURING21_PAGEVERSION (0x00)
  677. #define MPI2_MANUFACTURING22_PAGEVERSION (0x00)
  678. #define MPI2_MANUFACTURING23_PAGEVERSION (0x00)
  679. #define MPI2_MANUFACTURING24_PAGEVERSION (0x00)
  680. #define MPI2_MANUFACTURING25_PAGEVERSION (0x00)
  681. #define MPI2_MANUFACTURING26_PAGEVERSION (0x00)
  682. #define MPI2_MANUFACTURING27_PAGEVERSION (0x00)
  683. #define MPI2_MANUFACTURING28_PAGEVERSION (0x00)
  684. #define MPI2_MANUFACTURING29_PAGEVERSION (0x00)
  685. #define MPI2_MANUFACTURING30_PAGEVERSION (0x00)
  686. #define MPI2_MANUFACTURING31_PAGEVERSION (0x00)
  687. /****************************************************************************
  688. * IO Unit Config Pages
  689. ****************************************************************************/
  690. /*IO Unit Page 0 */
  691. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_0 {
  692. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  693. U64 UniqueValue; /*0x04 */
  694. MPI2_VERSION_UNION NvdataVersionDefault; /*0x08 */
  695. MPI2_VERSION_UNION NvdataVersionPersistent; /*0x0A */
  696. } MPI2_CONFIG_PAGE_IO_UNIT_0,
  697. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_0,
  698. Mpi2IOUnitPage0_t, *pMpi2IOUnitPage0_t;
  699. #define MPI2_IOUNITPAGE0_PAGEVERSION (0x02)
  700. /*IO Unit Page 1 */
  701. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_1 {
  702. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  703. U32 Flags; /*0x04 */
  704. } MPI2_CONFIG_PAGE_IO_UNIT_1,
  705. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_1,
  706. Mpi2IOUnitPage1_t, *pMpi2IOUnitPage1_t;
  707. #define MPI2_IOUNITPAGE1_PAGEVERSION (0x04)
  708. /*IO Unit Page 1 Flags defines */
  709. #define MPI2_IOUNITPAGE1_ATA_SECURITY_FREEZE_LOCK (0x00004000)
  710. #define MPI25_IOUNITPAGE1_NEW_DEVICE_FAST_PATH_DISABLE (0x00002000)
  711. #define MPI25_IOUNITPAGE1_DISABLE_FAST_PATH (0x00001000)
  712. #define MPI2_IOUNITPAGE1_ENABLE_HOST_BASED_DISCOVERY (0x00000800)
  713. #define MPI2_IOUNITPAGE1_MASK_SATA_WRITE_CACHE (0x00000600)
  714. #define MPI2_IOUNITPAGE1_SATA_WRITE_CACHE_SHIFT (9)
  715. #define MPI2_IOUNITPAGE1_ENABLE_SATA_WRITE_CACHE (0x00000000)
  716. #define MPI2_IOUNITPAGE1_DISABLE_SATA_WRITE_CACHE (0x00000200)
  717. #define MPI2_IOUNITPAGE1_UNCHANGED_SATA_WRITE_CACHE (0x00000400)
  718. #define MPI2_IOUNITPAGE1_NATIVE_COMMAND_Q_DISABLE (0x00000100)
  719. #define MPI2_IOUNITPAGE1_DISABLE_IR (0x00000040)
  720. #define MPI2_IOUNITPAGE1_DISABLE_TASK_SET_FULL_HANDLING (0x00000020)
  721. #define MPI2_IOUNITPAGE1_IR_USE_STATIC_VOLUME_ID (0x00000004)
  722. /*IO Unit Page 3 */
  723. /*
  724. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  725. *one and check the value returned for GPIOCount at runtime.
  726. */
  727. #ifndef MPI2_IO_UNIT_PAGE_3_GPIO_VAL_MAX
  728. #define MPI2_IO_UNIT_PAGE_3_GPIO_VAL_MAX (1)
  729. #endif
  730. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_3 {
  731. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  732. U8 GPIOCount; /*0x04 */
  733. U8 Reserved1; /*0x05 */
  734. U16 Reserved2; /*0x06 */
  735. U16
  736. GPIOVal[MPI2_IO_UNIT_PAGE_3_GPIO_VAL_MAX];/*0x08 */
  737. } MPI2_CONFIG_PAGE_IO_UNIT_3,
  738. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_3,
  739. Mpi2IOUnitPage3_t, *pMpi2IOUnitPage3_t;
  740. #define MPI2_IOUNITPAGE3_PAGEVERSION (0x01)
  741. /*defines for IO Unit Page 3 GPIOVal field */
  742. #define MPI2_IOUNITPAGE3_GPIO_FUNCTION_MASK (0xFFFC)
  743. #define MPI2_IOUNITPAGE3_GPIO_FUNCTION_SHIFT (2)
  744. #define MPI2_IOUNITPAGE3_GPIO_SETTING_OFF (0x0000)
  745. #define MPI2_IOUNITPAGE3_GPIO_SETTING_ON (0x0001)
  746. /*IO Unit Page 5 */
  747. /*
  748. *Upper layer code (drivers, utilities, etc.) should leave this define set to
  749. *one and check the value returned for NumDmaEngines at runtime.
  750. */
  751. #ifndef MPI2_IOUNITPAGE5_DMAENGINE_ENTRIES
  752. #define MPI2_IOUNITPAGE5_DMAENGINE_ENTRIES (1)
  753. #endif
  754. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_5 {
  755. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  756. U64
  757. RaidAcceleratorBufferBaseAddress; /*0x04 */
  758. U64
  759. RaidAcceleratorBufferSize; /*0x0C */
  760. U64
  761. RaidAcceleratorControlBaseAddress; /*0x14 */
  762. U8 RAControlSize; /*0x1C */
  763. U8 NumDmaEngines; /*0x1D */
  764. U8 RAMinControlSize; /*0x1E */
  765. U8 RAMaxControlSize; /*0x1F */
  766. U32 Reserved1; /*0x20 */
  767. U32 Reserved2; /*0x24 */
  768. U32 Reserved3; /*0x28 */
  769. U32
  770. DmaEngineCapabilities[MPI2_IOUNITPAGE5_DMAENGINE_ENTRIES]; /*0x2C */
  771. } MPI2_CONFIG_PAGE_IO_UNIT_5,
  772. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_5,
  773. Mpi2IOUnitPage5_t, *pMpi2IOUnitPage5_t;
  774. #define MPI2_IOUNITPAGE5_PAGEVERSION (0x00)
  775. /*defines for IO Unit Page 5 DmaEngineCapabilities field */
  776. #define MPI2_IOUNITPAGE5_DMA_CAP_MASK_MAX_REQUESTS (0xFFFF0000)
  777. #define MPI2_IOUNITPAGE5_DMA_CAP_SHIFT_MAX_REQUESTS (16)
  778. #define MPI2_IOUNITPAGE5_DMA_CAP_EEDP (0x0008)
  779. #define MPI2_IOUNITPAGE5_DMA_CAP_PARITY_GENERATION (0x0004)
  780. #define MPI2_IOUNITPAGE5_DMA_CAP_HASHING (0x0002)
  781. #define MPI2_IOUNITPAGE5_DMA_CAP_ENCRYPTION (0x0001)
  782. /*IO Unit Page 6 */
  783. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_6 {
  784. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  785. U16 Flags; /*0x04 */
  786. U8 RAHostControlSize; /*0x06 */
  787. U8 Reserved0; /*0x07 */
  788. U64
  789. RaidAcceleratorHostControlBaseAddress; /*0x08 */
  790. U32 Reserved1; /*0x10 */
  791. U32 Reserved2; /*0x14 */
  792. U32 Reserved3; /*0x18 */
  793. } MPI2_CONFIG_PAGE_IO_UNIT_6,
  794. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_6,
  795. Mpi2IOUnitPage6_t, *pMpi2IOUnitPage6_t;
  796. #define MPI2_IOUNITPAGE6_PAGEVERSION (0x00)
  797. /*defines for IO Unit Page 6 Flags field */
  798. #define MPI2_IOUNITPAGE6_FLAGS_ENABLE_RAID_ACCELERATOR (0x0001)
  799. /*IO Unit Page 7 */
  800. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_7 {
  801. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  802. U8 CurrentPowerMode; /*0x04 */
  803. U8 PreviousPowerMode; /*0x05 */
  804. U8 PCIeWidth; /*0x06 */
  805. U8 PCIeSpeed; /*0x07 */
  806. U32 ProcessorState; /*0x08 */
  807. U32
  808. PowerManagementCapabilities; /*0x0C */
  809. U16 IOCTemperature; /*0x10 */
  810. U8
  811. IOCTemperatureUnits; /*0x12 */
  812. U8 IOCSpeed; /*0x13 */
  813. U16 BoardTemperature; /*0x14 */
  814. U8
  815. BoardTemperatureUnits; /*0x16 */
  816. U8 Reserved3; /*0x17 */
  817. U32 BoardPowerRequirement; /*0x18 */
  818. U32 PCISlotPowerAllocation; /*0x1C */
  819. /* reserved prior to MPI v2.6 */
  820. U8 Flags; /* 0x20 */
  821. U8 Reserved6; /* 0x21 */
  822. U16 Reserved7; /* 0x22 */
  823. U32 Reserved8; /* 0x24 */
  824. } MPI2_CONFIG_PAGE_IO_UNIT_7,
  825. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_7,
  826. Mpi2IOUnitPage7_t, *pMpi2IOUnitPage7_t;
  827. #define MPI2_IOUNITPAGE7_PAGEVERSION (0x05)
  828. /*defines for IO Unit Page 7 CurrentPowerMode and PreviousPowerMode fields */
  829. #define MPI25_IOUNITPAGE7_PM_INIT_MASK (0xC0)
  830. #define MPI25_IOUNITPAGE7_PM_INIT_UNAVAILABLE (0x00)
  831. #define MPI25_IOUNITPAGE7_PM_INIT_HOST (0x40)
  832. #define MPI25_IOUNITPAGE7_PM_INIT_IO_UNIT (0x80)
  833. #define MPI25_IOUNITPAGE7_PM_INIT_PCIE_DPA (0xC0)
  834. #define MPI25_IOUNITPAGE7_PM_MODE_MASK (0x07)
  835. #define MPI25_IOUNITPAGE7_PM_MODE_UNAVAILABLE (0x00)
  836. #define MPI25_IOUNITPAGE7_PM_MODE_UNKNOWN (0x01)
  837. #define MPI25_IOUNITPAGE7_PM_MODE_FULL_POWER (0x04)
  838. #define MPI25_IOUNITPAGE7_PM_MODE_REDUCED_POWER (0x05)
  839. #define MPI25_IOUNITPAGE7_PM_MODE_STANDBY (0x06)
  840. /*defines for IO Unit Page 7 PCIeWidth field */
  841. #define MPI2_IOUNITPAGE7_PCIE_WIDTH_X1 (0x01)
  842. #define MPI2_IOUNITPAGE7_PCIE_WIDTH_X2 (0x02)
  843. #define MPI2_IOUNITPAGE7_PCIE_WIDTH_X4 (0x04)
  844. #define MPI2_IOUNITPAGE7_PCIE_WIDTH_X8 (0x08)
  845. /*defines for IO Unit Page 7 PCIeSpeed field */
  846. #define MPI2_IOUNITPAGE7_PCIE_SPEED_2_5_GBPS (0x00)
  847. #define MPI2_IOUNITPAGE7_PCIE_SPEED_5_0_GBPS (0x01)
  848. #define MPI2_IOUNITPAGE7_PCIE_SPEED_8_0_GBPS (0x02)
  849. /*defines for IO Unit Page 7 ProcessorState field */
  850. #define MPI2_IOUNITPAGE7_PSTATE_MASK_SECOND (0x0000000F)
  851. #define MPI2_IOUNITPAGE7_PSTATE_SHIFT_SECOND (0)
  852. #define MPI2_IOUNITPAGE7_PSTATE_NOT_PRESENT (0x00)
  853. #define MPI2_IOUNITPAGE7_PSTATE_DISABLED (0x01)
  854. #define MPI2_IOUNITPAGE7_PSTATE_ENABLED (0x02)
  855. /*defines for IO Unit Page 7 PowerManagementCapabilities field */
  856. #define MPI25_IOUNITPAGE7_PMCAP_DPA_FULL_PWR_MODE (0x00400000)
  857. #define MPI25_IOUNITPAGE7_PMCAP_DPA_REDUCED_PWR_MODE (0x00200000)
  858. #define MPI25_IOUNITPAGE7_PMCAP_DPA_STANDBY_MODE (0x00100000)
  859. #define MPI25_IOUNITPAGE7_PMCAP_HOST_FULL_PWR_MODE (0x00040000)
  860. #define MPI25_IOUNITPAGE7_PMCAP_HOST_REDUCED_PWR_MODE (0x00020000)
  861. #define MPI25_IOUNITPAGE7_PMCAP_HOST_STANDBY_MODE (0x00010000)
  862. #define MPI25_IOUNITPAGE7_PMCAP_IO_FULL_PWR_MODE (0x00004000)
  863. #define MPI25_IOUNITPAGE7_PMCAP_IO_REDUCED_PWR_MODE (0x00002000)
  864. #define MPI25_IOUNITPAGE7_PMCAP_IO_STANDBY_MODE (0x00001000)
  865. #define MPI2_IOUNITPAGE7_PMCAP_HOST_12_5_PCT_IOCSPEED (0x00000400)
  866. #define MPI2_IOUNITPAGE7_PMCAP_HOST_25_0_PCT_IOCSPEED (0x00000200)
  867. #define MPI2_IOUNITPAGE7_PMCAP_HOST_50_0_PCT_IOCSPEED (0x00000100)
  868. #define MPI25_IOUNITPAGE7_PMCAP_IO_12_5_PCT_IOCSPEED (0x00000040)
  869. #define MPI25_IOUNITPAGE7_PMCAP_IO_25_0_PCT_IOCSPEED (0x00000020)
  870. #define MPI25_IOUNITPAGE7_PMCAP_IO_50_0_PCT_IOCSPEED (0x00000010)
  871. #define MPI2_IOUNITPAGE7_PMCAP_HOST_WIDTH_CHANGE_PCIE (0x00000008)
  872. #define MPI2_IOUNITPAGE7_PMCAP_HOST_SPEED_CHANGE_PCIE (0x00000004)
  873. #define MPI25_IOUNITPAGE7_PMCAP_IO_WIDTH_CHANGE_PCIE (0x00000002)
  874. #define MPI25_IOUNITPAGE7_PMCAP_IO_SPEED_CHANGE_PCIE (0x00000001)
  875. /*obsolete names for the PowerManagementCapabilities bits (above) */
  876. #define MPI2_IOUNITPAGE7_PMCAP_12_5_PCT_IOCSPEED (0x00000400)
  877. #define MPI2_IOUNITPAGE7_PMCAP_25_0_PCT_IOCSPEED (0x00000200)
  878. #define MPI2_IOUNITPAGE7_PMCAP_50_0_PCT_IOCSPEED (0x00000100)
  879. #define MPI2_IOUNITPAGE7_PMCAP_PCIE_WIDTH_CHANGE (0x00000008) /*obsolete */
  880. #define MPI2_IOUNITPAGE7_PMCAP_PCIE_SPEED_CHANGE (0x00000004) /*obsolete */
  881. /*defines for IO Unit Page 7 IOCTemperatureUnits field */
  882. #define MPI2_IOUNITPAGE7_IOC_TEMP_NOT_PRESENT (0x00)
  883. #define MPI2_IOUNITPAGE7_IOC_TEMP_FAHRENHEIT (0x01)
  884. #define MPI2_IOUNITPAGE7_IOC_TEMP_CELSIUS (0x02)
  885. /*defines for IO Unit Page 7 IOCSpeed field */
  886. #define MPI2_IOUNITPAGE7_IOC_SPEED_FULL (0x01)
  887. #define MPI2_IOUNITPAGE7_IOC_SPEED_HALF (0x02)
  888. #define MPI2_IOUNITPAGE7_IOC_SPEED_QUARTER (0x04)
  889. #define MPI2_IOUNITPAGE7_IOC_SPEED_EIGHTH (0x08)
  890. /*defines for IO Unit Page 7 BoardTemperatureUnits field */
  891. #define MPI2_IOUNITPAGE7_BOARD_TEMP_NOT_PRESENT (0x00)
  892. #define MPI2_IOUNITPAGE7_BOARD_TEMP_FAHRENHEIT (0x01)
  893. #define MPI2_IOUNITPAGE7_BOARD_TEMP_CELSIUS (0x02)
  894. /* defines for IO Unit Page 7 Flags field */
  895. #define MPI2_IOUNITPAGE7_FLAG_CABLE_POWER_EXC (0x01)
  896. /*IO Unit Page 8 */
  897. #define MPI2_IOUNIT8_NUM_THRESHOLDS (4)
  898. typedef struct _MPI2_IOUNIT8_SENSOR {
  899. U16 Flags; /*0x00 */
  900. U16 Reserved1; /*0x02 */
  901. U16
  902. Threshold[MPI2_IOUNIT8_NUM_THRESHOLDS]; /*0x04 */
  903. U32 Reserved2; /*0x0C */
  904. U32 Reserved3; /*0x10 */
  905. U32 Reserved4; /*0x14 */
  906. } MPI2_IOUNIT8_SENSOR, *PTR_MPI2_IOUNIT8_SENSOR,
  907. Mpi2IOUnit8Sensor_t, *pMpi2IOUnit8Sensor_t;
  908. /*defines for IO Unit Page 8 Sensor Flags field */
  909. #define MPI2_IOUNIT8_SENSOR_FLAGS_T3_ENABLE (0x0008)
  910. #define MPI2_IOUNIT8_SENSOR_FLAGS_T2_ENABLE (0x0004)
  911. #define MPI2_IOUNIT8_SENSOR_FLAGS_T1_ENABLE (0x0002)
  912. #define MPI2_IOUNIT8_SENSOR_FLAGS_T0_ENABLE (0x0001)
  913. /*
  914. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  915. *one and check the value returned for NumSensors at runtime.
  916. */
  917. #ifndef MPI2_IOUNITPAGE8_SENSOR_ENTRIES
  918. #define MPI2_IOUNITPAGE8_SENSOR_ENTRIES (1)
  919. #endif
  920. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_8 {
  921. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  922. U32 Reserved1; /*0x04 */
  923. U32 Reserved2; /*0x08 */
  924. U8 NumSensors; /*0x0C */
  925. U8 PollingInterval; /*0x0D */
  926. U16 Reserved3; /*0x0E */
  927. MPI2_IOUNIT8_SENSOR
  928. Sensor[MPI2_IOUNITPAGE8_SENSOR_ENTRIES];/*0x10 */
  929. } MPI2_CONFIG_PAGE_IO_UNIT_8,
  930. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_8,
  931. Mpi2IOUnitPage8_t, *pMpi2IOUnitPage8_t;
  932. #define MPI2_IOUNITPAGE8_PAGEVERSION (0x00)
  933. /*IO Unit Page 9 */
  934. typedef struct _MPI2_IOUNIT9_SENSOR {
  935. U16 CurrentTemperature; /*0x00 */
  936. U16 Reserved1; /*0x02 */
  937. U8 Flags; /*0x04 */
  938. U8 Reserved2; /*0x05 */
  939. U16 Reserved3; /*0x06 */
  940. U32 Reserved4; /*0x08 */
  941. U32 Reserved5; /*0x0C */
  942. } MPI2_IOUNIT9_SENSOR, *PTR_MPI2_IOUNIT9_SENSOR,
  943. Mpi2IOUnit9Sensor_t, *pMpi2IOUnit9Sensor_t;
  944. /*defines for IO Unit Page 9 Sensor Flags field */
  945. #define MPI2_IOUNIT9_SENSOR_FLAGS_TEMP_VALID (0x01)
  946. /*
  947. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  948. *one and check the value returned for NumSensors at runtime.
  949. */
  950. #ifndef MPI2_IOUNITPAGE9_SENSOR_ENTRIES
  951. #define MPI2_IOUNITPAGE9_SENSOR_ENTRIES (1)
  952. #endif
  953. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_9 {
  954. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  955. U32 Reserved1; /*0x04 */
  956. U32 Reserved2; /*0x08 */
  957. U8 NumSensors; /*0x0C */
  958. U8 Reserved4; /*0x0D */
  959. U16 Reserved3; /*0x0E */
  960. MPI2_IOUNIT9_SENSOR
  961. Sensor[MPI2_IOUNITPAGE9_SENSOR_ENTRIES];/*0x10 */
  962. } MPI2_CONFIG_PAGE_IO_UNIT_9,
  963. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_9,
  964. Mpi2IOUnitPage9_t, *pMpi2IOUnitPage9_t;
  965. #define MPI2_IOUNITPAGE9_PAGEVERSION (0x00)
  966. /*IO Unit Page 10 */
  967. typedef struct _MPI2_IOUNIT10_FUNCTION {
  968. U8 CreditPercent; /*0x00 */
  969. U8 Reserved1; /*0x01 */
  970. U16 Reserved2; /*0x02 */
  971. } MPI2_IOUNIT10_FUNCTION,
  972. *PTR_MPI2_IOUNIT10_FUNCTION,
  973. Mpi2IOUnit10Function_t,
  974. *pMpi2IOUnit10Function_t;
  975. /*
  976. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  977. *one and check the value returned for NumFunctions at runtime.
  978. */
  979. #ifndef MPI2_IOUNITPAGE10_FUNCTION_ENTRIES
  980. #define MPI2_IOUNITPAGE10_FUNCTION_ENTRIES (1)
  981. #endif
  982. typedef struct _MPI2_CONFIG_PAGE_IO_UNIT_10 {
  983. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  984. U8 NumFunctions; /*0x04 */
  985. U8 Reserved1; /*0x05 */
  986. U16 Reserved2; /*0x06 */
  987. U32 Reserved3; /*0x08 */
  988. U32 Reserved4; /*0x0C */
  989. MPI2_IOUNIT10_FUNCTION
  990. Function[MPI2_IOUNITPAGE10_FUNCTION_ENTRIES];/*0x10 */
  991. } MPI2_CONFIG_PAGE_IO_UNIT_10,
  992. *PTR_MPI2_CONFIG_PAGE_IO_UNIT_10,
  993. Mpi2IOUnitPage10_t, *pMpi2IOUnitPage10_t;
  994. #define MPI2_IOUNITPAGE10_PAGEVERSION (0x01)
  995. /* IO Unit Page 11 (for MPI v2.6 and later) */
  996. typedef struct _MPI26_IOUNIT11_SPINUP_GROUP {
  997. U8 MaxTargetSpinup; /* 0x00 */
  998. U8 SpinupDelay; /* 0x01 */
  999. U8 SpinupFlags; /* 0x02 */
  1000. U8 Reserved1; /* 0x03 */
  1001. } MPI26_IOUNIT11_SPINUP_GROUP,
  1002. *PTR_MPI26_IOUNIT11_SPINUP_GROUP,
  1003. Mpi26IOUnit11SpinupGroup_t,
  1004. *pMpi26IOUnit11SpinupGroup_t;
  1005. /* defines for IO Unit Page 11 SpinupFlags */
  1006. #define MPI26_IOUNITPAGE11_SPINUP_DISABLE_FLAG (0x01)
  1007. /*
  1008. * Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  1009. * four and check the value returned for NumPhys at runtime.
  1010. */
  1011. #ifndef MPI26_IOUNITPAGE11_PHY_MAX
  1012. #define MPI26_IOUNITPAGE11_PHY_MAX (4)
  1013. #endif
  1014. typedef struct _MPI26_CONFIG_PAGE_IO_UNIT_11 {
  1015. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1016. U32 Reserved1; /*0x04 */
  1017. MPI26_IOUNIT11_SPINUP_GROUP SpinupGroupParameters[4]; /*0x08 */
  1018. U32 Reserved2; /*0x18 */
  1019. U32 Reserved3; /*0x1C */
  1020. U32 Reserved4; /*0x20 */
  1021. U8 BootDeviceWaitTime; /*0x24 */
  1022. U8 Reserved5; /*0x25 */
  1023. U16 Reserved6; /*0x26 */
  1024. U8 NumPhys; /*0x28 */
  1025. U8 PEInitialSpinupDelay; /*0x29 */
  1026. U8 PEReplyDelay; /*0x2A */
  1027. U8 Flags; /*0x2B */
  1028. U8 PHY[MPI26_IOUNITPAGE11_PHY_MAX];/*0x2C */
  1029. } MPI26_CONFIG_PAGE_IO_UNIT_11,
  1030. *PTR_MPI26_CONFIG_PAGE_IO_UNIT_11,
  1031. Mpi26IOUnitPage11_t,
  1032. *pMpi26IOUnitPage11_t;
  1033. #define MPI26_IOUNITPAGE11_PAGEVERSION (0x00)
  1034. /* defines for Flags field */
  1035. #define MPI26_IOUNITPAGE11_FLAGS_AUTO_PORTENABLE (0x01)
  1036. /* defines for PHY field */
  1037. #define MPI26_IOUNITPAGE11_PHY_SPINUP_GROUP_MASK (0x03)
  1038. /****************************************************************************
  1039. * IOC Config Pages
  1040. ****************************************************************************/
  1041. /*IOC Page 0 */
  1042. typedef struct _MPI2_CONFIG_PAGE_IOC_0 {
  1043. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1044. U32 Reserved1; /*0x04 */
  1045. U32 Reserved2; /*0x08 */
  1046. U16 VendorID; /*0x0C */
  1047. U16 DeviceID; /*0x0E */
  1048. U8 RevisionID; /*0x10 */
  1049. U8 Reserved3; /*0x11 */
  1050. U16 Reserved4; /*0x12 */
  1051. U32 ClassCode; /*0x14 */
  1052. U16 SubsystemVendorID; /*0x18 */
  1053. U16 SubsystemID; /*0x1A */
  1054. } MPI2_CONFIG_PAGE_IOC_0,
  1055. *PTR_MPI2_CONFIG_PAGE_IOC_0,
  1056. Mpi2IOCPage0_t, *pMpi2IOCPage0_t;
  1057. #define MPI2_IOCPAGE0_PAGEVERSION (0x02)
  1058. /*IOC Page 1 */
  1059. typedef struct _MPI2_CONFIG_PAGE_IOC_1 {
  1060. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1061. U32 Flags; /*0x04 */
  1062. U32 CoalescingTimeout; /*0x08 */
  1063. U8 CoalescingDepth; /*0x0C */
  1064. U8 PCISlotNum; /*0x0D */
  1065. U8 PCIBusNum; /*0x0E */
  1066. U8 PCIDomainSegment; /*0x0F */
  1067. U32 Reserved1; /*0x10 */
  1068. U32 Reserved2; /*0x14 */
  1069. } MPI2_CONFIG_PAGE_IOC_1,
  1070. *PTR_MPI2_CONFIG_PAGE_IOC_1,
  1071. Mpi2IOCPage1_t, *pMpi2IOCPage1_t;
  1072. #define MPI2_IOCPAGE1_PAGEVERSION (0x05)
  1073. /*defines for IOC Page 1 Flags field */
  1074. #define MPI2_IOCPAGE1_REPLY_COALESCING (0x00000001)
  1075. #define MPI2_IOCPAGE1_PCISLOTNUM_UNKNOWN (0xFF)
  1076. #define MPI2_IOCPAGE1_PCIBUSNUM_UNKNOWN (0xFF)
  1077. #define MPI2_IOCPAGE1_PCIDOMAIN_UNKNOWN (0xFF)
  1078. /*IOC Page 6 */
  1079. typedef struct _MPI2_CONFIG_PAGE_IOC_6 {
  1080. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1081. U32
  1082. CapabilitiesFlags; /*0x04 */
  1083. U8 MaxDrivesRAID0; /*0x08 */
  1084. U8 MaxDrivesRAID1; /*0x09 */
  1085. U8
  1086. MaxDrivesRAID1E; /*0x0A */
  1087. U8
  1088. MaxDrivesRAID10; /*0x0B */
  1089. U8 MinDrivesRAID0; /*0x0C */
  1090. U8 MinDrivesRAID1; /*0x0D */
  1091. U8
  1092. MinDrivesRAID1E; /*0x0E */
  1093. U8
  1094. MinDrivesRAID10; /*0x0F */
  1095. U32 Reserved1; /*0x10 */
  1096. U8
  1097. MaxGlobalHotSpares; /*0x14 */
  1098. U8 MaxPhysDisks; /*0x15 */
  1099. U8 MaxVolumes; /*0x16 */
  1100. U8 MaxConfigs; /*0x17 */
  1101. U8 MaxOCEDisks; /*0x18 */
  1102. U8 Reserved2; /*0x19 */
  1103. U16 Reserved3; /*0x1A */
  1104. U32
  1105. SupportedStripeSizeMapRAID0; /*0x1C */
  1106. U32
  1107. SupportedStripeSizeMapRAID1E; /*0x20 */
  1108. U32
  1109. SupportedStripeSizeMapRAID10; /*0x24 */
  1110. U32 Reserved4; /*0x28 */
  1111. U32 Reserved5; /*0x2C */
  1112. U16
  1113. DefaultMetadataSize; /*0x30 */
  1114. U16 Reserved6; /*0x32 */
  1115. U16
  1116. MaxBadBlockTableEntries; /*0x34 */
  1117. U16 Reserved7; /*0x36 */
  1118. U32
  1119. IRNvsramVersion; /*0x38 */
  1120. } MPI2_CONFIG_PAGE_IOC_6,
  1121. *PTR_MPI2_CONFIG_PAGE_IOC_6,
  1122. Mpi2IOCPage6_t, *pMpi2IOCPage6_t;
  1123. #define MPI2_IOCPAGE6_PAGEVERSION (0x05)
  1124. /*defines for IOC Page 6 CapabilitiesFlags */
  1125. #define MPI2_IOCPAGE6_CAP_FLAGS_4K_SECTORS_SUPPORT (0x00000020)
  1126. #define MPI2_IOCPAGE6_CAP_FLAGS_RAID10_SUPPORT (0x00000010)
  1127. #define MPI2_IOCPAGE6_CAP_FLAGS_RAID1_SUPPORT (0x00000008)
  1128. #define MPI2_IOCPAGE6_CAP_FLAGS_RAID1E_SUPPORT (0x00000004)
  1129. #define MPI2_IOCPAGE6_CAP_FLAGS_RAID0_SUPPORT (0x00000002)
  1130. #define MPI2_IOCPAGE6_CAP_FLAGS_GLOBAL_HOT_SPARE (0x00000001)
  1131. /*IOC Page 7 */
  1132. #define MPI2_IOCPAGE7_EVENTMASK_WORDS (4)
  1133. typedef struct _MPI2_CONFIG_PAGE_IOC_7 {
  1134. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1135. U32 Reserved1; /*0x04 */
  1136. U32
  1137. EventMasks[MPI2_IOCPAGE7_EVENTMASK_WORDS];/*0x08 */
  1138. U16 SASBroadcastPrimitiveMasks; /*0x18 */
  1139. U16 SASNotifyPrimitiveMasks; /*0x1A */
  1140. U32 Reserved3; /*0x1C */
  1141. } MPI2_CONFIG_PAGE_IOC_7,
  1142. *PTR_MPI2_CONFIG_PAGE_IOC_7,
  1143. Mpi2IOCPage7_t, *pMpi2IOCPage7_t;
  1144. #define MPI2_IOCPAGE7_PAGEVERSION (0x02)
  1145. /*IOC Page 8 */
  1146. typedef struct _MPI2_CONFIG_PAGE_IOC_8 {
  1147. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1148. U8 NumDevsPerEnclosure; /*0x04 */
  1149. U8 Reserved1; /*0x05 */
  1150. U16 Reserved2; /*0x06 */
  1151. U16 MaxPersistentEntries; /*0x08 */
  1152. U16 MaxNumPhysicalMappedIDs; /*0x0A */
  1153. U16 Flags; /*0x0C */
  1154. U16 Reserved3; /*0x0E */
  1155. U16 IRVolumeMappingFlags; /*0x10 */
  1156. U16 Reserved4; /*0x12 */
  1157. U32 Reserved5; /*0x14 */
  1158. } MPI2_CONFIG_PAGE_IOC_8,
  1159. *PTR_MPI2_CONFIG_PAGE_IOC_8,
  1160. Mpi2IOCPage8_t, *pMpi2IOCPage8_t;
  1161. #define MPI2_IOCPAGE8_PAGEVERSION (0x00)
  1162. /*defines for IOC Page 8 Flags field */
  1163. #define MPI2_IOCPAGE8_FLAGS_DA_START_SLOT_1 (0x00000020)
  1164. #define MPI2_IOCPAGE8_FLAGS_RESERVED_TARGETID_0 (0x00000010)
  1165. #define MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE (0x0000000E)
  1166. #define MPI2_IOCPAGE8_FLAGS_DEVICE_PERSISTENCE_MAPPING (0x00000000)
  1167. #define MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING (0x00000002)
  1168. #define MPI2_IOCPAGE8_FLAGS_DISABLE_PERSISTENT_MAPPING (0x00000001)
  1169. #define MPI2_IOCPAGE8_FLAGS_ENABLE_PERSISTENT_MAPPING (0x00000000)
  1170. /*defines for IOC Page 8 IRVolumeMappingFlags */
  1171. #define MPI2_IOCPAGE8_IRFLAGS_MASK_VOLUME_MAPPING_MODE (0x00000003)
  1172. #define MPI2_IOCPAGE8_IRFLAGS_LOW_VOLUME_MAPPING (0x00000000)
  1173. #define MPI2_IOCPAGE8_IRFLAGS_HIGH_VOLUME_MAPPING (0x00000001)
  1174. /****************************************************************************
  1175. * BIOS Config Pages
  1176. ****************************************************************************/
  1177. /*BIOS Page 1 */
  1178. typedef struct _MPI2_CONFIG_PAGE_BIOS_1 {
  1179. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1180. U32 BiosOptions; /*0x04 */
  1181. U32 IOCSettings; /*0x08 */
  1182. U8 SSUTimeout; /*0x0C */
  1183. U8 Reserved1; /*0x0D */
  1184. U16 Reserved2; /*0x0E */
  1185. U32 DeviceSettings; /*0x10 */
  1186. U16 NumberOfDevices; /*0x14 */
  1187. U16 UEFIVersion; /*0x16 */
  1188. U16 IOTimeoutBlockDevicesNonRM; /*0x18 */
  1189. U16 IOTimeoutSequential; /*0x1A */
  1190. U16 IOTimeoutOther; /*0x1C */
  1191. U16 IOTimeoutBlockDevicesRM; /*0x1E */
  1192. } MPI2_CONFIG_PAGE_BIOS_1,
  1193. *PTR_MPI2_CONFIG_PAGE_BIOS_1,
  1194. Mpi2BiosPage1_t, *pMpi2BiosPage1_t;
  1195. #define MPI2_BIOSPAGE1_PAGEVERSION (0x07)
  1196. /*values for BIOS Page 1 BiosOptions field */
  1197. #define MPI2_BIOSPAGE1_OPTIONS_BOOT_LIST_ADD_ALT_BOOT_DEVICE (0x00008000)
  1198. #define MPI2_BIOSPAGE1_OPTIONS_ADVANCED_CONFIG (0x00004000)
  1199. #define MPI2_BIOSPAGE1_OPTIONS_PNS_MASK (0x00003800)
  1200. #define MPI2_BIOSPAGE1_OPTIONS_PNS_MASK (0x00003800)
  1201. #define MPI2_BIOSPAGE1_OPTIONS_PNS_PBDHL (0x00000000)
  1202. #define MPI2_BIOSPAGE1_OPTIONS_PNS_ENCSLOSURE (0x00000800)
  1203. #define MPI2_BIOSPAGE1_OPTIONS_PNS_LWWID (0x00001000)
  1204. #define MPI2_BIOSPAGE1_OPTIONS_PNS_PSENS (0x00001800)
  1205. #define MPI2_BIOSPAGE1_OPTIONS_PNS_ESPHY (0x00002000)
  1206. #define MPI2_BIOSPAGE1_OPTIONS_X86_DISABLE_BIOS (0x00000400)
  1207. #define MPI2_BIOSPAGE1_OPTIONS_MASK_REGISTRATION_UEFI_BSD (0x00000300)
  1208. #define MPI2_BIOSPAGE1_OPTIONS_USE_BIT0_REGISTRATION_UEFI_BSD (0x00000000)
  1209. #define MPI2_BIOSPAGE1_OPTIONS_FULL_REGISTRATION_UEFI_BSD (0x00000100)
  1210. #define MPI2_BIOSPAGE1_OPTIONS_ADAPTER_REGISTRATION_UEFI_BSD (0x00000200)
  1211. #define MPI2_BIOSPAGE1_OPTIONS_DISABLE_REGISTRATION_UEFI_BSD (0x00000300)
  1212. #define MPI2_BIOSPAGE1_OPTIONS_MASK_OEM_ID (0x000000F0)
  1213. #define MPI2_BIOSPAGE1_OPTIONS_LSI_OEM_ID (0x00000000)
  1214. #define MPI2_BIOSPAGE1_OPTIONS_MASK_UEFI_HII_REGISTRATION (0x00000006)
  1215. #define MPI2_BIOSPAGE1_OPTIONS_ENABLE_UEFI_HII (0x00000000)
  1216. #define MPI2_BIOSPAGE1_OPTIONS_DISABLE_UEFI_HII (0x00000002)
  1217. #define MPI2_BIOSPAGE1_OPTIONS_VERSION_CHECK_UEFI_HII (0x00000004)
  1218. #define MPI2_BIOSPAGE1_OPTIONS_DISABLE_BIOS (0x00000001)
  1219. /*values for BIOS Page 1 IOCSettings field */
  1220. #define MPI2_BIOSPAGE1_IOCSET_MASK_BOOT_PREFERENCE (0x00030000)
  1221. #define MPI2_BIOSPAGE1_IOCSET_ENCLOSURE_SLOT_BOOT (0x00000000)
  1222. #define MPI2_BIOSPAGE1_IOCSET_SAS_ADDRESS_BOOT (0x00010000)
  1223. #define MPI2_BIOSPAGE1_IOCSET_MASK_RM_SETTING (0x000000C0)
  1224. #define MPI2_BIOSPAGE1_IOCSET_NONE_RM_SETTING (0x00000000)
  1225. #define MPI2_BIOSPAGE1_IOCSET_BOOT_RM_SETTING (0x00000040)
  1226. #define MPI2_BIOSPAGE1_IOCSET_MEDIA_RM_SETTING (0x00000080)
  1227. #define MPI2_BIOSPAGE1_IOCSET_MASK_ADAPTER_SUPPORT (0x00000030)
  1228. #define MPI2_BIOSPAGE1_IOCSET_NO_SUPPORT (0x00000000)
  1229. #define MPI2_BIOSPAGE1_IOCSET_BIOS_SUPPORT (0x00000010)
  1230. #define MPI2_BIOSPAGE1_IOCSET_OS_SUPPORT (0x00000020)
  1231. #define MPI2_BIOSPAGE1_IOCSET_ALL_SUPPORT (0x00000030)
  1232. #define MPI2_BIOSPAGE1_IOCSET_ALTERNATE_CHS (0x00000008)
  1233. /*values for BIOS Page 1 DeviceSettings field */
  1234. #define MPI2_BIOSPAGE1_DEVSET_DISABLE_SMART_POLLING (0x00000010)
  1235. #define MPI2_BIOSPAGE1_DEVSET_DISABLE_SEQ_LUN (0x00000008)
  1236. #define MPI2_BIOSPAGE1_DEVSET_DISABLE_RM_LUN (0x00000004)
  1237. #define MPI2_BIOSPAGE1_DEVSET_DISABLE_NON_RM_LUN (0x00000002)
  1238. #define MPI2_BIOSPAGE1_DEVSET_DISABLE_OTHER_LUN (0x00000001)
  1239. /*defines for BIOS Page 1 UEFIVersion field */
  1240. #define MPI2_BIOSPAGE1_UEFI_VER_MAJOR_MASK (0xFF00)
  1241. #define MPI2_BIOSPAGE1_UEFI_VER_MAJOR_SHIFT (8)
  1242. #define MPI2_BIOSPAGE1_UEFI_VER_MINOR_MASK (0x00FF)
  1243. #define MPI2_BIOSPAGE1_UEFI_VER_MINOR_SHIFT (0)
  1244. /*BIOS Page 2 */
  1245. typedef struct _MPI2_BOOT_DEVICE_ADAPTER_ORDER {
  1246. U32 Reserved1; /*0x00 */
  1247. U32 Reserved2; /*0x04 */
  1248. U32 Reserved3; /*0x08 */
  1249. U32 Reserved4; /*0x0C */
  1250. U32 Reserved5; /*0x10 */
  1251. U32 Reserved6; /*0x14 */
  1252. } MPI2_BOOT_DEVICE_ADAPTER_ORDER,
  1253. *PTR_MPI2_BOOT_DEVICE_ADAPTER_ORDER,
  1254. Mpi2BootDeviceAdapterOrder_t,
  1255. *pMpi2BootDeviceAdapterOrder_t;
  1256. typedef struct _MPI2_BOOT_DEVICE_SAS_WWID {
  1257. U64 SASAddress; /*0x00 */
  1258. U8 LUN[8]; /*0x08 */
  1259. U32 Reserved1; /*0x10 */
  1260. U32 Reserved2; /*0x14 */
  1261. } MPI2_BOOT_DEVICE_SAS_WWID,
  1262. *PTR_MPI2_BOOT_DEVICE_SAS_WWID,
  1263. Mpi2BootDeviceSasWwid_t,
  1264. *pMpi2BootDeviceSasWwid_t;
  1265. typedef struct _MPI2_BOOT_DEVICE_ENCLOSURE_SLOT {
  1266. U64 EnclosureLogicalID; /*0x00 */
  1267. U32 Reserved1; /*0x08 */
  1268. U32 Reserved2; /*0x0C */
  1269. U16 SlotNumber; /*0x10 */
  1270. U16 Reserved3; /*0x12 */
  1271. U32 Reserved4; /*0x14 */
  1272. } MPI2_BOOT_DEVICE_ENCLOSURE_SLOT,
  1273. *PTR_MPI2_BOOT_DEVICE_ENCLOSURE_SLOT,
  1274. Mpi2BootDeviceEnclosureSlot_t,
  1275. *pMpi2BootDeviceEnclosureSlot_t;
  1276. typedef struct _MPI2_BOOT_DEVICE_DEVICE_NAME {
  1277. U64 DeviceName; /*0x00 */
  1278. U8 LUN[8]; /*0x08 */
  1279. U32 Reserved1; /*0x10 */
  1280. U32 Reserved2; /*0x14 */
  1281. } MPI2_BOOT_DEVICE_DEVICE_NAME,
  1282. *PTR_MPI2_BOOT_DEVICE_DEVICE_NAME,
  1283. Mpi2BootDeviceDeviceName_t,
  1284. *pMpi2BootDeviceDeviceName_t;
  1285. typedef union _MPI2_MPI2_BIOSPAGE2_BOOT_DEVICE {
  1286. MPI2_BOOT_DEVICE_ADAPTER_ORDER AdapterOrder;
  1287. MPI2_BOOT_DEVICE_SAS_WWID SasWwid;
  1288. MPI2_BOOT_DEVICE_ENCLOSURE_SLOT EnclosureSlot;
  1289. MPI2_BOOT_DEVICE_DEVICE_NAME DeviceName;
  1290. } MPI2_BIOSPAGE2_BOOT_DEVICE,
  1291. *PTR_MPI2_BIOSPAGE2_BOOT_DEVICE,
  1292. Mpi2BiosPage2BootDevice_t,
  1293. *pMpi2BiosPage2BootDevice_t;
  1294. typedef struct _MPI2_CONFIG_PAGE_BIOS_2 {
  1295. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1296. U32 Reserved1; /*0x04 */
  1297. U32 Reserved2; /*0x08 */
  1298. U32 Reserved3; /*0x0C */
  1299. U32 Reserved4; /*0x10 */
  1300. U32 Reserved5; /*0x14 */
  1301. U32 Reserved6; /*0x18 */
  1302. U8 ReqBootDeviceForm; /*0x1C */
  1303. U8 Reserved7; /*0x1D */
  1304. U16 Reserved8; /*0x1E */
  1305. MPI2_BIOSPAGE2_BOOT_DEVICE RequestedBootDevice; /*0x20 */
  1306. U8 ReqAltBootDeviceForm; /*0x38 */
  1307. U8 Reserved9; /*0x39 */
  1308. U16 Reserved10; /*0x3A */
  1309. MPI2_BIOSPAGE2_BOOT_DEVICE RequestedAltBootDevice; /*0x3C */
  1310. U8 CurrentBootDeviceForm; /*0x58 */
  1311. U8 Reserved11; /*0x59 */
  1312. U16 Reserved12; /*0x5A */
  1313. MPI2_BIOSPAGE2_BOOT_DEVICE CurrentBootDevice; /*0x58 */
  1314. } MPI2_CONFIG_PAGE_BIOS_2, *PTR_MPI2_CONFIG_PAGE_BIOS_2,
  1315. Mpi2BiosPage2_t, *pMpi2BiosPage2_t;
  1316. #define MPI2_BIOSPAGE2_PAGEVERSION (0x04)
  1317. /*values for BIOS Page 2 BootDeviceForm fields */
  1318. #define MPI2_BIOSPAGE2_FORM_MASK (0x0F)
  1319. #define MPI2_BIOSPAGE2_FORM_NO_DEVICE_SPECIFIED (0x00)
  1320. #define MPI2_BIOSPAGE2_FORM_SAS_WWID (0x05)
  1321. #define MPI2_BIOSPAGE2_FORM_ENCLOSURE_SLOT (0x06)
  1322. #define MPI2_BIOSPAGE2_FORM_DEVICE_NAME (0x07)
  1323. /*BIOS Page 3 */
  1324. #define MPI2_BIOSPAGE3_NUM_ADAPTER (4)
  1325. typedef struct _MPI2_ADAPTER_INFO {
  1326. U8 PciBusNumber; /*0x00 */
  1327. U8 PciDeviceAndFunctionNumber; /*0x01 */
  1328. U16 AdapterFlags; /*0x02 */
  1329. } MPI2_ADAPTER_INFO, *PTR_MPI2_ADAPTER_INFO,
  1330. Mpi2AdapterInfo_t, *pMpi2AdapterInfo_t;
  1331. #define MPI2_ADAPTER_INFO_FLAGS_EMBEDDED (0x0001)
  1332. #define MPI2_ADAPTER_INFO_FLAGS_INIT_STATUS (0x0002)
  1333. typedef struct _MPI2_ADAPTER_ORDER_AUX {
  1334. U64 WWID; /* 0x00 */
  1335. U32 Reserved1; /* 0x08 */
  1336. U32 Reserved2; /* 0x0C */
  1337. } MPI2_ADAPTER_ORDER_AUX, *PTR_MPI2_ADAPTER_ORDER_AUX,
  1338. Mpi2AdapterOrderAux_t, *pMpi2AdapterOrderAux_t;
  1339. typedef struct _MPI2_CONFIG_PAGE_BIOS_3 {
  1340. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1341. U32 GlobalFlags; /*0x04 */
  1342. U32 BiosVersion; /*0x08 */
  1343. MPI2_ADAPTER_INFO AdapterOrder[MPI2_BIOSPAGE3_NUM_ADAPTER];
  1344. U32 Reserved1; /*0x1C */
  1345. MPI2_ADAPTER_ORDER_AUX AdapterOrderAux[MPI2_BIOSPAGE3_NUM_ADAPTER];
  1346. } MPI2_CONFIG_PAGE_BIOS_3,
  1347. *PTR_MPI2_CONFIG_PAGE_BIOS_3,
  1348. Mpi2BiosPage3_t, *pMpi2BiosPage3_t;
  1349. #define MPI2_BIOSPAGE3_PAGEVERSION (0x01)
  1350. /*values for BIOS Page 3 GlobalFlags */
  1351. #define MPI2_BIOSPAGE3_FLAGS_PAUSE_ON_ERROR (0x00000002)
  1352. #define MPI2_BIOSPAGE3_FLAGS_VERBOSE_ENABLE (0x00000004)
  1353. #define MPI2_BIOSPAGE3_FLAGS_HOOK_INT_40_DISABLE (0x00000010)
  1354. #define MPI2_BIOSPAGE3_FLAGS_DEV_LIST_DISPLAY_MASK (0x000000E0)
  1355. #define MPI2_BIOSPAGE3_FLAGS_INSTALLED_DEV_DISPLAY (0x00000000)
  1356. #define MPI2_BIOSPAGE3_FLAGS_ADAPTER_DISPLAY (0x00000020)
  1357. #define MPI2_BIOSPAGE3_FLAGS_ADAPTER_DEV_DISPLAY (0x00000040)
  1358. /*BIOS Page 4 */
  1359. /*
  1360. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  1361. *one and check the value returned for NumPhys at runtime.
  1362. */
  1363. #ifndef MPI2_BIOS_PAGE_4_PHY_ENTRIES
  1364. #define MPI2_BIOS_PAGE_4_PHY_ENTRIES (1)
  1365. #endif
  1366. typedef struct _MPI2_BIOS4_ENTRY {
  1367. U64 ReassignmentWWID; /*0x00 */
  1368. U64 ReassignmentDeviceName; /*0x08 */
  1369. } MPI2_BIOS4_ENTRY, *PTR_MPI2_BIOS4_ENTRY,
  1370. Mpi2MBios4Entry_t, *pMpi2Bios4Entry_t;
  1371. typedef struct _MPI2_CONFIG_PAGE_BIOS_4 {
  1372. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1373. U8 NumPhys; /*0x04 */
  1374. U8 Reserved1; /*0x05 */
  1375. U16 Reserved2; /*0x06 */
  1376. MPI2_BIOS4_ENTRY
  1377. Phy[MPI2_BIOS_PAGE_4_PHY_ENTRIES]; /*0x08 */
  1378. } MPI2_CONFIG_PAGE_BIOS_4, *PTR_MPI2_CONFIG_PAGE_BIOS_4,
  1379. Mpi2BiosPage4_t, *pMpi2BiosPage4_t;
  1380. #define MPI2_BIOSPAGE4_PAGEVERSION (0x01)
  1381. /****************************************************************************
  1382. * RAID Volume Config Pages
  1383. ****************************************************************************/
  1384. /*RAID Volume Page 0 */
  1385. typedef struct _MPI2_RAIDVOL0_PHYS_DISK {
  1386. U8 RAIDSetNum; /*0x00 */
  1387. U8 PhysDiskMap; /*0x01 */
  1388. U8 PhysDiskNum; /*0x02 */
  1389. U8 Reserved; /*0x03 */
  1390. } MPI2_RAIDVOL0_PHYS_DISK, *PTR_MPI2_RAIDVOL0_PHYS_DISK,
  1391. Mpi2RaidVol0PhysDisk_t, *pMpi2RaidVol0PhysDisk_t;
  1392. /*defines for the PhysDiskMap field */
  1393. #define MPI2_RAIDVOL0_PHYSDISK_PRIMARY (0x01)
  1394. #define MPI2_RAIDVOL0_PHYSDISK_SECONDARY (0x02)
  1395. typedef struct _MPI2_RAIDVOL0_SETTINGS {
  1396. U16 Settings; /*0x00 */
  1397. U8 HotSparePool; /*0x01 */
  1398. U8 Reserved; /*0x02 */
  1399. } MPI2_RAIDVOL0_SETTINGS, *PTR_MPI2_RAIDVOL0_SETTINGS,
  1400. Mpi2RaidVol0Settings_t,
  1401. *pMpi2RaidVol0Settings_t;
  1402. /*RAID Volume Page 0 HotSparePool defines, also used in RAID Physical Disk */
  1403. #define MPI2_RAID_HOT_SPARE_POOL_0 (0x01)
  1404. #define MPI2_RAID_HOT_SPARE_POOL_1 (0x02)
  1405. #define MPI2_RAID_HOT_SPARE_POOL_2 (0x04)
  1406. #define MPI2_RAID_HOT_SPARE_POOL_3 (0x08)
  1407. #define MPI2_RAID_HOT_SPARE_POOL_4 (0x10)
  1408. #define MPI2_RAID_HOT_SPARE_POOL_5 (0x20)
  1409. #define MPI2_RAID_HOT_SPARE_POOL_6 (0x40)
  1410. #define MPI2_RAID_HOT_SPARE_POOL_7 (0x80)
  1411. /*RAID Volume Page 0 VolumeSettings defines */
  1412. #define MPI2_RAIDVOL0_SETTING_USE_PRODUCT_ID_SUFFIX (0x0008)
  1413. #define MPI2_RAIDVOL0_SETTING_AUTO_CONFIG_HSWAP_DISABLE (0x0004)
  1414. #define MPI2_RAIDVOL0_SETTING_MASK_WRITE_CACHING (0x0003)
  1415. #define MPI2_RAIDVOL0_SETTING_UNCHANGED (0x0000)
  1416. #define MPI2_RAIDVOL0_SETTING_DISABLE_WRITE_CACHING (0x0001)
  1417. #define MPI2_RAIDVOL0_SETTING_ENABLE_WRITE_CACHING (0x0002)
  1418. /*
  1419. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  1420. *one and check the value returned for NumPhysDisks at runtime.
  1421. */
  1422. #ifndef MPI2_RAID_VOL_PAGE_0_PHYSDISK_MAX
  1423. #define MPI2_RAID_VOL_PAGE_0_PHYSDISK_MAX (1)
  1424. #endif
  1425. typedef struct _MPI2_CONFIG_PAGE_RAID_VOL_0 {
  1426. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1427. U16 DevHandle; /*0x04 */
  1428. U8 VolumeState; /*0x06 */
  1429. U8 VolumeType; /*0x07 */
  1430. U32 VolumeStatusFlags; /*0x08 */
  1431. MPI2_RAIDVOL0_SETTINGS VolumeSettings; /*0x0C */
  1432. U64 MaxLBA; /*0x10 */
  1433. U32 StripeSize; /*0x18 */
  1434. U16 BlockSize; /*0x1C */
  1435. U16 Reserved1; /*0x1E */
  1436. U8 SupportedPhysDisks;/*0x20 */
  1437. U8 ResyncRate; /*0x21 */
  1438. U16 DataScrubDuration; /*0x22 */
  1439. U8 NumPhysDisks; /*0x24 */
  1440. U8 Reserved2; /*0x25 */
  1441. U8 Reserved3; /*0x26 */
  1442. U8 InactiveStatus; /*0x27 */
  1443. MPI2_RAIDVOL0_PHYS_DISK
  1444. PhysDisk[MPI2_RAID_VOL_PAGE_0_PHYSDISK_MAX]; /*0x28 */
  1445. } MPI2_CONFIG_PAGE_RAID_VOL_0,
  1446. *PTR_MPI2_CONFIG_PAGE_RAID_VOL_0,
  1447. Mpi2RaidVolPage0_t, *pMpi2RaidVolPage0_t;
  1448. #define MPI2_RAIDVOLPAGE0_PAGEVERSION (0x0A)
  1449. /*values for RAID VolumeState */
  1450. #define MPI2_RAID_VOL_STATE_MISSING (0x00)
  1451. #define MPI2_RAID_VOL_STATE_FAILED (0x01)
  1452. #define MPI2_RAID_VOL_STATE_INITIALIZING (0x02)
  1453. #define MPI2_RAID_VOL_STATE_ONLINE (0x03)
  1454. #define MPI2_RAID_VOL_STATE_DEGRADED (0x04)
  1455. #define MPI2_RAID_VOL_STATE_OPTIMAL (0x05)
  1456. /*values for RAID VolumeType */
  1457. #define MPI2_RAID_VOL_TYPE_RAID0 (0x00)
  1458. #define MPI2_RAID_VOL_TYPE_RAID1E (0x01)
  1459. #define MPI2_RAID_VOL_TYPE_RAID1 (0x02)
  1460. #define MPI2_RAID_VOL_TYPE_RAID10 (0x05)
  1461. #define MPI2_RAID_VOL_TYPE_UNKNOWN (0xFF)
  1462. /*values for RAID Volume Page 0 VolumeStatusFlags field */
  1463. #define MPI2_RAIDVOL0_STATUS_FLAG_PENDING_RESYNC (0x02000000)
  1464. #define MPI2_RAIDVOL0_STATUS_FLAG_BACKG_INIT_PENDING (0x01000000)
  1465. #define MPI2_RAIDVOL0_STATUS_FLAG_MDC_PENDING (0x00800000)
  1466. #define MPI2_RAIDVOL0_STATUS_FLAG_USER_CONSIST_PENDING (0x00400000)
  1467. #define MPI2_RAIDVOL0_STATUS_FLAG_MAKE_DATA_CONSISTENT (0x00200000)
  1468. #define MPI2_RAIDVOL0_STATUS_FLAG_DATA_SCRUB (0x00100000)
  1469. #define MPI2_RAIDVOL0_STATUS_FLAG_CONSISTENCY_CHECK (0x00080000)
  1470. #define MPI2_RAIDVOL0_STATUS_FLAG_CAPACITY_EXPANSION (0x00040000)
  1471. #define MPI2_RAIDVOL0_STATUS_FLAG_BACKGROUND_INIT (0x00020000)
  1472. #define MPI2_RAIDVOL0_STATUS_FLAG_RESYNC_IN_PROGRESS (0x00010000)
  1473. #define MPI2_RAIDVOL0_STATUS_FLAG_VOL_NOT_CONSISTENT (0x00000080)
  1474. #define MPI2_RAIDVOL0_STATUS_FLAG_OCE_ALLOWED (0x00000040)
  1475. #define MPI2_RAIDVOL0_STATUS_FLAG_BGI_COMPLETE (0x00000020)
  1476. #define MPI2_RAIDVOL0_STATUS_FLAG_1E_OFFSET_MIRROR (0x00000000)
  1477. #define MPI2_RAIDVOL0_STATUS_FLAG_1E_ADJACENT_MIRROR (0x00000010)
  1478. #define MPI2_RAIDVOL0_STATUS_FLAG_BAD_BLOCK_TABLE_FULL (0x00000008)
  1479. #define MPI2_RAIDVOL0_STATUS_FLAG_VOLUME_INACTIVE (0x00000004)
  1480. #define MPI2_RAIDVOL0_STATUS_FLAG_QUIESCED (0x00000002)
  1481. #define MPI2_RAIDVOL0_STATUS_FLAG_ENABLED (0x00000001)
  1482. /*values for RAID Volume Page 0 SupportedPhysDisks field */
  1483. #define MPI2_RAIDVOL0_SUPPORT_SOLID_STATE_DISKS (0x08)
  1484. #define MPI2_RAIDVOL0_SUPPORT_HARD_DISKS (0x04)
  1485. #define MPI2_RAIDVOL0_SUPPORT_SAS_PROTOCOL (0x02)
  1486. #define MPI2_RAIDVOL0_SUPPORT_SATA_PROTOCOL (0x01)
  1487. /*values for RAID Volume Page 0 InactiveStatus field */
  1488. #define MPI2_RAIDVOLPAGE0_UNKNOWN_INACTIVE (0x00)
  1489. #define MPI2_RAIDVOLPAGE0_STALE_METADATA_INACTIVE (0x01)
  1490. #define MPI2_RAIDVOLPAGE0_FOREIGN_VOLUME_INACTIVE (0x02)
  1491. #define MPI2_RAIDVOLPAGE0_INSUFFICIENT_RESOURCE_INACTIVE (0x03)
  1492. #define MPI2_RAIDVOLPAGE0_CLONE_VOLUME_INACTIVE (0x04)
  1493. #define MPI2_RAIDVOLPAGE0_INSUFFICIENT_METADATA_INACTIVE (0x05)
  1494. #define MPI2_RAIDVOLPAGE0_PREVIOUSLY_DELETED (0x06)
  1495. /*RAID Volume Page 1 */
  1496. typedef struct _MPI2_CONFIG_PAGE_RAID_VOL_1 {
  1497. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1498. U16 DevHandle; /*0x04 */
  1499. U16 Reserved0; /*0x06 */
  1500. U8 GUID[24]; /*0x08 */
  1501. U8 Name[16]; /*0x20 */
  1502. U64 WWID; /*0x30 */
  1503. U32 Reserved1; /*0x38 */
  1504. U32 Reserved2; /*0x3C */
  1505. } MPI2_CONFIG_PAGE_RAID_VOL_1,
  1506. *PTR_MPI2_CONFIG_PAGE_RAID_VOL_1,
  1507. Mpi2RaidVolPage1_t, *pMpi2RaidVolPage1_t;
  1508. #define MPI2_RAIDVOLPAGE1_PAGEVERSION (0x03)
  1509. /****************************************************************************
  1510. * RAID Physical Disk Config Pages
  1511. ****************************************************************************/
  1512. /*RAID Physical Disk Page 0 */
  1513. typedef struct _MPI2_RAIDPHYSDISK0_SETTINGS {
  1514. U16 Reserved1; /*0x00 */
  1515. U8 HotSparePool; /*0x02 */
  1516. U8 Reserved2; /*0x03 */
  1517. } MPI2_RAIDPHYSDISK0_SETTINGS,
  1518. *PTR_MPI2_RAIDPHYSDISK0_SETTINGS,
  1519. Mpi2RaidPhysDisk0Settings_t,
  1520. *pMpi2RaidPhysDisk0Settings_t;
  1521. /*use MPI2_RAID_HOT_SPARE_POOL_ defines for the HotSparePool field */
  1522. typedef struct _MPI2_RAIDPHYSDISK0_INQUIRY_DATA {
  1523. U8 VendorID[8]; /*0x00 */
  1524. U8 ProductID[16]; /*0x08 */
  1525. U8 ProductRevLevel[4]; /*0x18 */
  1526. U8 SerialNum[32]; /*0x1C */
  1527. } MPI2_RAIDPHYSDISK0_INQUIRY_DATA,
  1528. *PTR_MPI2_RAIDPHYSDISK0_INQUIRY_DATA,
  1529. Mpi2RaidPhysDisk0InquiryData_t,
  1530. *pMpi2RaidPhysDisk0InquiryData_t;
  1531. typedef struct _MPI2_CONFIG_PAGE_RD_PDISK_0 {
  1532. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1533. U16 DevHandle; /*0x04 */
  1534. U8 Reserved1; /*0x06 */
  1535. U8 PhysDiskNum; /*0x07 */
  1536. MPI2_RAIDPHYSDISK0_SETTINGS PhysDiskSettings; /*0x08 */
  1537. U32 Reserved2; /*0x0C */
  1538. MPI2_RAIDPHYSDISK0_INQUIRY_DATA InquiryData; /*0x10 */
  1539. U32 Reserved3; /*0x4C */
  1540. U8 PhysDiskState; /*0x50 */
  1541. U8 OfflineReason; /*0x51 */
  1542. U8 IncompatibleReason; /*0x52 */
  1543. U8 PhysDiskAttributes; /*0x53 */
  1544. U32 PhysDiskStatusFlags;/*0x54 */
  1545. U64 DeviceMaxLBA; /*0x58 */
  1546. U64 HostMaxLBA; /*0x60 */
  1547. U64 CoercedMaxLBA; /*0x68 */
  1548. U16 BlockSize; /*0x70 */
  1549. U16 Reserved5; /*0x72 */
  1550. U32 Reserved6; /*0x74 */
  1551. } MPI2_CONFIG_PAGE_RD_PDISK_0,
  1552. *PTR_MPI2_CONFIG_PAGE_RD_PDISK_0,
  1553. Mpi2RaidPhysDiskPage0_t,
  1554. *pMpi2RaidPhysDiskPage0_t;
  1555. #define MPI2_RAIDPHYSDISKPAGE0_PAGEVERSION (0x05)
  1556. /*PhysDiskState defines */
  1557. #define MPI2_RAID_PD_STATE_NOT_CONFIGURED (0x00)
  1558. #define MPI2_RAID_PD_STATE_NOT_COMPATIBLE (0x01)
  1559. #define MPI2_RAID_PD_STATE_OFFLINE (0x02)
  1560. #define MPI2_RAID_PD_STATE_ONLINE (0x03)
  1561. #define MPI2_RAID_PD_STATE_HOT_SPARE (0x04)
  1562. #define MPI2_RAID_PD_STATE_DEGRADED (0x05)
  1563. #define MPI2_RAID_PD_STATE_REBUILDING (0x06)
  1564. #define MPI2_RAID_PD_STATE_OPTIMAL (0x07)
  1565. /*OfflineReason defines */
  1566. #define MPI2_PHYSDISK0_ONLINE (0x00)
  1567. #define MPI2_PHYSDISK0_OFFLINE_MISSING (0x01)
  1568. #define MPI2_PHYSDISK0_OFFLINE_FAILED (0x03)
  1569. #define MPI2_PHYSDISK0_OFFLINE_INITIALIZING (0x04)
  1570. #define MPI2_PHYSDISK0_OFFLINE_REQUESTED (0x05)
  1571. #define MPI2_PHYSDISK0_OFFLINE_FAILED_REQUESTED (0x06)
  1572. #define MPI2_PHYSDISK0_OFFLINE_OTHER (0xFF)
  1573. /*IncompatibleReason defines */
  1574. #define MPI2_PHYSDISK0_COMPATIBLE (0x00)
  1575. #define MPI2_PHYSDISK0_INCOMPATIBLE_PROTOCOL (0x01)
  1576. #define MPI2_PHYSDISK0_INCOMPATIBLE_BLOCKSIZE (0x02)
  1577. #define MPI2_PHYSDISK0_INCOMPATIBLE_MAX_LBA (0x03)
  1578. #define MPI2_PHYSDISK0_INCOMPATIBLE_SATA_EXTENDED_CMD (0x04)
  1579. #define MPI2_PHYSDISK0_INCOMPATIBLE_REMOVEABLE_MEDIA (0x05)
  1580. #define MPI2_PHYSDISK0_INCOMPATIBLE_MEDIA_TYPE (0x06)
  1581. #define MPI2_PHYSDISK0_INCOMPATIBLE_UNKNOWN (0xFF)
  1582. /*PhysDiskAttributes defines */
  1583. #define MPI2_PHYSDISK0_ATTRIB_MEDIA_MASK (0x0C)
  1584. #define MPI2_PHYSDISK0_ATTRIB_SOLID_STATE_DRIVE (0x08)
  1585. #define MPI2_PHYSDISK0_ATTRIB_HARD_DISK_DRIVE (0x04)
  1586. #define MPI2_PHYSDISK0_ATTRIB_PROTOCOL_MASK (0x03)
  1587. #define MPI2_PHYSDISK0_ATTRIB_SAS_PROTOCOL (0x02)
  1588. #define MPI2_PHYSDISK0_ATTRIB_SATA_PROTOCOL (0x01)
  1589. /*PhysDiskStatusFlags defines */
  1590. #define MPI2_PHYSDISK0_STATUS_FLAG_NOT_CERTIFIED (0x00000040)
  1591. #define MPI2_PHYSDISK0_STATUS_FLAG_OCE_TARGET (0x00000020)
  1592. #define MPI2_PHYSDISK0_STATUS_FLAG_WRITE_CACHE_ENABLED (0x00000010)
  1593. #define MPI2_PHYSDISK0_STATUS_FLAG_OPTIMAL_PREVIOUS (0x00000000)
  1594. #define MPI2_PHYSDISK0_STATUS_FLAG_NOT_OPTIMAL_PREVIOUS (0x00000008)
  1595. #define MPI2_PHYSDISK0_STATUS_FLAG_INACTIVE_VOLUME (0x00000004)
  1596. #define MPI2_PHYSDISK0_STATUS_FLAG_QUIESCED (0x00000002)
  1597. #define MPI2_PHYSDISK0_STATUS_FLAG_OUT_OF_SYNC (0x00000001)
  1598. /*RAID Physical Disk Page 1 */
  1599. /*
  1600. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  1601. *one and check the value returned for NumPhysDiskPaths at runtime.
  1602. */
  1603. #ifndef MPI2_RAID_PHYS_DISK1_PATH_MAX
  1604. #define MPI2_RAID_PHYS_DISK1_PATH_MAX (1)
  1605. #endif
  1606. typedef struct _MPI2_RAIDPHYSDISK1_PATH {
  1607. U16 DevHandle; /*0x00 */
  1608. U16 Reserved1; /*0x02 */
  1609. U64 WWID; /*0x04 */
  1610. U64 OwnerWWID; /*0x0C */
  1611. U8 OwnerIdentifier; /*0x14 */
  1612. U8 Reserved2; /*0x15 */
  1613. U16 Flags; /*0x16 */
  1614. } MPI2_RAIDPHYSDISK1_PATH, *PTR_MPI2_RAIDPHYSDISK1_PATH,
  1615. Mpi2RaidPhysDisk1Path_t,
  1616. *pMpi2RaidPhysDisk1Path_t;
  1617. /*RAID Physical Disk Page 1 Physical Disk Path Flags field defines */
  1618. #define MPI2_RAID_PHYSDISK1_FLAG_PRIMARY (0x0004)
  1619. #define MPI2_RAID_PHYSDISK1_FLAG_BROKEN (0x0002)
  1620. #define MPI2_RAID_PHYSDISK1_FLAG_INVALID (0x0001)
  1621. typedef struct _MPI2_CONFIG_PAGE_RD_PDISK_1 {
  1622. MPI2_CONFIG_PAGE_HEADER Header; /*0x00 */
  1623. U8 NumPhysDiskPaths; /*0x04 */
  1624. U8 PhysDiskNum; /*0x05 */
  1625. U16 Reserved1; /*0x06 */
  1626. U32 Reserved2; /*0x08 */
  1627. MPI2_RAIDPHYSDISK1_PATH
  1628. PhysicalDiskPath[MPI2_RAID_PHYS_DISK1_PATH_MAX];/*0x0C */
  1629. } MPI2_CONFIG_PAGE_RD_PDISK_1,
  1630. *PTR_MPI2_CONFIG_PAGE_RD_PDISK_1,
  1631. Mpi2RaidPhysDiskPage1_t,
  1632. *pMpi2RaidPhysDiskPage1_t;
  1633. #define MPI2_RAIDPHYSDISKPAGE1_PAGEVERSION (0x02)
  1634. /****************************************************************************
  1635. * values for fields used by several types of SAS Config Pages
  1636. ****************************************************************************/
  1637. /*values for NegotiatedLinkRates fields */
  1638. #define MPI2_SAS_NEG_LINK_RATE_MASK_LOGICAL (0xF0)
  1639. #define MPI2_SAS_NEG_LINK_RATE_SHIFT_LOGICAL (4)
  1640. #define MPI2_SAS_NEG_LINK_RATE_MASK_PHYSICAL (0x0F)
  1641. /*link rates used for Negotiated Physical and Logical Link Rate */
  1642. #define MPI2_SAS_NEG_LINK_RATE_UNKNOWN_LINK_RATE (0x00)
  1643. #define MPI2_SAS_NEG_LINK_RATE_PHY_DISABLED (0x01)
  1644. #define MPI2_SAS_NEG_LINK_RATE_NEGOTIATION_FAILED (0x02)
  1645. #define MPI2_SAS_NEG_LINK_RATE_SATA_OOB_COMPLETE (0x03)
  1646. #define MPI2_SAS_NEG_LINK_RATE_PORT_SELECTOR (0x04)
  1647. #define MPI2_SAS_NEG_LINK_RATE_SMP_RESET_IN_PROGRESS (0x05)
  1648. #define MPI2_SAS_NEG_LINK_RATE_UNSUPPORTED_PHY (0x06)
  1649. #define MPI2_SAS_NEG_LINK_RATE_1_5 (0x08)
  1650. #define MPI2_SAS_NEG_LINK_RATE_3_0 (0x09)
  1651. #define MPI2_SAS_NEG_LINK_RATE_6_0 (0x0A)
  1652. #define MPI25_SAS_NEG_LINK_RATE_12_0 (0x0B)
  1653. /*values for AttachedPhyInfo fields */
  1654. #define MPI2_SAS_APHYINFO_INSIDE_ZPSDS_PERSISTENT (0x00000040)
  1655. #define MPI2_SAS_APHYINFO_REQUESTED_INSIDE_ZPSDS (0x00000020)
  1656. #define MPI2_SAS_APHYINFO_BREAK_REPLY_CAPABLE (0x00000010)
  1657. #define MPI2_SAS_APHYINFO_REASON_MASK (0x0000000F)
  1658. #define MPI2_SAS_APHYINFO_REASON_UNKNOWN (0x00000000)
  1659. #define MPI2_SAS_APHYINFO_REASON_POWER_ON (0x00000001)
  1660. #define MPI2_SAS_APHYINFO_REASON_HARD_RESET (0x00000002)
  1661. #define MPI2_SAS_APHYINFO_REASON_SMP_PHY_CONTROL (0x00000003)
  1662. #define MPI2_SAS_APHYINFO_REASON_LOSS_OF_SYNC (0x00000004)
  1663. #define MPI2_SAS_APHYINFO_REASON_MULTIPLEXING_SEQ (0x00000005)
  1664. #define MPI2_SAS_APHYINFO_REASON_IT_NEXUS_LOSS_TIMER (0x00000006)
  1665. #define MPI2_SAS_APHYINFO_REASON_BREAK_TIMEOUT (0x00000007)
  1666. #define MPI2_SAS_APHYINFO_REASON_PHY_TEST_STOPPED (0x00000008)
  1667. /*values for PhyInfo fields */
  1668. #define MPI2_SAS_PHYINFO_PHY_VACANT (0x80000000)
  1669. #define MPI2_SAS_PHYINFO_PHY_POWER_CONDITION_MASK (0x18000000)
  1670. #define MPI2_SAS_PHYINFO_SHIFT_PHY_POWER_CONDITION (27)
  1671. #define MPI2_SAS_PHYINFO_PHY_POWER_ACTIVE (0x00000000)
  1672. #define MPI2_SAS_PHYINFO_PHY_POWER_PARTIAL (0x08000000)
  1673. #define MPI2_SAS_PHYINFO_PHY_POWER_SLUMBER (0x10000000)
  1674. #define MPI2_SAS_PHYINFO_CHANGED_REQ_INSIDE_ZPSDS (0x04000000)
  1675. #define MPI2_SAS_PHYINFO_INSIDE_ZPSDS_PERSISTENT (0x02000000)
  1676. #define MPI2_SAS_PHYINFO_REQ_INSIDE_ZPSDS (0x01000000)
  1677. #define MPI2_SAS_PHYINFO_ZONE_GROUP_PERSISTENT (0x00400000)
  1678. #define MPI2_SAS_PHYINFO_INSIDE_ZPSDS (0x00200000)
  1679. #define MPI2_SAS_PHYINFO_ZONING_ENABLED (0x00100000)
  1680. #define MPI2_SAS_PHYINFO_REASON_MASK (0x000F0000)
  1681. #define MPI2_SAS_PHYINFO_REASON_UNKNOWN (0x00000000)
  1682. #define MPI2_SAS_PHYINFO_REASON_POWER_ON (0x00010000)
  1683. #define MPI2_SAS_PHYINFO_REASON_HARD_RESET (0x00020000)
  1684. #define MPI2_SAS_PHYINFO_REASON_SMP_PHY_CONTROL (0x00030000)
  1685. #define MPI2_SAS_PHYINFO_REASON_LOSS_OF_SYNC (0x00040000)
  1686. #define MPI2_SAS_PHYINFO_REASON_MULTIPLEXING_SEQ (0x00050000)
  1687. #define MPI2_SAS_PHYINFO_REASON_IT_NEXUS_LOSS_TIMER (0x00060000)
  1688. #define MPI2_SAS_PHYINFO_REASON_BREAK_TIMEOUT (0x00070000)
  1689. #define MPI2_SAS_PHYINFO_REASON_PHY_TEST_STOPPED (0x00080000)
  1690. #define MPI2_SAS_PHYINFO_MULTIPLEXING_SUPPORTED (0x00008000)
  1691. #define MPI2_SAS_PHYINFO_SATA_PORT_ACTIVE (0x00004000)
  1692. #define MPI2_SAS_PHYINFO_SATA_PORT_SELECTOR_PRESENT (0x00002000)
  1693. #define MPI2_SAS_PHYINFO_VIRTUAL_PHY (0x00001000)
  1694. #define MPI2_SAS_PHYINFO_MASK_PARTIAL_PATHWAY_TIME (0x00000F00)
  1695. #define MPI2_SAS_PHYINFO_SHIFT_PARTIAL_PATHWAY_TIME (8)
  1696. #define MPI2_SAS_PHYINFO_MASK_ROUTING_ATTRIBUTE (0x000000F0)
  1697. #define MPI2_SAS_PHYINFO_DIRECT_ROUTING (0x00000000)
  1698. #define MPI2_SAS_PHYINFO_SUBTRACTIVE_ROUTING (0x00000010)
  1699. #define MPI2_SAS_PHYINFO_TABLE_ROUTING (0x00000020)
  1700. /*values for SAS ProgrammedLinkRate fields */
  1701. #define MPI2_SAS_PRATE_MAX_RATE_MASK (0xF0)
  1702. #define MPI2_SAS_PRATE_MAX_RATE_NOT_PROGRAMMABLE (0x00)
  1703. #define MPI2_SAS_PRATE_MAX_RATE_1_5 (0x80)
  1704. #define MPI2_SAS_PRATE_MAX_RATE_3_0 (0x90)
  1705. #define MPI2_SAS_PRATE_MAX_RATE_6_0 (0xA0)
  1706. #define MPI25_SAS_PRATE_MAX_RATE_12_0 (0xB0)
  1707. #define MPI2_SAS_PRATE_MIN_RATE_MASK (0x0F)
  1708. #define MPI2_SAS_PRATE_MIN_RATE_NOT_PROGRAMMABLE (0x00)
  1709. #define MPI2_SAS_PRATE_MIN_RATE_1_5 (0x08)
  1710. #define MPI2_SAS_PRATE_MIN_RATE_3_0 (0x09)
  1711. #define MPI2_SAS_PRATE_MIN_RATE_6_0 (0x0A)
  1712. #define MPI25_SAS_PRATE_MIN_RATE_12_0 (0x0B)
  1713. /*values for SAS HwLinkRate fields */
  1714. #define MPI2_SAS_HWRATE_MAX_RATE_MASK (0xF0)
  1715. #define MPI2_SAS_HWRATE_MAX_RATE_1_5 (0x80)
  1716. #define MPI2_SAS_HWRATE_MAX_RATE_3_0 (0x90)
  1717. #define MPI2_SAS_HWRATE_MAX_RATE_6_0 (0xA0)
  1718. #define MPI25_SAS_HWRATE_MAX_RATE_12_0 (0xB0)
  1719. #define MPI2_SAS_HWRATE_MIN_RATE_MASK (0x0F)
  1720. #define MPI2_SAS_HWRATE_MIN_RATE_1_5 (0x08)
  1721. #define MPI2_SAS_HWRATE_MIN_RATE_3_0 (0x09)
  1722. #define MPI2_SAS_HWRATE_MIN_RATE_6_0 (0x0A)
  1723. #define MPI25_SAS_HWRATE_MIN_RATE_12_0 (0x0B)
  1724. /****************************************************************************
  1725. * SAS IO Unit Config Pages
  1726. ****************************************************************************/
  1727. /*SAS IO Unit Page 0 */
  1728. typedef struct _MPI2_SAS_IO_UNIT0_PHY_DATA {
  1729. U8 Port; /*0x00 */
  1730. U8 PortFlags; /*0x01 */
  1731. U8 PhyFlags; /*0x02 */
  1732. U8 NegotiatedLinkRate; /*0x03 */
  1733. U32 ControllerPhyDeviceInfo;/*0x04 */
  1734. U16 AttachedDevHandle; /*0x08 */
  1735. U16 ControllerDevHandle; /*0x0A */
  1736. U32 DiscoveryStatus; /*0x0C */
  1737. U32 Reserved; /*0x10 */
  1738. } MPI2_SAS_IO_UNIT0_PHY_DATA,
  1739. *PTR_MPI2_SAS_IO_UNIT0_PHY_DATA,
  1740. Mpi2SasIOUnit0PhyData_t,
  1741. *pMpi2SasIOUnit0PhyData_t;
  1742. /*
  1743. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  1744. *one and check the value returned for NumPhys at runtime.
  1745. */
  1746. #ifndef MPI2_SAS_IOUNIT0_PHY_MAX
  1747. #define MPI2_SAS_IOUNIT0_PHY_MAX (1)
  1748. #endif
  1749. typedef struct _MPI2_CONFIG_PAGE_SASIOUNIT_0 {
  1750. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  1751. U32 Reserved1;/*0x08 */
  1752. U8 NumPhys; /*0x0C */
  1753. U8 Reserved2;/*0x0D */
  1754. U16 Reserved3;/*0x0E */
  1755. MPI2_SAS_IO_UNIT0_PHY_DATA
  1756. PhyData[MPI2_SAS_IOUNIT0_PHY_MAX]; /*0x10 */
  1757. } MPI2_CONFIG_PAGE_SASIOUNIT_0,
  1758. *PTR_MPI2_CONFIG_PAGE_SASIOUNIT_0,
  1759. Mpi2SasIOUnitPage0_t, *pMpi2SasIOUnitPage0_t;
  1760. #define MPI2_SASIOUNITPAGE0_PAGEVERSION (0x05)
  1761. /*values for SAS IO Unit Page 0 PortFlags */
  1762. #define MPI2_SASIOUNIT0_PORTFLAGS_DISCOVERY_IN_PROGRESS (0x08)
  1763. #define MPI2_SASIOUNIT0_PORTFLAGS_AUTO_PORT_CONFIG (0x01)
  1764. /*values for SAS IO Unit Page 0 PhyFlags */
  1765. #define MPI2_SASIOUNIT0_PHYFLAGS_INIT_PERSIST_CONNECT (0x40)
  1766. #define MPI2_SASIOUNIT0_PHYFLAGS_TARG_PERSIST_CONNECT (0x20)
  1767. #define MPI2_SASIOUNIT0_PHYFLAGS_ZONING_ENABLED (0x10)
  1768. #define MPI2_SASIOUNIT0_PHYFLAGS_PHY_DISABLED (0x08)
  1769. /*use MPI2_SAS_NEG_LINK_RATE_ defines for the NegotiatedLinkRate field */
  1770. /*see mpi2_sas.h for values for
  1771. *SAS IO Unit Page 0 ControllerPhyDeviceInfo values */
  1772. /*values for SAS IO Unit Page 0 DiscoveryStatus */
  1773. #define MPI2_SASIOUNIT0_DS_MAX_ENCLOSURES_EXCEED (0x80000000)
  1774. #define MPI2_SASIOUNIT0_DS_MAX_EXPANDERS_EXCEED (0x40000000)
  1775. #define MPI2_SASIOUNIT0_DS_MAX_DEVICES_EXCEED (0x20000000)
  1776. #define MPI2_SASIOUNIT0_DS_MAX_TOPO_PHYS_EXCEED (0x10000000)
  1777. #define MPI2_SASIOUNIT0_DS_DOWNSTREAM_INITIATOR (0x08000000)
  1778. #define MPI2_SASIOUNIT0_DS_MULTI_SUBTRACTIVE_SUBTRACTIVE (0x00008000)
  1779. #define MPI2_SASIOUNIT0_DS_EXP_MULTI_SUBTRACTIVE (0x00004000)
  1780. #define MPI2_SASIOUNIT0_DS_MULTI_PORT_DOMAIN (0x00002000)
  1781. #define MPI2_SASIOUNIT0_DS_TABLE_TO_SUBTRACTIVE_LINK (0x00001000)
  1782. #define MPI2_SASIOUNIT0_DS_UNSUPPORTED_DEVICE (0x00000800)
  1783. #define MPI2_SASIOUNIT0_DS_TABLE_LINK (0x00000400)
  1784. #define MPI2_SASIOUNIT0_DS_SUBTRACTIVE_LINK (0x00000200)
  1785. #define MPI2_SASIOUNIT0_DS_SMP_CRC_ERROR (0x00000100)
  1786. #define MPI2_SASIOUNIT0_DS_SMP_FUNCTION_FAILED (0x00000080)
  1787. #define MPI2_SASIOUNIT0_DS_INDEX_NOT_EXIST (0x00000040)
  1788. #define MPI2_SASIOUNIT0_DS_OUT_ROUTE_ENTRIES (0x00000020)
  1789. #define MPI2_SASIOUNIT0_DS_SMP_TIMEOUT (0x00000010)
  1790. #define MPI2_SASIOUNIT0_DS_MULTIPLE_PORTS (0x00000004)
  1791. #define MPI2_SASIOUNIT0_DS_UNADDRESSABLE_DEVICE (0x00000002)
  1792. #define MPI2_SASIOUNIT0_DS_LOOP_DETECTED (0x00000001)
  1793. /*SAS IO Unit Page 1 */
  1794. typedef struct _MPI2_SAS_IO_UNIT1_PHY_DATA {
  1795. U8 Port; /*0x00 */
  1796. U8 PortFlags; /*0x01 */
  1797. U8 PhyFlags; /*0x02 */
  1798. U8 MaxMinLinkRate; /*0x03 */
  1799. U32 ControllerPhyDeviceInfo; /*0x04 */
  1800. U16 MaxTargetPortConnectTime; /*0x08 */
  1801. U16 Reserved1; /*0x0A */
  1802. } MPI2_SAS_IO_UNIT1_PHY_DATA,
  1803. *PTR_MPI2_SAS_IO_UNIT1_PHY_DATA,
  1804. Mpi2SasIOUnit1PhyData_t,
  1805. *pMpi2SasIOUnit1PhyData_t;
  1806. /*
  1807. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  1808. *one and check the value returned for NumPhys at runtime.
  1809. */
  1810. #ifndef MPI2_SAS_IOUNIT1_PHY_MAX
  1811. #define MPI2_SAS_IOUNIT1_PHY_MAX (1)
  1812. #endif
  1813. typedef struct _MPI2_CONFIG_PAGE_SASIOUNIT_1 {
  1814. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  1815. U16
  1816. ControlFlags; /*0x08 */
  1817. U16
  1818. SASNarrowMaxQueueDepth; /*0x0A */
  1819. U16
  1820. AdditionalControlFlags; /*0x0C */
  1821. U16
  1822. SASWideMaxQueueDepth; /*0x0E */
  1823. U8
  1824. NumPhys; /*0x10 */
  1825. U8
  1826. SATAMaxQDepth; /*0x11 */
  1827. U8
  1828. ReportDeviceMissingDelay; /*0x12 */
  1829. U8
  1830. IODeviceMissingDelay; /*0x13 */
  1831. MPI2_SAS_IO_UNIT1_PHY_DATA
  1832. PhyData[MPI2_SAS_IOUNIT1_PHY_MAX]; /*0x14 */
  1833. } MPI2_CONFIG_PAGE_SASIOUNIT_1,
  1834. *PTR_MPI2_CONFIG_PAGE_SASIOUNIT_1,
  1835. Mpi2SasIOUnitPage1_t, *pMpi2SasIOUnitPage1_t;
  1836. #define MPI2_SASIOUNITPAGE1_PAGEVERSION (0x09)
  1837. /*values for SAS IO Unit Page 1 ControlFlags */
  1838. #define MPI2_SASIOUNIT1_CONTROL_DEVICE_SELF_TEST (0x8000)
  1839. #define MPI2_SASIOUNIT1_CONTROL_SATA_3_0_MAX (0x4000)
  1840. #define MPI2_SASIOUNIT1_CONTROL_SATA_1_5_MAX (0x2000)
  1841. #define MPI2_SASIOUNIT1_CONTROL_SATA_SW_PRESERVE (0x1000)
  1842. #define MPI2_SASIOUNIT1_CONTROL_MASK_DEV_SUPPORT (0x0600)
  1843. #define MPI2_SASIOUNIT1_CONTROL_SHIFT_DEV_SUPPORT (9)
  1844. #define MPI2_SASIOUNIT1_CONTROL_DEV_SUPPORT_BOTH (0x0)
  1845. #define MPI2_SASIOUNIT1_CONTROL_DEV_SAS_SUPPORT (0x1)
  1846. #define MPI2_SASIOUNIT1_CONTROL_DEV_SATA_SUPPORT (0x2)
  1847. #define MPI2_SASIOUNIT1_CONTROL_SATA_48BIT_LBA_REQUIRED (0x0080)
  1848. #define MPI2_SASIOUNIT1_CONTROL_SATA_SMART_REQUIRED (0x0040)
  1849. #define MPI2_SASIOUNIT1_CONTROL_SATA_NCQ_REQUIRED (0x0020)
  1850. #define MPI2_SASIOUNIT1_CONTROL_SATA_FUA_REQUIRED (0x0010)
  1851. #define MPI2_SASIOUNIT1_CONTROL_TABLE_SUBTRACTIVE_ILLEGAL (0x0008)
  1852. #define MPI2_SASIOUNIT1_CONTROL_SUBTRACTIVE_ILLEGAL (0x0004)
  1853. #define MPI2_SASIOUNIT1_CONTROL_FIRST_LVL_DISC_ONLY (0x0002)
  1854. #define MPI2_SASIOUNIT1_CONTROL_CLEAR_AFFILIATION (0x0001)
  1855. /*values for SAS IO Unit Page 1 AdditionalControlFlags */
  1856. #define MPI2_SASIOUNIT1_ACONTROL_DA_PERSIST_CONNECT (0x0100)
  1857. #define MPI2_SASIOUNIT1_ACONTROL_MULTI_PORT_DOMAIN_ILLEGAL (0x0080)
  1858. #define MPI2_SASIOUNIT1_ACONTROL_SATA_ASYNCHROUNOUS_NOTIFICATION (0x0040)
  1859. #define MPI2_SASIOUNIT1_ACONTROL_INVALID_TOPOLOGY_CORRECTION (0x0020)
  1860. #define MPI2_SASIOUNIT1_ACONTROL_PORT_ENABLE_ONLY_SATA_LINK_RESET (0x0010)
  1861. #define MPI2_SASIOUNIT1_ACONTROL_OTHER_AFFILIATION_SATA_LINK_RESET (0x0008)
  1862. #define MPI2_SASIOUNIT1_ACONTROL_SELF_AFFILIATION_SATA_LINK_RESET (0x0004)
  1863. #define MPI2_SASIOUNIT1_ACONTROL_NO_AFFILIATION_SATA_LINK_RESET (0x0002)
  1864. #define MPI2_SASIOUNIT1_ACONTROL_ALLOW_TABLE_TO_TABLE (0x0001)
  1865. /*defines for SAS IO Unit Page 1 ReportDeviceMissingDelay */
  1866. #define MPI2_SASIOUNIT1_REPORT_MISSING_TIMEOUT_MASK (0x7F)
  1867. #define MPI2_SASIOUNIT1_REPORT_MISSING_UNIT_16 (0x80)
  1868. /*values for SAS IO Unit Page 1 PortFlags */
  1869. #define MPI2_SASIOUNIT1_PORT_FLAGS_AUTO_PORT_CONFIG (0x01)
  1870. /*values for SAS IO Unit Page 1 PhyFlags */
  1871. #define MPI2_SASIOUNIT1_PHYFLAGS_INIT_PERSIST_CONNECT (0x40)
  1872. #define MPI2_SASIOUNIT1_PHYFLAGS_TARG_PERSIST_CONNECT (0x20)
  1873. #define MPI2_SASIOUNIT1_PHYFLAGS_ZONING_ENABLE (0x10)
  1874. #define MPI2_SASIOUNIT1_PHYFLAGS_PHY_DISABLE (0x08)
  1875. /*values for SAS IO Unit Page 1 MaxMinLinkRate */
  1876. #define MPI2_SASIOUNIT1_MAX_RATE_MASK (0xF0)
  1877. #define MPI2_SASIOUNIT1_MAX_RATE_1_5 (0x80)
  1878. #define MPI2_SASIOUNIT1_MAX_RATE_3_0 (0x90)
  1879. #define MPI2_SASIOUNIT1_MAX_RATE_6_0 (0xA0)
  1880. #define MPI25_SASIOUNIT1_MAX_RATE_12_0 (0xB0)
  1881. #define MPI2_SASIOUNIT1_MIN_RATE_MASK (0x0F)
  1882. #define MPI2_SASIOUNIT1_MIN_RATE_1_5 (0x08)
  1883. #define MPI2_SASIOUNIT1_MIN_RATE_3_0 (0x09)
  1884. #define MPI2_SASIOUNIT1_MIN_RATE_6_0 (0x0A)
  1885. #define MPI25_SASIOUNIT1_MIN_RATE_12_0 (0x0B)
  1886. /*see mpi2_sas.h for values for
  1887. *SAS IO Unit Page 1 ControllerPhyDeviceInfo values */
  1888. /*SAS IO Unit Page 4 (for MPI v2.5 and earlier) */
  1889. typedef struct _MPI2_SAS_IOUNIT4_SPINUP_GROUP {
  1890. U8 MaxTargetSpinup; /*0x00 */
  1891. U8 SpinupDelay; /*0x01 */
  1892. U8 SpinupFlags; /*0x02 */
  1893. U8 Reserved1; /*0x03 */
  1894. } MPI2_SAS_IOUNIT4_SPINUP_GROUP,
  1895. *PTR_MPI2_SAS_IOUNIT4_SPINUP_GROUP,
  1896. Mpi2SasIOUnit4SpinupGroup_t,
  1897. *pMpi2SasIOUnit4SpinupGroup_t;
  1898. /*defines for SAS IO Unit Page 4 SpinupFlags */
  1899. #define MPI2_SASIOUNIT4_SPINUP_DISABLE_FLAG (0x01)
  1900. /*
  1901. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  1902. *one and check the value returned for NumPhys at runtime.
  1903. */
  1904. #ifndef MPI2_SAS_IOUNIT4_PHY_MAX
  1905. #define MPI2_SAS_IOUNIT4_PHY_MAX (4)
  1906. #endif
  1907. typedef struct _MPI2_CONFIG_PAGE_SASIOUNIT_4 {
  1908. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header;/*0x00 */
  1909. MPI2_SAS_IOUNIT4_SPINUP_GROUP
  1910. SpinupGroupParameters[4]; /*0x08 */
  1911. U32
  1912. Reserved1; /*0x18 */
  1913. U32
  1914. Reserved2; /*0x1C */
  1915. U32
  1916. Reserved3; /*0x20 */
  1917. U8
  1918. BootDeviceWaitTime; /*0x24 */
  1919. U8
  1920. SATADeviceWaitTime; /*0x25 */
  1921. U16
  1922. Reserved5; /*0x26 */
  1923. U8
  1924. NumPhys; /*0x28 */
  1925. U8
  1926. PEInitialSpinupDelay; /*0x29 */
  1927. U8
  1928. PEReplyDelay; /*0x2A */
  1929. U8
  1930. Flags; /*0x2B */
  1931. U8
  1932. PHY[MPI2_SAS_IOUNIT4_PHY_MAX]; /*0x2C */
  1933. } MPI2_CONFIG_PAGE_SASIOUNIT_4,
  1934. *PTR_MPI2_CONFIG_PAGE_SASIOUNIT_4,
  1935. Mpi2SasIOUnitPage4_t, *pMpi2SasIOUnitPage4_t;
  1936. #define MPI2_SASIOUNITPAGE4_PAGEVERSION (0x02)
  1937. /*defines for Flags field */
  1938. #define MPI2_SASIOUNIT4_FLAGS_AUTO_PORTENABLE (0x01)
  1939. /*defines for PHY field */
  1940. #define MPI2_SASIOUNIT4_PHY_SPINUP_GROUP_MASK (0x03)
  1941. /*SAS IO Unit Page 5 */
  1942. typedef struct _MPI2_SAS_IO_UNIT5_PHY_PM_SETTINGS {
  1943. U8 ControlFlags; /*0x00 */
  1944. U8 PortWidthModGroup; /*0x01 */
  1945. U16 InactivityTimerExponent; /*0x02 */
  1946. U8 SATAPartialTimeout; /*0x04 */
  1947. U8 Reserved2; /*0x05 */
  1948. U8 SATASlumberTimeout; /*0x06 */
  1949. U8 Reserved3; /*0x07 */
  1950. U8 SASPartialTimeout; /*0x08 */
  1951. U8 Reserved4; /*0x09 */
  1952. U8 SASSlumberTimeout; /*0x0A */
  1953. U8 Reserved5; /*0x0B */
  1954. } MPI2_SAS_IO_UNIT5_PHY_PM_SETTINGS,
  1955. *PTR_MPI2_SAS_IO_UNIT5_PHY_PM_SETTINGS,
  1956. Mpi2SasIOUnit5PhyPmSettings_t,
  1957. *pMpi2SasIOUnit5PhyPmSettings_t;
  1958. /*defines for ControlFlags field */
  1959. #define MPI2_SASIOUNIT5_CONTROL_SAS_SLUMBER_ENABLE (0x08)
  1960. #define MPI2_SASIOUNIT5_CONTROL_SAS_PARTIAL_ENABLE (0x04)
  1961. #define MPI2_SASIOUNIT5_CONTROL_SATA_SLUMBER_ENABLE (0x02)
  1962. #define MPI2_SASIOUNIT5_CONTROL_SATA_PARTIAL_ENABLE (0x01)
  1963. /*defines for PortWidthModeGroup field */
  1964. #define MPI2_SASIOUNIT5_PWMG_DISABLE (0xFF)
  1965. /*defines for InactivityTimerExponent field */
  1966. #define MPI2_SASIOUNIT5_ITE_MASK_SAS_SLUMBER (0x7000)
  1967. #define MPI2_SASIOUNIT5_ITE_SHIFT_SAS_SLUMBER (12)
  1968. #define MPI2_SASIOUNIT5_ITE_MASK_SAS_PARTIAL (0x0700)
  1969. #define MPI2_SASIOUNIT5_ITE_SHIFT_SAS_PARTIAL (8)
  1970. #define MPI2_SASIOUNIT5_ITE_MASK_SATA_SLUMBER (0x0070)
  1971. #define MPI2_SASIOUNIT5_ITE_SHIFT_SATA_SLUMBER (4)
  1972. #define MPI2_SASIOUNIT5_ITE_MASK_SATA_PARTIAL (0x0007)
  1973. #define MPI2_SASIOUNIT5_ITE_SHIFT_SATA_PARTIAL (0)
  1974. #define MPI2_SASIOUNIT5_ITE_TEN_SECONDS (7)
  1975. #define MPI2_SASIOUNIT5_ITE_ONE_SECOND (6)
  1976. #define MPI2_SASIOUNIT5_ITE_HUNDRED_MILLISECONDS (5)
  1977. #define MPI2_SASIOUNIT5_ITE_TEN_MILLISECONDS (4)
  1978. #define MPI2_SASIOUNIT5_ITE_ONE_MILLISECOND (3)
  1979. #define MPI2_SASIOUNIT5_ITE_HUNDRED_MICROSECONDS (2)
  1980. #define MPI2_SASIOUNIT5_ITE_TEN_MICROSECONDS (1)
  1981. #define MPI2_SASIOUNIT5_ITE_ONE_MICROSECOND (0)
  1982. /*
  1983. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  1984. *one and check the value returned for NumPhys at runtime.
  1985. */
  1986. #ifndef MPI2_SAS_IOUNIT5_PHY_MAX
  1987. #define MPI2_SAS_IOUNIT5_PHY_MAX (1)
  1988. #endif
  1989. typedef struct _MPI2_CONFIG_PAGE_SASIOUNIT_5 {
  1990. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  1991. U8 NumPhys; /*0x08 */
  1992. U8 Reserved1;/*0x09 */
  1993. U16 Reserved2;/*0x0A */
  1994. U32 Reserved3;/*0x0C */
  1995. MPI2_SAS_IO_UNIT5_PHY_PM_SETTINGS
  1996. SASPhyPowerManagementSettings[MPI2_SAS_IOUNIT5_PHY_MAX];/*0x10 */
  1997. } MPI2_CONFIG_PAGE_SASIOUNIT_5,
  1998. *PTR_MPI2_CONFIG_PAGE_SASIOUNIT_5,
  1999. Mpi2SasIOUnitPage5_t, *pMpi2SasIOUnitPage5_t;
  2000. #define MPI2_SASIOUNITPAGE5_PAGEVERSION (0x01)
  2001. /*SAS IO Unit Page 6 */
  2002. typedef struct _MPI2_SAS_IO_UNIT6_PORT_WIDTH_MOD_GROUP_STATUS {
  2003. U8 CurrentStatus; /*0x00 */
  2004. U8 CurrentModulation; /*0x01 */
  2005. U8 CurrentUtilization; /*0x02 */
  2006. U8 Reserved1; /*0x03 */
  2007. U32 Reserved2; /*0x04 */
  2008. } MPI2_SAS_IO_UNIT6_PORT_WIDTH_MOD_GROUP_STATUS,
  2009. *PTR_MPI2_SAS_IO_UNIT6_PORT_WIDTH_MOD_GROUP_STATUS,
  2010. Mpi2SasIOUnit6PortWidthModGroupStatus_t,
  2011. *pMpi2SasIOUnit6PortWidthModGroupStatus_t;
  2012. /*defines for CurrentStatus field */
  2013. #define MPI2_SASIOUNIT6_STATUS_UNAVAILABLE (0x00)
  2014. #define MPI2_SASIOUNIT6_STATUS_UNCONFIGURED (0x01)
  2015. #define MPI2_SASIOUNIT6_STATUS_INVALID_CONFIG (0x02)
  2016. #define MPI2_SASIOUNIT6_STATUS_LINK_DOWN (0x03)
  2017. #define MPI2_SASIOUNIT6_STATUS_OBSERVATION_ONLY (0x04)
  2018. #define MPI2_SASIOUNIT6_STATUS_INACTIVE (0x05)
  2019. #define MPI2_SASIOUNIT6_STATUS_ACTIVE_IOUNIT (0x06)
  2020. #define MPI2_SASIOUNIT6_STATUS_ACTIVE_HOST (0x07)
  2021. /*defines for CurrentModulation field */
  2022. #define MPI2_SASIOUNIT6_MODULATION_25_PERCENT (0x00)
  2023. #define MPI2_SASIOUNIT6_MODULATION_50_PERCENT (0x01)
  2024. #define MPI2_SASIOUNIT6_MODULATION_75_PERCENT (0x02)
  2025. #define MPI2_SASIOUNIT6_MODULATION_100_PERCENT (0x03)
  2026. /*
  2027. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  2028. *one and check the value returned for NumGroups at runtime.
  2029. */
  2030. #ifndef MPI2_SAS_IOUNIT6_GROUP_MAX
  2031. #define MPI2_SAS_IOUNIT6_GROUP_MAX (1)
  2032. #endif
  2033. typedef struct _MPI2_CONFIG_PAGE_SASIOUNIT_6 {
  2034. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  2035. U32 Reserved1; /*0x08 */
  2036. U32 Reserved2; /*0x0C */
  2037. U8 NumGroups; /*0x10 */
  2038. U8 Reserved3; /*0x11 */
  2039. U16 Reserved4; /*0x12 */
  2040. MPI2_SAS_IO_UNIT6_PORT_WIDTH_MOD_GROUP_STATUS
  2041. PortWidthModulationGroupStatus[MPI2_SAS_IOUNIT6_GROUP_MAX]; /*0x14 */
  2042. } MPI2_CONFIG_PAGE_SASIOUNIT_6,
  2043. *PTR_MPI2_CONFIG_PAGE_SASIOUNIT_6,
  2044. Mpi2SasIOUnitPage6_t, *pMpi2SasIOUnitPage6_t;
  2045. #define MPI2_SASIOUNITPAGE6_PAGEVERSION (0x00)
  2046. /*SAS IO Unit Page 7 */
  2047. typedef struct _MPI2_SAS_IO_UNIT7_PORT_WIDTH_MOD_GROUP_SETTINGS {
  2048. U8 Flags; /*0x00 */
  2049. U8 Reserved1; /*0x01 */
  2050. U16 Reserved2; /*0x02 */
  2051. U8 Threshold75Pct; /*0x04 */
  2052. U8 Threshold50Pct; /*0x05 */
  2053. U8 Threshold25Pct; /*0x06 */
  2054. U8 Reserved3; /*0x07 */
  2055. } MPI2_SAS_IO_UNIT7_PORT_WIDTH_MOD_GROUP_SETTINGS,
  2056. *PTR_MPI2_SAS_IO_UNIT7_PORT_WIDTH_MOD_GROUP_SETTINGS,
  2057. Mpi2SasIOUnit7PortWidthModGroupSettings_t,
  2058. *pMpi2SasIOUnit7PortWidthModGroupSettings_t;
  2059. /*defines for Flags field */
  2060. #define MPI2_SASIOUNIT7_FLAGS_ENABLE_PORT_WIDTH_MODULATION (0x01)
  2061. /*
  2062. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  2063. *one and check the value returned for NumGroups at runtime.
  2064. */
  2065. #ifndef MPI2_SAS_IOUNIT7_GROUP_MAX
  2066. #define MPI2_SAS_IOUNIT7_GROUP_MAX (1)
  2067. #endif
  2068. typedef struct _MPI2_CONFIG_PAGE_SASIOUNIT_7 {
  2069. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  2070. U8 SamplingInterval; /*0x08 */
  2071. U8 WindowLength; /*0x09 */
  2072. U16 Reserved1; /*0x0A */
  2073. U32 Reserved2; /*0x0C */
  2074. U32 Reserved3; /*0x10 */
  2075. U8 NumGroups; /*0x14 */
  2076. U8 Reserved4; /*0x15 */
  2077. U16 Reserved5; /*0x16 */
  2078. MPI2_SAS_IO_UNIT7_PORT_WIDTH_MOD_GROUP_SETTINGS
  2079. PortWidthModulationGroupSettings[MPI2_SAS_IOUNIT7_GROUP_MAX];/*0x18 */
  2080. } MPI2_CONFIG_PAGE_SASIOUNIT_7,
  2081. *PTR_MPI2_CONFIG_PAGE_SASIOUNIT_7,
  2082. Mpi2SasIOUnitPage7_t, *pMpi2SasIOUnitPage7_t;
  2083. #define MPI2_SASIOUNITPAGE7_PAGEVERSION (0x00)
  2084. /*SAS IO Unit Page 8 */
  2085. typedef struct _MPI2_CONFIG_PAGE_SASIOUNIT_8 {
  2086. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2087. Header; /*0x00 */
  2088. U32
  2089. Reserved1; /*0x08 */
  2090. U32
  2091. PowerManagementCapabilities; /*0x0C */
  2092. U8
  2093. TxRxSleepStatus; /*0x10 */
  2094. U8
  2095. Reserved2; /*0x11 */
  2096. U16
  2097. Reserved3; /*0x12 */
  2098. } MPI2_CONFIG_PAGE_SASIOUNIT_8,
  2099. *PTR_MPI2_CONFIG_PAGE_SASIOUNIT_8,
  2100. Mpi2SasIOUnitPage8_t, *pMpi2SasIOUnitPage8_t;
  2101. #define MPI2_SASIOUNITPAGE8_PAGEVERSION (0x00)
  2102. /*defines for PowerManagementCapabilities field */
  2103. #define MPI2_SASIOUNIT8_PM_HOST_PORT_WIDTH_MOD (0x00001000)
  2104. #define MPI2_SASIOUNIT8_PM_HOST_SAS_SLUMBER_MODE (0x00000800)
  2105. #define MPI2_SASIOUNIT8_PM_HOST_SAS_PARTIAL_MODE (0x00000400)
  2106. #define MPI2_SASIOUNIT8_PM_HOST_SATA_SLUMBER_MODE (0x00000200)
  2107. #define MPI2_SASIOUNIT8_PM_HOST_SATA_PARTIAL_MODE (0x00000100)
  2108. #define MPI2_SASIOUNIT8_PM_IOUNIT_PORT_WIDTH_MOD (0x00000010)
  2109. #define MPI2_SASIOUNIT8_PM_IOUNIT_SAS_SLUMBER_MODE (0x00000008)
  2110. #define MPI2_SASIOUNIT8_PM_IOUNIT_SAS_PARTIAL_MODE (0x00000004)
  2111. #define MPI2_SASIOUNIT8_PM_IOUNIT_SATA_SLUMBER_MODE (0x00000002)
  2112. #define MPI2_SASIOUNIT8_PM_IOUNIT_SATA_PARTIAL_MODE (0x00000001)
  2113. /*defines for TxRxSleepStatus field */
  2114. #define MPI25_SASIOUNIT8_TXRXSLEEP_UNSUPPORTED (0x00)
  2115. #define MPI25_SASIOUNIT8_TXRXSLEEP_DISENGAGED (0x01)
  2116. #define MPI25_SASIOUNIT8_TXRXSLEEP_ACTIVE (0x02)
  2117. #define MPI25_SASIOUNIT8_TXRXSLEEP_SHUTDOWN (0x03)
  2118. /*SAS IO Unit Page 16 */
  2119. typedef struct _MPI2_CONFIG_PAGE_SASIOUNIT16 {
  2120. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2121. Header; /*0x00 */
  2122. U64
  2123. TimeStamp; /*0x08 */
  2124. U32
  2125. Reserved1; /*0x10 */
  2126. U32
  2127. Reserved2; /*0x14 */
  2128. U32
  2129. FastPathPendedRequests; /*0x18 */
  2130. U32
  2131. FastPathUnPendedRequests; /*0x1C */
  2132. U32
  2133. FastPathHostRequestStarts; /*0x20 */
  2134. U32
  2135. FastPathFirmwareRequestStarts; /*0x24 */
  2136. U32
  2137. FastPathHostCompletions; /*0x28 */
  2138. U32
  2139. FastPathFirmwareCompletions; /*0x2C */
  2140. U32
  2141. NonFastPathRequestStarts; /*0x30 */
  2142. U32
  2143. NonFastPathHostCompletions; /*0x30 */
  2144. } MPI2_CONFIG_PAGE_SASIOUNIT16,
  2145. *PTR_MPI2_CONFIG_PAGE_SASIOUNIT16,
  2146. Mpi2SasIOUnitPage16_t, *pMpi2SasIOUnitPage16_t;
  2147. #define MPI2_SASIOUNITPAGE16_PAGEVERSION (0x00)
  2148. /****************************************************************************
  2149. * SAS Expander Config Pages
  2150. ****************************************************************************/
  2151. /*SAS Expander Page 0 */
  2152. typedef struct _MPI2_CONFIG_PAGE_EXPANDER_0 {
  2153. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2154. Header; /*0x00 */
  2155. U8
  2156. PhysicalPort; /*0x08 */
  2157. U8
  2158. ReportGenLength; /*0x09 */
  2159. U16
  2160. EnclosureHandle; /*0x0A */
  2161. U64
  2162. SASAddress; /*0x0C */
  2163. U32
  2164. DiscoveryStatus; /*0x14 */
  2165. U16
  2166. DevHandle; /*0x18 */
  2167. U16
  2168. ParentDevHandle; /*0x1A */
  2169. U16
  2170. ExpanderChangeCount; /*0x1C */
  2171. U16
  2172. ExpanderRouteIndexes; /*0x1E */
  2173. U8
  2174. NumPhys; /*0x20 */
  2175. U8
  2176. SASLevel; /*0x21 */
  2177. U16
  2178. Flags; /*0x22 */
  2179. U16
  2180. STPBusInactivityTimeLimit; /*0x24 */
  2181. U16
  2182. STPMaxConnectTimeLimit; /*0x26 */
  2183. U16
  2184. STP_SMP_NexusLossTime; /*0x28 */
  2185. U16
  2186. MaxNumRoutedSasAddresses; /*0x2A */
  2187. U64
  2188. ActiveZoneManagerSASAddress;/*0x2C */
  2189. U16
  2190. ZoneLockInactivityLimit; /*0x34 */
  2191. U16
  2192. Reserved1; /*0x36 */
  2193. U8
  2194. TimeToReducedFunc; /*0x38 */
  2195. U8
  2196. InitialTimeToReducedFunc; /*0x39 */
  2197. U8
  2198. MaxReducedFuncTime; /*0x3A */
  2199. U8
  2200. Reserved2; /*0x3B */
  2201. } MPI2_CONFIG_PAGE_EXPANDER_0,
  2202. *PTR_MPI2_CONFIG_PAGE_EXPANDER_0,
  2203. Mpi2ExpanderPage0_t, *pMpi2ExpanderPage0_t;
  2204. #define MPI2_SASEXPANDER0_PAGEVERSION (0x06)
  2205. /*values for SAS Expander Page 0 DiscoveryStatus field */
  2206. #define MPI2_SAS_EXPANDER0_DS_MAX_ENCLOSURES_EXCEED (0x80000000)
  2207. #define MPI2_SAS_EXPANDER0_DS_MAX_EXPANDERS_EXCEED (0x40000000)
  2208. #define MPI2_SAS_EXPANDER0_DS_MAX_DEVICES_EXCEED (0x20000000)
  2209. #define MPI2_SAS_EXPANDER0_DS_MAX_TOPO_PHYS_EXCEED (0x10000000)
  2210. #define MPI2_SAS_EXPANDER0_DS_DOWNSTREAM_INITIATOR (0x08000000)
  2211. #define MPI2_SAS_EXPANDER0_DS_MULTI_SUBTRACTIVE_SUBTRACTIVE (0x00008000)
  2212. #define MPI2_SAS_EXPANDER0_DS_EXP_MULTI_SUBTRACTIVE (0x00004000)
  2213. #define MPI2_SAS_EXPANDER0_DS_MULTI_PORT_DOMAIN (0x00002000)
  2214. #define MPI2_SAS_EXPANDER0_DS_TABLE_TO_SUBTRACTIVE_LINK (0x00001000)
  2215. #define MPI2_SAS_EXPANDER0_DS_UNSUPPORTED_DEVICE (0x00000800)
  2216. #define MPI2_SAS_EXPANDER0_DS_TABLE_LINK (0x00000400)
  2217. #define MPI2_SAS_EXPANDER0_DS_SUBTRACTIVE_LINK (0x00000200)
  2218. #define MPI2_SAS_EXPANDER0_DS_SMP_CRC_ERROR (0x00000100)
  2219. #define MPI2_SAS_EXPANDER0_DS_SMP_FUNCTION_FAILED (0x00000080)
  2220. #define MPI2_SAS_EXPANDER0_DS_INDEX_NOT_EXIST (0x00000040)
  2221. #define MPI2_SAS_EXPANDER0_DS_OUT_ROUTE_ENTRIES (0x00000020)
  2222. #define MPI2_SAS_EXPANDER0_DS_SMP_TIMEOUT (0x00000010)
  2223. #define MPI2_SAS_EXPANDER0_DS_MULTIPLE_PORTS (0x00000004)
  2224. #define MPI2_SAS_EXPANDER0_DS_UNADDRESSABLE_DEVICE (0x00000002)
  2225. #define MPI2_SAS_EXPANDER0_DS_LOOP_DETECTED (0x00000001)
  2226. /*values for SAS Expander Page 0 Flags field */
  2227. #define MPI2_SAS_EXPANDER0_FLAGS_REDUCED_FUNCTIONALITY (0x2000)
  2228. #define MPI2_SAS_EXPANDER0_FLAGS_ZONE_LOCKED (0x1000)
  2229. #define MPI2_SAS_EXPANDER0_FLAGS_SUPPORTED_PHYSICAL_PRES (0x0800)
  2230. #define MPI2_SAS_EXPANDER0_FLAGS_ASSERTED_PHYSICAL_PRES (0x0400)
  2231. #define MPI2_SAS_EXPANDER0_FLAGS_ZONING_SUPPORT (0x0200)
  2232. #define MPI2_SAS_EXPANDER0_FLAGS_ENABLED_ZONING (0x0100)
  2233. #define MPI2_SAS_EXPANDER0_FLAGS_TABLE_TO_TABLE_SUPPORT (0x0080)
  2234. #define MPI2_SAS_EXPANDER0_FLAGS_CONNECTOR_END_DEVICE (0x0010)
  2235. #define MPI2_SAS_EXPANDER0_FLAGS_OTHERS_CONFIG (0x0004)
  2236. #define MPI2_SAS_EXPANDER0_FLAGS_CONFIG_IN_PROGRESS (0x0002)
  2237. #define MPI2_SAS_EXPANDER0_FLAGS_ROUTE_TABLE_CONFIG (0x0001)
  2238. /*SAS Expander Page 1 */
  2239. typedef struct _MPI2_CONFIG_PAGE_EXPANDER_1 {
  2240. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2241. Header; /*0x00 */
  2242. U8
  2243. PhysicalPort; /*0x08 */
  2244. U8
  2245. Reserved1; /*0x09 */
  2246. U16
  2247. Reserved2; /*0x0A */
  2248. U8
  2249. NumPhys; /*0x0C */
  2250. U8
  2251. Phy; /*0x0D */
  2252. U16
  2253. NumTableEntriesProgrammed; /*0x0E */
  2254. U8
  2255. ProgrammedLinkRate; /*0x10 */
  2256. U8
  2257. HwLinkRate; /*0x11 */
  2258. U16
  2259. AttachedDevHandle; /*0x12 */
  2260. U32
  2261. PhyInfo; /*0x14 */
  2262. U32
  2263. AttachedDeviceInfo; /*0x18 */
  2264. U16
  2265. ExpanderDevHandle; /*0x1C */
  2266. U8
  2267. ChangeCount; /*0x1E */
  2268. U8
  2269. NegotiatedLinkRate; /*0x1F */
  2270. U8
  2271. PhyIdentifier; /*0x20 */
  2272. U8
  2273. AttachedPhyIdentifier; /*0x21 */
  2274. U8
  2275. Reserved3; /*0x22 */
  2276. U8
  2277. DiscoveryInfo; /*0x23 */
  2278. U32
  2279. AttachedPhyInfo; /*0x24 */
  2280. U8
  2281. ZoneGroup; /*0x28 */
  2282. U8
  2283. SelfConfigStatus; /*0x29 */
  2284. U16
  2285. Reserved4; /*0x2A */
  2286. } MPI2_CONFIG_PAGE_EXPANDER_1,
  2287. *PTR_MPI2_CONFIG_PAGE_EXPANDER_1,
  2288. Mpi2ExpanderPage1_t, *pMpi2ExpanderPage1_t;
  2289. #define MPI2_SASEXPANDER1_PAGEVERSION (0x02)
  2290. /*use MPI2_SAS_PRATE_ defines for the ProgrammedLinkRate field */
  2291. /*use MPI2_SAS_HWRATE_ defines for the HwLinkRate field */
  2292. /*use MPI2_SAS_PHYINFO_ for the PhyInfo field */
  2293. /*see mpi2_sas.h for the MPI2_SAS_DEVICE_INFO_ defines
  2294. *used for the AttachedDeviceInfo field */
  2295. /*use MPI2_SAS_NEG_LINK_RATE_ defines for the NegotiatedLinkRate field */
  2296. /*values for SAS Expander Page 1 DiscoveryInfo field */
  2297. #define MPI2_SAS_EXPANDER1_DISCINFO_BAD_PHY_DISABLED (0x04)
  2298. #define MPI2_SAS_EXPANDER1_DISCINFO_LINK_STATUS_CHANGE (0x02)
  2299. #define MPI2_SAS_EXPANDER1_DISCINFO_NO_ROUTING_ENTRIES (0x01)
  2300. /*use MPI2_SAS_APHYINFO_ defines for AttachedPhyInfo field */
  2301. /****************************************************************************
  2302. * SAS Device Config Pages
  2303. ****************************************************************************/
  2304. /*SAS Device Page 0 */
  2305. typedef struct _MPI2_CONFIG_PAGE_SAS_DEV_0 {
  2306. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2307. Header; /*0x00 */
  2308. U16
  2309. Slot; /*0x08 */
  2310. U16
  2311. EnclosureHandle; /*0x0A */
  2312. U64
  2313. SASAddress; /*0x0C */
  2314. U16
  2315. ParentDevHandle; /*0x14 */
  2316. U8
  2317. PhyNum; /*0x16 */
  2318. U8
  2319. AccessStatus; /*0x17 */
  2320. U16
  2321. DevHandle; /*0x18 */
  2322. U8
  2323. AttachedPhyIdentifier; /*0x1A */
  2324. U8
  2325. ZoneGroup; /*0x1B */
  2326. U32
  2327. DeviceInfo; /*0x1C */
  2328. U16
  2329. Flags; /*0x20 */
  2330. U8
  2331. PhysicalPort; /*0x22 */
  2332. U8
  2333. MaxPortConnections; /*0x23 */
  2334. U64
  2335. DeviceName; /*0x24 */
  2336. U8
  2337. PortGroups; /*0x2C */
  2338. U8
  2339. DmaGroup; /*0x2D */
  2340. U8
  2341. ControlGroup; /*0x2E */
  2342. U8
  2343. EnclosureLevel; /*0x2F */
  2344. U32
  2345. ConnectorName[4]; /*0x30 */
  2346. U32
  2347. Reserved3; /*0x34 */
  2348. } MPI2_CONFIG_PAGE_SAS_DEV_0,
  2349. *PTR_MPI2_CONFIG_PAGE_SAS_DEV_0,
  2350. Mpi2SasDevicePage0_t,
  2351. *pMpi2SasDevicePage0_t;
  2352. #define MPI2_SASDEVICE0_PAGEVERSION (0x09)
  2353. /*values for SAS Device Page 0 AccessStatus field */
  2354. #define MPI2_SAS_DEVICE0_ASTATUS_NO_ERRORS (0x00)
  2355. #define MPI2_SAS_DEVICE0_ASTATUS_SATA_INIT_FAILED (0x01)
  2356. #define MPI2_SAS_DEVICE0_ASTATUS_SATA_CAPABILITY_FAILED (0x02)
  2357. #define MPI2_SAS_DEVICE0_ASTATUS_SATA_AFFILIATION_CONFLICT (0x03)
  2358. #define MPI2_SAS_DEVICE0_ASTATUS_SATA_NEEDS_INITIALIZATION (0x04)
  2359. #define MPI2_SAS_DEVICE0_ASTATUS_ROUTE_NOT_ADDRESSABLE (0x05)
  2360. #define MPI2_SAS_DEVICE0_ASTATUS_SMP_ERROR_NOT_ADDRESSABLE (0x06)
  2361. #define MPI2_SAS_DEVICE0_ASTATUS_DEVICE_BLOCKED (0x07)
  2362. /*specific values for SATA Init failures */
  2363. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_UNKNOWN (0x10)
  2364. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_AFFILIATION_CONFLICT (0x11)
  2365. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_DIAG (0x12)
  2366. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_IDENTIFICATION (0x13)
  2367. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_CHECK_POWER (0x14)
  2368. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_PIO_SN (0x15)
  2369. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_MDMA_SN (0x16)
  2370. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_UDMA_SN (0x17)
  2371. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_ZONING_VIOLATION (0x18)
  2372. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_NOT_ADDRESSABLE (0x19)
  2373. #define MPI2_SAS_DEVICE0_ASTATUS_SIF_MAX (0x1F)
  2374. /*see mpi2_sas.h for values for SAS Device Page 0 DeviceInfo values */
  2375. /*values for SAS Device Page 0 Flags field */
  2376. #define MPI2_SAS_DEVICE0_FLAGS_UNAUTHORIZED_DEVICE (0x8000)
  2377. #define MPI25_SAS_DEVICE0_FLAGS_ENABLED_FAST_PATH (0x4000)
  2378. #define MPI25_SAS_DEVICE0_FLAGS_FAST_PATH_CAPABLE (0x2000)
  2379. #define MPI2_SAS_DEVICE0_FLAGS_SLUMBER_PM_CAPABLE (0x1000)
  2380. #define MPI2_SAS_DEVICE0_FLAGS_PARTIAL_PM_CAPABLE (0x0800)
  2381. #define MPI2_SAS_DEVICE0_FLAGS_SATA_ASYNCHRONOUS_NOTIFY (0x0400)
  2382. #define MPI2_SAS_DEVICE0_FLAGS_SATA_SW_PRESERVE (0x0200)
  2383. #define MPI2_SAS_DEVICE0_FLAGS_UNSUPPORTED_DEVICE (0x0100)
  2384. #define MPI2_SAS_DEVICE0_FLAGS_SATA_48BIT_LBA_SUPPORTED (0x0080)
  2385. #define MPI2_SAS_DEVICE0_FLAGS_SATA_SMART_SUPPORTED (0x0040)
  2386. #define MPI2_SAS_DEVICE0_FLAGS_SATA_NCQ_SUPPORTED (0x0020)
  2387. #define MPI2_SAS_DEVICE0_FLAGS_SATA_FUA_SUPPORTED (0x0010)
  2388. #define MPI2_SAS_DEVICE0_FLAGS_PORT_SELECTOR_ATTACH (0x0008)
  2389. #define MPI2_SAS_DEVICE0_FLAGS_PERSIST_CAPABLE (0x0004)
  2390. #define MPI2_SAS_DEVICE0_FLAGS_ENCL_LEVEL_VALID (0x0002)
  2391. #define MPI2_SAS_DEVICE0_FLAGS_DEVICE_PRESENT (0x0001)
  2392. /*SAS Device Page 1 */
  2393. typedef struct _MPI2_CONFIG_PAGE_SAS_DEV_1 {
  2394. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2395. Header; /*0x00 */
  2396. U32
  2397. Reserved1; /*0x08 */
  2398. U64
  2399. SASAddress; /*0x0C */
  2400. U32
  2401. Reserved2; /*0x14 */
  2402. U16
  2403. DevHandle; /*0x18 */
  2404. U16
  2405. Reserved3; /*0x1A */
  2406. U8
  2407. InitialRegDeviceFIS[20];/*0x1C */
  2408. } MPI2_CONFIG_PAGE_SAS_DEV_1,
  2409. *PTR_MPI2_CONFIG_PAGE_SAS_DEV_1,
  2410. Mpi2SasDevicePage1_t,
  2411. *pMpi2SasDevicePage1_t;
  2412. #define MPI2_SASDEVICE1_PAGEVERSION (0x01)
  2413. /****************************************************************************
  2414. * SAS PHY Config Pages
  2415. ****************************************************************************/
  2416. /*SAS PHY Page 0 */
  2417. typedef struct _MPI2_CONFIG_PAGE_SAS_PHY_0 {
  2418. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2419. Header; /*0x00 */
  2420. U16
  2421. OwnerDevHandle; /*0x08 */
  2422. U16
  2423. Reserved1; /*0x0A */
  2424. U16
  2425. AttachedDevHandle; /*0x0C */
  2426. U8
  2427. AttachedPhyIdentifier; /*0x0E */
  2428. U8
  2429. Reserved2; /*0x0F */
  2430. U32
  2431. AttachedPhyInfo; /*0x10 */
  2432. U8
  2433. ProgrammedLinkRate; /*0x14 */
  2434. U8
  2435. HwLinkRate; /*0x15 */
  2436. U8
  2437. ChangeCount; /*0x16 */
  2438. U8
  2439. Flags; /*0x17 */
  2440. U32
  2441. PhyInfo; /*0x18 */
  2442. U8
  2443. NegotiatedLinkRate; /*0x1C */
  2444. U8
  2445. Reserved3; /*0x1D */
  2446. U16
  2447. Reserved4; /*0x1E */
  2448. } MPI2_CONFIG_PAGE_SAS_PHY_0,
  2449. *PTR_MPI2_CONFIG_PAGE_SAS_PHY_0,
  2450. Mpi2SasPhyPage0_t, *pMpi2SasPhyPage0_t;
  2451. #define MPI2_SASPHY0_PAGEVERSION (0x03)
  2452. /*use MPI2_SAS_APHYINFO_ defines for AttachedPhyInfo field */
  2453. /*use MPI2_SAS_PRATE_ defines for the ProgrammedLinkRate field */
  2454. /*use MPI2_SAS_HWRATE_ defines for the HwLinkRate field */
  2455. /*values for SAS PHY Page 0 Flags field */
  2456. #define MPI2_SAS_PHY0_FLAGS_SGPIO_DIRECT_ATTACH_ENC (0x01)
  2457. /*use MPI2_SAS_PHYINFO_ for the PhyInfo field */
  2458. /*use MPI2_SAS_NEG_LINK_RATE_ defines for the NegotiatedLinkRate field */
  2459. /*SAS PHY Page 1 */
  2460. typedef struct _MPI2_CONFIG_PAGE_SAS_PHY_1 {
  2461. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2462. Header; /*0x00 */
  2463. U32
  2464. Reserved1; /*0x08 */
  2465. U32
  2466. InvalidDwordCount; /*0x0C */
  2467. U32
  2468. RunningDisparityErrorCount; /*0x10 */
  2469. U32
  2470. LossDwordSynchCount; /*0x14 */
  2471. U32
  2472. PhyResetProblemCount; /*0x18 */
  2473. } MPI2_CONFIG_PAGE_SAS_PHY_1,
  2474. *PTR_MPI2_CONFIG_PAGE_SAS_PHY_1,
  2475. Mpi2SasPhyPage1_t, *pMpi2SasPhyPage1_t;
  2476. #define MPI2_SASPHY1_PAGEVERSION (0x01)
  2477. /*SAS PHY Page 2 */
  2478. typedef struct _MPI2_SASPHY2_PHY_EVENT {
  2479. U8 PhyEventCode; /*0x00 */
  2480. U8 Reserved1; /*0x01 */
  2481. U16 Reserved2; /*0x02 */
  2482. U32 PhyEventInfo; /*0x04 */
  2483. } MPI2_SASPHY2_PHY_EVENT, *PTR_MPI2_SASPHY2_PHY_EVENT,
  2484. Mpi2SasPhy2PhyEvent_t, *pMpi2SasPhy2PhyEvent_t;
  2485. /*use MPI2_SASPHY3_EVENT_CODE_ for the PhyEventCode field */
  2486. /*
  2487. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  2488. *one and check the value returned for NumPhyEvents at runtime.
  2489. */
  2490. #ifndef MPI2_SASPHY2_PHY_EVENT_MAX
  2491. #define MPI2_SASPHY2_PHY_EVENT_MAX (1)
  2492. #endif
  2493. typedef struct _MPI2_CONFIG_PAGE_SAS_PHY_2 {
  2494. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2495. Header; /*0x00 */
  2496. U32
  2497. Reserved1; /*0x08 */
  2498. U8
  2499. NumPhyEvents; /*0x0C */
  2500. U8
  2501. Reserved2; /*0x0D */
  2502. U16
  2503. Reserved3; /*0x0E */
  2504. MPI2_SASPHY2_PHY_EVENT
  2505. PhyEvent[MPI2_SASPHY2_PHY_EVENT_MAX]; /*0x10 */
  2506. } MPI2_CONFIG_PAGE_SAS_PHY_2,
  2507. *PTR_MPI2_CONFIG_PAGE_SAS_PHY_2,
  2508. Mpi2SasPhyPage2_t,
  2509. *pMpi2SasPhyPage2_t;
  2510. #define MPI2_SASPHY2_PAGEVERSION (0x00)
  2511. /*SAS PHY Page 3 */
  2512. typedef struct _MPI2_SASPHY3_PHY_EVENT_CONFIG {
  2513. U8 PhyEventCode; /*0x00 */
  2514. U8 Reserved1; /*0x01 */
  2515. U16 Reserved2; /*0x02 */
  2516. U8 CounterType; /*0x04 */
  2517. U8 ThresholdWindow; /*0x05 */
  2518. U8 TimeUnits; /*0x06 */
  2519. U8 Reserved3; /*0x07 */
  2520. U32 EventThreshold; /*0x08 */
  2521. U16 ThresholdFlags; /*0x0C */
  2522. U16 Reserved4; /*0x0E */
  2523. } MPI2_SASPHY3_PHY_EVENT_CONFIG,
  2524. *PTR_MPI2_SASPHY3_PHY_EVENT_CONFIG,
  2525. Mpi2SasPhy3PhyEventConfig_t,
  2526. *pMpi2SasPhy3PhyEventConfig_t;
  2527. /*values for PhyEventCode field */
  2528. #define MPI2_SASPHY3_EVENT_CODE_NO_EVENT (0x00)
  2529. #define MPI2_SASPHY3_EVENT_CODE_INVALID_DWORD (0x01)
  2530. #define MPI2_SASPHY3_EVENT_CODE_RUNNING_DISPARITY_ERROR (0x02)
  2531. #define MPI2_SASPHY3_EVENT_CODE_LOSS_DWORD_SYNC (0x03)
  2532. #define MPI2_SASPHY3_EVENT_CODE_PHY_RESET_PROBLEM (0x04)
  2533. #define MPI2_SASPHY3_EVENT_CODE_ELASTICITY_BUF_OVERFLOW (0x05)
  2534. #define MPI2_SASPHY3_EVENT_CODE_RX_ERROR (0x06)
  2535. #define MPI2_SASPHY3_EVENT_CODE_RX_ADDR_FRAME_ERROR (0x20)
  2536. #define MPI2_SASPHY3_EVENT_CODE_TX_AC_OPEN_REJECT (0x21)
  2537. #define MPI2_SASPHY3_EVENT_CODE_RX_AC_OPEN_REJECT (0x22)
  2538. #define MPI2_SASPHY3_EVENT_CODE_TX_RC_OPEN_REJECT (0x23)
  2539. #define MPI2_SASPHY3_EVENT_CODE_RX_RC_OPEN_REJECT (0x24)
  2540. #define MPI2_SASPHY3_EVENT_CODE_RX_AIP_PARTIAL_WAITING_ON (0x25)
  2541. #define MPI2_SASPHY3_EVENT_CODE_RX_AIP_CONNECT_WAITING_ON (0x26)
  2542. #define MPI2_SASPHY3_EVENT_CODE_TX_BREAK (0x27)
  2543. #define MPI2_SASPHY3_EVENT_CODE_RX_BREAK (0x28)
  2544. #define MPI2_SASPHY3_EVENT_CODE_BREAK_TIMEOUT (0x29)
  2545. #define MPI2_SASPHY3_EVENT_CODE_CONNECTION (0x2A)
  2546. #define MPI2_SASPHY3_EVENT_CODE_PEAKTX_PATHWAY_BLOCKED (0x2B)
  2547. #define MPI2_SASPHY3_EVENT_CODE_PEAKTX_ARB_WAIT_TIME (0x2C)
  2548. #define MPI2_SASPHY3_EVENT_CODE_PEAK_ARB_WAIT_TIME (0x2D)
  2549. #define MPI2_SASPHY3_EVENT_CODE_PEAK_CONNECT_TIME (0x2E)
  2550. #define MPI2_SASPHY3_EVENT_CODE_TX_SSP_FRAMES (0x40)
  2551. #define MPI2_SASPHY3_EVENT_CODE_RX_SSP_FRAMES (0x41)
  2552. #define MPI2_SASPHY3_EVENT_CODE_TX_SSP_ERROR_FRAMES (0x42)
  2553. #define MPI2_SASPHY3_EVENT_CODE_RX_SSP_ERROR_FRAMES (0x43)
  2554. #define MPI2_SASPHY3_EVENT_CODE_TX_CREDIT_BLOCKED (0x44)
  2555. #define MPI2_SASPHY3_EVENT_CODE_RX_CREDIT_BLOCKED (0x45)
  2556. #define MPI2_SASPHY3_EVENT_CODE_TX_SATA_FRAMES (0x50)
  2557. #define MPI2_SASPHY3_EVENT_CODE_RX_SATA_FRAMES (0x51)
  2558. #define MPI2_SASPHY3_EVENT_CODE_SATA_OVERFLOW (0x52)
  2559. #define MPI2_SASPHY3_EVENT_CODE_TX_SMP_FRAMES (0x60)
  2560. #define MPI2_SASPHY3_EVENT_CODE_RX_SMP_FRAMES (0x61)
  2561. #define MPI2_SASPHY3_EVENT_CODE_RX_SMP_ERROR_FRAMES (0x63)
  2562. #define MPI2_SASPHY3_EVENT_CODE_HOTPLUG_TIMEOUT (0xD0)
  2563. #define MPI2_SASPHY3_EVENT_CODE_MISALIGNED_MUX_PRIMITIVE (0xD1)
  2564. #define MPI2_SASPHY3_EVENT_CODE_RX_AIP (0xD2)
  2565. /*Following codes are product specific and in MPI v2.6 and later */
  2566. #define MPI2_SASPHY3_EVENT_CODE_LCARB_WAIT_TIME (0xD3)
  2567. #define MPI2_SASPHY3_EVENT_CODE_RCVD_CONN_RESP_WAIT_TIME (0xD4)
  2568. #define MPI2_SASPHY3_EVENT_CODE_LCCONN_TIME (0xD5)
  2569. #define MPI2_SASPHY3_EVENT_CODE_SSP_TX_START_TRANSMIT (0xD6)
  2570. #define MPI2_SASPHY3_EVENT_CODE_SATA_TX_START (0xD7)
  2571. #define MPI2_SASPHY3_EVENT_CODE_SMP_TX_START_TRANSMT (0xD8)
  2572. #define MPI2_SASPHY3_EVENT_CODE_TX_SMP_BREAK_CONN (0xD9)
  2573. #define MPI2_SASPHY3_EVENT_CODE_SSP_RX_START_RECEIVE (0xDA)
  2574. #define MPI2_SASPHY3_EVENT_CODE_SATA_RX_START_RECEIVE (0xDB)
  2575. #define MPI2_SASPHY3_EVENT_CODE_SMP_RX_START_RECEIVE (0xDC)
  2576. /*values for the CounterType field */
  2577. #define MPI2_SASPHY3_COUNTER_TYPE_WRAPPING (0x00)
  2578. #define MPI2_SASPHY3_COUNTER_TYPE_SATURATING (0x01)
  2579. #define MPI2_SASPHY3_COUNTER_TYPE_PEAK_VALUE (0x02)
  2580. /*values for the TimeUnits field */
  2581. #define MPI2_SASPHY3_TIME_UNITS_10_MICROSECONDS (0x00)
  2582. #define MPI2_SASPHY3_TIME_UNITS_100_MICROSECONDS (0x01)
  2583. #define MPI2_SASPHY3_TIME_UNITS_1_MILLISECOND (0x02)
  2584. #define MPI2_SASPHY3_TIME_UNITS_10_MILLISECONDS (0x03)
  2585. /*values for the ThresholdFlags field */
  2586. #define MPI2_SASPHY3_TFLAGS_PHY_RESET (0x0002)
  2587. #define MPI2_SASPHY3_TFLAGS_EVENT_NOTIFY (0x0001)
  2588. /*
  2589. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  2590. *one and check the value returned for NumPhyEvents at runtime.
  2591. */
  2592. #ifndef MPI2_SASPHY3_PHY_EVENT_MAX
  2593. #define MPI2_SASPHY3_PHY_EVENT_MAX (1)
  2594. #endif
  2595. typedef struct _MPI2_CONFIG_PAGE_SAS_PHY_3 {
  2596. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2597. Header; /*0x00 */
  2598. U32
  2599. Reserved1; /*0x08 */
  2600. U8
  2601. NumPhyEvents; /*0x0C */
  2602. U8
  2603. Reserved2; /*0x0D */
  2604. U16
  2605. Reserved3; /*0x0E */
  2606. MPI2_SASPHY3_PHY_EVENT_CONFIG
  2607. PhyEventConfig[MPI2_SASPHY3_PHY_EVENT_MAX]; /*0x10 */
  2608. } MPI2_CONFIG_PAGE_SAS_PHY_3,
  2609. *PTR_MPI2_CONFIG_PAGE_SAS_PHY_3,
  2610. Mpi2SasPhyPage3_t, *pMpi2SasPhyPage3_t;
  2611. #define MPI2_SASPHY3_PAGEVERSION (0x00)
  2612. /*SAS PHY Page 4 */
  2613. typedef struct _MPI2_CONFIG_PAGE_SAS_PHY_4 {
  2614. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2615. Header; /*0x00 */
  2616. U16
  2617. Reserved1; /*0x08 */
  2618. U8
  2619. Reserved2; /*0x0A */
  2620. U8
  2621. Flags; /*0x0B */
  2622. U8
  2623. InitialFrame[28]; /*0x0C */
  2624. } MPI2_CONFIG_PAGE_SAS_PHY_4,
  2625. *PTR_MPI2_CONFIG_PAGE_SAS_PHY_4,
  2626. Mpi2SasPhyPage4_t, *pMpi2SasPhyPage4_t;
  2627. #define MPI2_SASPHY4_PAGEVERSION (0x00)
  2628. /*values for the Flags field */
  2629. #define MPI2_SASPHY4_FLAGS_FRAME_VALID (0x02)
  2630. #define MPI2_SASPHY4_FLAGS_SATA_FRAME (0x01)
  2631. /****************************************************************************
  2632. * SAS Port Config Pages
  2633. ****************************************************************************/
  2634. /*SAS Port Page 0 */
  2635. typedef struct _MPI2_CONFIG_PAGE_SAS_PORT_0 {
  2636. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2637. Header; /*0x00 */
  2638. U8
  2639. PortNumber; /*0x08 */
  2640. U8
  2641. PhysicalPort; /*0x09 */
  2642. U8
  2643. PortWidth; /*0x0A */
  2644. U8
  2645. PhysicalPortWidth; /*0x0B */
  2646. U8
  2647. ZoneGroup; /*0x0C */
  2648. U8
  2649. Reserved1; /*0x0D */
  2650. U16
  2651. Reserved2; /*0x0E */
  2652. U64
  2653. SASAddress; /*0x10 */
  2654. U32
  2655. DeviceInfo; /*0x18 */
  2656. U32
  2657. Reserved3; /*0x1C */
  2658. U32
  2659. Reserved4; /*0x20 */
  2660. } MPI2_CONFIG_PAGE_SAS_PORT_0,
  2661. *PTR_MPI2_CONFIG_PAGE_SAS_PORT_0,
  2662. Mpi2SasPortPage0_t, *pMpi2SasPortPage0_t;
  2663. #define MPI2_SASPORT0_PAGEVERSION (0x00)
  2664. /*see mpi2_sas.h for values for SAS Port Page 0 DeviceInfo values */
  2665. /****************************************************************************
  2666. * SAS Enclosure Config Pages
  2667. ****************************************************************************/
  2668. /*SAS Enclosure Page 0 */
  2669. typedef struct _MPI2_CONFIG_PAGE_SAS_ENCLOSURE_0 {
  2670. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2671. Header; /*0x00 */
  2672. U32
  2673. Reserved1; /*0x08 */
  2674. U64
  2675. EnclosureLogicalID; /*0x0C */
  2676. U16
  2677. Flags; /*0x14 */
  2678. U16
  2679. EnclosureHandle; /*0x16 */
  2680. U16
  2681. NumSlots; /*0x18 */
  2682. U16
  2683. StartSlot; /*0x1A */
  2684. U8
  2685. Reserved2; /*0x1C */
  2686. U8
  2687. EnclosureLevel; /*0x1D */
  2688. U16
  2689. SEPDevHandle; /*0x1E */
  2690. U32
  2691. Reserved3; /*0x20 */
  2692. U32
  2693. Reserved4; /*0x24 */
  2694. } MPI2_CONFIG_PAGE_SAS_ENCLOSURE_0,
  2695. *PTR_MPI2_CONFIG_PAGE_SAS_ENCLOSURE_0,
  2696. Mpi2SasEnclosurePage0_t, *pMpi2SasEnclosurePage0_t;
  2697. #define MPI2_SASENCLOSURE0_PAGEVERSION (0x04)
  2698. /*values for SAS Enclosure Page 0 Flags field */
  2699. #define MPI2_SAS_ENCLS0_FLAGS_ENCL_LEVEL_VALID (0x0010)
  2700. #define MPI2_SAS_ENCLS0_FLAGS_MNG_MASK (0x000F)
  2701. #define MPI2_SAS_ENCLS0_FLAGS_MNG_UNKNOWN (0x0000)
  2702. #define MPI2_SAS_ENCLS0_FLAGS_MNG_IOC_SES (0x0001)
  2703. #define MPI2_SAS_ENCLS0_FLAGS_MNG_IOC_SGPIO (0x0002)
  2704. #define MPI2_SAS_ENCLS0_FLAGS_MNG_EXP_SGPIO (0x0003)
  2705. #define MPI2_SAS_ENCLS0_FLAGS_MNG_SES_ENCLOSURE (0x0004)
  2706. #define MPI2_SAS_ENCLS0_FLAGS_MNG_IOC_GPIO (0x0005)
  2707. /****************************************************************************
  2708. * Log Config Page
  2709. ****************************************************************************/
  2710. /*Log Page 0 */
  2711. /*
  2712. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  2713. *one and check the value returned for NumLogEntries at runtime.
  2714. */
  2715. #ifndef MPI2_LOG_0_NUM_LOG_ENTRIES
  2716. #define MPI2_LOG_0_NUM_LOG_ENTRIES (1)
  2717. #endif
  2718. #define MPI2_LOG_0_LOG_DATA_LENGTH (0x1C)
  2719. typedef struct _MPI2_LOG_0_ENTRY {
  2720. U64 TimeStamp; /*0x00 */
  2721. U32 Reserved1; /*0x08 */
  2722. U16 LogSequence; /*0x0C */
  2723. U16 LogEntryQualifier; /*0x0E */
  2724. U8 VP_ID; /*0x10 */
  2725. U8 VF_ID; /*0x11 */
  2726. U16 Reserved2; /*0x12 */
  2727. U8
  2728. LogData[MPI2_LOG_0_LOG_DATA_LENGTH];/*0x14 */
  2729. } MPI2_LOG_0_ENTRY, *PTR_MPI2_LOG_0_ENTRY,
  2730. Mpi2Log0Entry_t, *pMpi2Log0Entry_t;
  2731. /*values for Log Page 0 LogEntry LogEntryQualifier field */
  2732. #define MPI2_LOG_0_ENTRY_QUAL_ENTRY_UNUSED (0x0000)
  2733. #define MPI2_LOG_0_ENTRY_QUAL_POWER_ON_RESET (0x0001)
  2734. #define MPI2_LOG_0_ENTRY_QUAL_TIMESTAMP_UPDATE (0x0002)
  2735. #define MPI2_LOG_0_ENTRY_QUAL_MIN_IMPLEMENT_SPEC (0x8000)
  2736. #define MPI2_LOG_0_ENTRY_QUAL_MAX_IMPLEMENT_SPEC (0xFFFF)
  2737. typedef struct _MPI2_CONFIG_PAGE_LOG_0 {
  2738. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  2739. U32 Reserved1; /*0x08 */
  2740. U32 Reserved2; /*0x0C */
  2741. U16 NumLogEntries;/*0x10 */
  2742. U16 Reserved3; /*0x12 */
  2743. MPI2_LOG_0_ENTRY
  2744. LogEntry[MPI2_LOG_0_NUM_LOG_ENTRIES]; /*0x14 */
  2745. } MPI2_CONFIG_PAGE_LOG_0, *PTR_MPI2_CONFIG_PAGE_LOG_0,
  2746. Mpi2LogPage0_t, *pMpi2LogPage0_t;
  2747. #define MPI2_LOG_0_PAGEVERSION (0x02)
  2748. /****************************************************************************
  2749. * RAID Config Page
  2750. ****************************************************************************/
  2751. /*RAID Page 0 */
  2752. /*
  2753. *Host code (drivers, BIOS, utilities, etc.) should leave this define set to
  2754. *one and check the value returned for NumElements at runtime.
  2755. */
  2756. #ifndef MPI2_RAIDCONFIG0_MAX_ELEMENTS
  2757. #define MPI2_RAIDCONFIG0_MAX_ELEMENTS (1)
  2758. #endif
  2759. typedef struct _MPI2_RAIDCONFIG0_CONFIG_ELEMENT {
  2760. U16 ElementFlags; /*0x00 */
  2761. U16 VolDevHandle; /*0x02 */
  2762. U8 HotSparePool; /*0x04 */
  2763. U8 PhysDiskNum; /*0x05 */
  2764. U16 PhysDiskDevHandle; /*0x06 */
  2765. } MPI2_RAIDCONFIG0_CONFIG_ELEMENT,
  2766. *PTR_MPI2_RAIDCONFIG0_CONFIG_ELEMENT,
  2767. Mpi2RaidConfig0ConfigElement_t,
  2768. *pMpi2RaidConfig0ConfigElement_t;
  2769. /*values for the ElementFlags field */
  2770. #define MPI2_RAIDCONFIG0_EFLAGS_MASK_ELEMENT_TYPE (0x000F)
  2771. #define MPI2_RAIDCONFIG0_EFLAGS_VOLUME_ELEMENT (0x0000)
  2772. #define MPI2_RAIDCONFIG0_EFLAGS_VOL_PHYS_DISK_ELEMENT (0x0001)
  2773. #define MPI2_RAIDCONFIG0_EFLAGS_HOT_SPARE_ELEMENT (0x0002)
  2774. #define MPI2_RAIDCONFIG0_EFLAGS_OCE_ELEMENT (0x0003)
  2775. typedef struct _MPI2_CONFIG_PAGE_RAID_CONFIGURATION_0 {
  2776. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  2777. U8 NumHotSpares; /*0x08 */
  2778. U8 NumPhysDisks; /*0x09 */
  2779. U8 NumVolumes; /*0x0A */
  2780. U8 ConfigNum; /*0x0B */
  2781. U32 Flags; /*0x0C */
  2782. U8 ConfigGUID[24]; /*0x10 */
  2783. U32 Reserved1; /*0x28 */
  2784. U8 NumElements; /*0x2C */
  2785. U8 Reserved2; /*0x2D */
  2786. U16 Reserved3; /*0x2E */
  2787. MPI2_RAIDCONFIG0_CONFIG_ELEMENT
  2788. ConfigElement[MPI2_RAIDCONFIG0_MAX_ELEMENTS]; /*0x30 */
  2789. } MPI2_CONFIG_PAGE_RAID_CONFIGURATION_0,
  2790. *PTR_MPI2_CONFIG_PAGE_RAID_CONFIGURATION_0,
  2791. Mpi2RaidConfigurationPage0_t,
  2792. *pMpi2RaidConfigurationPage0_t;
  2793. #define MPI2_RAIDCONFIG0_PAGEVERSION (0x00)
  2794. /*values for RAID Configuration Page 0 Flags field */
  2795. #define MPI2_RAIDCONFIG0_FLAG_FOREIGN_CONFIG (0x00000001)
  2796. /****************************************************************************
  2797. * Driver Persistent Mapping Config Pages
  2798. ****************************************************************************/
  2799. /*Driver Persistent Mapping Page 0 */
  2800. typedef struct _MPI2_CONFIG_PAGE_DRIVER_MAP0_ENTRY {
  2801. U64 PhysicalIdentifier; /*0x00 */
  2802. U16 MappingInformation; /*0x08 */
  2803. U16 DeviceIndex; /*0x0A */
  2804. U32 PhysicalBitsMapping; /*0x0C */
  2805. U32 Reserved1; /*0x10 */
  2806. } MPI2_CONFIG_PAGE_DRIVER_MAP0_ENTRY,
  2807. *PTR_MPI2_CONFIG_PAGE_DRIVER_MAP0_ENTRY,
  2808. Mpi2DriverMap0Entry_t, *pMpi2DriverMap0Entry_t;
  2809. typedef struct _MPI2_CONFIG_PAGE_DRIVER_MAPPING_0 {
  2810. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  2811. MPI2_CONFIG_PAGE_DRIVER_MAP0_ENTRY Entry; /*0x08 */
  2812. } MPI2_CONFIG_PAGE_DRIVER_MAPPING_0,
  2813. *PTR_MPI2_CONFIG_PAGE_DRIVER_MAPPING_0,
  2814. Mpi2DriverMappingPage0_t, *pMpi2DriverMappingPage0_t;
  2815. #define MPI2_DRIVERMAPPING0_PAGEVERSION (0x00)
  2816. /*values for Driver Persistent Mapping Page 0 MappingInformation field */
  2817. #define MPI2_DRVMAP0_MAPINFO_SLOT_MASK (0x07F0)
  2818. #define MPI2_DRVMAP0_MAPINFO_SLOT_SHIFT (4)
  2819. #define MPI2_DRVMAP0_MAPINFO_MISSING_MASK (0x000F)
  2820. /****************************************************************************
  2821. * Ethernet Config Pages
  2822. ****************************************************************************/
  2823. /*Ethernet Page 0 */
  2824. /*IP address (union of IPv4 and IPv6) */
  2825. typedef union _MPI2_ETHERNET_IP_ADDR {
  2826. U32 IPv4Addr;
  2827. U32 IPv6Addr[4];
  2828. } MPI2_ETHERNET_IP_ADDR, *PTR_MPI2_ETHERNET_IP_ADDR,
  2829. Mpi2EthernetIpAddr_t, *pMpi2EthernetIpAddr_t;
  2830. #define MPI2_ETHERNET_HOST_NAME_LENGTH (32)
  2831. typedef struct _MPI2_CONFIG_PAGE_ETHERNET_0 {
  2832. MPI2_CONFIG_EXTENDED_PAGE_HEADER Header; /*0x00 */
  2833. U8 NumInterfaces; /*0x08 */
  2834. U8 Reserved0; /*0x09 */
  2835. U16 Reserved1; /*0x0A */
  2836. U32 Status; /*0x0C */
  2837. U8 MediaState; /*0x10 */
  2838. U8 Reserved2; /*0x11 */
  2839. U16 Reserved3; /*0x12 */
  2840. U8 MacAddress[6]; /*0x14 */
  2841. U8 Reserved4; /*0x1A */
  2842. U8 Reserved5; /*0x1B */
  2843. MPI2_ETHERNET_IP_ADDR IpAddress; /*0x1C */
  2844. MPI2_ETHERNET_IP_ADDR SubnetMask; /*0x2C */
  2845. MPI2_ETHERNET_IP_ADDR GatewayIpAddress;/*0x3C */
  2846. MPI2_ETHERNET_IP_ADDR DNS1IpAddress; /*0x4C */
  2847. MPI2_ETHERNET_IP_ADDR DNS2IpAddress; /*0x5C */
  2848. MPI2_ETHERNET_IP_ADDR DhcpIpAddress; /*0x6C */
  2849. U8
  2850. HostName[MPI2_ETHERNET_HOST_NAME_LENGTH];/*0x7C */
  2851. } MPI2_CONFIG_PAGE_ETHERNET_0,
  2852. *PTR_MPI2_CONFIG_PAGE_ETHERNET_0,
  2853. Mpi2EthernetPage0_t, *pMpi2EthernetPage0_t;
  2854. #define MPI2_ETHERNETPAGE0_PAGEVERSION (0x00)
  2855. /*values for Ethernet Page 0 Status field */
  2856. #define MPI2_ETHPG0_STATUS_IPV6_CAPABLE (0x80000000)
  2857. #define MPI2_ETHPG0_STATUS_IPV4_CAPABLE (0x40000000)
  2858. #define MPI2_ETHPG0_STATUS_CONSOLE_CONNECTED (0x20000000)
  2859. #define MPI2_ETHPG0_STATUS_DEFAULT_IF (0x00000100)
  2860. #define MPI2_ETHPG0_STATUS_FW_DWNLD_ENABLED (0x00000080)
  2861. #define MPI2_ETHPG0_STATUS_TELNET_ENABLED (0x00000040)
  2862. #define MPI2_ETHPG0_STATUS_SSH2_ENABLED (0x00000020)
  2863. #define MPI2_ETHPG0_STATUS_DHCP_CLIENT_ENABLED (0x00000010)
  2864. #define MPI2_ETHPG0_STATUS_IPV6_ENABLED (0x00000008)
  2865. #define MPI2_ETHPG0_STATUS_IPV4_ENABLED (0x00000004)
  2866. #define MPI2_ETHPG0_STATUS_IPV6_ADDRESSES (0x00000002)
  2867. #define MPI2_ETHPG0_STATUS_ETH_IF_ENABLED (0x00000001)
  2868. /*values for Ethernet Page 0 MediaState field */
  2869. #define MPI2_ETHPG0_MS_DUPLEX_MASK (0x80)
  2870. #define MPI2_ETHPG0_MS_HALF_DUPLEX (0x00)
  2871. #define MPI2_ETHPG0_MS_FULL_DUPLEX (0x80)
  2872. #define MPI2_ETHPG0_MS_CONNECT_SPEED_MASK (0x07)
  2873. #define MPI2_ETHPG0_MS_NOT_CONNECTED (0x00)
  2874. #define MPI2_ETHPG0_MS_10MBIT (0x01)
  2875. #define MPI2_ETHPG0_MS_100MBIT (0x02)
  2876. #define MPI2_ETHPG0_MS_1GBIT (0x03)
  2877. /*Ethernet Page 1 */
  2878. typedef struct _MPI2_CONFIG_PAGE_ETHERNET_1 {
  2879. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2880. Header; /*0x00 */
  2881. U32
  2882. Reserved0; /*0x08 */
  2883. U32
  2884. Flags; /*0x0C */
  2885. U8
  2886. MediaState; /*0x10 */
  2887. U8
  2888. Reserved1; /*0x11 */
  2889. U16
  2890. Reserved2; /*0x12 */
  2891. U8
  2892. MacAddress[6]; /*0x14 */
  2893. U8
  2894. Reserved3; /*0x1A */
  2895. U8
  2896. Reserved4; /*0x1B */
  2897. MPI2_ETHERNET_IP_ADDR
  2898. StaticIpAddress; /*0x1C */
  2899. MPI2_ETHERNET_IP_ADDR
  2900. StaticSubnetMask; /*0x2C */
  2901. MPI2_ETHERNET_IP_ADDR
  2902. StaticGatewayIpAddress; /*0x3C */
  2903. MPI2_ETHERNET_IP_ADDR
  2904. StaticDNS1IpAddress; /*0x4C */
  2905. MPI2_ETHERNET_IP_ADDR
  2906. StaticDNS2IpAddress; /*0x5C */
  2907. U32
  2908. Reserved5; /*0x6C */
  2909. U32
  2910. Reserved6; /*0x70 */
  2911. U32
  2912. Reserved7; /*0x74 */
  2913. U32
  2914. Reserved8; /*0x78 */
  2915. U8
  2916. HostName[MPI2_ETHERNET_HOST_NAME_LENGTH];/*0x7C */
  2917. } MPI2_CONFIG_PAGE_ETHERNET_1,
  2918. *PTR_MPI2_CONFIG_PAGE_ETHERNET_1,
  2919. Mpi2EthernetPage1_t, *pMpi2EthernetPage1_t;
  2920. #define MPI2_ETHERNETPAGE1_PAGEVERSION (0x00)
  2921. /*values for Ethernet Page 1 Flags field */
  2922. #define MPI2_ETHPG1_FLAG_SET_DEFAULT_IF (0x00000100)
  2923. #define MPI2_ETHPG1_FLAG_ENABLE_FW_DOWNLOAD (0x00000080)
  2924. #define MPI2_ETHPG1_FLAG_ENABLE_TELNET (0x00000040)
  2925. #define MPI2_ETHPG1_FLAG_ENABLE_SSH2 (0x00000020)
  2926. #define MPI2_ETHPG1_FLAG_ENABLE_DHCP_CLIENT (0x00000010)
  2927. #define MPI2_ETHPG1_FLAG_ENABLE_IPV6 (0x00000008)
  2928. #define MPI2_ETHPG1_FLAG_ENABLE_IPV4 (0x00000004)
  2929. #define MPI2_ETHPG1_FLAG_USE_IPV6_ADDRESSES (0x00000002)
  2930. #define MPI2_ETHPG1_FLAG_ENABLE_ETH_IF (0x00000001)
  2931. /*values for Ethernet Page 1 MediaState field */
  2932. #define MPI2_ETHPG1_MS_DUPLEX_MASK (0x80)
  2933. #define MPI2_ETHPG1_MS_HALF_DUPLEX (0x00)
  2934. #define MPI2_ETHPG1_MS_FULL_DUPLEX (0x80)
  2935. #define MPI2_ETHPG1_MS_DATA_RATE_MASK (0x07)
  2936. #define MPI2_ETHPG1_MS_DATA_RATE_AUTO (0x00)
  2937. #define MPI2_ETHPG1_MS_DATA_RATE_10MBIT (0x01)
  2938. #define MPI2_ETHPG1_MS_DATA_RATE_100MBIT (0x02)
  2939. #define MPI2_ETHPG1_MS_DATA_RATE_1GBIT (0x03)
  2940. /****************************************************************************
  2941. * Extended Manufacturing Config Pages
  2942. ****************************************************************************/
  2943. /*
  2944. *Generic structure to use for product-specific extended manufacturing pages
  2945. *(currently Extended Manufacturing Page 40 through Extended Manufacturing
  2946. *Page 60).
  2947. */
  2948. typedef struct _MPI2_CONFIG_PAGE_EXT_MAN_PS {
  2949. MPI2_CONFIG_EXTENDED_PAGE_HEADER
  2950. Header; /*0x00 */
  2951. U32
  2952. ProductSpecificInfo; /*0x08 */
  2953. } MPI2_CONFIG_PAGE_EXT_MAN_PS,
  2954. *PTR_MPI2_CONFIG_PAGE_EXT_MAN_PS,
  2955. Mpi2ExtManufacturingPagePS_t,
  2956. *pMpi2ExtManufacturingPagePS_t;
  2957. /*PageVersion should be provided by product-specific code */
  2958. #endif