regs.h 65 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564
  1. #define A_SG_CONTROL 0x0
  2. #define S_CONGMODE 29
  3. #define V_CONGMODE(x) ((x) << S_CONGMODE)
  4. #define F_CONGMODE V_CONGMODE(1U)
  5. #define S_TNLFLMODE 28
  6. #define V_TNLFLMODE(x) ((x) << S_TNLFLMODE)
  7. #define F_TNLFLMODE V_TNLFLMODE(1U)
  8. #define S_FATLPERREN 27
  9. #define V_FATLPERREN(x) ((x) << S_FATLPERREN)
  10. #define F_FATLPERREN V_FATLPERREN(1U)
  11. #define S_DROPPKT 20
  12. #define V_DROPPKT(x) ((x) << S_DROPPKT)
  13. #define F_DROPPKT V_DROPPKT(1U)
  14. #define S_EGRGENCTRL 19
  15. #define V_EGRGENCTRL(x) ((x) << S_EGRGENCTRL)
  16. #define F_EGRGENCTRL V_EGRGENCTRL(1U)
  17. #define S_USERSPACESIZE 14
  18. #define M_USERSPACESIZE 0x1f
  19. #define V_USERSPACESIZE(x) ((x) << S_USERSPACESIZE)
  20. #define S_HOSTPAGESIZE 11
  21. #define M_HOSTPAGESIZE 0x7
  22. #define V_HOSTPAGESIZE(x) ((x) << S_HOSTPAGESIZE)
  23. #define S_FLMODE 9
  24. #define V_FLMODE(x) ((x) << S_FLMODE)
  25. #define F_FLMODE V_FLMODE(1U)
  26. #define S_PKTSHIFT 6
  27. #define M_PKTSHIFT 0x7
  28. #define V_PKTSHIFT(x) ((x) << S_PKTSHIFT)
  29. #define S_ONEINTMULTQ 5
  30. #define V_ONEINTMULTQ(x) ((x) << S_ONEINTMULTQ)
  31. #define F_ONEINTMULTQ V_ONEINTMULTQ(1U)
  32. #define S_BIGENDIANINGRESS 2
  33. #define V_BIGENDIANINGRESS(x) ((x) << S_BIGENDIANINGRESS)
  34. #define F_BIGENDIANINGRESS V_BIGENDIANINGRESS(1U)
  35. #define S_ISCSICOALESCING 1
  36. #define V_ISCSICOALESCING(x) ((x) << S_ISCSICOALESCING)
  37. #define F_ISCSICOALESCING V_ISCSICOALESCING(1U)
  38. #define S_GLOBALENABLE 0
  39. #define V_GLOBALENABLE(x) ((x) << S_GLOBALENABLE)
  40. #define F_GLOBALENABLE V_GLOBALENABLE(1U)
  41. #define S_AVOIDCQOVFL 24
  42. #define V_AVOIDCQOVFL(x) ((x) << S_AVOIDCQOVFL)
  43. #define F_AVOIDCQOVFL V_AVOIDCQOVFL(1U)
  44. #define S_OPTONEINTMULTQ 23
  45. #define V_OPTONEINTMULTQ(x) ((x) << S_OPTONEINTMULTQ)
  46. #define F_OPTONEINTMULTQ V_OPTONEINTMULTQ(1U)
  47. #define S_CQCRDTCTRL 22
  48. #define V_CQCRDTCTRL(x) ((x) << S_CQCRDTCTRL)
  49. #define F_CQCRDTCTRL V_CQCRDTCTRL(1U)
  50. #define A_SG_KDOORBELL 0x4
  51. #define S_SELEGRCNTX 31
  52. #define V_SELEGRCNTX(x) ((x) << S_SELEGRCNTX)
  53. #define F_SELEGRCNTX V_SELEGRCNTX(1U)
  54. #define S_EGRCNTX 0
  55. #define M_EGRCNTX 0xffff
  56. #define V_EGRCNTX(x) ((x) << S_EGRCNTX)
  57. #define A_SG_GTS 0x8
  58. #define S_RSPQ 29
  59. #define M_RSPQ 0x7
  60. #define V_RSPQ(x) ((x) << S_RSPQ)
  61. #define G_RSPQ(x) (((x) >> S_RSPQ) & M_RSPQ)
  62. #define S_NEWTIMER 16
  63. #define M_NEWTIMER 0x1fff
  64. #define V_NEWTIMER(x) ((x) << S_NEWTIMER)
  65. #define S_NEWINDEX 0
  66. #define M_NEWINDEX 0xffff
  67. #define V_NEWINDEX(x) ((x) << S_NEWINDEX)
  68. #define A_SG_CONTEXT_CMD 0xc
  69. #define S_CONTEXT_CMD_OPCODE 28
  70. #define M_CONTEXT_CMD_OPCODE 0xf
  71. #define V_CONTEXT_CMD_OPCODE(x) ((x) << S_CONTEXT_CMD_OPCODE)
  72. #define S_CONTEXT_CMD_BUSY 27
  73. #define V_CONTEXT_CMD_BUSY(x) ((x) << S_CONTEXT_CMD_BUSY)
  74. #define F_CONTEXT_CMD_BUSY V_CONTEXT_CMD_BUSY(1U)
  75. #define S_CQ_CREDIT 20
  76. #define M_CQ_CREDIT 0x7f
  77. #define V_CQ_CREDIT(x) ((x) << S_CQ_CREDIT)
  78. #define G_CQ_CREDIT(x) (((x) >> S_CQ_CREDIT) & M_CQ_CREDIT)
  79. #define S_CQ 19
  80. #define V_CQ(x) ((x) << S_CQ)
  81. #define F_CQ V_CQ(1U)
  82. #define S_RESPONSEQ 18
  83. #define V_RESPONSEQ(x) ((x) << S_RESPONSEQ)
  84. #define F_RESPONSEQ V_RESPONSEQ(1U)
  85. #define S_EGRESS 17
  86. #define V_EGRESS(x) ((x) << S_EGRESS)
  87. #define F_EGRESS V_EGRESS(1U)
  88. #define S_FREELIST 16
  89. #define V_FREELIST(x) ((x) << S_FREELIST)
  90. #define F_FREELIST V_FREELIST(1U)
  91. #define S_CONTEXT 0
  92. #define M_CONTEXT 0xffff
  93. #define V_CONTEXT(x) ((x) << S_CONTEXT)
  94. #define G_CONTEXT(x) (((x) >> S_CONTEXT) & M_CONTEXT)
  95. #define A_SG_CONTEXT_DATA0 0x10
  96. #define A_SG_CONTEXT_DATA1 0x14
  97. #define A_SG_CONTEXT_DATA2 0x18
  98. #define A_SG_CONTEXT_DATA3 0x1c
  99. #define A_SG_CONTEXT_MASK0 0x20
  100. #define A_SG_CONTEXT_MASK1 0x24
  101. #define A_SG_CONTEXT_MASK2 0x28
  102. #define A_SG_CONTEXT_MASK3 0x2c
  103. #define A_SG_RSPQ_CREDIT_RETURN 0x30
  104. #define S_CREDITS 0
  105. #define M_CREDITS 0xffff
  106. #define V_CREDITS(x) ((x) << S_CREDITS)
  107. #define A_SG_DATA_INTR 0x34
  108. #define S_ERRINTR 31
  109. #define V_ERRINTR(x) ((x) << S_ERRINTR)
  110. #define F_ERRINTR V_ERRINTR(1U)
  111. #define A_SG_HI_DRB_HI_THRSH 0x38
  112. #define A_SG_HI_DRB_LO_THRSH 0x3c
  113. #define A_SG_LO_DRB_HI_THRSH 0x40
  114. #define A_SG_LO_DRB_LO_THRSH 0x44
  115. #define A_SG_RSPQ_FL_STATUS 0x4c
  116. #define S_RSPQ0DISABLED 8
  117. #define S_FL0EMPTY 16
  118. #define V_FL0EMPTY(x) ((x) << S_FL0EMPTY)
  119. #define F_FL0EMPTY V_FL0EMPTY(1U)
  120. #define A_SG_EGR_RCQ_DRB_THRSH 0x54
  121. #define S_HIRCQDRBTHRSH 16
  122. #define M_HIRCQDRBTHRSH 0x7ff
  123. #define V_HIRCQDRBTHRSH(x) ((x) << S_HIRCQDRBTHRSH)
  124. #define S_LORCQDRBTHRSH 0
  125. #define M_LORCQDRBTHRSH 0x7ff
  126. #define V_LORCQDRBTHRSH(x) ((x) << S_LORCQDRBTHRSH)
  127. #define A_SG_EGR_CNTX_BADDR 0x58
  128. #define A_SG_INT_CAUSE 0x5c
  129. #define S_HIRCQPARITYERROR 31
  130. #define V_HIRCQPARITYERROR(x) ((x) << S_HIRCQPARITYERROR)
  131. #define F_HIRCQPARITYERROR V_HIRCQPARITYERROR(1U)
  132. #define S_LORCQPARITYERROR 30
  133. #define V_LORCQPARITYERROR(x) ((x) << S_LORCQPARITYERROR)
  134. #define F_LORCQPARITYERROR V_LORCQPARITYERROR(1U)
  135. #define S_HIDRBPARITYERROR 29
  136. #define V_HIDRBPARITYERROR(x) ((x) << S_HIDRBPARITYERROR)
  137. #define F_HIDRBPARITYERROR V_HIDRBPARITYERROR(1U)
  138. #define S_LODRBPARITYERROR 28
  139. #define V_LODRBPARITYERROR(x) ((x) << S_LODRBPARITYERROR)
  140. #define F_LODRBPARITYERROR V_LODRBPARITYERROR(1U)
  141. #define S_FLPARITYERROR 22
  142. #define M_FLPARITYERROR 0x3f
  143. #define V_FLPARITYERROR(x) ((x) << S_FLPARITYERROR)
  144. #define G_FLPARITYERROR(x) (((x) >> S_FLPARITYERROR) & M_FLPARITYERROR)
  145. #define S_ITPARITYERROR 20
  146. #define M_ITPARITYERROR 0x3
  147. #define V_ITPARITYERROR(x) ((x) << S_ITPARITYERROR)
  148. #define G_ITPARITYERROR(x) (((x) >> S_ITPARITYERROR) & M_ITPARITYERROR)
  149. #define S_IRPARITYERROR 19
  150. #define V_IRPARITYERROR(x) ((x) << S_IRPARITYERROR)
  151. #define F_IRPARITYERROR V_IRPARITYERROR(1U)
  152. #define S_RCPARITYERROR 18
  153. #define V_RCPARITYERROR(x) ((x) << S_RCPARITYERROR)
  154. #define F_RCPARITYERROR V_RCPARITYERROR(1U)
  155. #define S_OCPARITYERROR 17
  156. #define V_OCPARITYERROR(x) ((x) << S_OCPARITYERROR)
  157. #define F_OCPARITYERROR V_OCPARITYERROR(1U)
  158. #define S_CPPARITYERROR 16
  159. #define V_CPPARITYERROR(x) ((x) << S_CPPARITYERROR)
  160. #define F_CPPARITYERROR V_CPPARITYERROR(1U)
  161. #define S_R_REQ_FRAMINGERROR 15
  162. #define V_R_REQ_FRAMINGERROR(x) ((x) << S_R_REQ_FRAMINGERROR)
  163. #define F_R_REQ_FRAMINGERROR V_R_REQ_FRAMINGERROR(1U)
  164. #define S_UC_REQ_FRAMINGERROR 14
  165. #define V_UC_REQ_FRAMINGERROR(x) ((x) << S_UC_REQ_FRAMINGERROR)
  166. #define F_UC_REQ_FRAMINGERROR V_UC_REQ_FRAMINGERROR(1U)
  167. #define S_HICTLDRBDROPERR 13
  168. #define V_HICTLDRBDROPERR(x) ((x) << S_HICTLDRBDROPERR)
  169. #define F_HICTLDRBDROPERR V_HICTLDRBDROPERR(1U)
  170. #define S_LOCTLDRBDROPERR 12
  171. #define V_LOCTLDRBDROPERR(x) ((x) << S_LOCTLDRBDROPERR)
  172. #define F_LOCTLDRBDROPERR V_LOCTLDRBDROPERR(1U)
  173. #define S_HIPIODRBDROPERR 11
  174. #define V_HIPIODRBDROPERR(x) ((x) << S_HIPIODRBDROPERR)
  175. #define F_HIPIODRBDROPERR V_HIPIODRBDROPERR(1U)
  176. #define S_LOPIODRBDROPERR 10
  177. #define V_LOPIODRBDROPERR(x) ((x) << S_LOPIODRBDROPERR)
  178. #define F_LOPIODRBDROPERR V_LOPIODRBDROPERR(1U)
  179. #define S_HIPRIORITYDBFULL 7
  180. #define V_HIPRIORITYDBFULL(x) ((x) << S_HIPRIORITYDBFULL)
  181. #define F_HIPRIORITYDBFULL V_HIPRIORITYDBFULL(1U)
  182. #define S_HIPRIORITYDBEMPTY 6
  183. #define V_HIPRIORITYDBEMPTY(x) ((x) << S_HIPRIORITYDBEMPTY)
  184. #define F_HIPRIORITYDBEMPTY V_HIPRIORITYDBEMPTY(1U)
  185. #define S_LOPRIORITYDBFULL 5
  186. #define V_LOPRIORITYDBFULL(x) ((x) << S_LOPRIORITYDBFULL)
  187. #define F_LOPRIORITYDBFULL V_LOPRIORITYDBFULL(1U)
  188. #define S_LOPRIORITYDBEMPTY 4
  189. #define V_LOPRIORITYDBEMPTY(x) ((x) << S_LOPRIORITYDBEMPTY)
  190. #define F_LOPRIORITYDBEMPTY V_LOPRIORITYDBEMPTY(1U)
  191. #define S_RSPQDISABLED 3
  192. #define V_RSPQDISABLED(x) ((x) << S_RSPQDISABLED)
  193. #define F_RSPQDISABLED V_RSPQDISABLED(1U)
  194. #define S_RSPQCREDITOVERFOW 2
  195. #define V_RSPQCREDITOVERFOW(x) ((x) << S_RSPQCREDITOVERFOW)
  196. #define F_RSPQCREDITOVERFOW V_RSPQCREDITOVERFOW(1U)
  197. #define S_FLEMPTY 1
  198. #define V_FLEMPTY(x) ((x) << S_FLEMPTY)
  199. #define F_FLEMPTY V_FLEMPTY(1U)
  200. #define A_SG_INT_ENABLE 0x60
  201. #define A_SG_CMDQ_CREDIT_TH 0x64
  202. #define S_TIMEOUT 8
  203. #define M_TIMEOUT 0xffffff
  204. #define V_TIMEOUT(x) ((x) << S_TIMEOUT)
  205. #define S_THRESHOLD 0
  206. #define M_THRESHOLD 0xff
  207. #define V_THRESHOLD(x) ((x) << S_THRESHOLD)
  208. #define A_SG_TIMER_TICK 0x68
  209. #define A_SG_CQ_CONTEXT_BADDR 0x6c
  210. #define A_SG_OCO_BASE 0x70
  211. #define S_BASE1 16
  212. #define M_BASE1 0xffff
  213. #define V_BASE1(x) ((x) << S_BASE1)
  214. #define A_SG_DRB_PRI_THRESH 0x74
  215. #define A_PCIX_INT_ENABLE 0x80
  216. #define S_MSIXPARERR 22
  217. #define M_MSIXPARERR 0x7
  218. #define V_MSIXPARERR(x) ((x) << S_MSIXPARERR)
  219. #define S_CFPARERR 18
  220. #define M_CFPARERR 0xf
  221. #define V_CFPARERR(x) ((x) << S_CFPARERR)
  222. #define S_RFPARERR 14
  223. #define M_RFPARERR 0xf
  224. #define V_RFPARERR(x) ((x) << S_RFPARERR)
  225. #define S_WFPARERR 12
  226. #define M_WFPARERR 0x3
  227. #define V_WFPARERR(x) ((x) << S_WFPARERR)
  228. #define S_PIOPARERR 11
  229. #define V_PIOPARERR(x) ((x) << S_PIOPARERR)
  230. #define F_PIOPARERR V_PIOPARERR(1U)
  231. #define S_DETUNCECCERR 10
  232. #define V_DETUNCECCERR(x) ((x) << S_DETUNCECCERR)
  233. #define F_DETUNCECCERR V_DETUNCECCERR(1U)
  234. #define S_DETCORECCERR 9
  235. #define V_DETCORECCERR(x) ((x) << S_DETCORECCERR)
  236. #define F_DETCORECCERR V_DETCORECCERR(1U)
  237. #define S_RCVSPLCMPERR 8
  238. #define V_RCVSPLCMPERR(x) ((x) << S_RCVSPLCMPERR)
  239. #define F_RCVSPLCMPERR V_RCVSPLCMPERR(1U)
  240. #define S_UNXSPLCMP 7
  241. #define V_UNXSPLCMP(x) ((x) << S_UNXSPLCMP)
  242. #define F_UNXSPLCMP V_UNXSPLCMP(1U)
  243. #define S_SPLCMPDIS 6
  244. #define V_SPLCMPDIS(x) ((x) << S_SPLCMPDIS)
  245. #define F_SPLCMPDIS V_SPLCMPDIS(1U)
  246. #define S_DETPARERR 5
  247. #define V_DETPARERR(x) ((x) << S_DETPARERR)
  248. #define F_DETPARERR V_DETPARERR(1U)
  249. #define S_SIGSYSERR 4
  250. #define V_SIGSYSERR(x) ((x) << S_SIGSYSERR)
  251. #define F_SIGSYSERR V_SIGSYSERR(1U)
  252. #define S_RCVMSTABT 3
  253. #define V_RCVMSTABT(x) ((x) << S_RCVMSTABT)
  254. #define F_RCVMSTABT V_RCVMSTABT(1U)
  255. #define S_RCVTARABT 2
  256. #define V_RCVTARABT(x) ((x) << S_RCVTARABT)
  257. #define F_RCVTARABT V_RCVTARABT(1U)
  258. #define S_SIGTARABT 1
  259. #define V_SIGTARABT(x) ((x) << S_SIGTARABT)
  260. #define F_SIGTARABT V_SIGTARABT(1U)
  261. #define S_MSTDETPARERR 0
  262. #define V_MSTDETPARERR(x) ((x) << S_MSTDETPARERR)
  263. #define F_MSTDETPARERR V_MSTDETPARERR(1U)
  264. #define A_PCIX_INT_CAUSE 0x84
  265. #define A_PCIX_CFG 0x88
  266. #define S_DMASTOPEN 19
  267. #define V_DMASTOPEN(x) ((x) << S_DMASTOPEN)
  268. #define F_DMASTOPEN V_DMASTOPEN(1U)
  269. #define S_CLIDECEN 18
  270. #define V_CLIDECEN(x) ((x) << S_CLIDECEN)
  271. #define F_CLIDECEN V_CLIDECEN(1U)
  272. #define A_PCIX_MODE 0x8c
  273. #define S_PCLKRANGE 6
  274. #define M_PCLKRANGE 0x3
  275. #define V_PCLKRANGE(x) ((x) << S_PCLKRANGE)
  276. #define G_PCLKRANGE(x) (((x) >> S_PCLKRANGE) & M_PCLKRANGE)
  277. #define S_PCIXINITPAT 2
  278. #define M_PCIXINITPAT 0xf
  279. #define V_PCIXINITPAT(x) ((x) << S_PCIXINITPAT)
  280. #define G_PCIXINITPAT(x) (((x) >> S_PCIXINITPAT) & M_PCIXINITPAT)
  281. #define S_64BIT 0
  282. #define V_64BIT(x) ((x) << S_64BIT)
  283. #define F_64BIT V_64BIT(1U)
  284. #define A_PCIE_INT_ENABLE 0x80
  285. #define S_BISTERR 15
  286. #define M_BISTERR 0xff
  287. #define V_BISTERR(x) ((x) << S_BISTERR)
  288. #define S_TXPARERR 18
  289. #define V_TXPARERR(x) ((x) << S_TXPARERR)
  290. #define F_TXPARERR V_TXPARERR(1U)
  291. #define S_RXPARERR 17
  292. #define V_RXPARERR(x) ((x) << S_RXPARERR)
  293. #define F_RXPARERR V_RXPARERR(1U)
  294. #define S_RETRYLUTPARERR 16
  295. #define V_RETRYLUTPARERR(x) ((x) << S_RETRYLUTPARERR)
  296. #define F_RETRYLUTPARERR V_RETRYLUTPARERR(1U)
  297. #define S_RETRYBUFPARERR 15
  298. #define V_RETRYBUFPARERR(x) ((x) << S_RETRYBUFPARERR)
  299. #define F_RETRYBUFPARERR V_RETRYBUFPARERR(1U)
  300. #define S_PCIE_MSIXPARERR 12
  301. #define M_PCIE_MSIXPARERR 0x7
  302. #define V_PCIE_MSIXPARERR(x) ((x) << S_PCIE_MSIXPARERR)
  303. #define S_PCIE_CFPARERR 11
  304. #define V_PCIE_CFPARERR(x) ((x) << S_PCIE_CFPARERR)
  305. #define F_PCIE_CFPARERR V_PCIE_CFPARERR(1U)
  306. #define S_PCIE_RFPARERR 10
  307. #define V_PCIE_RFPARERR(x) ((x) << S_PCIE_RFPARERR)
  308. #define F_PCIE_RFPARERR V_PCIE_RFPARERR(1U)
  309. #define S_PCIE_WFPARERR 9
  310. #define V_PCIE_WFPARERR(x) ((x) << S_PCIE_WFPARERR)
  311. #define F_PCIE_WFPARERR V_PCIE_WFPARERR(1U)
  312. #define S_PCIE_PIOPARERR 8
  313. #define V_PCIE_PIOPARERR(x) ((x) << S_PCIE_PIOPARERR)
  314. #define F_PCIE_PIOPARERR V_PCIE_PIOPARERR(1U)
  315. #define S_UNXSPLCPLERRC 7
  316. #define V_UNXSPLCPLERRC(x) ((x) << S_UNXSPLCPLERRC)
  317. #define F_UNXSPLCPLERRC V_UNXSPLCPLERRC(1U)
  318. #define S_UNXSPLCPLERRR 6
  319. #define V_UNXSPLCPLERRR(x) ((x) << S_UNXSPLCPLERRR)
  320. #define F_UNXSPLCPLERRR V_UNXSPLCPLERRR(1U)
  321. #define S_PEXERR 0
  322. #define V_PEXERR(x) ((x) << S_PEXERR)
  323. #define F_PEXERR V_PEXERR(1U)
  324. #define A_PCIE_INT_CAUSE 0x84
  325. #define S_PCIE_DMASTOPEN 24
  326. #define V_PCIE_DMASTOPEN(x) ((x) << S_PCIE_DMASTOPEN)
  327. #define F_PCIE_DMASTOPEN V_PCIE_DMASTOPEN(1U)
  328. #define A_PCIE_CFG 0x88
  329. #define S_ENABLELINKDWNDRST 21
  330. #define V_ENABLELINKDWNDRST(x) ((x) << S_ENABLELINKDWNDRST)
  331. #define F_ENABLELINKDWNDRST V_ENABLELINKDWNDRST(1U)
  332. #define S_ENABLELINKDOWNRST 20
  333. #define V_ENABLELINKDOWNRST(x) ((x) << S_ENABLELINKDOWNRST)
  334. #define F_ENABLELINKDOWNRST V_ENABLELINKDOWNRST(1U)
  335. #define S_PCIE_CLIDECEN 16
  336. #define V_PCIE_CLIDECEN(x) ((x) << S_PCIE_CLIDECEN)
  337. #define F_PCIE_CLIDECEN V_PCIE_CLIDECEN(1U)
  338. #define S_CRSTWRMMODE 0
  339. #define V_CRSTWRMMODE(x) ((x) << S_CRSTWRMMODE)
  340. #define F_CRSTWRMMODE V_CRSTWRMMODE(1U)
  341. #define A_PCIE_MODE 0x8c
  342. #define S_NUMFSTTRNSEQRX 10
  343. #define M_NUMFSTTRNSEQRX 0xff
  344. #define V_NUMFSTTRNSEQRX(x) ((x) << S_NUMFSTTRNSEQRX)
  345. #define G_NUMFSTTRNSEQRX(x) (((x) >> S_NUMFSTTRNSEQRX) & M_NUMFSTTRNSEQRX)
  346. #define A_PCIE_PEX_CTRL0 0x98
  347. #define S_NUMFSTTRNSEQ 22
  348. #define M_NUMFSTTRNSEQ 0xff
  349. #define V_NUMFSTTRNSEQ(x) ((x) << S_NUMFSTTRNSEQ)
  350. #define G_NUMFSTTRNSEQ(x) (((x) >> S_NUMFSTTRNSEQ) & M_NUMFSTTRNSEQ)
  351. #define S_REPLAYLMT 2
  352. #define M_REPLAYLMT 0xfffff
  353. #define V_REPLAYLMT(x) ((x) << S_REPLAYLMT)
  354. #define A_PCIE_PEX_CTRL1 0x9c
  355. #define S_T3A_ACKLAT 0
  356. #define M_T3A_ACKLAT 0x7ff
  357. #define V_T3A_ACKLAT(x) ((x) << S_T3A_ACKLAT)
  358. #define S_ACKLAT 0
  359. #define M_ACKLAT 0x1fff
  360. #define V_ACKLAT(x) ((x) << S_ACKLAT)
  361. #define A_PCIE_PEX_ERR 0xa4
  362. #define A_T3DBG_GPIO_EN 0xd0
  363. #define S_GPIO11_OEN 27
  364. #define V_GPIO11_OEN(x) ((x) << S_GPIO11_OEN)
  365. #define F_GPIO11_OEN V_GPIO11_OEN(1U)
  366. #define S_GPIO10_OEN 26
  367. #define V_GPIO10_OEN(x) ((x) << S_GPIO10_OEN)
  368. #define F_GPIO10_OEN V_GPIO10_OEN(1U)
  369. #define S_GPIO7_OEN 23
  370. #define V_GPIO7_OEN(x) ((x) << S_GPIO7_OEN)
  371. #define F_GPIO7_OEN V_GPIO7_OEN(1U)
  372. #define S_GPIO6_OEN 22
  373. #define V_GPIO6_OEN(x) ((x) << S_GPIO6_OEN)
  374. #define F_GPIO6_OEN V_GPIO6_OEN(1U)
  375. #define S_GPIO5_OEN 21
  376. #define V_GPIO5_OEN(x) ((x) << S_GPIO5_OEN)
  377. #define F_GPIO5_OEN V_GPIO5_OEN(1U)
  378. #define S_GPIO4_OEN 20
  379. #define V_GPIO4_OEN(x) ((x) << S_GPIO4_OEN)
  380. #define F_GPIO4_OEN V_GPIO4_OEN(1U)
  381. #define S_GPIO2_OEN 18
  382. #define V_GPIO2_OEN(x) ((x) << S_GPIO2_OEN)
  383. #define F_GPIO2_OEN V_GPIO2_OEN(1U)
  384. #define S_GPIO1_OEN 17
  385. #define V_GPIO1_OEN(x) ((x) << S_GPIO1_OEN)
  386. #define F_GPIO1_OEN V_GPIO1_OEN(1U)
  387. #define S_GPIO0_OEN 16
  388. #define V_GPIO0_OEN(x) ((x) << S_GPIO0_OEN)
  389. #define F_GPIO0_OEN V_GPIO0_OEN(1U)
  390. #define S_GPIO10_OUT_VAL 10
  391. #define V_GPIO10_OUT_VAL(x) ((x) << S_GPIO10_OUT_VAL)
  392. #define F_GPIO10_OUT_VAL V_GPIO10_OUT_VAL(1U)
  393. #define S_GPIO7_OUT_VAL 7
  394. #define V_GPIO7_OUT_VAL(x) ((x) << S_GPIO7_OUT_VAL)
  395. #define F_GPIO7_OUT_VAL V_GPIO7_OUT_VAL(1U)
  396. #define S_GPIO6_OUT_VAL 6
  397. #define V_GPIO6_OUT_VAL(x) ((x) << S_GPIO6_OUT_VAL)
  398. #define F_GPIO6_OUT_VAL V_GPIO6_OUT_VAL(1U)
  399. #define S_GPIO5_OUT_VAL 5
  400. #define V_GPIO5_OUT_VAL(x) ((x) << S_GPIO5_OUT_VAL)
  401. #define F_GPIO5_OUT_VAL V_GPIO5_OUT_VAL(1U)
  402. #define S_GPIO4_OUT_VAL 4
  403. #define V_GPIO4_OUT_VAL(x) ((x) << S_GPIO4_OUT_VAL)
  404. #define F_GPIO4_OUT_VAL V_GPIO4_OUT_VAL(1U)
  405. #define S_GPIO2_OUT_VAL 2
  406. #define V_GPIO2_OUT_VAL(x) ((x) << S_GPIO2_OUT_VAL)
  407. #define F_GPIO2_OUT_VAL V_GPIO2_OUT_VAL(1U)
  408. #define S_GPIO1_OUT_VAL 1
  409. #define V_GPIO1_OUT_VAL(x) ((x) << S_GPIO1_OUT_VAL)
  410. #define F_GPIO1_OUT_VAL V_GPIO1_OUT_VAL(1U)
  411. #define S_GPIO0_OUT_VAL 0
  412. #define V_GPIO0_OUT_VAL(x) ((x) << S_GPIO0_OUT_VAL)
  413. #define F_GPIO0_OUT_VAL V_GPIO0_OUT_VAL(1U)
  414. #define A_T3DBG_INT_ENABLE 0xd8
  415. #define S_GPIO11 11
  416. #define V_GPIO11(x) ((x) << S_GPIO11)
  417. #define F_GPIO11 V_GPIO11(1U)
  418. #define S_GPIO10 10
  419. #define V_GPIO10(x) ((x) << S_GPIO10)
  420. #define F_GPIO10 V_GPIO10(1U)
  421. #define S_GPIO9 9
  422. #define V_GPIO9(x) ((x) << S_GPIO9)
  423. #define F_GPIO9 V_GPIO9(1U)
  424. #define S_GPIO7 7
  425. #define V_GPIO7(x) ((x) << S_GPIO7)
  426. #define F_GPIO7 V_GPIO7(1U)
  427. #define S_GPIO6 6
  428. #define V_GPIO6(x) ((x) << S_GPIO6)
  429. #define F_GPIO6 V_GPIO6(1U)
  430. #define S_GPIO5 5
  431. #define V_GPIO5(x) ((x) << S_GPIO5)
  432. #define F_GPIO5 V_GPIO5(1U)
  433. #define S_GPIO4 4
  434. #define V_GPIO4(x) ((x) << S_GPIO4)
  435. #define F_GPIO4 V_GPIO4(1U)
  436. #define S_GPIO3 3
  437. #define V_GPIO3(x) ((x) << S_GPIO3)
  438. #define F_GPIO3 V_GPIO3(1U)
  439. #define S_GPIO2 2
  440. #define V_GPIO2(x) ((x) << S_GPIO2)
  441. #define F_GPIO2 V_GPIO2(1U)
  442. #define S_GPIO1 1
  443. #define V_GPIO1(x) ((x) << S_GPIO1)
  444. #define F_GPIO1 V_GPIO1(1U)
  445. #define S_GPIO0 0
  446. #define V_GPIO0(x) ((x) << S_GPIO0)
  447. #define F_GPIO0 V_GPIO0(1U)
  448. #define A_T3DBG_INT_CAUSE 0xdc
  449. #define A_T3DBG_GPIO_ACT_LOW 0xf0
  450. #define MC7_PMRX_BASE_ADDR 0x100
  451. #define A_MC7_CFG 0x100
  452. #define S_IFEN 13
  453. #define V_IFEN(x) ((x) << S_IFEN)
  454. #define F_IFEN V_IFEN(1U)
  455. #define S_TERM150 11
  456. #define V_TERM150(x) ((x) << S_TERM150)
  457. #define F_TERM150 V_TERM150(1U)
  458. #define S_SLOW 10
  459. #define V_SLOW(x) ((x) << S_SLOW)
  460. #define F_SLOW V_SLOW(1U)
  461. #define S_WIDTH 8
  462. #define M_WIDTH 0x3
  463. #define V_WIDTH(x) ((x) << S_WIDTH)
  464. #define G_WIDTH(x) (((x) >> S_WIDTH) & M_WIDTH)
  465. #define S_BKS 6
  466. #define V_BKS(x) ((x) << S_BKS)
  467. #define F_BKS V_BKS(1U)
  468. #define S_ORG 5
  469. #define V_ORG(x) ((x) << S_ORG)
  470. #define F_ORG V_ORG(1U)
  471. #define S_DEN 2
  472. #define M_DEN 0x7
  473. #define V_DEN(x) ((x) << S_DEN)
  474. #define G_DEN(x) (((x) >> S_DEN) & M_DEN)
  475. #define S_RDY 1
  476. #define V_RDY(x) ((x) << S_RDY)
  477. #define F_RDY V_RDY(1U)
  478. #define S_CLKEN 0
  479. #define V_CLKEN(x) ((x) << S_CLKEN)
  480. #define F_CLKEN V_CLKEN(1U)
  481. #define A_MC7_MODE 0x104
  482. #define S_BUSY 31
  483. #define V_BUSY(x) ((x) << S_BUSY)
  484. #define F_BUSY V_BUSY(1U)
  485. #define A_MC7_EXT_MODE1 0x108
  486. #define A_MC7_EXT_MODE2 0x10c
  487. #define A_MC7_EXT_MODE3 0x110
  488. #define A_MC7_PRE 0x114
  489. #define A_MC7_REF 0x118
  490. #define S_PREREFDIV 1
  491. #define M_PREREFDIV 0x3fff
  492. #define V_PREREFDIV(x) ((x) << S_PREREFDIV)
  493. #define S_PERREFEN 0
  494. #define V_PERREFEN(x) ((x) << S_PERREFEN)
  495. #define F_PERREFEN V_PERREFEN(1U)
  496. #define A_MC7_DLL 0x11c
  497. #define S_DLLENB 1
  498. #define V_DLLENB(x) ((x) << S_DLLENB)
  499. #define F_DLLENB V_DLLENB(1U)
  500. #define S_DLLRST 0
  501. #define V_DLLRST(x) ((x) << S_DLLRST)
  502. #define F_DLLRST V_DLLRST(1U)
  503. #define A_MC7_PARM 0x120
  504. #define S_ACTTOPREDLY 26
  505. #define M_ACTTOPREDLY 0xf
  506. #define V_ACTTOPREDLY(x) ((x) << S_ACTTOPREDLY)
  507. #define S_ACTTORDWRDLY 23
  508. #define M_ACTTORDWRDLY 0x7
  509. #define V_ACTTORDWRDLY(x) ((x) << S_ACTTORDWRDLY)
  510. #define S_PRECYC 20
  511. #define M_PRECYC 0x7
  512. #define V_PRECYC(x) ((x) << S_PRECYC)
  513. #define S_REFCYC 13
  514. #define M_REFCYC 0x7f
  515. #define V_REFCYC(x) ((x) << S_REFCYC)
  516. #define S_BKCYC 8
  517. #define M_BKCYC 0x1f
  518. #define V_BKCYC(x) ((x) << S_BKCYC)
  519. #define S_WRTORDDLY 4
  520. #define M_WRTORDDLY 0xf
  521. #define V_WRTORDDLY(x) ((x) << S_WRTORDDLY)
  522. #define S_RDTOWRDLY 0
  523. #define M_RDTOWRDLY 0xf
  524. #define V_RDTOWRDLY(x) ((x) << S_RDTOWRDLY)
  525. #define A_MC7_CAL 0x128
  526. #define S_CAL_FAULT 30
  527. #define V_CAL_FAULT(x) ((x) << S_CAL_FAULT)
  528. #define F_CAL_FAULT V_CAL_FAULT(1U)
  529. #define S_SGL_CAL_EN 20
  530. #define V_SGL_CAL_EN(x) ((x) << S_SGL_CAL_EN)
  531. #define F_SGL_CAL_EN V_SGL_CAL_EN(1U)
  532. #define A_MC7_ERR_ADDR 0x12c
  533. #define A_MC7_ECC 0x130
  534. #define S_ECCCHKEN 1
  535. #define V_ECCCHKEN(x) ((x) << S_ECCCHKEN)
  536. #define F_ECCCHKEN V_ECCCHKEN(1U)
  537. #define S_ECCGENEN 0
  538. #define V_ECCGENEN(x) ((x) << S_ECCGENEN)
  539. #define F_ECCGENEN V_ECCGENEN(1U)
  540. #define A_MC7_CE_ADDR 0x134
  541. #define A_MC7_CE_DATA0 0x138
  542. #define A_MC7_CE_DATA1 0x13c
  543. #define A_MC7_CE_DATA2 0x140
  544. #define S_DATA 0
  545. #define M_DATA 0xff
  546. #define G_DATA(x) (((x) >> S_DATA) & M_DATA)
  547. #define A_MC7_UE_ADDR 0x144
  548. #define A_MC7_UE_DATA0 0x148
  549. #define A_MC7_UE_DATA1 0x14c
  550. #define A_MC7_UE_DATA2 0x150
  551. #define A_MC7_BD_ADDR 0x154
  552. #define S_ADDR 3
  553. #define M_ADDR 0x1fffffff
  554. #define A_MC7_BD_DATA0 0x158
  555. #define A_MC7_BD_DATA1 0x15c
  556. #define A_MC7_BD_OP 0x164
  557. #define S_OP 0
  558. #define V_OP(x) ((x) << S_OP)
  559. #define F_OP V_OP(1U)
  560. #define A_MC7_BIST_ADDR_BEG 0x168
  561. #define A_MC7_BIST_ADDR_END 0x16c
  562. #define A_MC7_BIST_DATA 0x170
  563. #define A_MC7_BIST_OP 0x174
  564. #define S_CONT 3
  565. #define V_CONT(x) ((x) << S_CONT)
  566. #define F_CONT V_CONT(1U)
  567. #define A_MC7_INT_ENABLE 0x178
  568. #define S_AE 17
  569. #define V_AE(x) ((x) << S_AE)
  570. #define F_AE V_AE(1U)
  571. #define S_PE 2
  572. #define M_PE 0x7fff
  573. #define V_PE(x) ((x) << S_PE)
  574. #define G_PE(x) (((x) >> S_PE) & M_PE)
  575. #define S_UE 1
  576. #define V_UE(x) ((x) << S_UE)
  577. #define F_UE V_UE(1U)
  578. #define S_CE 0
  579. #define V_CE(x) ((x) << S_CE)
  580. #define F_CE V_CE(1U)
  581. #define A_MC7_INT_CAUSE 0x17c
  582. #define MC7_PMTX_BASE_ADDR 0x180
  583. #define MC7_CM_BASE_ADDR 0x200
  584. #define A_CIM_BOOT_CFG 0x280
  585. #define S_BOOTADDR 2
  586. #define M_BOOTADDR 0x3fffffff
  587. #define V_BOOTADDR(x) ((x) << S_BOOTADDR)
  588. #define A_CIM_SDRAM_BASE_ADDR 0x28c
  589. #define A_CIM_SDRAM_ADDR_SIZE 0x290
  590. #define A_CIM_HOST_INT_ENABLE 0x298
  591. #define S_DTAGPARERR 28
  592. #define V_DTAGPARERR(x) ((x) << S_DTAGPARERR)
  593. #define F_DTAGPARERR V_DTAGPARERR(1U)
  594. #define S_ITAGPARERR 27
  595. #define V_ITAGPARERR(x) ((x) << S_ITAGPARERR)
  596. #define F_ITAGPARERR V_ITAGPARERR(1U)
  597. #define S_IBQTPPARERR 26
  598. #define V_IBQTPPARERR(x) ((x) << S_IBQTPPARERR)
  599. #define F_IBQTPPARERR V_IBQTPPARERR(1U)
  600. #define S_IBQULPPARERR 25
  601. #define V_IBQULPPARERR(x) ((x) << S_IBQULPPARERR)
  602. #define F_IBQULPPARERR V_IBQULPPARERR(1U)
  603. #define S_IBQSGEHIPARERR 24
  604. #define V_IBQSGEHIPARERR(x) ((x) << S_IBQSGEHIPARERR)
  605. #define F_IBQSGEHIPARERR V_IBQSGEHIPARERR(1U)
  606. #define S_IBQSGELOPARERR 23
  607. #define V_IBQSGELOPARERR(x) ((x) << S_IBQSGELOPARERR)
  608. #define F_IBQSGELOPARERR V_IBQSGELOPARERR(1U)
  609. #define S_OBQULPLOPARERR 22
  610. #define V_OBQULPLOPARERR(x) ((x) << S_OBQULPLOPARERR)
  611. #define F_OBQULPLOPARERR V_OBQULPLOPARERR(1U)
  612. #define S_OBQULPHIPARERR 21
  613. #define V_OBQULPHIPARERR(x) ((x) << S_OBQULPHIPARERR)
  614. #define F_OBQULPHIPARERR V_OBQULPHIPARERR(1U)
  615. #define S_OBQSGEPARERR 20
  616. #define V_OBQSGEPARERR(x) ((x) << S_OBQSGEPARERR)
  617. #define F_OBQSGEPARERR V_OBQSGEPARERR(1U)
  618. #define S_DCACHEPARERR 19
  619. #define V_DCACHEPARERR(x) ((x) << S_DCACHEPARERR)
  620. #define F_DCACHEPARERR V_DCACHEPARERR(1U)
  621. #define S_ICACHEPARERR 18
  622. #define V_ICACHEPARERR(x) ((x) << S_ICACHEPARERR)
  623. #define F_ICACHEPARERR V_ICACHEPARERR(1U)
  624. #define S_DRAMPARERR 17
  625. #define V_DRAMPARERR(x) ((x) << S_DRAMPARERR)
  626. #define F_DRAMPARERR V_DRAMPARERR(1U)
  627. #define A_CIM_HOST_INT_CAUSE 0x29c
  628. #define S_BLKWRPLINT 12
  629. #define V_BLKWRPLINT(x) ((x) << S_BLKWRPLINT)
  630. #define F_BLKWRPLINT V_BLKWRPLINT(1U)
  631. #define S_BLKRDPLINT 11
  632. #define V_BLKRDPLINT(x) ((x) << S_BLKRDPLINT)
  633. #define F_BLKRDPLINT V_BLKRDPLINT(1U)
  634. #define S_BLKWRCTLINT 10
  635. #define V_BLKWRCTLINT(x) ((x) << S_BLKWRCTLINT)
  636. #define F_BLKWRCTLINT V_BLKWRCTLINT(1U)
  637. #define S_BLKRDCTLINT 9
  638. #define V_BLKRDCTLINT(x) ((x) << S_BLKRDCTLINT)
  639. #define F_BLKRDCTLINT V_BLKRDCTLINT(1U)
  640. #define S_BLKWRFLASHINT 8
  641. #define V_BLKWRFLASHINT(x) ((x) << S_BLKWRFLASHINT)
  642. #define F_BLKWRFLASHINT V_BLKWRFLASHINT(1U)
  643. #define S_BLKRDFLASHINT 7
  644. #define V_BLKRDFLASHINT(x) ((x) << S_BLKRDFLASHINT)
  645. #define F_BLKRDFLASHINT V_BLKRDFLASHINT(1U)
  646. #define S_SGLWRFLASHINT 6
  647. #define V_SGLWRFLASHINT(x) ((x) << S_SGLWRFLASHINT)
  648. #define F_SGLWRFLASHINT V_SGLWRFLASHINT(1U)
  649. #define S_WRBLKFLASHINT 5
  650. #define V_WRBLKFLASHINT(x) ((x) << S_WRBLKFLASHINT)
  651. #define F_WRBLKFLASHINT V_WRBLKFLASHINT(1U)
  652. #define S_BLKWRBOOTINT 4
  653. #define V_BLKWRBOOTINT(x) ((x) << S_BLKWRBOOTINT)
  654. #define F_BLKWRBOOTINT V_BLKWRBOOTINT(1U)
  655. #define S_FLASHRANGEINT 2
  656. #define V_FLASHRANGEINT(x) ((x) << S_FLASHRANGEINT)
  657. #define F_FLASHRANGEINT V_FLASHRANGEINT(1U)
  658. #define S_SDRAMRANGEINT 1
  659. #define V_SDRAMRANGEINT(x) ((x) << S_SDRAMRANGEINT)
  660. #define F_SDRAMRANGEINT V_SDRAMRANGEINT(1U)
  661. #define S_RSVDSPACEINT 0
  662. #define V_RSVDSPACEINT(x) ((x) << S_RSVDSPACEINT)
  663. #define F_RSVDSPACEINT V_RSVDSPACEINT(1U)
  664. #define A_CIM_HOST_ACC_CTRL 0x2b0
  665. #define S_HOSTBUSY 17
  666. #define V_HOSTBUSY(x) ((x) << S_HOSTBUSY)
  667. #define F_HOSTBUSY V_HOSTBUSY(1U)
  668. #define A_CIM_HOST_ACC_DATA 0x2b4
  669. #define A_CIM_IBQ_DBG_CFG 0x2c0
  670. #define S_IBQDBGADDR 16
  671. #define M_IBQDBGADDR 0x1ff
  672. #define V_IBQDBGADDR(x) ((x) << S_IBQDBGADDR)
  673. #define G_IBQDBGADDR(x) (((x) >> S_IBQDBGADDR) & M_IBQDBGADDR)
  674. #define S_IBQDBGQID 3
  675. #define M_IBQDBGQID 0x3
  676. #define V_IBQDBGQID(x) ((x) << S_IBQDBGQID)
  677. #define G_IBQDBGQID(x) (((x) >> S_IBQDBGQID) & M_IBQDBGQID)
  678. #define S_IBQDBGWR 2
  679. #define V_IBQDBGWR(x) ((x) << S_IBQDBGWR)
  680. #define F_IBQDBGWR V_IBQDBGWR(1U)
  681. #define S_IBQDBGBUSY 1
  682. #define V_IBQDBGBUSY(x) ((x) << S_IBQDBGBUSY)
  683. #define F_IBQDBGBUSY V_IBQDBGBUSY(1U)
  684. #define S_IBQDBGEN 0
  685. #define V_IBQDBGEN(x) ((x) << S_IBQDBGEN)
  686. #define F_IBQDBGEN V_IBQDBGEN(1U)
  687. #define A_CIM_IBQ_DBG_DATA 0x2c8
  688. #define A_TP_IN_CONFIG 0x300
  689. #define S_RXFBARBPRIO 25
  690. #define V_RXFBARBPRIO(x) ((x) << S_RXFBARBPRIO)
  691. #define F_RXFBARBPRIO V_RXFBARBPRIO(1U)
  692. #define S_TXFBARBPRIO 24
  693. #define V_TXFBARBPRIO(x) ((x) << S_TXFBARBPRIO)
  694. #define F_TXFBARBPRIO V_TXFBARBPRIO(1U)
  695. #define S_NICMODE 14
  696. #define V_NICMODE(x) ((x) << S_NICMODE)
  697. #define F_NICMODE V_NICMODE(1U)
  698. #define S_IPV6ENABLE 15
  699. #define V_IPV6ENABLE(x) ((x) << S_IPV6ENABLE)
  700. #define F_IPV6ENABLE V_IPV6ENABLE(1U)
  701. #define A_TP_OUT_CONFIG 0x304
  702. #define S_VLANEXTRACTIONENABLE 12
  703. #define A_TP_GLOBAL_CONFIG 0x308
  704. #define S_TXPACINGENABLE 24
  705. #define V_TXPACINGENABLE(x) ((x) << S_TXPACINGENABLE)
  706. #define F_TXPACINGENABLE V_TXPACINGENABLE(1U)
  707. #define S_PATHMTU 15
  708. #define V_PATHMTU(x) ((x) << S_PATHMTU)
  709. #define F_PATHMTU V_PATHMTU(1U)
  710. #define S_IPCHECKSUMOFFLOAD 13
  711. #define V_IPCHECKSUMOFFLOAD(x) ((x) << S_IPCHECKSUMOFFLOAD)
  712. #define F_IPCHECKSUMOFFLOAD V_IPCHECKSUMOFFLOAD(1U)
  713. #define S_UDPCHECKSUMOFFLOAD 12
  714. #define V_UDPCHECKSUMOFFLOAD(x) ((x) << S_UDPCHECKSUMOFFLOAD)
  715. #define F_UDPCHECKSUMOFFLOAD V_UDPCHECKSUMOFFLOAD(1U)
  716. #define S_TCPCHECKSUMOFFLOAD 11
  717. #define V_TCPCHECKSUMOFFLOAD(x) ((x) << S_TCPCHECKSUMOFFLOAD)
  718. #define F_TCPCHECKSUMOFFLOAD V_TCPCHECKSUMOFFLOAD(1U)
  719. #define S_IPTTL 0
  720. #define M_IPTTL 0xff
  721. #define V_IPTTL(x) ((x) << S_IPTTL)
  722. #define A_TP_CMM_MM_BASE 0x314
  723. #define A_TP_CMM_TIMER_BASE 0x318
  724. #define S_CMTIMERMAXNUM 28
  725. #define M_CMTIMERMAXNUM 0x3
  726. #define V_CMTIMERMAXNUM(x) ((x) << S_CMTIMERMAXNUM)
  727. #define A_TP_PMM_SIZE 0x31c
  728. #define A_TP_PMM_TX_BASE 0x320
  729. #define A_TP_PMM_RX_BASE 0x328
  730. #define A_TP_PMM_RX_PAGE_SIZE 0x32c
  731. #define A_TP_PMM_RX_MAX_PAGE 0x330
  732. #define A_TP_PMM_TX_PAGE_SIZE 0x334
  733. #define A_TP_PMM_TX_MAX_PAGE 0x338
  734. #define A_TP_TCP_OPTIONS 0x340
  735. #define S_MTUDEFAULT 16
  736. #define M_MTUDEFAULT 0xffff
  737. #define V_MTUDEFAULT(x) ((x) << S_MTUDEFAULT)
  738. #define S_MTUENABLE 10
  739. #define V_MTUENABLE(x) ((x) << S_MTUENABLE)
  740. #define F_MTUENABLE V_MTUENABLE(1U)
  741. #define S_SACKRX 8
  742. #define V_SACKRX(x) ((x) << S_SACKRX)
  743. #define F_SACKRX V_SACKRX(1U)
  744. #define S_SACKMODE 4
  745. #define M_SACKMODE 0x3
  746. #define V_SACKMODE(x) ((x) << S_SACKMODE)
  747. #define S_WINDOWSCALEMODE 2
  748. #define M_WINDOWSCALEMODE 0x3
  749. #define V_WINDOWSCALEMODE(x) ((x) << S_WINDOWSCALEMODE)
  750. #define S_TIMESTAMPSMODE 0
  751. #define M_TIMESTAMPSMODE 0x3
  752. #define V_TIMESTAMPSMODE(x) ((x) << S_TIMESTAMPSMODE)
  753. #define A_TP_DACK_CONFIG 0x344
  754. #define S_AUTOSTATE3 30
  755. #define M_AUTOSTATE3 0x3
  756. #define V_AUTOSTATE3(x) ((x) << S_AUTOSTATE3)
  757. #define S_AUTOSTATE2 28
  758. #define M_AUTOSTATE2 0x3
  759. #define V_AUTOSTATE2(x) ((x) << S_AUTOSTATE2)
  760. #define S_AUTOSTATE1 26
  761. #define M_AUTOSTATE1 0x3
  762. #define V_AUTOSTATE1(x) ((x) << S_AUTOSTATE1)
  763. #define S_BYTETHRESHOLD 5
  764. #define M_BYTETHRESHOLD 0xfffff
  765. #define V_BYTETHRESHOLD(x) ((x) << S_BYTETHRESHOLD)
  766. #define S_MSSTHRESHOLD 3
  767. #define M_MSSTHRESHOLD 0x3
  768. #define V_MSSTHRESHOLD(x) ((x) << S_MSSTHRESHOLD)
  769. #define S_AUTOCAREFUL 2
  770. #define V_AUTOCAREFUL(x) ((x) << S_AUTOCAREFUL)
  771. #define F_AUTOCAREFUL V_AUTOCAREFUL(1U)
  772. #define S_AUTOENABLE 1
  773. #define V_AUTOENABLE(x) ((x) << S_AUTOENABLE)
  774. #define F_AUTOENABLE V_AUTOENABLE(1U)
  775. #define S_DACK_MODE 0
  776. #define V_DACK_MODE(x) ((x) << S_DACK_MODE)
  777. #define F_DACK_MODE V_DACK_MODE(1U)
  778. #define A_TP_PC_CONFIG 0x348
  779. #define S_TXTOSQUEUEMAPMODE 26
  780. #define V_TXTOSQUEUEMAPMODE(x) ((x) << S_TXTOSQUEUEMAPMODE)
  781. #define F_TXTOSQUEUEMAPMODE V_TXTOSQUEUEMAPMODE(1U)
  782. #define S_ENABLEEPCMDAFULL 23
  783. #define V_ENABLEEPCMDAFULL(x) ((x) << S_ENABLEEPCMDAFULL)
  784. #define F_ENABLEEPCMDAFULL V_ENABLEEPCMDAFULL(1U)
  785. #define S_MODULATEUNIONMODE 22
  786. #define V_MODULATEUNIONMODE(x) ((x) << S_MODULATEUNIONMODE)
  787. #define F_MODULATEUNIONMODE V_MODULATEUNIONMODE(1U)
  788. #define S_TXDEFERENABLE 20
  789. #define V_TXDEFERENABLE(x) ((x) << S_TXDEFERENABLE)
  790. #define F_TXDEFERENABLE V_TXDEFERENABLE(1U)
  791. #define S_RXCONGESTIONMODE 19
  792. #define V_RXCONGESTIONMODE(x) ((x) << S_RXCONGESTIONMODE)
  793. #define F_RXCONGESTIONMODE V_RXCONGESTIONMODE(1U)
  794. #define S_HEARBEATDACK 16
  795. #define V_HEARBEATDACK(x) ((x) << S_HEARBEATDACK)
  796. #define F_HEARBEATDACK V_HEARBEATDACK(1U)
  797. #define S_TXCONGESTIONMODE 15
  798. #define V_TXCONGESTIONMODE(x) ((x) << S_TXCONGESTIONMODE)
  799. #define F_TXCONGESTIONMODE V_TXCONGESTIONMODE(1U)
  800. #define S_ENABLEOCSPIFULL 30
  801. #define V_ENABLEOCSPIFULL(x) ((x) << S_ENABLEOCSPIFULL)
  802. #define F_ENABLEOCSPIFULL V_ENABLEOCSPIFULL(1U)
  803. #define S_LOCKTID 28
  804. #define V_LOCKTID(x) ((x) << S_LOCKTID)
  805. #define F_LOCKTID V_LOCKTID(1U)
  806. #define S_TABLELATENCYDELTA 0
  807. #define M_TABLELATENCYDELTA 0xf
  808. #define V_TABLELATENCYDELTA(x) ((x) << S_TABLELATENCYDELTA)
  809. #define G_TABLELATENCYDELTA(x) \
  810. (((x) >> S_TABLELATENCYDELTA) & M_TABLELATENCYDELTA)
  811. #define A_TP_PC_CONFIG2 0x34c
  812. #define S_DISBLEDAPARBIT0 15
  813. #define V_DISBLEDAPARBIT0(x) ((x) << S_DISBLEDAPARBIT0)
  814. #define F_DISBLEDAPARBIT0 V_DISBLEDAPARBIT0(1U)
  815. #define S_ENABLEARPMISS 13
  816. #define V_ENABLEARPMISS(x) ((x) << S_ENABLEARPMISS)
  817. #define F_ENABLEARPMISS V_ENABLEARPMISS(1U)
  818. #define S_ENABLENONOFDTNLSYN 12
  819. #define V_ENABLENONOFDTNLSYN(x) ((x) << S_ENABLENONOFDTNLSYN)
  820. #define F_ENABLENONOFDTNLSYN V_ENABLENONOFDTNLSYN(1U)
  821. #define S_ENABLEIPV6RSS 11
  822. #define V_ENABLEIPV6RSS(x) ((x) << S_ENABLEIPV6RSS)
  823. #define F_ENABLEIPV6RSS V_ENABLEIPV6RSS(1U)
  824. #define S_CHDRAFULL 4
  825. #define V_CHDRAFULL(x) ((x) << S_CHDRAFULL)
  826. #define F_CHDRAFULL V_CHDRAFULL(1U)
  827. #define A_TP_TCP_BACKOFF_REG0 0x350
  828. #define A_TP_TCP_BACKOFF_REG1 0x354
  829. #define A_TP_TCP_BACKOFF_REG2 0x358
  830. #define A_TP_TCP_BACKOFF_REG3 0x35c
  831. #define A_TP_PARA_REG2 0x368
  832. #define S_MAXRXDATA 16
  833. #define M_MAXRXDATA 0xffff
  834. #define V_MAXRXDATA(x) ((x) << S_MAXRXDATA)
  835. #define S_RXCOALESCESIZE 0
  836. #define M_RXCOALESCESIZE 0xffff
  837. #define V_RXCOALESCESIZE(x) ((x) << S_RXCOALESCESIZE)
  838. #define A_TP_PARA_REG3 0x36c
  839. #define S_TXDATAACKIDX 16
  840. #define M_TXDATAACKIDX 0xf
  841. #define V_TXDATAACKIDX(x) ((x) << S_TXDATAACKIDX)
  842. #define S_TXPACEAUTOSTRICT 10
  843. #define V_TXPACEAUTOSTRICT(x) ((x) << S_TXPACEAUTOSTRICT)
  844. #define F_TXPACEAUTOSTRICT V_TXPACEAUTOSTRICT(1U)
  845. #define S_TXPACEFIXED 9
  846. #define V_TXPACEFIXED(x) ((x) << S_TXPACEFIXED)
  847. #define F_TXPACEFIXED V_TXPACEFIXED(1U)
  848. #define S_TXPACEAUTO 8
  849. #define V_TXPACEAUTO(x) ((x) << S_TXPACEAUTO)
  850. #define F_TXPACEAUTO V_TXPACEAUTO(1U)
  851. #define S_RXCOALESCEENABLE 1
  852. #define V_RXCOALESCEENABLE(x) ((x) << S_RXCOALESCEENABLE)
  853. #define F_RXCOALESCEENABLE V_RXCOALESCEENABLE(1U)
  854. #define S_RXCOALESCEPSHEN 0
  855. #define V_RXCOALESCEPSHEN(x) ((x) << S_RXCOALESCEPSHEN)
  856. #define F_RXCOALESCEPSHEN V_RXCOALESCEPSHEN(1U)
  857. #define A_TP_PARA_REG4 0x370
  858. #define A_TP_PARA_REG5 0x374
  859. #define S_RXDDPOFFINIT 3
  860. #define V_RXDDPOFFINIT(x) ((x) << S_RXDDPOFFINIT)
  861. #define F_RXDDPOFFINIT V_RXDDPOFFINIT(1U)
  862. #define A_TP_PARA_REG6 0x378
  863. #define S_T3A_ENABLEESND 13
  864. #define V_T3A_ENABLEESND(x) ((x) << S_T3A_ENABLEESND)
  865. #define F_T3A_ENABLEESND V_T3A_ENABLEESND(1U)
  866. #define S_ENABLEESND 11
  867. #define V_ENABLEESND(x) ((x) << S_ENABLEESND)
  868. #define F_ENABLEESND V_ENABLEESND(1U)
  869. #define A_TP_PARA_REG7 0x37c
  870. #define S_PMMAXXFERLEN1 16
  871. #define M_PMMAXXFERLEN1 0xffff
  872. #define V_PMMAXXFERLEN1(x) ((x) << S_PMMAXXFERLEN1)
  873. #define S_PMMAXXFERLEN0 0
  874. #define M_PMMAXXFERLEN0 0xffff
  875. #define V_PMMAXXFERLEN0(x) ((x) << S_PMMAXXFERLEN0)
  876. #define A_TP_TIMER_RESOLUTION 0x390
  877. #define S_TIMERRESOLUTION 16
  878. #define M_TIMERRESOLUTION 0xff
  879. #define V_TIMERRESOLUTION(x) ((x) << S_TIMERRESOLUTION)
  880. #define S_TIMESTAMPRESOLUTION 8
  881. #define M_TIMESTAMPRESOLUTION 0xff
  882. #define V_TIMESTAMPRESOLUTION(x) ((x) << S_TIMESTAMPRESOLUTION)
  883. #define S_DELAYEDACKRESOLUTION 0
  884. #define M_DELAYEDACKRESOLUTION 0xff
  885. #define V_DELAYEDACKRESOLUTION(x) ((x) << S_DELAYEDACKRESOLUTION)
  886. #define A_TP_MSL 0x394
  887. #define A_TP_RXT_MIN 0x398
  888. #define A_TP_RXT_MAX 0x39c
  889. #define A_TP_PERS_MIN 0x3a0
  890. #define A_TP_PERS_MAX 0x3a4
  891. #define A_TP_KEEP_IDLE 0x3a8
  892. #define A_TP_KEEP_INTVL 0x3ac
  893. #define A_TP_INIT_SRTT 0x3b0
  894. #define A_TP_DACK_TIMER 0x3b4
  895. #define A_TP_FINWAIT2_TIMER 0x3b8
  896. #define A_TP_SHIFT_CNT 0x3c0
  897. #define S_SYNSHIFTMAX 24
  898. #define M_SYNSHIFTMAX 0xff
  899. #define V_SYNSHIFTMAX(x) ((x) << S_SYNSHIFTMAX)
  900. #define S_RXTSHIFTMAXR1 20
  901. #define M_RXTSHIFTMAXR1 0xf
  902. #define V_RXTSHIFTMAXR1(x) ((x) << S_RXTSHIFTMAXR1)
  903. #define S_RXTSHIFTMAXR2 16
  904. #define M_RXTSHIFTMAXR2 0xf
  905. #define V_RXTSHIFTMAXR2(x) ((x) << S_RXTSHIFTMAXR2)
  906. #define S_PERSHIFTBACKOFFMAX 12
  907. #define M_PERSHIFTBACKOFFMAX 0xf
  908. #define V_PERSHIFTBACKOFFMAX(x) ((x) << S_PERSHIFTBACKOFFMAX)
  909. #define S_PERSHIFTMAX 8
  910. #define M_PERSHIFTMAX 0xf
  911. #define V_PERSHIFTMAX(x) ((x) << S_PERSHIFTMAX)
  912. #define S_KEEPALIVEMAX 0
  913. #define M_KEEPALIVEMAX 0xff
  914. #define V_KEEPALIVEMAX(x) ((x) << S_KEEPALIVEMAX)
  915. #define A_TP_MTU_PORT_TABLE 0x3d0
  916. #define A_TP_CCTRL_TABLE 0x3dc
  917. #define A_TP_MTU_TABLE 0x3e4
  918. #define A_TP_RSS_MAP_TABLE 0x3e8
  919. #define A_TP_RSS_LKP_TABLE 0x3ec
  920. #define A_TP_RSS_CONFIG 0x3f0
  921. #define S_TNL4TUPEN 29
  922. #define V_TNL4TUPEN(x) ((x) << S_TNL4TUPEN)
  923. #define F_TNL4TUPEN V_TNL4TUPEN(1U)
  924. #define S_TNL2TUPEN 28
  925. #define V_TNL2TUPEN(x) ((x) << S_TNL2TUPEN)
  926. #define F_TNL2TUPEN V_TNL2TUPEN(1U)
  927. #define S_TNLPRTEN 26
  928. #define V_TNLPRTEN(x) ((x) << S_TNLPRTEN)
  929. #define F_TNLPRTEN V_TNLPRTEN(1U)
  930. #define S_TNLMAPEN 25
  931. #define V_TNLMAPEN(x) ((x) << S_TNLMAPEN)
  932. #define F_TNLMAPEN V_TNLMAPEN(1U)
  933. #define S_TNLLKPEN 24
  934. #define V_TNLLKPEN(x) ((x) << S_TNLLKPEN)
  935. #define F_TNLLKPEN V_TNLLKPEN(1U)
  936. #define S_RRCPLMAPEN 7
  937. #define V_RRCPLMAPEN(x) ((x) << S_RRCPLMAPEN)
  938. #define F_RRCPLMAPEN V_RRCPLMAPEN(1U)
  939. #define S_RRCPLCPUSIZE 4
  940. #define M_RRCPLCPUSIZE 0x7
  941. #define V_RRCPLCPUSIZE(x) ((x) << S_RRCPLCPUSIZE)
  942. #define S_RQFEEDBACKENABLE 3
  943. #define V_RQFEEDBACKENABLE(x) ((x) << S_RQFEEDBACKENABLE)
  944. #define F_RQFEEDBACKENABLE V_RQFEEDBACKENABLE(1U)
  945. #define S_HASHTOEPLITZ 2
  946. #define V_HASHTOEPLITZ(x) ((x) << S_HASHTOEPLITZ)
  947. #define F_HASHTOEPLITZ V_HASHTOEPLITZ(1U)
  948. #define S_DISABLE 0
  949. #define A_TP_TM_PIO_ADDR 0x418
  950. #define A_TP_TM_PIO_DATA 0x41c
  951. #define A_TP_TX_MOD_QUE_TABLE 0x420
  952. #define A_TP_TX_RESOURCE_LIMIT 0x424
  953. #define A_TP_TX_MOD_QUEUE_REQ_MAP 0x428
  954. #define S_TX_MOD_QUEUE_REQ_MAP 0
  955. #define M_TX_MOD_QUEUE_REQ_MAP 0xff
  956. #define V_TX_MOD_QUEUE_REQ_MAP(x) ((x) << S_TX_MOD_QUEUE_REQ_MAP)
  957. #define A_TP_TX_MOD_QUEUE_WEIGHT1 0x42c
  958. #define A_TP_TX_MOD_QUEUE_WEIGHT0 0x430
  959. #define A_TP_MOD_CHANNEL_WEIGHT 0x434
  960. #define A_TP_MOD_RATE_LIMIT 0x438
  961. #define A_TP_PIO_ADDR 0x440
  962. #define A_TP_PIO_DATA 0x444
  963. #define A_TP_RESET 0x44c
  964. #define S_FLSTINITENABLE 1
  965. #define V_FLSTINITENABLE(x) ((x) << S_FLSTINITENABLE)
  966. #define F_FLSTINITENABLE V_FLSTINITENABLE(1U)
  967. #define S_TPRESET 0
  968. #define V_TPRESET(x) ((x) << S_TPRESET)
  969. #define F_TPRESET V_TPRESET(1U)
  970. #define A_TP_CMM_MM_RX_FLST_BASE 0x460
  971. #define A_TP_CMM_MM_TX_FLST_BASE 0x464
  972. #define A_TP_CMM_MM_PS_FLST_BASE 0x468
  973. #define A_TP_MIB_INDEX 0x450
  974. #define A_TP_MIB_RDATA 0x454
  975. #define A_TP_CMM_MM_MAX_PSTRUCT 0x46c
  976. #define A_TP_INT_ENABLE 0x470
  977. #define S_FLMTXFLSTEMPTY 30
  978. #define V_FLMTXFLSTEMPTY(x) ((x) << S_FLMTXFLSTEMPTY)
  979. #define F_FLMTXFLSTEMPTY V_FLMTXFLSTEMPTY(1U)
  980. #define S_FLMRXFLSTEMPTY 29
  981. #define V_FLMRXFLSTEMPTY(x) ((x) << S_FLMRXFLSTEMPTY)
  982. #define F_FLMRXFLSTEMPTY V_FLMRXFLSTEMPTY(1U)
  983. #define S_ARPLUTPERR 26
  984. #define V_ARPLUTPERR(x) ((x) << S_ARPLUTPERR)
  985. #define F_ARPLUTPERR V_ARPLUTPERR(1U)
  986. #define S_CMCACHEPERR 24
  987. #define V_CMCACHEPERR(x) ((x) << S_CMCACHEPERR)
  988. #define F_CMCACHEPERR V_CMCACHEPERR(1U)
  989. #define A_TP_INT_CAUSE 0x474
  990. #define A_TP_TX_MOD_Q1_Q0_RATE_LIMIT 0x8
  991. #define A_TP_TX_DROP_CFG_CH0 0x12b
  992. #define A_TP_TX_DROP_MODE 0x12f
  993. #define A_TP_EGRESS_CONFIG 0x145
  994. #define S_REWRITEFORCETOSIZE 0
  995. #define V_REWRITEFORCETOSIZE(x) ((x) << S_REWRITEFORCETOSIZE)
  996. #define F_REWRITEFORCETOSIZE V_REWRITEFORCETOSIZE(1U)
  997. #define A_TP_TX_TRC_KEY0 0x20
  998. #define A_TP_RX_TRC_KEY0 0x120
  999. #define A_TP_TX_DROP_CNT_CH0 0x12d
  1000. #define S_TXDROPCNTCH0RCVD 0
  1001. #define M_TXDROPCNTCH0RCVD 0xffff
  1002. #define V_TXDROPCNTCH0RCVD(x) ((x) << S_TXDROPCNTCH0RCVD)
  1003. #define G_TXDROPCNTCH0RCVD(x) (((x) >> S_TXDROPCNTCH0RCVD) & \
  1004. M_TXDROPCNTCH0RCVD)
  1005. #define A_TP_PROXY_FLOW_CNTL 0x4b0
  1006. #define A_TP_EMBED_OP_FIELD0 0x4e8
  1007. #define A_TP_EMBED_OP_FIELD1 0x4ec
  1008. #define A_TP_EMBED_OP_FIELD2 0x4f0
  1009. #define A_TP_EMBED_OP_FIELD3 0x4f4
  1010. #define A_TP_EMBED_OP_FIELD4 0x4f8
  1011. #define A_TP_EMBED_OP_FIELD5 0x4fc
  1012. #define A_ULPRX_CTL 0x500
  1013. #define S_ROUND_ROBIN 4
  1014. #define V_ROUND_ROBIN(x) ((x) << S_ROUND_ROBIN)
  1015. #define F_ROUND_ROBIN V_ROUND_ROBIN(1U)
  1016. #define A_ULPRX_INT_ENABLE 0x504
  1017. #define S_DATASELFRAMEERR0 7
  1018. #define V_DATASELFRAMEERR0(x) ((x) << S_DATASELFRAMEERR0)
  1019. #define F_DATASELFRAMEERR0 V_DATASELFRAMEERR0(1U)
  1020. #define S_DATASELFRAMEERR1 6
  1021. #define V_DATASELFRAMEERR1(x) ((x) << S_DATASELFRAMEERR1)
  1022. #define F_DATASELFRAMEERR1 V_DATASELFRAMEERR1(1U)
  1023. #define S_PCMDMUXPERR 5
  1024. #define V_PCMDMUXPERR(x) ((x) << S_PCMDMUXPERR)
  1025. #define F_PCMDMUXPERR V_PCMDMUXPERR(1U)
  1026. #define S_ARBFPERR 4
  1027. #define V_ARBFPERR(x) ((x) << S_ARBFPERR)
  1028. #define F_ARBFPERR V_ARBFPERR(1U)
  1029. #define S_ARBPF0PERR 3
  1030. #define V_ARBPF0PERR(x) ((x) << S_ARBPF0PERR)
  1031. #define F_ARBPF0PERR V_ARBPF0PERR(1U)
  1032. #define S_ARBPF1PERR 2
  1033. #define V_ARBPF1PERR(x) ((x) << S_ARBPF1PERR)
  1034. #define F_ARBPF1PERR V_ARBPF1PERR(1U)
  1035. #define S_PARERRPCMD 1
  1036. #define V_PARERRPCMD(x) ((x) << S_PARERRPCMD)
  1037. #define F_PARERRPCMD V_PARERRPCMD(1U)
  1038. #define S_PARERRDATA 0
  1039. #define V_PARERRDATA(x) ((x) << S_PARERRDATA)
  1040. #define F_PARERRDATA V_PARERRDATA(1U)
  1041. #define A_ULPRX_INT_CAUSE 0x508
  1042. #define A_ULPRX_ISCSI_LLIMIT 0x50c
  1043. #define A_ULPRX_ISCSI_ULIMIT 0x510
  1044. #define A_ULPRX_ISCSI_TAGMASK 0x514
  1045. #define A_ULPRX_ISCSI_PSZ 0x518
  1046. #define A_ULPRX_TDDP_LLIMIT 0x51c
  1047. #define A_ULPRX_TDDP_ULIMIT 0x520
  1048. #define A_ULPRX_TDDP_PSZ 0x528
  1049. #define S_HPZ0 0
  1050. #define M_HPZ0 0xf
  1051. #define V_HPZ0(x) ((x) << S_HPZ0)
  1052. #define G_HPZ0(x) (((x) >> S_HPZ0) & M_HPZ0)
  1053. #define A_ULPRX_STAG_LLIMIT 0x52c
  1054. #define A_ULPRX_STAG_ULIMIT 0x530
  1055. #define A_ULPRX_RQ_LLIMIT 0x534
  1056. #define A_ULPRX_RQ_ULIMIT 0x538
  1057. #define A_ULPRX_PBL_LLIMIT 0x53c
  1058. #define A_ULPRX_PBL_ULIMIT 0x540
  1059. #define A_ULPRX_TDDP_TAGMASK 0x524
  1060. #define A_ULPTX_CONFIG 0x580
  1061. #define S_CFG_CQE_SOP_MASK 1
  1062. #define V_CFG_CQE_SOP_MASK(x) ((x) << S_CFG_CQE_SOP_MASK)
  1063. #define F_CFG_CQE_SOP_MASK V_CFG_CQE_SOP_MASK(1U)
  1064. #define S_CFG_RR_ARB 0
  1065. #define V_CFG_RR_ARB(x) ((x) << S_CFG_RR_ARB)
  1066. #define F_CFG_RR_ARB V_CFG_RR_ARB(1U)
  1067. #define A_ULPTX_INT_ENABLE 0x584
  1068. #define S_PBL_BOUND_ERR_CH1 1
  1069. #define V_PBL_BOUND_ERR_CH1(x) ((x) << S_PBL_BOUND_ERR_CH1)
  1070. #define F_PBL_BOUND_ERR_CH1 V_PBL_BOUND_ERR_CH1(1U)
  1071. #define S_PBL_BOUND_ERR_CH0 0
  1072. #define V_PBL_BOUND_ERR_CH0(x) ((x) << S_PBL_BOUND_ERR_CH0)
  1073. #define F_PBL_BOUND_ERR_CH0 V_PBL_BOUND_ERR_CH0(1U)
  1074. #define A_ULPTX_INT_CAUSE 0x588
  1075. #define A_ULPTX_TPT_LLIMIT 0x58c
  1076. #define A_ULPTX_TPT_ULIMIT 0x590
  1077. #define A_ULPTX_PBL_LLIMIT 0x594
  1078. #define A_ULPTX_PBL_ULIMIT 0x598
  1079. #define A_ULPTX_DMA_WEIGHT 0x5ac
  1080. #define S_D1_WEIGHT 16
  1081. #define M_D1_WEIGHT 0xffff
  1082. #define V_D1_WEIGHT(x) ((x) << S_D1_WEIGHT)
  1083. #define S_D0_WEIGHT 0
  1084. #define M_D0_WEIGHT 0xffff
  1085. #define V_D0_WEIGHT(x) ((x) << S_D0_WEIGHT)
  1086. #define A_PM1_RX_CFG 0x5c0
  1087. #define A_PM1_RX_MODE 0x5c4
  1088. #define A_PM1_RX_INT_ENABLE 0x5d8
  1089. #define S_ZERO_E_CMD_ERROR 18
  1090. #define V_ZERO_E_CMD_ERROR(x) ((x) << S_ZERO_E_CMD_ERROR)
  1091. #define F_ZERO_E_CMD_ERROR V_ZERO_E_CMD_ERROR(1U)
  1092. #define S_IESPI0_FIFO2X_RX_FRAMING_ERROR 17
  1093. #define V_IESPI0_FIFO2X_RX_FRAMING_ERROR(x) ((x) << S_IESPI0_FIFO2X_RX_FRAMING_ERROR)
  1094. #define F_IESPI0_FIFO2X_RX_FRAMING_ERROR V_IESPI0_FIFO2X_RX_FRAMING_ERROR(1U)
  1095. #define S_IESPI1_FIFO2X_RX_FRAMING_ERROR 16
  1096. #define V_IESPI1_FIFO2X_RX_FRAMING_ERROR(x) ((x) << S_IESPI1_FIFO2X_RX_FRAMING_ERROR)
  1097. #define F_IESPI1_FIFO2X_RX_FRAMING_ERROR V_IESPI1_FIFO2X_RX_FRAMING_ERROR(1U)
  1098. #define S_IESPI0_RX_FRAMING_ERROR 15
  1099. #define V_IESPI0_RX_FRAMING_ERROR(x) ((x) << S_IESPI0_RX_FRAMING_ERROR)
  1100. #define F_IESPI0_RX_FRAMING_ERROR V_IESPI0_RX_FRAMING_ERROR(1U)
  1101. #define S_IESPI1_RX_FRAMING_ERROR 14
  1102. #define V_IESPI1_RX_FRAMING_ERROR(x) ((x) << S_IESPI1_RX_FRAMING_ERROR)
  1103. #define F_IESPI1_RX_FRAMING_ERROR V_IESPI1_RX_FRAMING_ERROR(1U)
  1104. #define S_IESPI0_TX_FRAMING_ERROR 13
  1105. #define V_IESPI0_TX_FRAMING_ERROR(x) ((x) << S_IESPI0_TX_FRAMING_ERROR)
  1106. #define F_IESPI0_TX_FRAMING_ERROR V_IESPI0_TX_FRAMING_ERROR(1U)
  1107. #define S_IESPI1_TX_FRAMING_ERROR 12
  1108. #define V_IESPI1_TX_FRAMING_ERROR(x) ((x) << S_IESPI1_TX_FRAMING_ERROR)
  1109. #define F_IESPI1_TX_FRAMING_ERROR V_IESPI1_TX_FRAMING_ERROR(1U)
  1110. #define S_OCSPI0_RX_FRAMING_ERROR 11
  1111. #define V_OCSPI0_RX_FRAMING_ERROR(x) ((x) << S_OCSPI0_RX_FRAMING_ERROR)
  1112. #define F_OCSPI0_RX_FRAMING_ERROR V_OCSPI0_RX_FRAMING_ERROR(1U)
  1113. #define S_OCSPI1_RX_FRAMING_ERROR 10
  1114. #define V_OCSPI1_RX_FRAMING_ERROR(x) ((x) << S_OCSPI1_RX_FRAMING_ERROR)
  1115. #define F_OCSPI1_RX_FRAMING_ERROR V_OCSPI1_RX_FRAMING_ERROR(1U)
  1116. #define S_OCSPI0_TX_FRAMING_ERROR 9
  1117. #define V_OCSPI0_TX_FRAMING_ERROR(x) ((x) << S_OCSPI0_TX_FRAMING_ERROR)
  1118. #define F_OCSPI0_TX_FRAMING_ERROR V_OCSPI0_TX_FRAMING_ERROR(1U)
  1119. #define S_OCSPI1_TX_FRAMING_ERROR 8
  1120. #define V_OCSPI1_TX_FRAMING_ERROR(x) ((x) << S_OCSPI1_TX_FRAMING_ERROR)
  1121. #define F_OCSPI1_TX_FRAMING_ERROR V_OCSPI1_TX_FRAMING_ERROR(1U)
  1122. #define S_OCSPI0_OFIFO2X_TX_FRAMING_ERROR 7
  1123. #define V_OCSPI0_OFIFO2X_TX_FRAMING_ERROR(x) ((x) << S_OCSPI0_OFIFO2X_TX_FRAMING_ERROR)
  1124. #define F_OCSPI0_OFIFO2X_TX_FRAMING_ERROR V_OCSPI0_OFIFO2X_TX_FRAMING_ERROR(1U)
  1125. #define S_OCSPI1_OFIFO2X_TX_FRAMING_ERROR 6
  1126. #define V_OCSPI1_OFIFO2X_TX_FRAMING_ERROR(x) ((x) << S_OCSPI1_OFIFO2X_TX_FRAMING_ERROR)
  1127. #define F_OCSPI1_OFIFO2X_TX_FRAMING_ERROR V_OCSPI1_OFIFO2X_TX_FRAMING_ERROR(1U)
  1128. #define S_IESPI_PAR_ERROR 3
  1129. #define M_IESPI_PAR_ERROR 0x7
  1130. #define V_IESPI_PAR_ERROR(x) ((x) << S_IESPI_PAR_ERROR)
  1131. #define S_OCSPI_PAR_ERROR 0
  1132. #define M_OCSPI_PAR_ERROR 0x7
  1133. #define V_OCSPI_PAR_ERROR(x) ((x) << S_OCSPI_PAR_ERROR)
  1134. #define A_PM1_RX_INT_CAUSE 0x5dc
  1135. #define A_PM1_TX_CFG 0x5e0
  1136. #define A_PM1_TX_MODE 0x5e4
  1137. #define A_PM1_TX_INT_ENABLE 0x5f8
  1138. #define S_ZERO_C_CMD_ERROR 18
  1139. #define V_ZERO_C_CMD_ERROR(x) ((x) << S_ZERO_C_CMD_ERROR)
  1140. #define F_ZERO_C_CMD_ERROR V_ZERO_C_CMD_ERROR(1U)
  1141. #define S_ICSPI0_FIFO2X_RX_FRAMING_ERROR 17
  1142. #define V_ICSPI0_FIFO2X_RX_FRAMING_ERROR(x) ((x) << S_ICSPI0_FIFO2X_RX_FRAMING_ERROR)
  1143. #define F_ICSPI0_FIFO2X_RX_FRAMING_ERROR V_ICSPI0_FIFO2X_RX_FRAMING_ERROR(1U)
  1144. #define S_ICSPI1_FIFO2X_RX_FRAMING_ERROR 16
  1145. #define V_ICSPI1_FIFO2X_RX_FRAMING_ERROR(x) ((x) << S_ICSPI1_FIFO2X_RX_FRAMING_ERROR)
  1146. #define F_ICSPI1_FIFO2X_RX_FRAMING_ERROR V_ICSPI1_FIFO2X_RX_FRAMING_ERROR(1U)
  1147. #define S_ICSPI0_RX_FRAMING_ERROR 15
  1148. #define V_ICSPI0_RX_FRAMING_ERROR(x) ((x) << S_ICSPI0_RX_FRAMING_ERROR)
  1149. #define F_ICSPI0_RX_FRAMING_ERROR V_ICSPI0_RX_FRAMING_ERROR(1U)
  1150. #define S_ICSPI1_RX_FRAMING_ERROR 14
  1151. #define V_ICSPI1_RX_FRAMING_ERROR(x) ((x) << S_ICSPI1_RX_FRAMING_ERROR)
  1152. #define F_ICSPI1_RX_FRAMING_ERROR V_ICSPI1_RX_FRAMING_ERROR(1U)
  1153. #define S_ICSPI0_TX_FRAMING_ERROR 13
  1154. #define V_ICSPI0_TX_FRAMING_ERROR(x) ((x) << S_ICSPI0_TX_FRAMING_ERROR)
  1155. #define F_ICSPI0_TX_FRAMING_ERROR V_ICSPI0_TX_FRAMING_ERROR(1U)
  1156. #define S_ICSPI1_TX_FRAMING_ERROR 12
  1157. #define V_ICSPI1_TX_FRAMING_ERROR(x) ((x) << S_ICSPI1_TX_FRAMING_ERROR)
  1158. #define F_ICSPI1_TX_FRAMING_ERROR V_ICSPI1_TX_FRAMING_ERROR(1U)
  1159. #define S_OESPI0_RX_FRAMING_ERROR 11
  1160. #define V_OESPI0_RX_FRAMING_ERROR(x) ((x) << S_OESPI0_RX_FRAMING_ERROR)
  1161. #define F_OESPI0_RX_FRAMING_ERROR V_OESPI0_RX_FRAMING_ERROR(1U)
  1162. #define S_OESPI1_RX_FRAMING_ERROR 10
  1163. #define V_OESPI1_RX_FRAMING_ERROR(x) ((x) << S_OESPI1_RX_FRAMING_ERROR)
  1164. #define F_OESPI1_RX_FRAMING_ERROR V_OESPI1_RX_FRAMING_ERROR(1U)
  1165. #define S_OESPI0_TX_FRAMING_ERROR 9
  1166. #define V_OESPI0_TX_FRAMING_ERROR(x) ((x) << S_OESPI0_TX_FRAMING_ERROR)
  1167. #define F_OESPI0_TX_FRAMING_ERROR V_OESPI0_TX_FRAMING_ERROR(1U)
  1168. #define S_OESPI1_TX_FRAMING_ERROR 8
  1169. #define V_OESPI1_TX_FRAMING_ERROR(x) ((x) << S_OESPI1_TX_FRAMING_ERROR)
  1170. #define F_OESPI1_TX_FRAMING_ERROR V_OESPI1_TX_FRAMING_ERROR(1U)
  1171. #define S_OESPI0_OFIFO2X_TX_FRAMING_ERROR 7
  1172. #define V_OESPI0_OFIFO2X_TX_FRAMING_ERROR(x) ((x) << S_OESPI0_OFIFO2X_TX_FRAMING_ERROR)
  1173. #define F_OESPI0_OFIFO2X_TX_FRAMING_ERROR V_OESPI0_OFIFO2X_TX_FRAMING_ERROR(1U)
  1174. #define S_OESPI1_OFIFO2X_TX_FRAMING_ERROR 6
  1175. #define V_OESPI1_OFIFO2X_TX_FRAMING_ERROR(x) ((x) << S_OESPI1_OFIFO2X_TX_FRAMING_ERROR)
  1176. #define F_OESPI1_OFIFO2X_TX_FRAMING_ERROR V_OESPI1_OFIFO2X_TX_FRAMING_ERROR(1U)
  1177. #define S_ICSPI_PAR_ERROR 3
  1178. #define M_ICSPI_PAR_ERROR 0x7
  1179. #define V_ICSPI_PAR_ERROR(x) ((x) << S_ICSPI_PAR_ERROR)
  1180. #define S_OESPI_PAR_ERROR 0
  1181. #define M_OESPI_PAR_ERROR 0x7
  1182. #define V_OESPI_PAR_ERROR(x) ((x) << S_OESPI_PAR_ERROR)
  1183. #define A_PM1_TX_INT_CAUSE 0x5fc
  1184. #define A_MPS_CFG 0x600
  1185. #define S_TPRXPORTEN 4
  1186. #define V_TPRXPORTEN(x) ((x) << S_TPRXPORTEN)
  1187. #define F_TPRXPORTEN V_TPRXPORTEN(1U)
  1188. #define S_TPTXPORT1EN 3
  1189. #define V_TPTXPORT1EN(x) ((x) << S_TPTXPORT1EN)
  1190. #define F_TPTXPORT1EN V_TPTXPORT1EN(1U)
  1191. #define S_TPTXPORT0EN 2
  1192. #define V_TPTXPORT0EN(x) ((x) << S_TPTXPORT0EN)
  1193. #define F_TPTXPORT0EN V_TPTXPORT0EN(1U)
  1194. #define S_PORT1ACTIVE 1
  1195. #define V_PORT1ACTIVE(x) ((x) << S_PORT1ACTIVE)
  1196. #define F_PORT1ACTIVE V_PORT1ACTIVE(1U)
  1197. #define S_PORT0ACTIVE 0
  1198. #define V_PORT0ACTIVE(x) ((x) << S_PORT0ACTIVE)
  1199. #define F_PORT0ACTIVE V_PORT0ACTIVE(1U)
  1200. #define S_ENFORCEPKT 11
  1201. #define V_ENFORCEPKT(x) ((x) << S_ENFORCEPKT)
  1202. #define F_ENFORCEPKT V_ENFORCEPKT(1U)
  1203. #define A_MPS_INT_ENABLE 0x61c
  1204. #define S_MCAPARERRENB 6
  1205. #define M_MCAPARERRENB 0x7
  1206. #define V_MCAPARERRENB(x) ((x) << S_MCAPARERRENB)
  1207. #define S_RXTPPARERRENB 4
  1208. #define M_RXTPPARERRENB 0x3
  1209. #define V_RXTPPARERRENB(x) ((x) << S_RXTPPARERRENB)
  1210. #define S_TX1TPPARERRENB 2
  1211. #define M_TX1TPPARERRENB 0x3
  1212. #define V_TX1TPPARERRENB(x) ((x) << S_TX1TPPARERRENB)
  1213. #define S_TX0TPPARERRENB 0
  1214. #define M_TX0TPPARERRENB 0x3
  1215. #define V_TX0TPPARERRENB(x) ((x) << S_TX0TPPARERRENB)
  1216. #define A_MPS_INT_CAUSE 0x620
  1217. #define S_MCAPARERR 6
  1218. #define M_MCAPARERR 0x7
  1219. #define V_MCAPARERR(x) ((x) << S_MCAPARERR)
  1220. #define S_RXTPPARERR 4
  1221. #define M_RXTPPARERR 0x3
  1222. #define V_RXTPPARERR(x) ((x) << S_RXTPPARERR)
  1223. #define S_TX1TPPARERR 2
  1224. #define M_TX1TPPARERR 0x3
  1225. #define V_TX1TPPARERR(x) ((x) << S_TX1TPPARERR)
  1226. #define S_TX0TPPARERR 0
  1227. #define M_TX0TPPARERR 0x3
  1228. #define V_TX0TPPARERR(x) ((x) << S_TX0TPPARERR)
  1229. #define A_CPL_SWITCH_CNTRL 0x640
  1230. #define A_CPL_INTR_ENABLE 0x650
  1231. #define S_CIM_OP_MAP_PERR 5
  1232. #define V_CIM_OP_MAP_PERR(x) ((x) << S_CIM_OP_MAP_PERR)
  1233. #define F_CIM_OP_MAP_PERR V_CIM_OP_MAP_PERR(1U)
  1234. #define S_CIM_OVFL_ERROR 4
  1235. #define V_CIM_OVFL_ERROR(x) ((x) << S_CIM_OVFL_ERROR)
  1236. #define F_CIM_OVFL_ERROR V_CIM_OVFL_ERROR(1U)
  1237. #define S_TP_FRAMING_ERROR 3
  1238. #define V_TP_FRAMING_ERROR(x) ((x) << S_TP_FRAMING_ERROR)
  1239. #define F_TP_FRAMING_ERROR V_TP_FRAMING_ERROR(1U)
  1240. #define S_SGE_FRAMING_ERROR 2
  1241. #define V_SGE_FRAMING_ERROR(x) ((x) << S_SGE_FRAMING_ERROR)
  1242. #define F_SGE_FRAMING_ERROR V_SGE_FRAMING_ERROR(1U)
  1243. #define S_CIM_FRAMING_ERROR 1
  1244. #define V_CIM_FRAMING_ERROR(x) ((x) << S_CIM_FRAMING_ERROR)
  1245. #define F_CIM_FRAMING_ERROR V_CIM_FRAMING_ERROR(1U)
  1246. #define S_ZERO_SWITCH_ERROR 0
  1247. #define V_ZERO_SWITCH_ERROR(x) ((x) << S_ZERO_SWITCH_ERROR)
  1248. #define F_ZERO_SWITCH_ERROR V_ZERO_SWITCH_ERROR(1U)
  1249. #define A_CPL_INTR_CAUSE 0x654
  1250. #define A_CPL_MAP_TBL_DATA 0x65c
  1251. #define A_SMB_GLOBAL_TIME_CFG 0x660
  1252. #define A_I2C_CFG 0x6a0
  1253. #define S_I2C_CLKDIV 0
  1254. #define M_I2C_CLKDIV 0xfff
  1255. #define V_I2C_CLKDIV(x) ((x) << S_I2C_CLKDIV)
  1256. #define A_MI1_CFG 0x6b0
  1257. #define S_CLKDIV 5
  1258. #define M_CLKDIV 0xff
  1259. #define V_CLKDIV(x) ((x) << S_CLKDIV)
  1260. #define S_ST 3
  1261. #define M_ST 0x3
  1262. #define V_ST(x) ((x) << S_ST)
  1263. #define G_ST(x) (((x) >> S_ST) & M_ST)
  1264. #define S_PREEN 2
  1265. #define V_PREEN(x) ((x) << S_PREEN)
  1266. #define F_PREEN V_PREEN(1U)
  1267. #define S_MDIINV 1
  1268. #define V_MDIINV(x) ((x) << S_MDIINV)
  1269. #define F_MDIINV V_MDIINV(1U)
  1270. #define S_MDIEN 0
  1271. #define V_MDIEN(x) ((x) << S_MDIEN)
  1272. #define F_MDIEN V_MDIEN(1U)
  1273. #define A_MI1_ADDR 0x6b4
  1274. #define S_PHYADDR 5
  1275. #define M_PHYADDR 0x1f
  1276. #define V_PHYADDR(x) ((x) << S_PHYADDR)
  1277. #define S_REGADDR 0
  1278. #define M_REGADDR 0x1f
  1279. #define V_REGADDR(x) ((x) << S_REGADDR)
  1280. #define A_MI1_DATA 0x6b8
  1281. #define A_MI1_OP 0x6bc
  1282. #define S_MDI_OP 0
  1283. #define M_MDI_OP 0x3
  1284. #define V_MDI_OP(x) ((x) << S_MDI_OP)
  1285. #define A_SF_DATA 0x6d8
  1286. #define A_SF_OP 0x6dc
  1287. #define S_BYTECNT 1
  1288. #define M_BYTECNT 0x3
  1289. #define V_BYTECNT(x) ((x) << S_BYTECNT)
  1290. #define A_PL_INT_ENABLE0 0x6e0
  1291. #define S_T3DBG 23
  1292. #define V_T3DBG(x) ((x) << S_T3DBG)
  1293. #define F_T3DBG V_T3DBG(1U)
  1294. #define S_XGMAC0_1 20
  1295. #define V_XGMAC0_1(x) ((x) << S_XGMAC0_1)
  1296. #define F_XGMAC0_1 V_XGMAC0_1(1U)
  1297. #define S_XGMAC0_0 19
  1298. #define V_XGMAC0_0(x) ((x) << S_XGMAC0_0)
  1299. #define F_XGMAC0_0 V_XGMAC0_0(1U)
  1300. #define S_MC5A 18
  1301. #define V_MC5A(x) ((x) << S_MC5A)
  1302. #define F_MC5A V_MC5A(1U)
  1303. #define S_CPL_SWITCH 12
  1304. #define V_CPL_SWITCH(x) ((x) << S_CPL_SWITCH)
  1305. #define F_CPL_SWITCH V_CPL_SWITCH(1U)
  1306. #define S_MPS0 11
  1307. #define V_MPS0(x) ((x) << S_MPS0)
  1308. #define F_MPS0 V_MPS0(1U)
  1309. #define S_PM1_TX 10
  1310. #define V_PM1_TX(x) ((x) << S_PM1_TX)
  1311. #define F_PM1_TX V_PM1_TX(1U)
  1312. #define S_PM1_RX 9
  1313. #define V_PM1_RX(x) ((x) << S_PM1_RX)
  1314. #define F_PM1_RX V_PM1_RX(1U)
  1315. #define S_ULP2_TX 8
  1316. #define V_ULP2_TX(x) ((x) << S_ULP2_TX)
  1317. #define F_ULP2_TX V_ULP2_TX(1U)
  1318. #define S_ULP2_RX 7
  1319. #define V_ULP2_RX(x) ((x) << S_ULP2_RX)
  1320. #define F_ULP2_RX V_ULP2_RX(1U)
  1321. #define S_TP1 6
  1322. #define V_TP1(x) ((x) << S_TP1)
  1323. #define F_TP1 V_TP1(1U)
  1324. #define S_CIM 5
  1325. #define V_CIM(x) ((x) << S_CIM)
  1326. #define F_CIM V_CIM(1U)
  1327. #define S_MC7_CM 4
  1328. #define V_MC7_CM(x) ((x) << S_MC7_CM)
  1329. #define F_MC7_CM V_MC7_CM(1U)
  1330. #define S_MC7_PMTX 3
  1331. #define V_MC7_PMTX(x) ((x) << S_MC7_PMTX)
  1332. #define F_MC7_PMTX V_MC7_PMTX(1U)
  1333. #define S_MC7_PMRX 2
  1334. #define V_MC7_PMRX(x) ((x) << S_MC7_PMRX)
  1335. #define F_MC7_PMRX V_MC7_PMRX(1U)
  1336. #define S_PCIM0 1
  1337. #define V_PCIM0(x) ((x) << S_PCIM0)
  1338. #define F_PCIM0 V_PCIM0(1U)
  1339. #define S_SGE3 0
  1340. #define V_SGE3(x) ((x) << S_SGE3)
  1341. #define F_SGE3 V_SGE3(1U)
  1342. #define A_PL_INT_CAUSE0 0x6e4
  1343. #define A_PL_RST 0x6f0
  1344. #define S_FATALPERREN 4
  1345. #define V_FATALPERREN(x) ((x) << S_FATALPERREN)
  1346. #define F_FATALPERREN V_FATALPERREN(1U)
  1347. #define S_CRSTWRM 1
  1348. #define V_CRSTWRM(x) ((x) << S_CRSTWRM)
  1349. #define F_CRSTWRM V_CRSTWRM(1U)
  1350. #define A_PL_REV 0x6f4
  1351. #define A_PL_CLI 0x6f8
  1352. #define A_MC5_DB_CONFIG 0x704
  1353. #define S_TMTYPEHI 30
  1354. #define V_TMTYPEHI(x) ((x) << S_TMTYPEHI)
  1355. #define F_TMTYPEHI V_TMTYPEHI(1U)
  1356. #define S_TMPARTSIZE 28
  1357. #define M_TMPARTSIZE 0x3
  1358. #define V_TMPARTSIZE(x) ((x) << S_TMPARTSIZE)
  1359. #define G_TMPARTSIZE(x) (((x) >> S_TMPARTSIZE) & M_TMPARTSIZE)
  1360. #define S_TMTYPE 26
  1361. #define M_TMTYPE 0x3
  1362. #define V_TMTYPE(x) ((x) << S_TMTYPE)
  1363. #define G_TMTYPE(x) (((x) >> S_TMTYPE) & M_TMTYPE)
  1364. #define S_COMPEN 17
  1365. #define V_COMPEN(x) ((x) << S_COMPEN)
  1366. #define F_COMPEN V_COMPEN(1U)
  1367. #define S_PRTYEN 6
  1368. #define V_PRTYEN(x) ((x) << S_PRTYEN)
  1369. #define F_PRTYEN V_PRTYEN(1U)
  1370. #define S_MBUSEN 5
  1371. #define V_MBUSEN(x) ((x) << S_MBUSEN)
  1372. #define F_MBUSEN V_MBUSEN(1U)
  1373. #define S_DBGIEN 4
  1374. #define V_DBGIEN(x) ((x) << S_DBGIEN)
  1375. #define F_DBGIEN V_DBGIEN(1U)
  1376. #define S_TMRDY 2
  1377. #define V_TMRDY(x) ((x) << S_TMRDY)
  1378. #define F_TMRDY V_TMRDY(1U)
  1379. #define S_TMRST 1
  1380. #define V_TMRST(x) ((x) << S_TMRST)
  1381. #define F_TMRST V_TMRST(1U)
  1382. #define S_TMMODE 0
  1383. #define V_TMMODE(x) ((x) << S_TMMODE)
  1384. #define F_TMMODE V_TMMODE(1U)
  1385. #define A_MC5_DB_ROUTING_TABLE_INDEX 0x70c
  1386. #define A_MC5_DB_FILTER_TABLE 0x710
  1387. #define A_MC5_DB_SERVER_INDEX 0x714
  1388. #define A_MC5_DB_RSP_LATENCY 0x720
  1389. #define S_RDLAT 16
  1390. #define M_RDLAT 0x1f
  1391. #define V_RDLAT(x) ((x) << S_RDLAT)
  1392. #define S_LRNLAT 8
  1393. #define M_LRNLAT 0x1f
  1394. #define V_LRNLAT(x) ((x) << S_LRNLAT)
  1395. #define S_SRCHLAT 0
  1396. #define M_SRCHLAT 0x1f
  1397. #define V_SRCHLAT(x) ((x) << S_SRCHLAT)
  1398. #define A_MC5_DB_PART_ID_INDEX 0x72c
  1399. #define A_MC5_DB_INT_ENABLE 0x740
  1400. #define S_DELACTEMPTY 18
  1401. #define V_DELACTEMPTY(x) ((x) << S_DELACTEMPTY)
  1402. #define F_DELACTEMPTY V_DELACTEMPTY(1U)
  1403. #define S_DISPQPARERR 17
  1404. #define V_DISPQPARERR(x) ((x) << S_DISPQPARERR)
  1405. #define F_DISPQPARERR V_DISPQPARERR(1U)
  1406. #define S_REQQPARERR 16
  1407. #define V_REQQPARERR(x) ((x) << S_REQQPARERR)
  1408. #define F_REQQPARERR V_REQQPARERR(1U)
  1409. #define S_UNKNOWNCMD 15
  1410. #define V_UNKNOWNCMD(x) ((x) << S_UNKNOWNCMD)
  1411. #define F_UNKNOWNCMD V_UNKNOWNCMD(1U)
  1412. #define S_NFASRCHFAIL 8
  1413. #define V_NFASRCHFAIL(x) ((x) << S_NFASRCHFAIL)
  1414. #define F_NFASRCHFAIL V_NFASRCHFAIL(1U)
  1415. #define S_ACTRGNFULL 7
  1416. #define V_ACTRGNFULL(x) ((x) << S_ACTRGNFULL)
  1417. #define F_ACTRGNFULL V_ACTRGNFULL(1U)
  1418. #define S_PARITYERR 6
  1419. #define V_PARITYERR(x) ((x) << S_PARITYERR)
  1420. #define F_PARITYERR V_PARITYERR(1U)
  1421. #define A_MC5_DB_INT_CAUSE 0x744
  1422. #define A_MC5_DB_DBGI_CONFIG 0x774
  1423. #define A_MC5_DB_DBGI_REQ_CMD 0x778
  1424. #define A_MC5_DB_DBGI_REQ_ADDR0 0x77c
  1425. #define A_MC5_DB_DBGI_REQ_ADDR1 0x780
  1426. #define A_MC5_DB_DBGI_REQ_ADDR2 0x784
  1427. #define A_MC5_DB_DBGI_REQ_DATA0 0x788
  1428. #define A_MC5_DB_DBGI_REQ_DATA1 0x78c
  1429. #define A_MC5_DB_DBGI_REQ_DATA2 0x790
  1430. #define A_MC5_DB_DBGI_RSP_STATUS 0x7b0
  1431. #define S_DBGIRSPVALID 0
  1432. #define V_DBGIRSPVALID(x) ((x) << S_DBGIRSPVALID)
  1433. #define F_DBGIRSPVALID V_DBGIRSPVALID(1U)
  1434. #define A_MC5_DB_DBGI_RSP_DATA0 0x7b4
  1435. #define A_MC5_DB_DBGI_RSP_DATA1 0x7b8
  1436. #define A_MC5_DB_DBGI_RSP_DATA2 0x7bc
  1437. #define A_MC5_DB_POPEN_DATA_WR_CMD 0x7cc
  1438. #define A_MC5_DB_POPEN_MASK_WR_CMD 0x7d0
  1439. #define A_MC5_DB_AOPEN_SRCH_CMD 0x7d4
  1440. #define A_MC5_DB_AOPEN_LRN_CMD 0x7d8
  1441. #define A_MC5_DB_SYN_SRCH_CMD 0x7dc
  1442. #define A_MC5_DB_SYN_LRN_CMD 0x7e0
  1443. #define A_MC5_DB_ACK_SRCH_CMD 0x7e4
  1444. #define A_MC5_DB_ACK_LRN_CMD 0x7e8
  1445. #define A_MC5_DB_ILOOKUP_CMD 0x7ec
  1446. #define A_MC5_DB_ELOOKUP_CMD 0x7f0
  1447. #define A_MC5_DB_DATA_WRITE_CMD 0x7f4
  1448. #define A_MC5_DB_DATA_READ_CMD 0x7f8
  1449. #define XGMAC0_0_BASE_ADDR 0x800
  1450. #define A_XGM_TX_CTRL 0x800
  1451. #define S_TXEN 0
  1452. #define V_TXEN(x) ((x) << S_TXEN)
  1453. #define F_TXEN V_TXEN(1U)
  1454. #define A_XGM_TX_CFG 0x804
  1455. #define S_TXPAUSEEN 0
  1456. #define V_TXPAUSEEN(x) ((x) << S_TXPAUSEEN)
  1457. #define F_TXPAUSEEN V_TXPAUSEEN(1U)
  1458. #define A_XGM_TX_PAUSE_QUANTA 0x808
  1459. #define A_XGM_RX_CTRL 0x80c
  1460. #define S_RXEN 0
  1461. #define V_RXEN(x) ((x) << S_RXEN)
  1462. #define F_RXEN V_RXEN(1U)
  1463. #define A_XGM_RX_CFG 0x810
  1464. #define S_DISPAUSEFRAMES 9
  1465. #define V_DISPAUSEFRAMES(x) ((x) << S_DISPAUSEFRAMES)
  1466. #define F_DISPAUSEFRAMES V_DISPAUSEFRAMES(1U)
  1467. #define S_EN1536BFRAMES 8
  1468. #define V_EN1536BFRAMES(x) ((x) << S_EN1536BFRAMES)
  1469. #define F_EN1536BFRAMES V_EN1536BFRAMES(1U)
  1470. #define S_ENJUMBO 7
  1471. #define V_ENJUMBO(x) ((x) << S_ENJUMBO)
  1472. #define F_ENJUMBO V_ENJUMBO(1U)
  1473. #define S_RMFCS 6
  1474. #define V_RMFCS(x) ((x) << S_RMFCS)
  1475. #define F_RMFCS V_RMFCS(1U)
  1476. #define S_ENHASHMCAST 2
  1477. #define V_ENHASHMCAST(x) ((x) << S_ENHASHMCAST)
  1478. #define F_ENHASHMCAST V_ENHASHMCAST(1U)
  1479. #define S_COPYALLFRAMES 0
  1480. #define V_COPYALLFRAMES(x) ((x) << S_COPYALLFRAMES)
  1481. #define F_COPYALLFRAMES V_COPYALLFRAMES(1U)
  1482. #define S_DISBCAST 1
  1483. #define V_DISBCAST(x) ((x) << S_DISBCAST)
  1484. #define F_DISBCAST V_DISBCAST(1U)
  1485. #define A_XGM_RX_HASH_LOW 0x814
  1486. #define A_XGM_RX_HASH_HIGH 0x818
  1487. #define A_XGM_RX_EXACT_MATCH_LOW_1 0x81c
  1488. #define A_XGM_RX_EXACT_MATCH_HIGH_1 0x820
  1489. #define A_XGM_RX_EXACT_MATCH_LOW_2 0x824
  1490. #define A_XGM_RX_EXACT_MATCH_LOW_3 0x82c
  1491. #define A_XGM_RX_EXACT_MATCH_LOW_4 0x834
  1492. #define A_XGM_RX_EXACT_MATCH_LOW_5 0x83c
  1493. #define A_XGM_RX_EXACT_MATCH_LOW_6 0x844
  1494. #define A_XGM_RX_EXACT_MATCH_LOW_7 0x84c
  1495. #define A_XGM_RX_EXACT_MATCH_LOW_8 0x854
  1496. #define A_XGM_INT_STATUS 0x86c
  1497. #define S_LINKFAULTCHANGE 9
  1498. #define V_LINKFAULTCHANGE(x) ((x) << S_LINKFAULTCHANGE)
  1499. #define F_LINKFAULTCHANGE V_LINKFAULTCHANGE(1U)
  1500. #define A_XGM_XGM_INT_ENABLE 0x874
  1501. #define A_XGM_XGM_INT_DISABLE 0x878
  1502. #define A_XGM_STAT_CTRL 0x880
  1503. #define S_CLRSTATS 2
  1504. #define V_CLRSTATS(x) ((x) << S_CLRSTATS)
  1505. #define F_CLRSTATS V_CLRSTATS(1U)
  1506. #define A_XGM_RXFIFO_CFG 0x884
  1507. #define S_RXFIFO_EMPTY 31
  1508. #define V_RXFIFO_EMPTY(x) ((x) << S_RXFIFO_EMPTY)
  1509. #define F_RXFIFO_EMPTY V_RXFIFO_EMPTY(1U)
  1510. #define S_RXFIFOPAUSEHWM 17
  1511. #define M_RXFIFOPAUSEHWM 0xfff
  1512. #define V_RXFIFOPAUSEHWM(x) ((x) << S_RXFIFOPAUSEHWM)
  1513. #define G_RXFIFOPAUSEHWM(x) (((x) >> S_RXFIFOPAUSEHWM) & M_RXFIFOPAUSEHWM)
  1514. #define S_RXFIFOPAUSELWM 5
  1515. #define M_RXFIFOPAUSELWM 0xfff
  1516. #define V_RXFIFOPAUSELWM(x) ((x) << S_RXFIFOPAUSELWM)
  1517. #define G_RXFIFOPAUSELWM(x) (((x) >> S_RXFIFOPAUSELWM) & M_RXFIFOPAUSELWM)
  1518. #define S_RXSTRFRWRD 1
  1519. #define V_RXSTRFRWRD(x) ((x) << S_RXSTRFRWRD)
  1520. #define F_RXSTRFRWRD V_RXSTRFRWRD(1U)
  1521. #define S_DISERRFRAMES 0
  1522. #define V_DISERRFRAMES(x) ((x) << S_DISERRFRAMES)
  1523. #define F_DISERRFRAMES V_DISERRFRAMES(1U)
  1524. #define A_XGM_TXFIFO_CFG 0x888
  1525. #define S_UNDERUNFIX 22
  1526. #define V_UNDERUNFIX(x) ((x) << S_UNDERUNFIX)
  1527. #define F_UNDERUNFIX V_UNDERUNFIX(1U)
  1528. #define S_TXIPG 13
  1529. #define M_TXIPG 0xff
  1530. #define V_TXIPG(x) ((x) << S_TXIPG)
  1531. #define G_TXIPG(x) (((x) >> S_TXIPG) & M_TXIPG)
  1532. #define S_TXFIFOTHRESH 4
  1533. #define M_TXFIFOTHRESH 0x1ff
  1534. #define V_TXFIFOTHRESH(x) ((x) << S_TXFIFOTHRESH)
  1535. #define S_ENDROPPKT 21
  1536. #define V_ENDROPPKT(x) ((x) << S_ENDROPPKT)
  1537. #define F_ENDROPPKT V_ENDROPPKT(1U)
  1538. #define A_XGM_SERDES_CTRL 0x890
  1539. #define A_XGM_SERDES_CTRL0 0x8e0
  1540. #define S_SERDESRESET_ 24
  1541. #define V_SERDESRESET_(x) ((x) << S_SERDESRESET_)
  1542. #define F_SERDESRESET_ V_SERDESRESET_(1U)
  1543. #define S_RXENABLE 4
  1544. #define V_RXENABLE(x) ((x) << S_RXENABLE)
  1545. #define F_RXENABLE V_RXENABLE(1U)
  1546. #define S_TXENABLE 3
  1547. #define V_TXENABLE(x) ((x) << S_TXENABLE)
  1548. #define F_TXENABLE V_TXENABLE(1U)
  1549. #define A_XGM_PAUSE_TIMER 0x890
  1550. #define A_XGM_RGMII_IMP 0x89c
  1551. #define S_XGM_IMPSETUPDATE 6
  1552. #define V_XGM_IMPSETUPDATE(x) ((x) << S_XGM_IMPSETUPDATE)
  1553. #define F_XGM_IMPSETUPDATE V_XGM_IMPSETUPDATE(1U)
  1554. #define S_RGMIIIMPPD 3
  1555. #define M_RGMIIIMPPD 0x7
  1556. #define V_RGMIIIMPPD(x) ((x) << S_RGMIIIMPPD)
  1557. #define S_RGMIIIMPPU 0
  1558. #define M_RGMIIIMPPU 0x7
  1559. #define V_RGMIIIMPPU(x) ((x) << S_RGMIIIMPPU)
  1560. #define S_CALRESET 8
  1561. #define V_CALRESET(x) ((x) << S_CALRESET)
  1562. #define F_CALRESET V_CALRESET(1U)
  1563. #define S_CALUPDATE 7
  1564. #define V_CALUPDATE(x) ((x) << S_CALUPDATE)
  1565. #define F_CALUPDATE V_CALUPDATE(1U)
  1566. #define A_XGM_XAUI_IMP 0x8a0
  1567. #define S_CALBUSY 31
  1568. #define V_CALBUSY(x) ((x) << S_CALBUSY)
  1569. #define F_CALBUSY V_CALBUSY(1U)
  1570. #define S_XGM_CALFAULT 29
  1571. #define V_XGM_CALFAULT(x) ((x) << S_XGM_CALFAULT)
  1572. #define F_XGM_CALFAULT V_XGM_CALFAULT(1U)
  1573. #define S_CALIMP 24
  1574. #define M_CALIMP 0x1f
  1575. #define V_CALIMP(x) ((x) << S_CALIMP)
  1576. #define G_CALIMP(x) (((x) >> S_CALIMP) & M_CALIMP)
  1577. #define S_XAUIIMP 0
  1578. #define M_XAUIIMP 0x7
  1579. #define V_XAUIIMP(x) ((x) << S_XAUIIMP)
  1580. #define A_XGM_RX_MAX_PKT_SIZE 0x8a8
  1581. #define S_RXMAXFRAMERSIZE 17
  1582. #define M_RXMAXFRAMERSIZE 0x3fff
  1583. #define V_RXMAXFRAMERSIZE(x) ((x) << S_RXMAXFRAMERSIZE)
  1584. #define G_RXMAXFRAMERSIZE(x) (((x) >> S_RXMAXFRAMERSIZE) & M_RXMAXFRAMERSIZE)
  1585. #define S_RXENFRAMER 14
  1586. #define V_RXENFRAMER(x) ((x) << S_RXENFRAMER)
  1587. #define F_RXENFRAMER V_RXENFRAMER(1U)
  1588. #define S_RXMAXPKTSIZE 0
  1589. #define M_RXMAXPKTSIZE 0x3fff
  1590. #define V_RXMAXPKTSIZE(x) ((x) << S_RXMAXPKTSIZE)
  1591. #define G_RXMAXPKTSIZE(x) (((x) >> S_RXMAXPKTSIZE) & M_RXMAXPKTSIZE)
  1592. #define A_XGM_RESET_CTRL 0x8ac
  1593. #define S_XGMAC_STOP_EN 4
  1594. #define V_XGMAC_STOP_EN(x) ((x) << S_XGMAC_STOP_EN)
  1595. #define F_XGMAC_STOP_EN V_XGMAC_STOP_EN(1U)
  1596. #define S_XG2G_RESET_ 3
  1597. #define V_XG2G_RESET_(x) ((x) << S_XG2G_RESET_)
  1598. #define F_XG2G_RESET_ V_XG2G_RESET_(1U)
  1599. #define S_RGMII_RESET_ 2
  1600. #define V_RGMII_RESET_(x) ((x) << S_RGMII_RESET_)
  1601. #define F_RGMII_RESET_ V_RGMII_RESET_(1U)
  1602. #define S_PCS_RESET_ 1
  1603. #define V_PCS_RESET_(x) ((x) << S_PCS_RESET_)
  1604. #define F_PCS_RESET_ V_PCS_RESET_(1U)
  1605. #define S_MAC_RESET_ 0
  1606. #define V_MAC_RESET_(x) ((x) << S_MAC_RESET_)
  1607. #define F_MAC_RESET_ V_MAC_RESET_(1U)
  1608. #define A_XGM_PORT_CFG 0x8b8
  1609. #define S_CLKDIVRESET_ 3
  1610. #define V_CLKDIVRESET_(x) ((x) << S_CLKDIVRESET_)
  1611. #define F_CLKDIVRESET_ V_CLKDIVRESET_(1U)
  1612. #define S_PORTSPEED 1
  1613. #define M_PORTSPEED 0x3
  1614. #define V_PORTSPEED(x) ((x) << S_PORTSPEED)
  1615. #define S_ENRGMII 0
  1616. #define V_ENRGMII(x) ((x) << S_ENRGMII)
  1617. #define F_ENRGMII V_ENRGMII(1U)
  1618. #define A_XGM_INT_ENABLE 0x8d4
  1619. #define S_TXFIFO_PRTY_ERR 17
  1620. #define M_TXFIFO_PRTY_ERR 0x7
  1621. #define V_TXFIFO_PRTY_ERR(x) ((x) << S_TXFIFO_PRTY_ERR)
  1622. #define S_RXFIFO_PRTY_ERR 14
  1623. #define M_RXFIFO_PRTY_ERR 0x7
  1624. #define V_RXFIFO_PRTY_ERR(x) ((x) << S_RXFIFO_PRTY_ERR)
  1625. #define S_TXFIFO_UNDERRUN 13
  1626. #define V_TXFIFO_UNDERRUN(x) ((x) << S_TXFIFO_UNDERRUN)
  1627. #define F_TXFIFO_UNDERRUN V_TXFIFO_UNDERRUN(1U)
  1628. #define S_RXFIFO_OVERFLOW 12
  1629. #define V_RXFIFO_OVERFLOW(x) ((x) << S_RXFIFO_OVERFLOW)
  1630. #define F_RXFIFO_OVERFLOW V_RXFIFO_OVERFLOW(1U)
  1631. #define S_SERDES_LOS 4
  1632. #define M_SERDES_LOS 0xf
  1633. #define V_SERDES_LOS(x) ((x) << S_SERDES_LOS)
  1634. #define S_XAUIPCSCTCERR 3
  1635. #define V_XAUIPCSCTCERR(x) ((x) << S_XAUIPCSCTCERR)
  1636. #define F_XAUIPCSCTCERR V_XAUIPCSCTCERR(1U)
  1637. #define S_XAUIPCSALIGNCHANGE 2
  1638. #define V_XAUIPCSALIGNCHANGE(x) ((x) << S_XAUIPCSALIGNCHANGE)
  1639. #define F_XAUIPCSALIGNCHANGE V_XAUIPCSALIGNCHANGE(1U)
  1640. #define S_XGM_INT 0
  1641. #define V_XGM_INT(x) ((x) << S_XGM_INT)
  1642. #define F_XGM_INT V_XGM_INT(1U)
  1643. #define A_XGM_INT_CAUSE 0x8d8
  1644. #define A_XGM_XAUI_ACT_CTRL 0x8dc
  1645. #define S_TXACTENABLE 1
  1646. #define V_TXACTENABLE(x) ((x) << S_TXACTENABLE)
  1647. #define F_TXACTENABLE V_TXACTENABLE(1U)
  1648. #define S_RESET3 23
  1649. #define V_RESET3(x) ((x) << S_RESET3)
  1650. #define F_RESET3 V_RESET3(1U)
  1651. #define S_RESET2 22
  1652. #define V_RESET2(x) ((x) << S_RESET2)
  1653. #define F_RESET2 V_RESET2(1U)
  1654. #define S_RESET1 21
  1655. #define V_RESET1(x) ((x) << S_RESET1)
  1656. #define F_RESET1 V_RESET1(1U)
  1657. #define S_RESET0 20
  1658. #define V_RESET0(x) ((x) << S_RESET0)
  1659. #define F_RESET0 V_RESET0(1U)
  1660. #define S_PWRDN3 19
  1661. #define V_PWRDN3(x) ((x) << S_PWRDN3)
  1662. #define F_PWRDN3 V_PWRDN3(1U)
  1663. #define S_PWRDN2 18
  1664. #define V_PWRDN2(x) ((x) << S_PWRDN2)
  1665. #define F_PWRDN2 V_PWRDN2(1U)
  1666. #define S_PWRDN1 17
  1667. #define V_PWRDN1(x) ((x) << S_PWRDN1)
  1668. #define F_PWRDN1 V_PWRDN1(1U)
  1669. #define S_PWRDN0 16
  1670. #define V_PWRDN0(x) ((x) << S_PWRDN0)
  1671. #define F_PWRDN0 V_PWRDN0(1U)
  1672. #define S_RESETPLL23 15
  1673. #define V_RESETPLL23(x) ((x) << S_RESETPLL23)
  1674. #define F_RESETPLL23 V_RESETPLL23(1U)
  1675. #define S_RESETPLL01 14
  1676. #define V_RESETPLL01(x) ((x) << S_RESETPLL01)
  1677. #define F_RESETPLL01 V_RESETPLL01(1U)
  1678. #define A_XGM_SERDES_STAT0 0x8f0
  1679. #define A_XGM_SERDES_STAT1 0x8f4
  1680. #define A_XGM_SERDES_STAT2 0x8f8
  1681. #define S_LOWSIG0 0
  1682. #define V_LOWSIG0(x) ((x) << S_LOWSIG0)
  1683. #define F_LOWSIG0 V_LOWSIG0(1U)
  1684. #define A_XGM_SERDES_STAT3 0x8fc
  1685. #define A_XGM_STAT_TX_BYTE_LOW 0x900
  1686. #define A_XGM_STAT_TX_BYTE_HIGH 0x904
  1687. #define A_XGM_STAT_TX_FRAME_LOW 0x908
  1688. #define A_XGM_STAT_TX_FRAME_HIGH 0x90c
  1689. #define A_XGM_STAT_TX_BCAST 0x910
  1690. #define A_XGM_STAT_TX_MCAST 0x914
  1691. #define A_XGM_STAT_TX_PAUSE 0x918
  1692. #define A_XGM_STAT_TX_64B_FRAMES 0x91c
  1693. #define A_XGM_STAT_TX_65_127B_FRAMES 0x920
  1694. #define A_XGM_STAT_TX_128_255B_FRAMES 0x924
  1695. #define A_XGM_STAT_TX_256_511B_FRAMES 0x928
  1696. #define A_XGM_STAT_TX_512_1023B_FRAMES 0x92c
  1697. #define A_XGM_STAT_TX_1024_1518B_FRAMES 0x930
  1698. #define A_XGM_STAT_TX_1519_MAXB_FRAMES 0x934
  1699. #define A_XGM_STAT_TX_ERR_FRAMES 0x938
  1700. #define A_XGM_STAT_RX_BYTES_LOW 0x93c
  1701. #define A_XGM_STAT_RX_BYTES_HIGH 0x940
  1702. #define A_XGM_STAT_RX_FRAMES_LOW 0x944
  1703. #define A_XGM_STAT_RX_FRAMES_HIGH 0x948
  1704. #define A_XGM_STAT_RX_BCAST_FRAMES 0x94c
  1705. #define A_XGM_STAT_RX_MCAST_FRAMES 0x950
  1706. #define A_XGM_STAT_RX_PAUSE_FRAMES 0x954
  1707. #define A_XGM_STAT_RX_64B_FRAMES 0x958
  1708. #define A_XGM_STAT_RX_65_127B_FRAMES 0x95c
  1709. #define A_XGM_STAT_RX_128_255B_FRAMES 0x960
  1710. #define A_XGM_STAT_RX_256_511B_FRAMES 0x964
  1711. #define A_XGM_STAT_RX_512_1023B_FRAMES 0x968
  1712. #define A_XGM_STAT_RX_1024_1518B_FRAMES 0x96c
  1713. #define A_XGM_STAT_RX_1519_MAXB_FRAMES 0x970
  1714. #define A_XGM_STAT_RX_SHORT_FRAMES 0x974
  1715. #define A_XGM_STAT_RX_OVERSIZE_FRAMES 0x978
  1716. #define A_XGM_STAT_RX_JABBER_FRAMES 0x97c
  1717. #define A_XGM_STAT_RX_CRC_ERR_FRAMES 0x980
  1718. #define A_XGM_STAT_RX_LENGTH_ERR_FRAMES 0x984
  1719. #define A_XGM_STAT_RX_SYM_CODE_ERR_FRAMES 0x988
  1720. #define A_XGM_SERDES_STATUS0 0x98c
  1721. #define A_XGM_SERDES_STATUS1 0x990
  1722. #define S_CMULOCK 31
  1723. #define V_CMULOCK(x) ((x) << S_CMULOCK)
  1724. #define F_CMULOCK V_CMULOCK(1U)
  1725. #define A_XGM_RX_MAX_PKT_SIZE_ERR_CNT 0x9a4
  1726. #define A_XGM_TX_SPI4_SOP_EOP_CNT 0x9a8
  1727. #define S_TXSPI4SOPCNT 16
  1728. #define M_TXSPI4SOPCNT 0xffff
  1729. #define V_TXSPI4SOPCNT(x) ((x) << S_TXSPI4SOPCNT)
  1730. #define G_TXSPI4SOPCNT(x) (((x) >> S_TXSPI4SOPCNT) & M_TXSPI4SOPCNT)
  1731. #define A_XGM_RX_SPI4_SOP_EOP_CNT 0x9ac
  1732. #define XGMAC0_1_BASE_ADDR 0xa00