omap_hwmod_33xx_data.c 84 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617
  1. /*
  2. * omap_hwmod_33xx_data.c: Hardware modules present on the AM33XX chips
  3. *
  4. * Copyright (C) {2012} Texas Instruments Incorporated - http://www.ti.com/
  5. *
  6. * This file is automatically generated from the AM33XX hardware databases.
  7. * This program is free software; you can redistribute it and/or
  8. * modify it under the terms of the GNU General Public License as
  9. * published by the Free Software Foundation version 2.
  10. *
  11. * This program is distributed "as is" WITHOUT ANY WARRANTY of any
  12. * kind, whether express or implied; without even the implied warranty
  13. * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. * GNU General Public License for more details.
  15. */
  16. #include <linux/i2c-omap.h>
  17. #include "omap_hwmod.h"
  18. #include <linux/platform_data/gpio-omap.h>
  19. #include <linux/platform_data/spi-omap2-mcspi.h>
  20. #include "omap_hwmod_common_data.h"
  21. #include "control.h"
  22. #include "cm33xx.h"
  23. #include "prm33xx.h"
  24. #include "prm-regbits-33xx.h"
  25. #include "i2c.h"
  26. #include "mmc.h"
  27. #include "wd_timer.h"
  28. /*
  29. * IP blocks
  30. */
  31. /*
  32. * 'emif_fw' class
  33. * instance(s): emif_fw
  34. */
  35. static struct omap_hwmod_class am33xx_emif_fw_hwmod_class = {
  36. .name = "emif_fw",
  37. };
  38. /* emif_fw */
  39. static struct omap_hwmod am33xx_emif_fw_hwmod = {
  40. .name = "emif_fw",
  41. .class = &am33xx_emif_fw_hwmod_class,
  42. .clkdm_name = "l4fw_clkdm",
  43. .main_clk = "l4fw_gclk",
  44. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  45. .prcm = {
  46. .omap4 = {
  47. .clkctrl_offs = AM33XX_CM_PER_EMIF_FW_CLKCTRL_OFFSET,
  48. .modulemode = MODULEMODE_SWCTRL,
  49. },
  50. },
  51. };
  52. /*
  53. * 'emif' class
  54. * instance(s): emif
  55. */
  56. static struct omap_hwmod_class_sysconfig am33xx_emif_sysc = {
  57. .rev_offs = 0x0000,
  58. };
  59. static struct omap_hwmod_class am33xx_emif_hwmod_class = {
  60. .name = "emif",
  61. .sysc = &am33xx_emif_sysc,
  62. };
  63. static struct omap_hwmod_irq_info am33xx_emif_irqs[] = {
  64. { .name = "ddrerr0", .irq = 101 + OMAP_INTC_START, },
  65. { .irq = -1 },
  66. };
  67. /* emif */
  68. static struct omap_hwmod am33xx_emif_hwmod = {
  69. .name = "emif",
  70. .class = &am33xx_emif_hwmod_class,
  71. .clkdm_name = "l3_clkdm",
  72. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  73. .mpu_irqs = am33xx_emif_irqs,
  74. .main_clk = "dpll_ddr_m2_div2_ck",
  75. .prcm = {
  76. .omap4 = {
  77. .clkctrl_offs = AM33XX_CM_PER_EMIF_CLKCTRL_OFFSET,
  78. .modulemode = MODULEMODE_SWCTRL,
  79. },
  80. },
  81. };
  82. /*
  83. * 'l3' class
  84. * instance(s): l3_main, l3_s, l3_instr
  85. */
  86. static struct omap_hwmod_class am33xx_l3_hwmod_class = {
  87. .name = "l3",
  88. };
  89. /* l3_main (l3_fast) */
  90. static struct omap_hwmod_irq_info am33xx_l3_main_irqs[] = {
  91. { .name = "l3debug", .irq = 9 + OMAP_INTC_START, },
  92. { .name = "l3appint", .irq = 10 + OMAP_INTC_START, },
  93. { .irq = -1 },
  94. };
  95. static struct omap_hwmod am33xx_l3_main_hwmod = {
  96. .name = "l3_main",
  97. .class = &am33xx_l3_hwmod_class,
  98. .clkdm_name = "l3_clkdm",
  99. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  100. .mpu_irqs = am33xx_l3_main_irqs,
  101. .main_clk = "l3_gclk",
  102. .prcm = {
  103. .omap4 = {
  104. .clkctrl_offs = AM33XX_CM_PER_L3_CLKCTRL_OFFSET,
  105. .modulemode = MODULEMODE_SWCTRL,
  106. },
  107. },
  108. };
  109. /* l3_s */
  110. static struct omap_hwmod am33xx_l3_s_hwmod = {
  111. .name = "l3_s",
  112. .class = &am33xx_l3_hwmod_class,
  113. .clkdm_name = "l3s_clkdm",
  114. };
  115. /* l3_instr */
  116. static struct omap_hwmod am33xx_l3_instr_hwmod = {
  117. .name = "l3_instr",
  118. .class = &am33xx_l3_hwmod_class,
  119. .clkdm_name = "l3_clkdm",
  120. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  121. .main_clk = "l3_gclk",
  122. .prcm = {
  123. .omap4 = {
  124. .clkctrl_offs = AM33XX_CM_PER_L3_INSTR_CLKCTRL_OFFSET,
  125. .modulemode = MODULEMODE_SWCTRL,
  126. },
  127. },
  128. };
  129. /*
  130. * 'l4' class
  131. * instance(s): l4_ls, l4_hs, l4_wkup, l4_fw
  132. */
  133. static struct omap_hwmod_class am33xx_l4_hwmod_class = {
  134. .name = "l4",
  135. };
  136. /* l4_ls */
  137. static struct omap_hwmod am33xx_l4_ls_hwmod = {
  138. .name = "l4_ls",
  139. .class = &am33xx_l4_hwmod_class,
  140. .clkdm_name = "l4ls_clkdm",
  141. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  142. .main_clk = "l4ls_gclk",
  143. .prcm = {
  144. .omap4 = {
  145. .clkctrl_offs = AM33XX_CM_PER_L4LS_CLKCTRL_OFFSET,
  146. .modulemode = MODULEMODE_SWCTRL,
  147. },
  148. },
  149. };
  150. /* l4_hs */
  151. static struct omap_hwmod am33xx_l4_hs_hwmod = {
  152. .name = "l4_hs",
  153. .class = &am33xx_l4_hwmod_class,
  154. .clkdm_name = "l4hs_clkdm",
  155. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  156. .main_clk = "l4hs_gclk",
  157. .prcm = {
  158. .omap4 = {
  159. .clkctrl_offs = AM33XX_CM_PER_L4HS_CLKCTRL_OFFSET,
  160. .modulemode = MODULEMODE_SWCTRL,
  161. },
  162. },
  163. };
  164. /* l4_wkup */
  165. static struct omap_hwmod am33xx_l4_wkup_hwmod = {
  166. .name = "l4_wkup",
  167. .class = &am33xx_l4_hwmod_class,
  168. .clkdm_name = "l4_wkup_clkdm",
  169. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  170. .prcm = {
  171. .omap4 = {
  172. .clkctrl_offs = AM33XX_CM_WKUP_L4WKUP_CLKCTRL_OFFSET,
  173. .modulemode = MODULEMODE_SWCTRL,
  174. },
  175. },
  176. };
  177. /* l4_fw */
  178. static struct omap_hwmod am33xx_l4_fw_hwmod = {
  179. .name = "l4_fw",
  180. .class = &am33xx_l4_hwmod_class,
  181. .clkdm_name = "l4fw_clkdm",
  182. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  183. .prcm = {
  184. .omap4 = {
  185. .clkctrl_offs = AM33XX_CM_PER_L4FW_CLKCTRL_OFFSET,
  186. .modulemode = MODULEMODE_SWCTRL,
  187. },
  188. },
  189. };
  190. /*
  191. * 'mpu' class
  192. */
  193. static struct omap_hwmod_class am33xx_mpu_hwmod_class = {
  194. .name = "mpu",
  195. };
  196. /* mpu */
  197. static struct omap_hwmod_irq_info am33xx_mpu_irqs[] = {
  198. { .name = "emuint", .irq = 0 + OMAP_INTC_START, },
  199. { .name = "commtx", .irq = 1 + OMAP_INTC_START, },
  200. { .name = "commrx", .irq = 2 + OMAP_INTC_START, },
  201. { .name = "bench", .irq = 3 + OMAP_INTC_START, },
  202. { .irq = -1 },
  203. };
  204. static struct omap_hwmod am33xx_mpu_hwmod = {
  205. .name = "mpu",
  206. .class = &am33xx_mpu_hwmod_class,
  207. .clkdm_name = "mpu_clkdm",
  208. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  209. .mpu_irqs = am33xx_mpu_irqs,
  210. .main_clk = "dpll_mpu_m2_ck",
  211. .prcm = {
  212. .omap4 = {
  213. .clkctrl_offs = AM33XX_CM_MPU_MPU_CLKCTRL_OFFSET,
  214. .modulemode = MODULEMODE_SWCTRL,
  215. },
  216. },
  217. };
  218. /*
  219. * 'wakeup m3' class
  220. * Wakeup controller sub-system under wakeup domain
  221. */
  222. static struct omap_hwmod_class am33xx_wkup_m3_hwmod_class = {
  223. .name = "wkup_m3",
  224. };
  225. static struct omap_hwmod_rst_info am33xx_wkup_m3_resets[] = {
  226. { .name = "wkup_m3", .rst_shift = 3, .st_shift = 5 },
  227. };
  228. static struct omap_hwmod_irq_info am33xx_wkup_m3_irqs[] = {
  229. { .name = "txev", .irq = 78 + OMAP_INTC_START, },
  230. { .irq = -1 },
  231. };
  232. /* wkup_m3 */
  233. static struct omap_hwmod am33xx_wkup_m3_hwmod = {
  234. .name = "wkup_m3",
  235. .class = &am33xx_wkup_m3_hwmod_class,
  236. .clkdm_name = "l4_wkup_aon_clkdm",
  237. /* Keep hardreset asserted */
  238. .flags = HWMOD_INIT_NO_RESET | HWMOD_NO_IDLEST,
  239. .mpu_irqs = am33xx_wkup_m3_irqs,
  240. .main_clk = "dpll_core_m4_div2_ck",
  241. .prcm = {
  242. .omap4 = {
  243. .clkctrl_offs = AM33XX_CM_WKUP_WKUP_M3_CLKCTRL_OFFSET,
  244. .rstctrl_offs = AM33XX_RM_WKUP_RSTCTRL_OFFSET,
  245. .rstst_offs = AM33XX_RM_WKUP_RSTST_OFFSET,
  246. .modulemode = MODULEMODE_SWCTRL,
  247. },
  248. },
  249. .rst_lines = am33xx_wkup_m3_resets,
  250. .rst_lines_cnt = ARRAY_SIZE(am33xx_wkup_m3_resets),
  251. };
  252. /*
  253. * 'pru-icss' class
  254. * Programmable Real-Time Unit and Industrial Communication Subsystem
  255. */
  256. static struct omap_hwmod_class am33xx_pruss_hwmod_class = {
  257. .name = "pruss",
  258. };
  259. static struct omap_hwmod_rst_info am33xx_pruss_resets[] = {
  260. { .name = "pruss", .rst_shift = 1 },
  261. };
  262. static struct omap_hwmod_irq_info am33xx_pruss_irqs[] = {
  263. { .name = "evtout0", .irq = 20 + OMAP_INTC_START, },
  264. { .name = "evtout1", .irq = 21 + OMAP_INTC_START, },
  265. { .name = "evtout2", .irq = 22 + OMAP_INTC_START, },
  266. { .name = "evtout3", .irq = 23 + OMAP_INTC_START, },
  267. { .name = "evtout4", .irq = 24 + OMAP_INTC_START, },
  268. { .name = "evtout5", .irq = 25 + OMAP_INTC_START, },
  269. { .name = "evtout6", .irq = 26 + OMAP_INTC_START, },
  270. { .name = "evtout7", .irq = 27 + OMAP_INTC_START, },
  271. { .irq = -1 },
  272. };
  273. /* pru-icss */
  274. /* Pseudo hwmod for reset control purpose only */
  275. static struct omap_hwmod am33xx_pruss_hwmod = {
  276. .name = "pruss",
  277. .class = &am33xx_pruss_hwmod_class,
  278. .clkdm_name = "pruss_ocp_clkdm",
  279. .mpu_irqs = am33xx_pruss_irqs,
  280. .main_clk = "pruss_ocp_gclk",
  281. .prcm = {
  282. .omap4 = {
  283. .clkctrl_offs = AM33XX_CM_PER_PRUSS_CLKCTRL_OFFSET,
  284. .rstctrl_offs = AM33XX_RM_PER_RSTCTRL_OFFSET,
  285. .modulemode = MODULEMODE_SWCTRL,
  286. },
  287. },
  288. .rst_lines = am33xx_pruss_resets,
  289. .rst_lines_cnt = ARRAY_SIZE(am33xx_pruss_resets),
  290. };
  291. /* gfx */
  292. /* Pseudo hwmod for reset control purpose only */
  293. static struct omap_hwmod_class am33xx_gfx_hwmod_class = {
  294. .name = "gfx",
  295. };
  296. static struct omap_hwmod_rst_info am33xx_gfx_resets[] = {
  297. { .name = "gfx", .rst_shift = 0, .st_shift = 0},
  298. };
  299. static struct omap_hwmod_irq_info am33xx_gfx_irqs[] = {
  300. { .name = "gfxint", .irq = 37 + OMAP_INTC_START, },
  301. { .irq = -1 },
  302. };
  303. static struct omap_hwmod am33xx_gfx_hwmod = {
  304. .name = "gfx",
  305. .class = &am33xx_gfx_hwmod_class,
  306. .clkdm_name = "gfx_l3_clkdm",
  307. .mpu_irqs = am33xx_gfx_irqs,
  308. .main_clk = "gfx_fck_div_ck",
  309. .prcm = {
  310. .omap4 = {
  311. .clkctrl_offs = AM33XX_CM_GFX_GFX_CLKCTRL_OFFSET,
  312. .rstctrl_offs = AM33XX_RM_GFX_RSTCTRL_OFFSET,
  313. .rstst_offs = AM33XX_RM_GFX_RSTST_OFFSET,
  314. .modulemode = MODULEMODE_SWCTRL,
  315. },
  316. },
  317. .rst_lines = am33xx_gfx_resets,
  318. .rst_lines_cnt = ARRAY_SIZE(am33xx_gfx_resets),
  319. };
  320. /*
  321. * 'prcm' class
  322. * power and reset manager (whole prcm infrastructure)
  323. */
  324. static struct omap_hwmod_class am33xx_prcm_hwmod_class = {
  325. .name = "prcm",
  326. };
  327. /* prcm */
  328. static struct omap_hwmod am33xx_prcm_hwmod = {
  329. .name = "prcm",
  330. .class = &am33xx_prcm_hwmod_class,
  331. .clkdm_name = "l4_wkup_clkdm",
  332. };
  333. /*
  334. * 'adc/tsc' class
  335. * TouchScreen Controller (Anolog-To-Digital Converter)
  336. */
  337. static struct omap_hwmod_class_sysconfig am33xx_adc_tsc_sysc = {
  338. .rev_offs = 0x00,
  339. .sysc_offs = 0x10,
  340. .sysc_flags = SYSC_HAS_SIDLEMODE,
  341. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  342. SIDLE_SMART_WKUP),
  343. .sysc_fields = &omap_hwmod_sysc_type2,
  344. };
  345. static struct omap_hwmod_class am33xx_adc_tsc_hwmod_class = {
  346. .name = "adc_tsc",
  347. .sysc = &am33xx_adc_tsc_sysc,
  348. };
  349. static struct omap_hwmod_irq_info am33xx_adc_tsc_irqs[] = {
  350. { .irq = 16 + OMAP_INTC_START, },
  351. { .irq = -1 },
  352. };
  353. static struct omap_hwmod am33xx_adc_tsc_hwmod = {
  354. .name = "adc_tsc",
  355. .class = &am33xx_adc_tsc_hwmod_class,
  356. .clkdm_name = "l4_wkup_clkdm",
  357. .mpu_irqs = am33xx_adc_tsc_irqs,
  358. .main_clk = "adc_tsc_fck",
  359. .prcm = {
  360. .omap4 = {
  361. .clkctrl_offs = AM33XX_CM_WKUP_ADC_TSC_CLKCTRL_OFFSET,
  362. .modulemode = MODULEMODE_SWCTRL,
  363. },
  364. },
  365. };
  366. /*
  367. * Modules omap_hwmod structures
  368. *
  369. * The following IPs are excluded for the moment because:
  370. * - They do not need an explicit SW control using omap_hwmod API.
  371. * - They still need to be validated with the driver
  372. * properly adapted to omap_hwmod / omap_device
  373. *
  374. * - cEFUSE (doesn't fall under any ocp_if)
  375. * - clkdiv32k
  376. * - debugss
  377. * - ocp watch point
  378. */
  379. #if 0
  380. /*
  381. * 'cefuse' class
  382. */
  383. static struct omap_hwmod_class am33xx_cefuse_hwmod_class = {
  384. .name = "cefuse",
  385. };
  386. static struct omap_hwmod am33xx_cefuse_hwmod = {
  387. .name = "cefuse",
  388. .class = &am33xx_cefuse_hwmod_class,
  389. .clkdm_name = "l4_cefuse_clkdm",
  390. .main_clk = "cefuse_fck",
  391. .prcm = {
  392. .omap4 = {
  393. .clkctrl_offs = AM33XX_CM_CEFUSE_CEFUSE_CLKCTRL_OFFSET,
  394. .modulemode = MODULEMODE_SWCTRL,
  395. },
  396. },
  397. };
  398. /*
  399. * 'clkdiv32k' class
  400. */
  401. static struct omap_hwmod_class am33xx_clkdiv32k_hwmod_class = {
  402. .name = "clkdiv32k",
  403. };
  404. static struct omap_hwmod am33xx_clkdiv32k_hwmod = {
  405. .name = "clkdiv32k",
  406. .class = &am33xx_clkdiv32k_hwmod_class,
  407. .clkdm_name = "clk_24mhz_clkdm",
  408. .main_clk = "clkdiv32k_ick",
  409. .prcm = {
  410. .omap4 = {
  411. .clkctrl_offs = AM33XX_CM_PER_CLKDIV32K_CLKCTRL_OFFSET,
  412. .modulemode = MODULEMODE_SWCTRL,
  413. },
  414. },
  415. };
  416. /*
  417. * 'debugss' class
  418. * debug sub system
  419. */
  420. static struct omap_hwmod_class am33xx_debugss_hwmod_class = {
  421. .name = "debugss",
  422. };
  423. static struct omap_hwmod am33xx_debugss_hwmod = {
  424. .name = "debugss",
  425. .class = &am33xx_debugss_hwmod_class,
  426. .clkdm_name = "l3_aon_clkdm",
  427. .main_clk = "debugss_ick",
  428. .prcm = {
  429. .omap4 = {
  430. .clkctrl_offs = AM33XX_CM_WKUP_DEBUGSS_CLKCTRL_OFFSET,
  431. .modulemode = MODULEMODE_SWCTRL,
  432. },
  433. },
  434. };
  435. /* ocpwp */
  436. static struct omap_hwmod_class am33xx_ocpwp_hwmod_class = {
  437. .name = "ocpwp",
  438. };
  439. static struct omap_hwmod am33xx_ocpwp_hwmod = {
  440. .name = "ocpwp",
  441. .class = &am33xx_ocpwp_hwmod_class,
  442. .clkdm_name = "l4ls_clkdm",
  443. .main_clk = "l4ls_gclk",
  444. .prcm = {
  445. .omap4 = {
  446. .clkctrl_offs = AM33XX_CM_PER_OCPWP_CLKCTRL_OFFSET,
  447. .modulemode = MODULEMODE_SWCTRL,
  448. },
  449. },
  450. };
  451. #endif
  452. /*
  453. * 'aes0' class
  454. */
  455. static struct omap_hwmod_class_sysconfig am33xx_aes0_sysc = {
  456. .rev_offs = 0x80,
  457. .sysc_offs = 0x84,
  458. .syss_offs = 0x88,
  459. .sysc_flags = SYSS_HAS_RESET_STATUS,
  460. };
  461. static struct omap_hwmod_class am33xx_aes0_hwmod_class = {
  462. .name = "aes0",
  463. .sysc = &am33xx_aes0_sysc,
  464. };
  465. static struct omap_hwmod_irq_info am33xx_aes0_irqs[] = {
  466. { .irq = 103 + OMAP_INTC_START, },
  467. { .irq = -1 },
  468. };
  469. static struct omap_hwmod_dma_info am33xx_aes0_edma_reqs[] = {
  470. { .name = "tx", .dma_req = 6, },
  471. { .name = "rx", .dma_req = 5, },
  472. { .dma_req = -1 }
  473. };
  474. static struct omap_hwmod am33xx_aes0_hwmod = {
  475. .name = "aes",
  476. .class = &am33xx_aes0_hwmod_class,
  477. .clkdm_name = "l3_clkdm",
  478. .mpu_irqs = am33xx_aes0_irqs,
  479. .sdma_reqs = am33xx_aes0_edma_reqs,
  480. .main_clk = "aes0_fck",
  481. .prcm = {
  482. .omap4 = {
  483. .clkctrl_offs = AM33XX_CM_PER_AES0_CLKCTRL_OFFSET,
  484. .modulemode = MODULEMODE_SWCTRL,
  485. },
  486. },
  487. };
  488. /* sha0 HIB2 (the 'P' (public) device) */
  489. static struct omap_hwmod_class_sysconfig am33xx_sha0_sysc = {
  490. .rev_offs = 0x100,
  491. .sysc_offs = 0x110,
  492. .syss_offs = 0x114,
  493. .sysc_flags = SYSS_HAS_RESET_STATUS,
  494. };
  495. static struct omap_hwmod_class am33xx_sha0_hwmod_class = {
  496. .name = "sha0",
  497. .sysc = &am33xx_sha0_sysc,
  498. };
  499. static struct omap_hwmod_irq_info am33xx_sha0_irqs[] = {
  500. { .irq = 109 + OMAP_INTC_START, },
  501. { .irq = -1 },
  502. };
  503. static struct omap_hwmod_dma_info am33xx_sha0_edma_reqs[] = {
  504. { .name = "rx", .dma_req = 36, },
  505. { .dma_req = -1 }
  506. };
  507. static struct omap_hwmod am33xx_sha0_hwmod = {
  508. .name = "sham",
  509. .class = &am33xx_sha0_hwmod_class,
  510. .clkdm_name = "l3_clkdm",
  511. .mpu_irqs = am33xx_sha0_irqs,
  512. .sdma_reqs = am33xx_sha0_edma_reqs,
  513. .main_clk = "l3_gclk",
  514. .prcm = {
  515. .omap4 = {
  516. .clkctrl_offs = AM33XX_CM_PER_SHA0_CLKCTRL_OFFSET,
  517. .modulemode = MODULEMODE_SWCTRL,
  518. },
  519. },
  520. };
  521. /* ocmcram */
  522. static struct omap_hwmod_class am33xx_ocmcram_hwmod_class = {
  523. .name = "ocmcram",
  524. };
  525. static struct omap_hwmod am33xx_ocmcram_hwmod = {
  526. .name = "ocmcram",
  527. .class = &am33xx_ocmcram_hwmod_class,
  528. .clkdm_name = "l3_clkdm",
  529. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  530. .main_clk = "l3_gclk",
  531. .prcm = {
  532. .omap4 = {
  533. .clkctrl_offs = AM33XX_CM_PER_OCMCRAM_CLKCTRL_OFFSET,
  534. .modulemode = MODULEMODE_SWCTRL,
  535. },
  536. },
  537. };
  538. /* 'smartreflex' class */
  539. static struct omap_hwmod_class am33xx_smartreflex_hwmod_class = {
  540. .name = "smartreflex",
  541. };
  542. /* smartreflex0 */
  543. static struct omap_hwmod_irq_info am33xx_smartreflex0_irqs[] = {
  544. { .irq = 120 + OMAP_INTC_START, },
  545. { .irq = -1 },
  546. };
  547. static struct omap_hwmod am33xx_smartreflex0_hwmod = {
  548. .name = "smartreflex0",
  549. .class = &am33xx_smartreflex_hwmod_class,
  550. .clkdm_name = "l4_wkup_clkdm",
  551. .mpu_irqs = am33xx_smartreflex0_irqs,
  552. .main_clk = "smartreflex0_fck",
  553. .prcm = {
  554. .omap4 = {
  555. .clkctrl_offs = AM33XX_CM_WKUP_SMARTREFLEX0_CLKCTRL_OFFSET,
  556. .modulemode = MODULEMODE_SWCTRL,
  557. },
  558. },
  559. };
  560. /* smartreflex1 */
  561. static struct omap_hwmod_irq_info am33xx_smartreflex1_irqs[] = {
  562. { .irq = 121 + OMAP_INTC_START, },
  563. { .irq = -1 },
  564. };
  565. static struct omap_hwmod am33xx_smartreflex1_hwmod = {
  566. .name = "smartreflex1",
  567. .class = &am33xx_smartreflex_hwmod_class,
  568. .clkdm_name = "l4_wkup_clkdm",
  569. .mpu_irqs = am33xx_smartreflex1_irqs,
  570. .main_clk = "smartreflex1_fck",
  571. .prcm = {
  572. .omap4 = {
  573. .clkctrl_offs = AM33XX_CM_WKUP_SMARTREFLEX1_CLKCTRL_OFFSET,
  574. .modulemode = MODULEMODE_SWCTRL,
  575. },
  576. },
  577. };
  578. /*
  579. * 'control' module class
  580. */
  581. static struct omap_hwmod_class am33xx_control_hwmod_class = {
  582. .name = "control",
  583. };
  584. static struct omap_hwmod_irq_info am33xx_control_irqs[] = {
  585. { .irq = 8 + OMAP_INTC_START, },
  586. { .irq = -1 },
  587. };
  588. static struct omap_hwmod am33xx_control_hwmod = {
  589. .name = "control",
  590. .class = &am33xx_control_hwmod_class,
  591. .clkdm_name = "l4_wkup_clkdm",
  592. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  593. .mpu_irqs = am33xx_control_irqs,
  594. .main_clk = "dpll_core_m4_div2_ck",
  595. .prcm = {
  596. .omap4 = {
  597. .clkctrl_offs = AM33XX_CM_WKUP_CONTROL_CLKCTRL_OFFSET,
  598. .modulemode = MODULEMODE_SWCTRL,
  599. },
  600. },
  601. };
  602. /*
  603. * 'cpgmac' class
  604. * cpsw/cpgmac sub system
  605. */
  606. static struct omap_hwmod_class_sysconfig am33xx_cpgmac_sysc = {
  607. .rev_offs = 0x0,
  608. .sysc_offs = 0x8,
  609. .syss_offs = 0x4,
  610. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE |
  611. SYSS_HAS_RESET_STATUS),
  612. .idlemodes = (SIDLE_FORCE | SIDLE_NO | MSTANDBY_FORCE |
  613. MSTANDBY_NO),
  614. .sysc_fields = &omap_hwmod_sysc_type3,
  615. };
  616. static struct omap_hwmod_class am33xx_cpgmac0_hwmod_class = {
  617. .name = "cpgmac0",
  618. .sysc = &am33xx_cpgmac_sysc,
  619. };
  620. static struct omap_hwmod_irq_info am33xx_cpgmac0_irqs[] = {
  621. { .name = "c0_rx_thresh_pend", .irq = 40 + OMAP_INTC_START, },
  622. { .name = "c0_rx_pend", .irq = 41 + OMAP_INTC_START, },
  623. { .name = "c0_tx_pend", .irq = 42 + OMAP_INTC_START, },
  624. { .name = "c0_misc_pend", .irq = 43 + OMAP_INTC_START, },
  625. { .irq = -1 },
  626. };
  627. static struct omap_hwmod am33xx_cpgmac0_hwmod = {
  628. .name = "cpgmac0",
  629. .class = &am33xx_cpgmac0_hwmod_class,
  630. .clkdm_name = "cpsw_125mhz_clkdm",
  631. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  632. .mpu_irqs = am33xx_cpgmac0_irqs,
  633. .main_clk = "cpsw_125mhz_gclk",
  634. .prcm = {
  635. .omap4 = {
  636. .clkctrl_offs = AM33XX_CM_PER_CPGMAC0_CLKCTRL_OFFSET,
  637. .modulemode = MODULEMODE_SWCTRL,
  638. },
  639. },
  640. };
  641. /*
  642. * mdio class
  643. */
  644. static struct omap_hwmod_class am33xx_mdio_hwmod_class = {
  645. .name = "davinci_mdio",
  646. };
  647. static struct omap_hwmod am33xx_mdio_hwmod = {
  648. .name = "davinci_mdio",
  649. .class = &am33xx_mdio_hwmod_class,
  650. .clkdm_name = "cpsw_125mhz_clkdm",
  651. .main_clk = "cpsw_125mhz_gclk",
  652. };
  653. /*
  654. * dcan class
  655. */
  656. static struct omap_hwmod_class am33xx_dcan_hwmod_class = {
  657. .name = "d_can",
  658. };
  659. /* dcan0 */
  660. static struct omap_hwmod_irq_info am33xx_dcan0_irqs[] = {
  661. { .name = "d_can_ms", .irq = 52 + OMAP_INTC_START, },
  662. { .name = "d_can_mo", .irq = 53 + OMAP_INTC_START, },
  663. { .irq = -1 },
  664. };
  665. static struct omap_hwmod am33xx_dcan0_hwmod = {
  666. .name = "d_can0",
  667. .class = &am33xx_dcan_hwmod_class,
  668. .clkdm_name = "l4ls_clkdm",
  669. .mpu_irqs = am33xx_dcan0_irqs,
  670. .main_clk = "dcan0_fck",
  671. .prcm = {
  672. .omap4 = {
  673. .clkctrl_offs = AM33XX_CM_PER_DCAN0_CLKCTRL_OFFSET,
  674. .modulemode = MODULEMODE_SWCTRL,
  675. },
  676. },
  677. };
  678. /* dcan1 */
  679. static struct omap_hwmod_irq_info am33xx_dcan1_irqs[] = {
  680. { .name = "d_can_ms", .irq = 55 + OMAP_INTC_START, },
  681. { .name = "d_can_mo", .irq = 56 + OMAP_INTC_START, },
  682. { .irq = -1 },
  683. };
  684. static struct omap_hwmod am33xx_dcan1_hwmod = {
  685. .name = "d_can1",
  686. .class = &am33xx_dcan_hwmod_class,
  687. .clkdm_name = "l4ls_clkdm",
  688. .mpu_irqs = am33xx_dcan1_irqs,
  689. .main_clk = "dcan1_fck",
  690. .prcm = {
  691. .omap4 = {
  692. .clkctrl_offs = AM33XX_CM_PER_DCAN1_CLKCTRL_OFFSET,
  693. .modulemode = MODULEMODE_SWCTRL,
  694. },
  695. },
  696. };
  697. /* elm */
  698. static struct omap_hwmod_class_sysconfig am33xx_elm_sysc = {
  699. .rev_offs = 0x0000,
  700. .sysc_offs = 0x0010,
  701. .syss_offs = 0x0014,
  702. .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
  703. SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
  704. SYSS_HAS_RESET_STATUS),
  705. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  706. .sysc_fields = &omap_hwmod_sysc_type1,
  707. };
  708. static struct omap_hwmod_class am33xx_elm_hwmod_class = {
  709. .name = "elm",
  710. .sysc = &am33xx_elm_sysc,
  711. };
  712. static struct omap_hwmod_irq_info am33xx_elm_irqs[] = {
  713. { .irq = 4 + OMAP_INTC_START, },
  714. { .irq = -1 },
  715. };
  716. static struct omap_hwmod am33xx_elm_hwmod = {
  717. .name = "elm",
  718. .class = &am33xx_elm_hwmod_class,
  719. .clkdm_name = "l4ls_clkdm",
  720. .mpu_irqs = am33xx_elm_irqs,
  721. .main_clk = "l4ls_gclk",
  722. .prcm = {
  723. .omap4 = {
  724. .clkctrl_offs = AM33XX_CM_PER_ELM_CLKCTRL_OFFSET,
  725. .modulemode = MODULEMODE_SWCTRL,
  726. },
  727. },
  728. };
  729. /* pwmss */
  730. static struct omap_hwmod_class_sysconfig am33xx_epwmss_sysc = {
  731. .rev_offs = 0x0,
  732. .sysc_offs = 0x4,
  733. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE),
  734. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  735. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  736. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  737. .sysc_fields = &omap_hwmod_sysc_type2,
  738. };
  739. static struct omap_hwmod_class am33xx_epwmss_hwmod_class = {
  740. .name = "epwmss",
  741. .sysc = &am33xx_epwmss_sysc,
  742. };
  743. static struct omap_hwmod_class am33xx_ecap_hwmod_class = {
  744. .name = "ecap",
  745. };
  746. static struct omap_hwmod_class am33xx_eqep_hwmod_class = {
  747. .name = "eqep",
  748. };
  749. static struct omap_hwmod_class am33xx_ehrpwm_hwmod_class = {
  750. .name = "ehrpwm",
  751. };
  752. /* epwmss0 */
  753. static struct omap_hwmod am33xx_epwmss0_hwmod = {
  754. .name = "epwmss0",
  755. .class = &am33xx_epwmss_hwmod_class,
  756. .clkdm_name = "l4ls_clkdm",
  757. .main_clk = "l4ls_gclk",
  758. .prcm = {
  759. .omap4 = {
  760. .clkctrl_offs = AM33XX_CM_PER_EPWMSS0_CLKCTRL_OFFSET,
  761. .modulemode = MODULEMODE_SWCTRL,
  762. },
  763. },
  764. };
  765. /* ecap0 */
  766. static struct omap_hwmod_irq_info am33xx_ecap0_irqs[] = {
  767. { .irq = 31 + OMAP_INTC_START, },
  768. { .irq = -1 },
  769. };
  770. static struct omap_hwmod am33xx_ecap0_hwmod = {
  771. .name = "ecap0",
  772. .class = &am33xx_ecap_hwmod_class,
  773. .clkdm_name = "l4ls_clkdm",
  774. .mpu_irqs = am33xx_ecap0_irqs,
  775. .main_clk = "l4ls_gclk",
  776. };
  777. /* eqep0 */
  778. static struct omap_hwmod_irq_info am33xx_eqep0_irqs[] = {
  779. { .irq = 79 + OMAP_INTC_START, },
  780. { .irq = -1 },
  781. };
  782. static struct omap_hwmod am33xx_eqep0_hwmod = {
  783. .name = "eqep0",
  784. .class = &am33xx_eqep_hwmod_class,
  785. .clkdm_name = "l4ls_clkdm",
  786. .mpu_irqs = am33xx_eqep0_irqs,
  787. .main_clk = "l4ls_gclk",
  788. };
  789. /* ehrpwm0 */
  790. static struct omap_hwmod_irq_info am33xx_ehrpwm0_irqs[] = {
  791. { .name = "int", .irq = 86 + OMAP_INTC_START, },
  792. { .name = "tzint", .irq = 58 + OMAP_INTC_START, },
  793. { .irq = -1 },
  794. };
  795. static struct omap_hwmod am33xx_ehrpwm0_hwmod = {
  796. .name = "ehrpwm0",
  797. .class = &am33xx_ehrpwm_hwmod_class,
  798. .clkdm_name = "l4ls_clkdm",
  799. .mpu_irqs = am33xx_ehrpwm0_irqs,
  800. .main_clk = "l4ls_gclk",
  801. };
  802. /* epwmss1 */
  803. static struct omap_hwmod am33xx_epwmss1_hwmod = {
  804. .name = "epwmss1",
  805. .class = &am33xx_epwmss_hwmod_class,
  806. .clkdm_name = "l4ls_clkdm",
  807. .main_clk = "l4ls_gclk",
  808. .prcm = {
  809. .omap4 = {
  810. .clkctrl_offs = AM33XX_CM_PER_EPWMSS1_CLKCTRL_OFFSET,
  811. .modulemode = MODULEMODE_SWCTRL,
  812. },
  813. },
  814. };
  815. /* ecap1 */
  816. static struct omap_hwmod_irq_info am33xx_ecap1_irqs[] = {
  817. { .irq = 47 + OMAP_INTC_START, },
  818. { .irq = -1 },
  819. };
  820. static struct omap_hwmod am33xx_ecap1_hwmod = {
  821. .name = "ecap1",
  822. .class = &am33xx_ecap_hwmod_class,
  823. .clkdm_name = "l4ls_clkdm",
  824. .mpu_irqs = am33xx_ecap1_irqs,
  825. .main_clk = "l4ls_gclk",
  826. };
  827. /* eqep1 */
  828. static struct omap_hwmod_irq_info am33xx_eqep1_irqs[] = {
  829. { .irq = 88 + OMAP_INTC_START, },
  830. { .irq = -1 },
  831. };
  832. static struct omap_hwmod am33xx_eqep1_hwmod = {
  833. .name = "eqep1",
  834. .class = &am33xx_eqep_hwmod_class,
  835. .clkdm_name = "l4ls_clkdm",
  836. .mpu_irqs = am33xx_eqep1_irqs,
  837. .main_clk = "l4ls_gclk",
  838. };
  839. /* ehrpwm1 */
  840. static struct omap_hwmod_irq_info am33xx_ehrpwm1_irqs[] = {
  841. { .name = "int", .irq = 87 + OMAP_INTC_START, },
  842. { .name = "tzint", .irq = 59 + OMAP_INTC_START, },
  843. { .irq = -1 },
  844. };
  845. static struct omap_hwmod am33xx_ehrpwm1_hwmod = {
  846. .name = "ehrpwm1",
  847. .class = &am33xx_ehrpwm_hwmod_class,
  848. .clkdm_name = "l4ls_clkdm",
  849. .mpu_irqs = am33xx_ehrpwm1_irqs,
  850. .main_clk = "l4ls_gclk",
  851. };
  852. /* epwmss2 */
  853. static struct omap_hwmod am33xx_epwmss2_hwmod = {
  854. .name = "epwmss2",
  855. .class = &am33xx_epwmss_hwmod_class,
  856. .clkdm_name = "l4ls_clkdm",
  857. .main_clk = "l4ls_gclk",
  858. .prcm = {
  859. .omap4 = {
  860. .clkctrl_offs = AM33XX_CM_PER_EPWMSS2_CLKCTRL_OFFSET,
  861. .modulemode = MODULEMODE_SWCTRL,
  862. },
  863. },
  864. };
  865. /* ecap2 */
  866. static struct omap_hwmod_irq_info am33xx_ecap2_irqs[] = {
  867. { .irq = 61 + OMAP_INTC_START, },
  868. { .irq = -1 },
  869. };
  870. static struct omap_hwmod am33xx_ecap2_hwmod = {
  871. .name = "ecap2",
  872. .class = &am33xx_ecap_hwmod_class,
  873. .clkdm_name = "l4ls_clkdm",
  874. .mpu_irqs = am33xx_ecap2_irqs,
  875. .main_clk = "l4ls_gclk",
  876. };
  877. /* eqep2 */
  878. static struct omap_hwmod_irq_info am33xx_eqep2_irqs[] = {
  879. { .irq = 89 + OMAP_INTC_START, },
  880. { .irq = -1 },
  881. };
  882. static struct omap_hwmod am33xx_eqep2_hwmod = {
  883. .name = "eqep2",
  884. .class = &am33xx_eqep_hwmod_class,
  885. .clkdm_name = "l4ls_clkdm",
  886. .mpu_irqs = am33xx_eqep2_irqs,
  887. .main_clk = "l4ls_gclk",
  888. };
  889. /* ehrpwm2 */
  890. static struct omap_hwmod_irq_info am33xx_ehrpwm2_irqs[] = {
  891. { .name = "int", .irq = 39 + OMAP_INTC_START, },
  892. { .name = "tzint", .irq = 60 + OMAP_INTC_START, },
  893. { .irq = -1 },
  894. };
  895. static struct omap_hwmod am33xx_ehrpwm2_hwmod = {
  896. .name = "ehrpwm2",
  897. .class = &am33xx_ehrpwm_hwmod_class,
  898. .clkdm_name = "l4ls_clkdm",
  899. .mpu_irqs = am33xx_ehrpwm2_irqs,
  900. .main_clk = "l4ls_gclk",
  901. };
  902. /*
  903. * 'gpio' class: for gpio 0,1,2,3
  904. */
  905. static struct omap_hwmod_class_sysconfig am33xx_gpio_sysc = {
  906. .rev_offs = 0x0000,
  907. .sysc_offs = 0x0010,
  908. .syss_offs = 0x0114,
  909. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  910. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  911. SYSS_HAS_RESET_STATUS),
  912. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  913. SIDLE_SMART_WKUP),
  914. .sysc_fields = &omap_hwmod_sysc_type1,
  915. };
  916. static struct omap_hwmod_class am33xx_gpio_hwmod_class = {
  917. .name = "gpio",
  918. .sysc = &am33xx_gpio_sysc,
  919. .rev = 2,
  920. };
  921. static struct omap_gpio_dev_attr gpio_dev_attr = {
  922. .bank_width = 32,
  923. .dbck_flag = true,
  924. };
  925. /* gpio0 */
  926. static struct omap_hwmod_opt_clk gpio0_opt_clks[] = {
  927. { .role = "dbclk", .clk = "gpio0_dbclk" },
  928. };
  929. static struct omap_hwmod_irq_info am33xx_gpio0_irqs[] = {
  930. { .irq = 96 + OMAP_INTC_START, },
  931. { .irq = -1 },
  932. };
  933. static struct omap_hwmod am33xx_gpio0_hwmod = {
  934. .name = "gpio1",
  935. .class = &am33xx_gpio_hwmod_class,
  936. .clkdm_name = "l4_wkup_clkdm",
  937. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  938. .mpu_irqs = am33xx_gpio0_irqs,
  939. .main_clk = "dpll_core_m4_div2_ck",
  940. .prcm = {
  941. .omap4 = {
  942. .clkctrl_offs = AM33XX_CM_WKUP_GPIO0_CLKCTRL_OFFSET,
  943. .modulemode = MODULEMODE_SWCTRL,
  944. },
  945. },
  946. .opt_clks = gpio0_opt_clks,
  947. .opt_clks_cnt = ARRAY_SIZE(gpio0_opt_clks),
  948. .dev_attr = &gpio_dev_attr,
  949. };
  950. /* gpio1 */
  951. static struct omap_hwmod_irq_info am33xx_gpio1_irqs[] = {
  952. { .irq = 98 + OMAP_INTC_START, },
  953. { .irq = -1 },
  954. };
  955. static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
  956. { .role = "dbclk", .clk = "gpio1_dbclk" },
  957. };
  958. static struct omap_hwmod am33xx_gpio1_hwmod = {
  959. .name = "gpio2",
  960. .class = &am33xx_gpio_hwmod_class,
  961. .clkdm_name = "l4ls_clkdm",
  962. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  963. .mpu_irqs = am33xx_gpio1_irqs,
  964. .main_clk = "l4ls_gclk",
  965. .prcm = {
  966. .omap4 = {
  967. .clkctrl_offs = AM33XX_CM_PER_GPIO1_CLKCTRL_OFFSET,
  968. .modulemode = MODULEMODE_SWCTRL,
  969. },
  970. },
  971. .opt_clks = gpio1_opt_clks,
  972. .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
  973. .dev_attr = &gpio_dev_attr,
  974. };
  975. /* gpio2 */
  976. static struct omap_hwmod_irq_info am33xx_gpio2_irqs[] = {
  977. { .irq = 32 + OMAP_INTC_START, },
  978. { .irq = -1 },
  979. };
  980. static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
  981. { .role = "dbclk", .clk = "gpio2_dbclk" },
  982. };
  983. static struct omap_hwmod am33xx_gpio2_hwmod = {
  984. .name = "gpio3",
  985. .class = &am33xx_gpio_hwmod_class,
  986. .clkdm_name = "l4ls_clkdm",
  987. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  988. .mpu_irqs = am33xx_gpio2_irqs,
  989. .main_clk = "l4ls_gclk",
  990. .prcm = {
  991. .omap4 = {
  992. .clkctrl_offs = AM33XX_CM_PER_GPIO2_CLKCTRL_OFFSET,
  993. .modulemode = MODULEMODE_SWCTRL,
  994. },
  995. },
  996. .opt_clks = gpio2_opt_clks,
  997. .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
  998. .dev_attr = &gpio_dev_attr,
  999. };
  1000. /* gpio3 */
  1001. static struct omap_hwmod_irq_info am33xx_gpio3_irqs[] = {
  1002. { .irq = 62 + OMAP_INTC_START, },
  1003. { .irq = -1 },
  1004. };
  1005. static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
  1006. { .role = "dbclk", .clk = "gpio3_dbclk" },
  1007. };
  1008. static struct omap_hwmod am33xx_gpio3_hwmod = {
  1009. .name = "gpio4",
  1010. .class = &am33xx_gpio_hwmod_class,
  1011. .clkdm_name = "l4ls_clkdm",
  1012. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  1013. .mpu_irqs = am33xx_gpio3_irqs,
  1014. .main_clk = "l4ls_gclk",
  1015. .prcm = {
  1016. .omap4 = {
  1017. .clkctrl_offs = AM33XX_CM_PER_GPIO3_CLKCTRL_OFFSET,
  1018. .modulemode = MODULEMODE_SWCTRL,
  1019. },
  1020. },
  1021. .opt_clks = gpio3_opt_clks,
  1022. .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
  1023. .dev_attr = &gpio_dev_attr,
  1024. };
  1025. /* gpmc */
  1026. static struct omap_hwmod_class_sysconfig gpmc_sysc = {
  1027. .rev_offs = 0x0,
  1028. .sysc_offs = 0x10,
  1029. .syss_offs = 0x14,
  1030. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
  1031. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1032. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1033. .sysc_fields = &omap_hwmod_sysc_type1,
  1034. };
  1035. static struct omap_hwmod_class am33xx_gpmc_hwmod_class = {
  1036. .name = "gpmc",
  1037. .sysc = &gpmc_sysc,
  1038. };
  1039. static struct omap_hwmod_irq_info am33xx_gpmc_irqs[] = {
  1040. { .irq = 100 + OMAP_INTC_START, },
  1041. { .irq = -1 },
  1042. };
  1043. static struct omap_hwmod am33xx_gpmc_hwmod = {
  1044. .name = "gpmc",
  1045. .class = &am33xx_gpmc_hwmod_class,
  1046. .clkdm_name = "l3s_clkdm",
  1047. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
  1048. .mpu_irqs = am33xx_gpmc_irqs,
  1049. .main_clk = "l3s_gclk",
  1050. .prcm = {
  1051. .omap4 = {
  1052. .clkctrl_offs = AM33XX_CM_PER_GPMC_CLKCTRL_OFFSET,
  1053. .modulemode = MODULEMODE_SWCTRL,
  1054. },
  1055. },
  1056. };
  1057. /* 'i2c' class */
  1058. static struct omap_hwmod_class_sysconfig am33xx_i2c_sysc = {
  1059. .sysc_offs = 0x0010,
  1060. .syss_offs = 0x0090,
  1061. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  1062. SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
  1063. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1064. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1065. SIDLE_SMART_WKUP),
  1066. .sysc_fields = &omap_hwmod_sysc_type1,
  1067. };
  1068. static struct omap_hwmod_class i2c_class = {
  1069. .name = "i2c",
  1070. .sysc = &am33xx_i2c_sysc,
  1071. .rev = OMAP_I2C_IP_VERSION_2,
  1072. .reset = &omap_i2c_reset,
  1073. };
  1074. static struct omap_i2c_dev_attr i2c_dev_attr = {
  1075. .flags = OMAP_I2C_FLAG_BUS_SHIFT_NONE,
  1076. };
  1077. /* i2c1 */
  1078. static struct omap_hwmod_irq_info i2c1_mpu_irqs[] = {
  1079. { .irq = 70 + OMAP_INTC_START, },
  1080. { .irq = -1 },
  1081. };
  1082. static struct omap_hwmod_dma_info i2c1_edma_reqs[] = {
  1083. { .name = "tx", .dma_req = 0, },
  1084. { .name = "rx", .dma_req = 0, },
  1085. { .dma_req = -1 }
  1086. };
  1087. static struct omap_hwmod am33xx_i2c1_hwmod = {
  1088. .name = "i2c1",
  1089. .class = &i2c_class,
  1090. .clkdm_name = "l4_wkup_clkdm",
  1091. .mpu_irqs = i2c1_mpu_irqs,
  1092. .sdma_reqs = i2c1_edma_reqs,
  1093. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  1094. .main_clk = "dpll_per_m2_div4_wkupdm_ck",
  1095. .prcm = {
  1096. .omap4 = {
  1097. .clkctrl_offs = AM33XX_CM_WKUP_I2C0_CLKCTRL_OFFSET,
  1098. .modulemode = MODULEMODE_SWCTRL,
  1099. },
  1100. },
  1101. .dev_attr = &i2c_dev_attr,
  1102. };
  1103. /* i2c1 */
  1104. static struct omap_hwmod_irq_info i2c2_mpu_irqs[] = {
  1105. { .irq = 71 + OMAP_INTC_START, },
  1106. { .irq = -1 },
  1107. };
  1108. static struct omap_hwmod_dma_info i2c2_edma_reqs[] = {
  1109. { .name = "tx", .dma_req = 0, },
  1110. { .name = "rx", .dma_req = 0, },
  1111. { .dma_req = -1 }
  1112. };
  1113. static struct omap_hwmod am33xx_i2c2_hwmod = {
  1114. .name = "i2c2",
  1115. .class = &i2c_class,
  1116. .clkdm_name = "l4ls_clkdm",
  1117. .mpu_irqs = i2c2_mpu_irqs,
  1118. .sdma_reqs = i2c2_edma_reqs,
  1119. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  1120. .main_clk = "dpll_per_m2_div4_ck",
  1121. .prcm = {
  1122. .omap4 = {
  1123. .clkctrl_offs = AM33XX_CM_PER_I2C1_CLKCTRL_OFFSET,
  1124. .modulemode = MODULEMODE_SWCTRL,
  1125. },
  1126. },
  1127. .dev_attr = &i2c_dev_attr,
  1128. };
  1129. /* i2c3 */
  1130. static struct omap_hwmod_dma_info i2c3_edma_reqs[] = {
  1131. { .name = "tx", .dma_req = 0, },
  1132. { .name = "rx", .dma_req = 0, },
  1133. { .dma_req = -1 }
  1134. };
  1135. static struct omap_hwmod_irq_info i2c3_mpu_irqs[] = {
  1136. { .irq = 30 + OMAP_INTC_START, },
  1137. { .irq = -1 },
  1138. };
  1139. static struct omap_hwmod am33xx_i2c3_hwmod = {
  1140. .name = "i2c3",
  1141. .class = &i2c_class,
  1142. .clkdm_name = "l4ls_clkdm",
  1143. .mpu_irqs = i2c3_mpu_irqs,
  1144. .sdma_reqs = i2c3_edma_reqs,
  1145. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  1146. .main_clk = "dpll_per_m2_div4_ck",
  1147. .prcm = {
  1148. .omap4 = {
  1149. .clkctrl_offs = AM33XX_CM_PER_I2C2_CLKCTRL_OFFSET,
  1150. .modulemode = MODULEMODE_SWCTRL,
  1151. },
  1152. },
  1153. .dev_attr = &i2c_dev_attr,
  1154. };
  1155. /* lcdc */
  1156. static struct omap_hwmod_class_sysconfig lcdc_sysc = {
  1157. .rev_offs = 0x0,
  1158. .sysc_offs = 0x54,
  1159. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE),
  1160. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1161. .sysc_fields = &omap_hwmod_sysc_type2,
  1162. };
  1163. static struct omap_hwmod_class am33xx_lcdc_hwmod_class = {
  1164. .name = "lcdc",
  1165. .sysc = &lcdc_sysc,
  1166. };
  1167. static struct omap_hwmod_irq_info am33xx_lcdc_irqs[] = {
  1168. { .irq = 36 + OMAP_INTC_START, },
  1169. { .irq = -1 },
  1170. };
  1171. static struct omap_hwmod am33xx_lcdc_hwmod = {
  1172. .name = "lcdc",
  1173. .class = &am33xx_lcdc_hwmod_class,
  1174. .clkdm_name = "lcdc_clkdm",
  1175. .mpu_irqs = am33xx_lcdc_irqs,
  1176. .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  1177. .main_clk = "lcd_gclk",
  1178. .prcm = {
  1179. .omap4 = {
  1180. .clkctrl_offs = AM33XX_CM_PER_LCDC_CLKCTRL_OFFSET,
  1181. .modulemode = MODULEMODE_SWCTRL,
  1182. },
  1183. },
  1184. };
  1185. /*
  1186. * 'mailbox' class
  1187. * mailbox module allowing communication between the on-chip processors using a
  1188. * queued mailbox-interrupt mechanism.
  1189. */
  1190. static struct omap_hwmod_class_sysconfig am33xx_mailbox_sysc = {
  1191. .rev_offs = 0x0000,
  1192. .sysc_offs = 0x0010,
  1193. .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  1194. SYSC_HAS_SOFTRESET),
  1195. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1196. .sysc_fields = &omap_hwmod_sysc_type2,
  1197. };
  1198. static struct omap_hwmod_class am33xx_mailbox_hwmod_class = {
  1199. .name = "mailbox",
  1200. .sysc = &am33xx_mailbox_sysc,
  1201. };
  1202. static struct omap_hwmod_irq_info am33xx_mailbox_irqs[] = {
  1203. { .irq = 77 + OMAP_INTC_START, },
  1204. { .irq = -1 },
  1205. };
  1206. static struct omap_hwmod am33xx_mailbox_hwmod = {
  1207. .name = "mailbox",
  1208. .class = &am33xx_mailbox_hwmod_class,
  1209. .clkdm_name = "l4ls_clkdm",
  1210. .mpu_irqs = am33xx_mailbox_irqs,
  1211. .main_clk = "l4ls_gclk",
  1212. .prcm = {
  1213. .omap4 = {
  1214. .clkctrl_offs = AM33XX_CM_PER_MAILBOX0_CLKCTRL_OFFSET,
  1215. .modulemode = MODULEMODE_SWCTRL,
  1216. },
  1217. },
  1218. };
  1219. /*
  1220. * 'mcasp' class
  1221. */
  1222. static struct omap_hwmod_class_sysconfig am33xx_mcasp_sysc = {
  1223. .rev_offs = 0x0,
  1224. .sysc_offs = 0x4,
  1225. .sysc_flags = SYSC_HAS_SIDLEMODE,
  1226. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1227. .sysc_fields = &omap_hwmod_sysc_type3,
  1228. };
  1229. static struct omap_hwmod_class am33xx_mcasp_hwmod_class = {
  1230. .name = "mcasp",
  1231. .sysc = &am33xx_mcasp_sysc,
  1232. };
  1233. /* mcasp0 */
  1234. static struct omap_hwmod_irq_info am33xx_mcasp0_irqs[] = {
  1235. { .name = "ax", .irq = 80 + OMAP_INTC_START, },
  1236. { .name = "ar", .irq = 81 + OMAP_INTC_START, },
  1237. { .irq = -1 },
  1238. };
  1239. static struct omap_hwmod_dma_info am33xx_mcasp0_edma_reqs[] = {
  1240. { .name = "tx", .dma_req = 8, },
  1241. { .name = "rx", .dma_req = 9, },
  1242. { .dma_req = -1 }
  1243. };
  1244. static struct omap_hwmod am33xx_mcasp0_hwmod = {
  1245. .name = "mcasp0",
  1246. .class = &am33xx_mcasp_hwmod_class,
  1247. .clkdm_name = "l3s_clkdm",
  1248. .mpu_irqs = am33xx_mcasp0_irqs,
  1249. .sdma_reqs = am33xx_mcasp0_edma_reqs,
  1250. .main_clk = "mcasp0_fck",
  1251. .prcm = {
  1252. .omap4 = {
  1253. .clkctrl_offs = AM33XX_CM_PER_MCASP0_CLKCTRL_OFFSET,
  1254. .modulemode = MODULEMODE_SWCTRL,
  1255. },
  1256. },
  1257. };
  1258. /* mcasp1 */
  1259. static struct omap_hwmod_irq_info am33xx_mcasp1_irqs[] = {
  1260. { .name = "ax", .irq = 82 + OMAP_INTC_START, },
  1261. { .name = "ar", .irq = 83 + OMAP_INTC_START, },
  1262. { .irq = -1 },
  1263. };
  1264. static struct omap_hwmod_dma_info am33xx_mcasp1_edma_reqs[] = {
  1265. { .name = "tx", .dma_req = 10, },
  1266. { .name = "rx", .dma_req = 11, },
  1267. { .dma_req = -1 }
  1268. };
  1269. static struct omap_hwmod am33xx_mcasp1_hwmod = {
  1270. .name = "mcasp1",
  1271. .class = &am33xx_mcasp_hwmod_class,
  1272. .clkdm_name = "l3s_clkdm",
  1273. .mpu_irqs = am33xx_mcasp1_irqs,
  1274. .sdma_reqs = am33xx_mcasp1_edma_reqs,
  1275. .main_clk = "mcasp1_fck",
  1276. .prcm = {
  1277. .omap4 = {
  1278. .clkctrl_offs = AM33XX_CM_PER_MCASP1_CLKCTRL_OFFSET,
  1279. .modulemode = MODULEMODE_SWCTRL,
  1280. },
  1281. },
  1282. };
  1283. /* 'mmc' class */
  1284. static struct omap_hwmod_class_sysconfig am33xx_mmc_sysc = {
  1285. .rev_offs = 0x1fc,
  1286. .sysc_offs = 0x10,
  1287. .syss_offs = 0x14,
  1288. .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
  1289. SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
  1290. SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
  1291. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1292. .sysc_fields = &omap_hwmod_sysc_type1,
  1293. };
  1294. static struct omap_hwmod_class am33xx_mmc_hwmod_class = {
  1295. .name = "mmc",
  1296. .sysc = &am33xx_mmc_sysc,
  1297. };
  1298. /* mmc0 */
  1299. static struct omap_hwmod_irq_info am33xx_mmc0_irqs[] = {
  1300. { .irq = 64 + OMAP_INTC_START, },
  1301. { .irq = -1 },
  1302. };
  1303. static struct omap_hwmod_dma_info am33xx_mmc0_edma_reqs[] = {
  1304. { .name = "tx", .dma_req = 24, },
  1305. { .name = "rx", .dma_req = 25, },
  1306. { .dma_req = -1 }
  1307. };
  1308. static struct omap_mmc_dev_attr am33xx_mmc0_dev_attr = {
  1309. .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
  1310. };
  1311. static struct omap_hwmod am33xx_mmc0_hwmod = {
  1312. .name = "mmc1",
  1313. .class = &am33xx_mmc_hwmod_class,
  1314. .clkdm_name = "l4ls_clkdm",
  1315. .mpu_irqs = am33xx_mmc0_irqs,
  1316. .sdma_reqs = am33xx_mmc0_edma_reqs,
  1317. .main_clk = "mmc_clk",
  1318. .prcm = {
  1319. .omap4 = {
  1320. .clkctrl_offs = AM33XX_CM_PER_MMC0_CLKCTRL_OFFSET,
  1321. .modulemode = MODULEMODE_SWCTRL,
  1322. },
  1323. },
  1324. .dev_attr = &am33xx_mmc0_dev_attr,
  1325. };
  1326. /* mmc1 */
  1327. static struct omap_hwmod_irq_info am33xx_mmc1_irqs[] = {
  1328. { .irq = 28 + OMAP_INTC_START, },
  1329. { .irq = -1 },
  1330. };
  1331. static struct omap_hwmod_dma_info am33xx_mmc1_edma_reqs[] = {
  1332. { .name = "tx", .dma_req = 2, },
  1333. { .name = "rx", .dma_req = 3, },
  1334. { .dma_req = -1 }
  1335. };
  1336. static struct omap_mmc_dev_attr am33xx_mmc1_dev_attr = {
  1337. .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
  1338. };
  1339. static struct omap_hwmod am33xx_mmc1_hwmod = {
  1340. .name = "mmc2",
  1341. .class = &am33xx_mmc_hwmod_class,
  1342. .clkdm_name = "l4ls_clkdm",
  1343. .mpu_irqs = am33xx_mmc1_irqs,
  1344. .sdma_reqs = am33xx_mmc1_edma_reqs,
  1345. .main_clk = "mmc_clk",
  1346. .prcm = {
  1347. .omap4 = {
  1348. .clkctrl_offs = AM33XX_CM_PER_MMC1_CLKCTRL_OFFSET,
  1349. .modulemode = MODULEMODE_SWCTRL,
  1350. },
  1351. },
  1352. .dev_attr = &am33xx_mmc1_dev_attr,
  1353. };
  1354. /* mmc2 */
  1355. static struct omap_hwmod_irq_info am33xx_mmc2_irqs[] = {
  1356. { .irq = 29 + OMAP_INTC_START, },
  1357. { .irq = -1 },
  1358. };
  1359. static struct omap_hwmod_dma_info am33xx_mmc2_edma_reqs[] = {
  1360. { .name = "tx", .dma_req = 64, },
  1361. { .name = "rx", .dma_req = 65, },
  1362. { .dma_req = -1 }
  1363. };
  1364. static struct omap_mmc_dev_attr am33xx_mmc2_dev_attr = {
  1365. .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
  1366. };
  1367. static struct omap_hwmod am33xx_mmc2_hwmod = {
  1368. .name = "mmc3",
  1369. .class = &am33xx_mmc_hwmod_class,
  1370. .clkdm_name = "l3s_clkdm",
  1371. .mpu_irqs = am33xx_mmc2_irqs,
  1372. .sdma_reqs = am33xx_mmc2_edma_reqs,
  1373. .main_clk = "mmc_clk",
  1374. .prcm = {
  1375. .omap4 = {
  1376. .clkctrl_offs = AM33XX_CM_PER_MMC2_CLKCTRL_OFFSET,
  1377. .modulemode = MODULEMODE_SWCTRL,
  1378. },
  1379. },
  1380. .dev_attr = &am33xx_mmc2_dev_attr,
  1381. };
  1382. /*
  1383. * 'rtc' class
  1384. * rtc subsystem
  1385. */
  1386. static struct omap_hwmod_class_sysconfig am33xx_rtc_sysc = {
  1387. .rev_offs = 0x0074,
  1388. .sysc_offs = 0x0078,
  1389. .sysc_flags = SYSC_HAS_SIDLEMODE,
  1390. .idlemodes = (SIDLE_FORCE | SIDLE_NO |
  1391. SIDLE_SMART | SIDLE_SMART_WKUP),
  1392. .sysc_fields = &omap_hwmod_sysc_type3,
  1393. };
  1394. static struct omap_hwmod_class am33xx_rtc_hwmod_class = {
  1395. .name = "rtc",
  1396. .sysc = &am33xx_rtc_sysc,
  1397. };
  1398. static struct omap_hwmod_irq_info am33xx_rtc_irqs[] = {
  1399. { .name = "rtcint", .irq = 75 + OMAP_INTC_START, },
  1400. { .name = "rtcalarmint", .irq = 76 + OMAP_INTC_START, },
  1401. { .irq = -1 },
  1402. };
  1403. static struct omap_hwmod am33xx_rtc_hwmod = {
  1404. .name = "rtc",
  1405. .class = &am33xx_rtc_hwmod_class,
  1406. .clkdm_name = "l4_rtc_clkdm",
  1407. .mpu_irqs = am33xx_rtc_irqs,
  1408. .main_clk = "clk_32768_ck",
  1409. .prcm = {
  1410. .omap4 = {
  1411. .clkctrl_offs = AM33XX_CM_RTC_RTC_CLKCTRL_OFFSET,
  1412. .modulemode = MODULEMODE_SWCTRL,
  1413. },
  1414. },
  1415. };
  1416. /* 'spi' class */
  1417. static struct omap_hwmod_class_sysconfig am33xx_mcspi_sysc = {
  1418. .rev_offs = 0x0000,
  1419. .sysc_offs = 0x0110,
  1420. .syss_offs = 0x0114,
  1421. .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
  1422. SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
  1423. SYSS_HAS_RESET_STATUS),
  1424. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1425. .sysc_fields = &omap_hwmod_sysc_type1,
  1426. };
  1427. static struct omap_hwmod_class am33xx_spi_hwmod_class = {
  1428. .name = "mcspi",
  1429. .sysc = &am33xx_mcspi_sysc,
  1430. .rev = OMAP4_MCSPI_REV,
  1431. };
  1432. /* spi0 */
  1433. static struct omap_hwmod_irq_info am33xx_spi0_irqs[] = {
  1434. { .irq = 65 + OMAP_INTC_START, },
  1435. { .irq = -1 },
  1436. };
  1437. static struct omap_hwmod_dma_info am33xx_mcspi0_edma_reqs[] = {
  1438. { .name = "rx0", .dma_req = 17 },
  1439. { .name = "tx0", .dma_req = 16 },
  1440. { .name = "rx1", .dma_req = 19 },
  1441. { .name = "tx1", .dma_req = 18 },
  1442. { .dma_req = -1 }
  1443. };
  1444. static struct omap2_mcspi_dev_attr mcspi_attrib = {
  1445. .num_chipselect = 2,
  1446. };
  1447. static struct omap_hwmod am33xx_spi0_hwmod = {
  1448. .name = "spi0",
  1449. .class = &am33xx_spi_hwmod_class,
  1450. .clkdm_name = "l4ls_clkdm",
  1451. .mpu_irqs = am33xx_spi0_irqs,
  1452. .sdma_reqs = am33xx_mcspi0_edma_reqs,
  1453. .main_clk = "dpll_per_m2_div4_ck",
  1454. .prcm = {
  1455. .omap4 = {
  1456. .clkctrl_offs = AM33XX_CM_PER_SPI0_CLKCTRL_OFFSET,
  1457. .modulemode = MODULEMODE_SWCTRL,
  1458. },
  1459. },
  1460. .dev_attr = &mcspi_attrib,
  1461. };
  1462. /* spi1 */
  1463. static struct omap_hwmod_irq_info am33xx_spi1_irqs[] = {
  1464. { .irq = 125 + OMAP_INTC_START, },
  1465. { .irq = -1 },
  1466. };
  1467. static struct omap_hwmod_dma_info am33xx_mcspi1_edma_reqs[] = {
  1468. { .name = "rx0", .dma_req = 43 },
  1469. { .name = "tx0", .dma_req = 42 },
  1470. { .name = "rx1", .dma_req = 45 },
  1471. { .name = "tx1", .dma_req = 44 },
  1472. { .dma_req = -1 }
  1473. };
  1474. static struct omap_hwmod am33xx_spi1_hwmod = {
  1475. .name = "spi1",
  1476. .class = &am33xx_spi_hwmod_class,
  1477. .clkdm_name = "l4ls_clkdm",
  1478. .mpu_irqs = am33xx_spi1_irqs,
  1479. .sdma_reqs = am33xx_mcspi1_edma_reqs,
  1480. .main_clk = "dpll_per_m2_div4_ck",
  1481. .prcm = {
  1482. .omap4 = {
  1483. .clkctrl_offs = AM33XX_CM_PER_SPI1_CLKCTRL_OFFSET,
  1484. .modulemode = MODULEMODE_SWCTRL,
  1485. },
  1486. },
  1487. .dev_attr = &mcspi_attrib,
  1488. };
  1489. /*
  1490. * 'spinlock' class
  1491. * spinlock provides hardware assistance for synchronizing the
  1492. * processes running on multiple processors
  1493. */
  1494. static struct omap_hwmod_class am33xx_spinlock_hwmod_class = {
  1495. .name = "spinlock",
  1496. };
  1497. static struct omap_hwmod am33xx_spinlock_hwmod = {
  1498. .name = "spinlock",
  1499. .class = &am33xx_spinlock_hwmod_class,
  1500. .clkdm_name = "l4ls_clkdm",
  1501. .main_clk = "l4ls_gclk",
  1502. .prcm = {
  1503. .omap4 = {
  1504. .clkctrl_offs = AM33XX_CM_PER_SPINLOCK_CLKCTRL_OFFSET,
  1505. .modulemode = MODULEMODE_SWCTRL,
  1506. },
  1507. },
  1508. };
  1509. /* 'timer 2-7' class */
  1510. static struct omap_hwmod_class_sysconfig am33xx_timer_sysc = {
  1511. .rev_offs = 0x0000,
  1512. .sysc_offs = 0x0010,
  1513. .syss_offs = 0x0014,
  1514. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1515. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1516. SIDLE_SMART_WKUP),
  1517. .sysc_fields = &omap_hwmod_sysc_type2,
  1518. };
  1519. static struct omap_hwmod_class am33xx_timer_hwmod_class = {
  1520. .name = "timer",
  1521. .sysc = &am33xx_timer_sysc,
  1522. };
  1523. /* timer1 1ms */
  1524. static struct omap_hwmod_class_sysconfig am33xx_timer1ms_sysc = {
  1525. .rev_offs = 0x0000,
  1526. .sysc_offs = 0x0010,
  1527. .syss_offs = 0x0014,
  1528. .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
  1529. SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
  1530. SYSS_HAS_RESET_STATUS),
  1531. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1532. .sysc_fields = &omap_hwmod_sysc_type1,
  1533. };
  1534. static struct omap_hwmod_class am33xx_timer1ms_hwmod_class = {
  1535. .name = "timer",
  1536. .sysc = &am33xx_timer1ms_sysc,
  1537. };
  1538. static struct omap_hwmod_irq_info am33xx_timer1_irqs[] = {
  1539. { .irq = 67 + OMAP_INTC_START, },
  1540. { .irq = -1 },
  1541. };
  1542. static struct omap_hwmod am33xx_timer1_hwmod = {
  1543. .name = "timer1",
  1544. .class = &am33xx_timer1ms_hwmod_class,
  1545. .clkdm_name = "l4_wkup_clkdm",
  1546. .mpu_irqs = am33xx_timer1_irqs,
  1547. .main_clk = "timer1_fck",
  1548. .prcm = {
  1549. .omap4 = {
  1550. .clkctrl_offs = AM33XX_CM_WKUP_TIMER1_CLKCTRL_OFFSET,
  1551. .modulemode = MODULEMODE_SWCTRL,
  1552. },
  1553. },
  1554. };
  1555. static struct omap_hwmod_irq_info am33xx_timer2_irqs[] = {
  1556. { .irq = 68 + OMAP_INTC_START, },
  1557. { .irq = -1 },
  1558. };
  1559. static struct omap_hwmod am33xx_timer2_hwmod = {
  1560. .name = "timer2",
  1561. .class = &am33xx_timer_hwmod_class,
  1562. .clkdm_name = "l4ls_clkdm",
  1563. .mpu_irqs = am33xx_timer2_irqs,
  1564. .main_clk = "timer2_fck",
  1565. .prcm = {
  1566. .omap4 = {
  1567. .clkctrl_offs = AM33XX_CM_PER_TIMER2_CLKCTRL_OFFSET,
  1568. .modulemode = MODULEMODE_SWCTRL,
  1569. },
  1570. },
  1571. };
  1572. static struct omap_hwmod_irq_info am33xx_timer3_irqs[] = {
  1573. { .irq = 69 + OMAP_INTC_START, },
  1574. { .irq = -1 },
  1575. };
  1576. static struct omap_hwmod am33xx_timer3_hwmod = {
  1577. .name = "timer3",
  1578. .class = &am33xx_timer_hwmod_class,
  1579. .clkdm_name = "l4ls_clkdm",
  1580. .mpu_irqs = am33xx_timer3_irqs,
  1581. .main_clk = "timer3_fck",
  1582. .prcm = {
  1583. .omap4 = {
  1584. .clkctrl_offs = AM33XX_CM_PER_TIMER3_CLKCTRL_OFFSET,
  1585. .modulemode = MODULEMODE_SWCTRL,
  1586. },
  1587. },
  1588. };
  1589. static struct omap_hwmod_irq_info am33xx_timer4_irqs[] = {
  1590. { .irq = 92 + OMAP_INTC_START, },
  1591. { .irq = -1 },
  1592. };
  1593. static struct omap_hwmod am33xx_timer4_hwmod = {
  1594. .name = "timer4",
  1595. .class = &am33xx_timer_hwmod_class,
  1596. .clkdm_name = "l4ls_clkdm",
  1597. .mpu_irqs = am33xx_timer4_irqs,
  1598. .main_clk = "timer4_fck",
  1599. .prcm = {
  1600. .omap4 = {
  1601. .clkctrl_offs = AM33XX_CM_PER_TIMER4_CLKCTRL_OFFSET,
  1602. .modulemode = MODULEMODE_SWCTRL,
  1603. },
  1604. },
  1605. };
  1606. static struct omap_hwmod_irq_info am33xx_timer5_irqs[] = {
  1607. { .irq = 93 + OMAP_INTC_START, },
  1608. { .irq = -1 },
  1609. };
  1610. static struct omap_hwmod am33xx_timer5_hwmod = {
  1611. .name = "timer5",
  1612. .class = &am33xx_timer_hwmod_class,
  1613. .clkdm_name = "l4ls_clkdm",
  1614. .mpu_irqs = am33xx_timer5_irqs,
  1615. .main_clk = "timer5_fck",
  1616. .prcm = {
  1617. .omap4 = {
  1618. .clkctrl_offs = AM33XX_CM_PER_TIMER5_CLKCTRL_OFFSET,
  1619. .modulemode = MODULEMODE_SWCTRL,
  1620. },
  1621. },
  1622. };
  1623. static struct omap_hwmod_irq_info am33xx_timer6_irqs[] = {
  1624. { .irq = 94 + OMAP_INTC_START, },
  1625. { .irq = -1 },
  1626. };
  1627. static struct omap_hwmod am33xx_timer6_hwmod = {
  1628. .name = "timer6",
  1629. .class = &am33xx_timer_hwmod_class,
  1630. .clkdm_name = "l4ls_clkdm",
  1631. .mpu_irqs = am33xx_timer6_irqs,
  1632. .main_clk = "timer6_fck",
  1633. .prcm = {
  1634. .omap4 = {
  1635. .clkctrl_offs = AM33XX_CM_PER_TIMER6_CLKCTRL_OFFSET,
  1636. .modulemode = MODULEMODE_SWCTRL,
  1637. },
  1638. },
  1639. };
  1640. static struct omap_hwmod_irq_info am33xx_timer7_irqs[] = {
  1641. { .irq = 95 + OMAP_INTC_START, },
  1642. { .irq = -1 },
  1643. };
  1644. static struct omap_hwmod am33xx_timer7_hwmod = {
  1645. .name = "timer7",
  1646. .class = &am33xx_timer_hwmod_class,
  1647. .clkdm_name = "l4ls_clkdm",
  1648. .mpu_irqs = am33xx_timer7_irqs,
  1649. .main_clk = "timer7_fck",
  1650. .prcm = {
  1651. .omap4 = {
  1652. .clkctrl_offs = AM33XX_CM_PER_TIMER7_CLKCTRL_OFFSET,
  1653. .modulemode = MODULEMODE_SWCTRL,
  1654. },
  1655. },
  1656. };
  1657. /* tpcc */
  1658. static struct omap_hwmod_class am33xx_tpcc_hwmod_class = {
  1659. .name = "tpcc",
  1660. };
  1661. static struct omap_hwmod_irq_info am33xx_tpcc_irqs[] = {
  1662. { .name = "edma0", .irq = 12 + OMAP_INTC_START, },
  1663. { .name = "edma0_mperr", .irq = 13 + OMAP_INTC_START, },
  1664. { .name = "edma0_err", .irq = 14 + OMAP_INTC_START, },
  1665. { .irq = -1 },
  1666. };
  1667. static struct omap_hwmod am33xx_tpcc_hwmod = {
  1668. .name = "tpcc",
  1669. .class = &am33xx_tpcc_hwmod_class,
  1670. .clkdm_name = "l3_clkdm",
  1671. .mpu_irqs = am33xx_tpcc_irqs,
  1672. .main_clk = "l3_gclk",
  1673. .prcm = {
  1674. .omap4 = {
  1675. .clkctrl_offs = AM33XX_CM_PER_TPCC_CLKCTRL_OFFSET,
  1676. .modulemode = MODULEMODE_SWCTRL,
  1677. },
  1678. },
  1679. };
  1680. static struct omap_hwmod_class_sysconfig am33xx_tptc_sysc = {
  1681. .rev_offs = 0x0,
  1682. .sysc_offs = 0x10,
  1683. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  1684. SYSC_HAS_MIDLEMODE),
  1685. .idlemodes = (SIDLE_FORCE | SIDLE_SMART | MSTANDBY_FORCE),
  1686. .sysc_fields = &omap_hwmod_sysc_type2,
  1687. };
  1688. /* 'tptc' class */
  1689. static struct omap_hwmod_class am33xx_tptc_hwmod_class = {
  1690. .name = "tptc",
  1691. .sysc = &am33xx_tptc_sysc,
  1692. };
  1693. /* tptc0 */
  1694. static struct omap_hwmod_irq_info am33xx_tptc0_irqs[] = {
  1695. { .irq = 112 + OMAP_INTC_START, },
  1696. { .irq = -1 },
  1697. };
  1698. static struct omap_hwmod am33xx_tptc0_hwmod = {
  1699. .name = "tptc0",
  1700. .class = &am33xx_tptc_hwmod_class,
  1701. .clkdm_name = "l3_clkdm",
  1702. .mpu_irqs = am33xx_tptc0_irqs,
  1703. .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  1704. .main_clk = "l3_gclk",
  1705. .prcm = {
  1706. .omap4 = {
  1707. .clkctrl_offs = AM33XX_CM_PER_TPTC0_CLKCTRL_OFFSET,
  1708. .modulemode = MODULEMODE_SWCTRL,
  1709. },
  1710. },
  1711. };
  1712. /* tptc1 */
  1713. static struct omap_hwmod_irq_info am33xx_tptc1_irqs[] = {
  1714. { .irq = 113 + OMAP_INTC_START, },
  1715. { .irq = -1 },
  1716. };
  1717. static struct omap_hwmod am33xx_tptc1_hwmod = {
  1718. .name = "tptc1",
  1719. .class = &am33xx_tptc_hwmod_class,
  1720. .clkdm_name = "l3_clkdm",
  1721. .mpu_irqs = am33xx_tptc1_irqs,
  1722. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  1723. .main_clk = "l3_gclk",
  1724. .prcm = {
  1725. .omap4 = {
  1726. .clkctrl_offs = AM33XX_CM_PER_TPTC1_CLKCTRL_OFFSET,
  1727. .modulemode = MODULEMODE_SWCTRL,
  1728. },
  1729. },
  1730. };
  1731. /* tptc2 */
  1732. static struct omap_hwmod_irq_info am33xx_tptc2_irqs[] = {
  1733. { .irq = 114 + OMAP_INTC_START, },
  1734. { .irq = -1 },
  1735. };
  1736. static struct omap_hwmod am33xx_tptc2_hwmod = {
  1737. .name = "tptc2",
  1738. .class = &am33xx_tptc_hwmod_class,
  1739. .clkdm_name = "l3_clkdm",
  1740. .mpu_irqs = am33xx_tptc2_irqs,
  1741. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  1742. .main_clk = "l3_gclk",
  1743. .prcm = {
  1744. .omap4 = {
  1745. .clkctrl_offs = AM33XX_CM_PER_TPTC2_CLKCTRL_OFFSET,
  1746. .modulemode = MODULEMODE_SWCTRL,
  1747. },
  1748. },
  1749. };
  1750. /* 'uart' class */
  1751. static struct omap_hwmod_class_sysconfig uart_sysc = {
  1752. .rev_offs = 0x50,
  1753. .sysc_offs = 0x54,
  1754. .syss_offs = 0x58,
  1755. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
  1756. SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
  1757. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1758. SIDLE_SMART_WKUP),
  1759. .sysc_fields = &omap_hwmod_sysc_type1,
  1760. };
  1761. static struct omap_hwmod_class uart_class = {
  1762. .name = "uart",
  1763. .sysc = &uart_sysc,
  1764. };
  1765. /* uart1 */
  1766. static struct omap_hwmod_dma_info uart1_edma_reqs[] = {
  1767. { .name = "tx", .dma_req = 26, },
  1768. { .name = "rx", .dma_req = 27, },
  1769. { .dma_req = -1 }
  1770. };
  1771. static struct omap_hwmod_irq_info am33xx_uart1_irqs[] = {
  1772. { .irq = 72 + OMAP_INTC_START, },
  1773. { .irq = -1 },
  1774. };
  1775. static struct omap_hwmod am33xx_uart1_hwmod = {
  1776. .name = "uart1",
  1777. .class = &uart_class,
  1778. .clkdm_name = "l4_wkup_clkdm",
  1779. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1780. .mpu_irqs = am33xx_uart1_irqs,
  1781. .sdma_reqs = uart1_edma_reqs,
  1782. .main_clk = "dpll_per_m2_div4_wkupdm_ck",
  1783. .prcm = {
  1784. .omap4 = {
  1785. .clkctrl_offs = AM33XX_CM_WKUP_UART0_CLKCTRL_OFFSET,
  1786. .modulemode = MODULEMODE_SWCTRL,
  1787. },
  1788. },
  1789. };
  1790. /* uart2 */
  1791. static struct omap_hwmod_dma_info uart2_edma_reqs[] = {
  1792. { .name = "tx", .dma_req = 28, },
  1793. { .name = "rx", .dma_req = 29, },
  1794. { .dma_req = -1 }
  1795. };
  1796. static struct omap_hwmod_irq_info am33xx_uart2_irqs[] = {
  1797. { .irq = 73 + OMAP_INTC_START, },
  1798. { .irq = -1 },
  1799. };
  1800. static struct omap_hwmod am33xx_uart2_hwmod = {
  1801. .name = "uart2",
  1802. .class = &uart_class,
  1803. .clkdm_name = "l4ls_clkdm",
  1804. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1805. .mpu_irqs = am33xx_uart2_irqs,
  1806. .sdma_reqs = uart2_edma_reqs,
  1807. .main_clk = "dpll_per_m2_div4_ck",
  1808. .prcm = {
  1809. .omap4 = {
  1810. .clkctrl_offs = AM33XX_CM_PER_UART1_CLKCTRL_OFFSET,
  1811. .modulemode = MODULEMODE_SWCTRL,
  1812. },
  1813. },
  1814. };
  1815. /* uart3 */
  1816. static struct omap_hwmod_dma_info uart3_edma_reqs[] = {
  1817. { .name = "tx", .dma_req = 30, },
  1818. { .name = "rx", .dma_req = 31, },
  1819. { .dma_req = -1 }
  1820. };
  1821. static struct omap_hwmod_irq_info am33xx_uart3_irqs[] = {
  1822. { .irq = 74 + OMAP_INTC_START, },
  1823. { .irq = -1 },
  1824. };
  1825. static struct omap_hwmod am33xx_uart3_hwmod = {
  1826. .name = "uart3",
  1827. .class = &uart_class,
  1828. .clkdm_name = "l4ls_clkdm",
  1829. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1830. .mpu_irqs = am33xx_uart3_irqs,
  1831. .sdma_reqs = uart3_edma_reqs,
  1832. .main_clk = "dpll_per_m2_div4_ck",
  1833. .prcm = {
  1834. .omap4 = {
  1835. .clkctrl_offs = AM33XX_CM_PER_UART2_CLKCTRL_OFFSET,
  1836. .modulemode = MODULEMODE_SWCTRL,
  1837. },
  1838. },
  1839. };
  1840. static struct omap_hwmod_irq_info am33xx_uart4_irqs[] = {
  1841. { .irq = 44 + OMAP_INTC_START, },
  1842. { .irq = -1 },
  1843. };
  1844. static struct omap_hwmod am33xx_uart4_hwmod = {
  1845. .name = "uart4",
  1846. .class = &uart_class,
  1847. .clkdm_name = "l4ls_clkdm",
  1848. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1849. .mpu_irqs = am33xx_uart4_irqs,
  1850. .sdma_reqs = uart1_edma_reqs,
  1851. .main_clk = "dpll_per_m2_div4_ck",
  1852. .prcm = {
  1853. .omap4 = {
  1854. .clkctrl_offs = AM33XX_CM_PER_UART3_CLKCTRL_OFFSET,
  1855. .modulemode = MODULEMODE_SWCTRL,
  1856. },
  1857. },
  1858. };
  1859. static struct omap_hwmod_irq_info am33xx_uart5_irqs[] = {
  1860. { .irq = 45 + OMAP_INTC_START, },
  1861. { .irq = -1 },
  1862. };
  1863. static struct omap_hwmod am33xx_uart5_hwmod = {
  1864. .name = "uart5",
  1865. .class = &uart_class,
  1866. .clkdm_name = "l4ls_clkdm",
  1867. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1868. .mpu_irqs = am33xx_uart5_irqs,
  1869. .sdma_reqs = uart1_edma_reqs,
  1870. .main_clk = "dpll_per_m2_div4_ck",
  1871. .prcm = {
  1872. .omap4 = {
  1873. .clkctrl_offs = AM33XX_CM_PER_UART4_CLKCTRL_OFFSET,
  1874. .modulemode = MODULEMODE_SWCTRL,
  1875. },
  1876. },
  1877. };
  1878. static struct omap_hwmod_irq_info am33xx_uart6_irqs[] = {
  1879. { .irq = 46 + OMAP_INTC_START, },
  1880. { .irq = -1 },
  1881. };
  1882. static struct omap_hwmod am33xx_uart6_hwmod = {
  1883. .name = "uart6",
  1884. .class = &uart_class,
  1885. .clkdm_name = "l4ls_clkdm",
  1886. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1887. .mpu_irqs = am33xx_uart6_irqs,
  1888. .sdma_reqs = uart1_edma_reqs,
  1889. .main_clk = "dpll_per_m2_div4_ck",
  1890. .prcm = {
  1891. .omap4 = {
  1892. .clkctrl_offs = AM33XX_CM_PER_UART5_CLKCTRL_OFFSET,
  1893. .modulemode = MODULEMODE_SWCTRL,
  1894. },
  1895. },
  1896. };
  1897. /* 'wd_timer' class */
  1898. static struct omap_hwmod_class_sysconfig wdt_sysc = {
  1899. .rev_offs = 0x0,
  1900. .sysc_offs = 0x10,
  1901. .syss_offs = 0x14,
  1902. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_SIDLEMODE |
  1903. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1904. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1905. SIDLE_SMART_WKUP),
  1906. .sysc_fields = &omap_hwmod_sysc_type1,
  1907. };
  1908. static struct omap_hwmod_class am33xx_wd_timer_hwmod_class = {
  1909. .name = "wd_timer",
  1910. .sysc = &wdt_sysc,
  1911. .pre_shutdown = &omap2_wd_timer_disable,
  1912. };
  1913. /*
  1914. * XXX: device.c file uses hardcoded name for watchdog timer
  1915. * driver "wd_timer2, so we are also using same name as of now...
  1916. */
  1917. static struct omap_hwmod am33xx_wd_timer1_hwmod = {
  1918. .name = "wd_timer2",
  1919. .class = &am33xx_wd_timer_hwmod_class,
  1920. .clkdm_name = "l4_wkup_clkdm",
  1921. .flags = HWMOD_SWSUP_SIDLE,
  1922. .main_clk = "wdt1_fck",
  1923. .prcm = {
  1924. .omap4 = {
  1925. .clkctrl_offs = AM33XX_CM_WKUP_WDT1_CLKCTRL_OFFSET,
  1926. .modulemode = MODULEMODE_SWCTRL,
  1927. },
  1928. },
  1929. };
  1930. /*
  1931. * 'usb_otg' class
  1932. * high-speed on-the-go universal serial bus (usb_otg) controller
  1933. */
  1934. static struct omap_hwmod_class_sysconfig am33xx_usbhsotg_sysc = {
  1935. .rev_offs = 0x0,
  1936. .sysc_offs = 0x10,
  1937. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE),
  1938. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1939. MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
  1940. .sysc_fields = &omap_hwmod_sysc_type2,
  1941. };
  1942. static struct omap_hwmod_class am33xx_usbotg_class = {
  1943. .name = "usbotg",
  1944. .sysc = &am33xx_usbhsotg_sysc,
  1945. };
  1946. static struct omap_hwmod_irq_info am33xx_usbss_mpu_irqs[] = {
  1947. { .name = "usbss-irq", .irq = 17 + OMAP_INTC_START, },
  1948. { .name = "musb0-irq", .irq = 18 + OMAP_INTC_START, },
  1949. { .name = "musb1-irq", .irq = 19 + OMAP_INTC_START, },
  1950. { .irq = -1, },
  1951. };
  1952. static struct omap_hwmod am33xx_usbss_hwmod = {
  1953. .name = "usb_otg_hs",
  1954. .class = &am33xx_usbotg_class,
  1955. .clkdm_name = "l3s_clkdm",
  1956. .mpu_irqs = am33xx_usbss_mpu_irqs,
  1957. .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  1958. .main_clk = "usbotg_fck",
  1959. .prcm = {
  1960. .omap4 = {
  1961. .clkctrl_offs = AM33XX_CM_PER_USB0_CLKCTRL_OFFSET,
  1962. .modulemode = MODULEMODE_SWCTRL,
  1963. },
  1964. },
  1965. };
  1966. /*
  1967. * Interfaces
  1968. */
  1969. /* l4 fw -> emif fw */
  1970. static struct omap_hwmod_ocp_if am33xx_l4_fw__emif_fw = {
  1971. .master = &am33xx_l4_fw_hwmod,
  1972. .slave = &am33xx_emif_fw_hwmod,
  1973. .clk = "l4fw_gclk",
  1974. .user = OCP_USER_MPU,
  1975. };
  1976. static struct omap_hwmod_addr_space am33xx_emif_addrs[] = {
  1977. {
  1978. .pa_start = 0x4c000000,
  1979. .pa_end = 0x4c000fff,
  1980. .flags = ADDR_TYPE_RT
  1981. },
  1982. { }
  1983. };
  1984. /* l3 main -> emif */
  1985. static struct omap_hwmod_ocp_if am33xx_l3_main__emif = {
  1986. .master = &am33xx_l3_main_hwmod,
  1987. .slave = &am33xx_emif_hwmod,
  1988. .clk = "dpll_core_m4_ck",
  1989. .addr = am33xx_emif_addrs,
  1990. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1991. };
  1992. /* mpu -> l3 main */
  1993. static struct omap_hwmod_ocp_if am33xx_mpu__l3_main = {
  1994. .master = &am33xx_mpu_hwmod,
  1995. .slave = &am33xx_l3_main_hwmod,
  1996. .clk = "dpll_mpu_m2_ck",
  1997. .user = OCP_USER_MPU,
  1998. };
  1999. /* l3 main -> l4 hs */
  2000. static struct omap_hwmod_ocp_if am33xx_l3_main__l4_hs = {
  2001. .master = &am33xx_l3_main_hwmod,
  2002. .slave = &am33xx_l4_hs_hwmod,
  2003. .clk = "l3s_gclk",
  2004. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2005. };
  2006. /* l3 main -> l3 s */
  2007. static struct omap_hwmod_ocp_if am33xx_l3_main__l3_s = {
  2008. .master = &am33xx_l3_main_hwmod,
  2009. .slave = &am33xx_l3_s_hwmod,
  2010. .clk = "l3s_gclk",
  2011. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2012. };
  2013. /* l3 s -> l4 per/ls */
  2014. static struct omap_hwmod_ocp_if am33xx_l3_s__l4_ls = {
  2015. .master = &am33xx_l3_s_hwmod,
  2016. .slave = &am33xx_l4_ls_hwmod,
  2017. .clk = "l3s_gclk",
  2018. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2019. };
  2020. /* l3 s -> l4 wkup */
  2021. static struct omap_hwmod_ocp_if am33xx_l3_s__l4_wkup = {
  2022. .master = &am33xx_l3_s_hwmod,
  2023. .slave = &am33xx_l4_wkup_hwmod,
  2024. .clk = "l3s_gclk",
  2025. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2026. };
  2027. /* l3 s -> l4 fw */
  2028. static struct omap_hwmod_ocp_if am33xx_l3_s__l4_fw = {
  2029. .master = &am33xx_l3_s_hwmod,
  2030. .slave = &am33xx_l4_fw_hwmod,
  2031. .clk = "l3s_gclk",
  2032. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2033. };
  2034. /* l3 main -> l3 instr */
  2035. static struct omap_hwmod_ocp_if am33xx_l3_main__l3_instr = {
  2036. .master = &am33xx_l3_main_hwmod,
  2037. .slave = &am33xx_l3_instr_hwmod,
  2038. .clk = "l3s_gclk",
  2039. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2040. };
  2041. /* mpu -> prcm */
  2042. static struct omap_hwmod_ocp_if am33xx_mpu__prcm = {
  2043. .master = &am33xx_mpu_hwmod,
  2044. .slave = &am33xx_prcm_hwmod,
  2045. .clk = "dpll_mpu_m2_ck",
  2046. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2047. };
  2048. /* l3 s -> l3 main*/
  2049. static struct omap_hwmod_ocp_if am33xx_l3_s__l3_main = {
  2050. .master = &am33xx_l3_s_hwmod,
  2051. .slave = &am33xx_l3_main_hwmod,
  2052. .clk = "l3s_gclk",
  2053. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2054. };
  2055. /* pru-icss -> l3 main */
  2056. static struct omap_hwmod_ocp_if am33xx_pruss__l3_main = {
  2057. .master = &am33xx_pruss_hwmod,
  2058. .slave = &am33xx_l3_main_hwmod,
  2059. .clk = "l3_gclk",
  2060. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2061. };
  2062. /* wkup m3 -> l4 wkup */
  2063. static struct omap_hwmod_ocp_if am33xx_wkup_m3__l4_wkup = {
  2064. .master = &am33xx_wkup_m3_hwmod,
  2065. .slave = &am33xx_l4_wkup_hwmod,
  2066. .clk = "dpll_core_m4_div2_ck",
  2067. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2068. };
  2069. /* gfx -> l3 main */
  2070. static struct omap_hwmod_ocp_if am33xx_gfx__l3_main = {
  2071. .master = &am33xx_gfx_hwmod,
  2072. .slave = &am33xx_l3_main_hwmod,
  2073. .clk = "dpll_core_m4_ck",
  2074. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2075. };
  2076. /* l4 wkup -> wkup m3 */
  2077. static struct omap_hwmod_addr_space am33xx_wkup_m3_addrs[] = {
  2078. {
  2079. .name = "umem",
  2080. .pa_start = 0x44d00000,
  2081. .pa_end = 0x44d00000 + SZ_16K - 1,
  2082. .flags = ADDR_TYPE_RT
  2083. },
  2084. {
  2085. .name = "dmem",
  2086. .pa_start = 0x44d80000,
  2087. .pa_end = 0x44d80000 + SZ_8K - 1,
  2088. .flags = ADDR_TYPE_RT
  2089. },
  2090. { }
  2091. };
  2092. static struct omap_hwmod_ocp_if am33xx_l4_wkup__wkup_m3 = {
  2093. .master = &am33xx_l4_wkup_hwmod,
  2094. .slave = &am33xx_wkup_m3_hwmod,
  2095. .clk = "dpll_core_m4_div2_ck",
  2096. .addr = am33xx_wkup_m3_addrs,
  2097. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2098. };
  2099. /* l4 hs -> pru-icss */
  2100. static struct omap_hwmod_addr_space am33xx_pruss_addrs[] = {
  2101. {
  2102. .pa_start = 0x4a300000,
  2103. .pa_end = 0x4a300000 + SZ_512K - 1,
  2104. .flags = ADDR_TYPE_RT
  2105. },
  2106. { }
  2107. };
  2108. static struct omap_hwmod_ocp_if am33xx_l4_hs__pruss = {
  2109. .master = &am33xx_l4_hs_hwmod,
  2110. .slave = &am33xx_pruss_hwmod,
  2111. .clk = "dpll_core_m4_ck",
  2112. .addr = am33xx_pruss_addrs,
  2113. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2114. };
  2115. /* l3 main -> gfx */
  2116. static struct omap_hwmod_addr_space am33xx_gfx_addrs[] = {
  2117. {
  2118. .pa_start = 0x56000000,
  2119. .pa_end = 0x56000000 + SZ_16M - 1,
  2120. .flags = ADDR_TYPE_RT
  2121. },
  2122. { }
  2123. };
  2124. static struct omap_hwmod_ocp_if am33xx_l3_main__gfx = {
  2125. .master = &am33xx_l3_main_hwmod,
  2126. .slave = &am33xx_gfx_hwmod,
  2127. .clk = "dpll_core_m4_ck",
  2128. .addr = am33xx_gfx_addrs,
  2129. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2130. };
  2131. /* l4 wkup -> smartreflex0 */
  2132. static struct omap_hwmod_addr_space am33xx_smartreflex0_addrs[] = {
  2133. {
  2134. .pa_start = 0x44e37000,
  2135. .pa_end = 0x44e37000 + SZ_4K - 1,
  2136. .flags = ADDR_TYPE_RT
  2137. },
  2138. { }
  2139. };
  2140. static struct omap_hwmod_ocp_if am33xx_l4_wkup__smartreflex0 = {
  2141. .master = &am33xx_l4_wkup_hwmod,
  2142. .slave = &am33xx_smartreflex0_hwmod,
  2143. .clk = "dpll_core_m4_div2_ck",
  2144. .addr = am33xx_smartreflex0_addrs,
  2145. .user = OCP_USER_MPU,
  2146. };
  2147. /* l4 wkup -> smartreflex1 */
  2148. static struct omap_hwmod_addr_space am33xx_smartreflex1_addrs[] = {
  2149. {
  2150. .pa_start = 0x44e39000,
  2151. .pa_end = 0x44e39000 + SZ_4K - 1,
  2152. .flags = ADDR_TYPE_RT
  2153. },
  2154. { }
  2155. };
  2156. static struct omap_hwmod_ocp_if am33xx_l4_wkup__smartreflex1 = {
  2157. .master = &am33xx_l4_wkup_hwmod,
  2158. .slave = &am33xx_smartreflex1_hwmod,
  2159. .clk = "dpll_core_m4_div2_ck",
  2160. .addr = am33xx_smartreflex1_addrs,
  2161. .user = OCP_USER_MPU,
  2162. };
  2163. /* l4 wkup -> control */
  2164. static struct omap_hwmod_addr_space am33xx_control_addrs[] = {
  2165. {
  2166. .pa_start = 0x44e10000,
  2167. .pa_end = 0x44e10000 + SZ_8K - 1,
  2168. .flags = ADDR_TYPE_RT
  2169. },
  2170. { }
  2171. };
  2172. static struct omap_hwmod_ocp_if am33xx_l4_wkup__control = {
  2173. .master = &am33xx_l4_wkup_hwmod,
  2174. .slave = &am33xx_control_hwmod,
  2175. .clk = "dpll_core_m4_div2_ck",
  2176. .addr = am33xx_control_addrs,
  2177. .user = OCP_USER_MPU,
  2178. };
  2179. /* l4 wkup -> rtc */
  2180. static struct omap_hwmod_addr_space am33xx_rtc_addrs[] = {
  2181. {
  2182. .pa_start = 0x44e3e000,
  2183. .pa_end = 0x44e3e000 + SZ_4K - 1,
  2184. .flags = ADDR_TYPE_RT
  2185. },
  2186. { }
  2187. };
  2188. static struct omap_hwmod_ocp_if am33xx_l4_wkup__rtc = {
  2189. .master = &am33xx_l4_wkup_hwmod,
  2190. .slave = &am33xx_rtc_hwmod,
  2191. .clk = "clkdiv32k_ick",
  2192. .addr = am33xx_rtc_addrs,
  2193. .user = OCP_USER_MPU,
  2194. };
  2195. /* l4 per/ls -> DCAN0 */
  2196. static struct omap_hwmod_addr_space am33xx_dcan0_addrs[] = {
  2197. {
  2198. .pa_start = 0x481CC000,
  2199. .pa_end = 0x481CC000 + SZ_4K - 1,
  2200. .flags = ADDR_TYPE_RT
  2201. },
  2202. { }
  2203. };
  2204. static struct omap_hwmod_ocp_if am33xx_l4_per__dcan0 = {
  2205. .master = &am33xx_l4_ls_hwmod,
  2206. .slave = &am33xx_dcan0_hwmod,
  2207. .clk = "l4ls_gclk",
  2208. .addr = am33xx_dcan0_addrs,
  2209. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2210. };
  2211. /* l4 per/ls -> DCAN1 */
  2212. static struct omap_hwmod_addr_space am33xx_dcan1_addrs[] = {
  2213. {
  2214. .pa_start = 0x481D0000,
  2215. .pa_end = 0x481D0000 + SZ_4K - 1,
  2216. .flags = ADDR_TYPE_RT
  2217. },
  2218. { }
  2219. };
  2220. static struct omap_hwmod_ocp_if am33xx_l4_per__dcan1 = {
  2221. .master = &am33xx_l4_ls_hwmod,
  2222. .slave = &am33xx_dcan1_hwmod,
  2223. .clk = "l4ls_gclk",
  2224. .addr = am33xx_dcan1_addrs,
  2225. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2226. };
  2227. /* l4 per/ls -> GPIO2 */
  2228. static struct omap_hwmod_addr_space am33xx_gpio1_addrs[] = {
  2229. {
  2230. .pa_start = 0x4804C000,
  2231. .pa_end = 0x4804C000 + SZ_4K - 1,
  2232. .flags = ADDR_TYPE_RT,
  2233. },
  2234. { }
  2235. };
  2236. static struct omap_hwmod_ocp_if am33xx_l4_per__gpio1 = {
  2237. .master = &am33xx_l4_ls_hwmod,
  2238. .slave = &am33xx_gpio1_hwmod,
  2239. .clk = "l4ls_gclk",
  2240. .addr = am33xx_gpio1_addrs,
  2241. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2242. };
  2243. /* l4 per/ls -> gpio3 */
  2244. static struct omap_hwmod_addr_space am33xx_gpio2_addrs[] = {
  2245. {
  2246. .pa_start = 0x481AC000,
  2247. .pa_end = 0x481AC000 + SZ_4K - 1,
  2248. .flags = ADDR_TYPE_RT,
  2249. },
  2250. { }
  2251. };
  2252. static struct omap_hwmod_ocp_if am33xx_l4_per__gpio2 = {
  2253. .master = &am33xx_l4_ls_hwmod,
  2254. .slave = &am33xx_gpio2_hwmod,
  2255. .clk = "l4ls_gclk",
  2256. .addr = am33xx_gpio2_addrs,
  2257. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2258. };
  2259. /* l4 per/ls -> gpio4 */
  2260. static struct omap_hwmod_addr_space am33xx_gpio3_addrs[] = {
  2261. {
  2262. .pa_start = 0x481AE000,
  2263. .pa_end = 0x481AE000 + SZ_4K - 1,
  2264. .flags = ADDR_TYPE_RT,
  2265. },
  2266. { }
  2267. };
  2268. static struct omap_hwmod_ocp_if am33xx_l4_per__gpio3 = {
  2269. .master = &am33xx_l4_ls_hwmod,
  2270. .slave = &am33xx_gpio3_hwmod,
  2271. .clk = "l4ls_gclk",
  2272. .addr = am33xx_gpio3_addrs,
  2273. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2274. };
  2275. /* L4 WKUP -> I2C1 */
  2276. static struct omap_hwmod_addr_space am33xx_i2c1_addr_space[] = {
  2277. {
  2278. .pa_start = 0x44E0B000,
  2279. .pa_end = 0x44E0B000 + SZ_4K - 1,
  2280. .flags = ADDR_TYPE_RT,
  2281. },
  2282. { }
  2283. };
  2284. static struct omap_hwmod_ocp_if am33xx_l4_wkup__i2c1 = {
  2285. .master = &am33xx_l4_wkup_hwmod,
  2286. .slave = &am33xx_i2c1_hwmod,
  2287. .clk = "dpll_core_m4_div2_ck",
  2288. .addr = am33xx_i2c1_addr_space,
  2289. .user = OCP_USER_MPU,
  2290. };
  2291. /* L4 WKUP -> GPIO1 */
  2292. static struct omap_hwmod_addr_space am33xx_gpio0_addrs[] = {
  2293. {
  2294. .pa_start = 0x44E07000,
  2295. .pa_end = 0x44E07000 + SZ_4K - 1,
  2296. .flags = ADDR_TYPE_RT,
  2297. },
  2298. { }
  2299. };
  2300. static struct omap_hwmod_ocp_if am33xx_l4_wkup__gpio0 = {
  2301. .master = &am33xx_l4_wkup_hwmod,
  2302. .slave = &am33xx_gpio0_hwmod,
  2303. .clk = "dpll_core_m4_div2_ck",
  2304. .addr = am33xx_gpio0_addrs,
  2305. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2306. };
  2307. /* L4 WKUP -> ADC_TSC */
  2308. static struct omap_hwmod_addr_space am33xx_adc_tsc_addrs[] = {
  2309. {
  2310. .pa_start = 0x44E0D000,
  2311. .pa_end = 0x44E0D000 + SZ_8K - 1,
  2312. .flags = ADDR_TYPE_RT
  2313. },
  2314. { }
  2315. };
  2316. static struct omap_hwmod_ocp_if am33xx_l4_wkup__adc_tsc = {
  2317. .master = &am33xx_l4_wkup_hwmod,
  2318. .slave = &am33xx_adc_tsc_hwmod,
  2319. .clk = "dpll_core_m4_div2_ck",
  2320. .addr = am33xx_adc_tsc_addrs,
  2321. .user = OCP_USER_MPU,
  2322. };
  2323. static struct omap_hwmod_addr_space am33xx_cpgmac0_addr_space[] = {
  2324. /* cpsw ss */
  2325. {
  2326. .pa_start = 0x4a100000,
  2327. .pa_end = 0x4a100000 + SZ_2K - 1,
  2328. },
  2329. /* cpsw wr */
  2330. {
  2331. .pa_start = 0x4a101200,
  2332. .pa_end = 0x4a101200 + SZ_256 - 1,
  2333. .flags = ADDR_TYPE_RT,
  2334. },
  2335. { }
  2336. };
  2337. static struct omap_hwmod_ocp_if am33xx_l4_hs__cpgmac0 = {
  2338. .master = &am33xx_l4_hs_hwmod,
  2339. .slave = &am33xx_cpgmac0_hwmod,
  2340. .clk = "cpsw_125mhz_gclk",
  2341. .addr = am33xx_cpgmac0_addr_space,
  2342. .user = OCP_USER_MPU,
  2343. };
  2344. static struct omap_hwmod_addr_space am33xx_mdio_addr_space[] = {
  2345. {
  2346. .pa_start = 0x4A101000,
  2347. .pa_end = 0x4A101000 + SZ_256 - 1,
  2348. },
  2349. { }
  2350. };
  2351. static struct omap_hwmod_ocp_if am33xx_cpgmac0__mdio = {
  2352. .master = &am33xx_cpgmac0_hwmod,
  2353. .slave = &am33xx_mdio_hwmod,
  2354. .addr = am33xx_mdio_addr_space,
  2355. .user = OCP_USER_MPU,
  2356. };
  2357. static struct omap_hwmod_addr_space am33xx_elm_addr_space[] = {
  2358. {
  2359. .pa_start = 0x48080000,
  2360. .pa_end = 0x48080000 + SZ_8K - 1,
  2361. .flags = ADDR_TYPE_RT
  2362. },
  2363. { }
  2364. };
  2365. static struct omap_hwmod_ocp_if am33xx_l4_ls__elm = {
  2366. .master = &am33xx_l4_ls_hwmod,
  2367. .slave = &am33xx_elm_hwmod,
  2368. .clk = "l4ls_gclk",
  2369. .addr = am33xx_elm_addr_space,
  2370. .user = OCP_USER_MPU,
  2371. };
  2372. static struct omap_hwmod_addr_space am33xx_epwmss0_addr_space[] = {
  2373. {
  2374. .pa_start = 0x48300000,
  2375. .pa_end = 0x48300000 + SZ_16 - 1,
  2376. .flags = ADDR_TYPE_RT
  2377. },
  2378. { }
  2379. };
  2380. static struct omap_hwmod_ocp_if am33xx_l4_ls__epwmss0 = {
  2381. .master = &am33xx_l4_ls_hwmod,
  2382. .slave = &am33xx_epwmss0_hwmod,
  2383. .clk = "l4ls_gclk",
  2384. .addr = am33xx_epwmss0_addr_space,
  2385. .user = OCP_USER_MPU,
  2386. };
  2387. static struct omap_hwmod_addr_space am33xx_ecap0_addr_space[] = {
  2388. {
  2389. .pa_start = 0x48300100,
  2390. .pa_end = 0x48300100 + SZ_128 - 1,
  2391. },
  2392. { }
  2393. };
  2394. static struct omap_hwmod_ocp_if am33xx_epwmss0__ecap0 = {
  2395. .master = &am33xx_epwmss0_hwmod,
  2396. .slave = &am33xx_ecap0_hwmod,
  2397. .clk = "l4ls_gclk",
  2398. .addr = am33xx_ecap0_addr_space,
  2399. .user = OCP_USER_MPU,
  2400. };
  2401. static struct omap_hwmod_addr_space am33xx_eqep0_addr_space[] = {
  2402. {
  2403. .pa_start = 0x48300180,
  2404. .pa_end = 0x48300180 + SZ_128 - 1,
  2405. },
  2406. { }
  2407. };
  2408. static struct omap_hwmod_ocp_if am33xx_epwmss0__eqep0 = {
  2409. .master = &am33xx_epwmss0_hwmod,
  2410. .slave = &am33xx_eqep0_hwmod,
  2411. .clk = "l4ls_gclk",
  2412. .addr = am33xx_eqep0_addr_space,
  2413. .user = OCP_USER_MPU,
  2414. };
  2415. static struct omap_hwmod_addr_space am33xx_ehrpwm0_addr_space[] = {
  2416. {
  2417. .pa_start = 0x48300200,
  2418. .pa_end = 0x48300200 + SZ_128 - 1,
  2419. },
  2420. { }
  2421. };
  2422. static struct omap_hwmod_ocp_if am33xx_epwmss0__ehrpwm0 = {
  2423. .master = &am33xx_epwmss0_hwmod,
  2424. .slave = &am33xx_ehrpwm0_hwmod,
  2425. .clk = "l4ls_gclk",
  2426. .addr = am33xx_ehrpwm0_addr_space,
  2427. .user = OCP_USER_MPU,
  2428. };
  2429. static struct omap_hwmod_addr_space am33xx_epwmss1_addr_space[] = {
  2430. {
  2431. .pa_start = 0x48302000,
  2432. .pa_end = 0x48302000 + SZ_16 - 1,
  2433. .flags = ADDR_TYPE_RT
  2434. },
  2435. { }
  2436. };
  2437. static struct omap_hwmod_ocp_if am33xx_l4_ls__epwmss1 = {
  2438. .master = &am33xx_l4_ls_hwmod,
  2439. .slave = &am33xx_epwmss1_hwmod,
  2440. .clk = "l4ls_gclk",
  2441. .addr = am33xx_epwmss1_addr_space,
  2442. .user = OCP_USER_MPU,
  2443. };
  2444. static struct omap_hwmod_addr_space am33xx_ecap1_addr_space[] = {
  2445. {
  2446. .pa_start = 0x48302100,
  2447. .pa_end = 0x48302100 + SZ_128 - 1,
  2448. },
  2449. { }
  2450. };
  2451. static struct omap_hwmod_ocp_if am33xx_epwmss1__ecap1 = {
  2452. .master = &am33xx_epwmss1_hwmod,
  2453. .slave = &am33xx_ecap1_hwmod,
  2454. .clk = "l4ls_gclk",
  2455. .addr = am33xx_ecap1_addr_space,
  2456. .user = OCP_USER_MPU,
  2457. };
  2458. static struct omap_hwmod_addr_space am33xx_eqep1_addr_space[] = {
  2459. {
  2460. .pa_start = 0x48302180,
  2461. .pa_end = 0x48302180 + SZ_128 - 1,
  2462. },
  2463. { }
  2464. };
  2465. static struct omap_hwmod_ocp_if am33xx_epwmss1__eqep1 = {
  2466. .master = &am33xx_epwmss1_hwmod,
  2467. .slave = &am33xx_eqep1_hwmod,
  2468. .clk = "l4ls_gclk",
  2469. .addr = am33xx_eqep1_addr_space,
  2470. .user = OCP_USER_MPU,
  2471. };
  2472. static struct omap_hwmod_addr_space am33xx_ehrpwm1_addr_space[] = {
  2473. {
  2474. .pa_start = 0x48302200,
  2475. .pa_end = 0x48302200 + SZ_128 - 1,
  2476. },
  2477. { }
  2478. };
  2479. static struct omap_hwmod_ocp_if am33xx_epwmss1__ehrpwm1 = {
  2480. .master = &am33xx_epwmss1_hwmod,
  2481. .slave = &am33xx_ehrpwm1_hwmod,
  2482. .clk = "l4ls_gclk",
  2483. .addr = am33xx_ehrpwm1_addr_space,
  2484. .user = OCP_USER_MPU,
  2485. };
  2486. static struct omap_hwmod_addr_space am33xx_epwmss2_addr_space[] = {
  2487. {
  2488. .pa_start = 0x48304000,
  2489. .pa_end = 0x48304000 + SZ_16 - 1,
  2490. .flags = ADDR_TYPE_RT
  2491. },
  2492. { }
  2493. };
  2494. static struct omap_hwmod_ocp_if am33xx_l4_ls__epwmss2 = {
  2495. .master = &am33xx_l4_ls_hwmod,
  2496. .slave = &am33xx_epwmss2_hwmod,
  2497. .clk = "l4ls_gclk",
  2498. .addr = am33xx_epwmss2_addr_space,
  2499. .user = OCP_USER_MPU,
  2500. };
  2501. static struct omap_hwmod_addr_space am33xx_ecap2_addr_space[] = {
  2502. {
  2503. .pa_start = 0x48304100,
  2504. .pa_end = 0x48304100 + SZ_128 - 1,
  2505. },
  2506. { }
  2507. };
  2508. static struct omap_hwmod_ocp_if am33xx_epwmss2__ecap2 = {
  2509. .master = &am33xx_epwmss2_hwmod,
  2510. .slave = &am33xx_ecap2_hwmod,
  2511. .clk = "l4ls_gclk",
  2512. .addr = am33xx_ecap2_addr_space,
  2513. .user = OCP_USER_MPU,
  2514. };
  2515. static struct omap_hwmod_addr_space am33xx_eqep2_addr_space[] = {
  2516. {
  2517. .pa_start = 0x48304180,
  2518. .pa_end = 0x48304180 + SZ_128 - 1,
  2519. },
  2520. { }
  2521. };
  2522. static struct omap_hwmod_ocp_if am33xx_epwmss2__eqep2 = {
  2523. .master = &am33xx_epwmss2_hwmod,
  2524. .slave = &am33xx_eqep2_hwmod,
  2525. .clk = "l4ls_gclk",
  2526. .addr = am33xx_eqep2_addr_space,
  2527. .user = OCP_USER_MPU,
  2528. };
  2529. static struct omap_hwmod_addr_space am33xx_ehrpwm2_addr_space[] = {
  2530. {
  2531. .pa_start = 0x48304200,
  2532. .pa_end = 0x48304200 + SZ_128 - 1,
  2533. },
  2534. { }
  2535. };
  2536. static struct omap_hwmod_ocp_if am33xx_epwmss2__ehrpwm2 = {
  2537. .master = &am33xx_epwmss2_hwmod,
  2538. .slave = &am33xx_ehrpwm2_hwmod,
  2539. .clk = "l4ls_gclk",
  2540. .addr = am33xx_ehrpwm2_addr_space,
  2541. .user = OCP_USER_MPU,
  2542. };
  2543. /* l3s cfg -> gpmc */
  2544. static struct omap_hwmod_addr_space am33xx_gpmc_addr_space[] = {
  2545. {
  2546. .pa_start = 0x50000000,
  2547. .pa_end = 0x50000000 + SZ_8K - 1,
  2548. .flags = ADDR_TYPE_RT,
  2549. },
  2550. { }
  2551. };
  2552. static struct omap_hwmod_ocp_if am33xx_l3_s__gpmc = {
  2553. .master = &am33xx_l3_s_hwmod,
  2554. .slave = &am33xx_gpmc_hwmod,
  2555. .clk = "l3s_gclk",
  2556. .addr = am33xx_gpmc_addr_space,
  2557. .user = OCP_USER_MPU,
  2558. };
  2559. /* i2c2 */
  2560. static struct omap_hwmod_addr_space am33xx_i2c2_addr_space[] = {
  2561. {
  2562. .pa_start = 0x4802A000,
  2563. .pa_end = 0x4802A000 + SZ_4K - 1,
  2564. .flags = ADDR_TYPE_RT,
  2565. },
  2566. { }
  2567. };
  2568. static struct omap_hwmod_ocp_if am33xx_l4_per__i2c2 = {
  2569. .master = &am33xx_l4_ls_hwmod,
  2570. .slave = &am33xx_i2c2_hwmod,
  2571. .clk = "l4ls_gclk",
  2572. .addr = am33xx_i2c2_addr_space,
  2573. .user = OCP_USER_MPU,
  2574. };
  2575. static struct omap_hwmod_addr_space am33xx_i2c3_addr_space[] = {
  2576. {
  2577. .pa_start = 0x4819C000,
  2578. .pa_end = 0x4819C000 + SZ_4K - 1,
  2579. .flags = ADDR_TYPE_RT
  2580. },
  2581. { }
  2582. };
  2583. static struct omap_hwmod_ocp_if am33xx_l4_per__i2c3 = {
  2584. .master = &am33xx_l4_ls_hwmod,
  2585. .slave = &am33xx_i2c3_hwmod,
  2586. .clk = "l4ls_gclk",
  2587. .addr = am33xx_i2c3_addr_space,
  2588. .user = OCP_USER_MPU,
  2589. };
  2590. static struct omap_hwmod_addr_space am33xx_lcdc_addr_space[] = {
  2591. {
  2592. .pa_start = 0x4830E000,
  2593. .pa_end = 0x4830E000 + SZ_8K - 1,
  2594. .flags = ADDR_TYPE_RT,
  2595. },
  2596. { }
  2597. };
  2598. static struct omap_hwmod_ocp_if am33xx_l3_main__lcdc = {
  2599. .master = &am33xx_l3_main_hwmod,
  2600. .slave = &am33xx_lcdc_hwmod,
  2601. .clk = "dpll_core_m4_ck",
  2602. .addr = am33xx_lcdc_addr_space,
  2603. .user = OCP_USER_MPU,
  2604. };
  2605. static struct omap_hwmod_addr_space am33xx_mailbox_addrs[] = {
  2606. {
  2607. .pa_start = 0x480C8000,
  2608. .pa_end = 0x480C8000 + (SZ_4K - 1),
  2609. .flags = ADDR_TYPE_RT
  2610. },
  2611. { }
  2612. };
  2613. /* l4 ls -> mailbox */
  2614. static struct omap_hwmod_ocp_if am33xx_l4_per__mailbox = {
  2615. .master = &am33xx_l4_ls_hwmod,
  2616. .slave = &am33xx_mailbox_hwmod,
  2617. .clk = "l4ls_gclk",
  2618. .addr = am33xx_mailbox_addrs,
  2619. .user = OCP_USER_MPU,
  2620. };
  2621. /* l4 ls -> spinlock */
  2622. static struct omap_hwmod_addr_space am33xx_spinlock_addrs[] = {
  2623. {
  2624. .pa_start = 0x480Ca000,
  2625. .pa_end = 0x480Ca000 + SZ_4K - 1,
  2626. .flags = ADDR_TYPE_RT
  2627. },
  2628. { }
  2629. };
  2630. static struct omap_hwmod_ocp_if am33xx_l4_ls__spinlock = {
  2631. .master = &am33xx_l4_ls_hwmod,
  2632. .slave = &am33xx_spinlock_hwmod,
  2633. .clk = "l4ls_gclk",
  2634. .addr = am33xx_spinlock_addrs,
  2635. .user = OCP_USER_MPU,
  2636. };
  2637. /* l4 ls -> mcasp0 */
  2638. static struct omap_hwmod_addr_space am33xx_mcasp0_addr_space[] = {
  2639. {
  2640. .pa_start = 0x48038000,
  2641. .pa_end = 0x48038000 + SZ_8K - 1,
  2642. .flags = ADDR_TYPE_RT
  2643. },
  2644. { }
  2645. };
  2646. static struct omap_hwmod_ocp_if am33xx_l4_ls__mcasp0 = {
  2647. .master = &am33xx_l4_ls_hwmod,
  2648. .slave = &am33xx_mcasp0_hwmod,
  2649. .clk = "l4ls_gclk",
  2650. .addr = am33xx_mcasp0_addr_space,
  2651. .user = OCP_USER_MPU,
  2652. };
  2653. /* l3 s -> mcasp0 data */
  2654. static struct omap_hwmod_addr_space am33xx_mcasp0_data_addr_space[] = {
  2655. {
  2656. .pa_start = 0x46000000,
  2657. .pa_end = 0x46000000 + SZ_4M - 1,
  2658. .flags = ADDR_TYPE_RT
  2659. },
  2660. { }
  2661. };
  2662. static struct omap_hwmod_ocp_if am33xx_l3_s__mcasp0_data = {
  2663. .master = &am33xx_l3_s_hwmod,
  2664. .slave = &am33xx_mcasp0_hwmod,
  2665. .clk = "l3s_gclk",
  2666. .addr = am33xx_mcasp0_data_addr_space,
  2667. .user = OCP_USER_SDMA,
  2668. };
  2669. /* l4 ls -> mcasp1 */
  2670. static struct omap_hwmod_addr_space am33xx_mcasp1_addr_space[] = {
  2671. {
  2672. .pa_start = 0x4803C000,
  2673. .pa_end = 0x4803C000 + SZ_8K - 1,
  2674. .flags = ADDR_TYPE_RT
  2675. },
  2676. { }
  2677. };
  2678. static struct omap_hwmod_ocp_if am33xx_l4_ls__mcasp1 = {
  2679. .master = &am33xx_l4_ls_hwmod,
  2680. .slave = &am33xx_mcasp1_hwmod,
  2681. .clk = "l4ls_gclk",
  2682. .addr = am33xx_mcasp1_addr_space,
  2683. .user = OCP_USER_MPU,
  2684. };
  2685. /* l3 s -> mcasp1 data */
  2686. static struct omap_hwmod_addr_space am33xx_mcasp1_data_addr_space[] = {
  2687. {
  2688. .pa_start = 0x46400000,
  2689. .pa_end = 0x46400000 + SZ_4M - 1,
  2690. .flags = ADDR_TYPE_RT
  2691. },
  2692. { }
  2693. };
  2694. static struct omap_hwmod_ocp_if am33xx_l3_s__mcasp1_data = {
  2695. .master = &am33xx_l3_s_hwmod,
  2696. .slave = &am33xx_mcasp1_hwmod,
  2697. .clk = "l3s_gclk",
  2698. .addr = am33xx_mcasp1_data_addr_space,
  2699. .user = OCP_USER_SDMA,
  2700. };
  2701. /* l4 ls -> mmc0 */
  2702. static struct omap_hwmod_addr_space am33xx_mmc0_addr_space[] = {
  2703. {
  2704. .pa_start = 0x48060100,
  2705. .pa_end = 0x48060100 + SZ_4K - 1,
  2706. .flags = ADDR_TYPE_RT,
  2707. },
  2708. { }
  2709. };
  2710. static struct omap_hwmod_ocp_if am33xx_l4_ls__mmc0 = {
  2711. .master = &am33xx_l4_ls_hwmod,
  2712. .slave = &am33xx_mmc0_hwmod,
  2713. .clk = "l4ls_gclk",
  2714. .addr = am33xx_mmc0_addr_space,
  2715. .user = OCP_USER_MPU,
  2716. };
  2717. /* l4 ls -> mmc1 */
  2718. static struct omap_hwmod_addr_space am33xx_mmc1_addr_space[] = {
  2719. {
  2720. .pa_start = 0x481d8100,
  2721. .pa_end = 0x481d8100 + SZ_4K - 1,
  2722. .flags = ADDR_TYPE_RT,
  2723. },
  2724. { }
  2725. };
  2726. static struct omap_hwmod_ocp_if am33xx_l4_ls__mmc1 = {
  2727. .master = &am33xx_l4_ls_hwmod,
  2728. .slave = &am33xx_mmc1_hwmod,
  2729. .clk = "l4ls_gclk",
  2730. .addr = am33xx_mmc1_addr_space,
  2731. .user = OCP_USER_MPU,
  2732. };
  2733. /* l3 s -> mmc2 */
  2734. static struct omap_hwmod_addr_space am33xx_mmc2_addr_space[] = {
  2735. {
  2736. .pa_start = 0x47810100,
  2737. .pa_end = 0x47810100 + SZ_64K - 1,
  2738. .flags = ADDR_TYPE_RT,
  2739. },
  2740. { }
  2741. };
  2742. static struct omap_hwmod_ocp_if am33xx_l3_s__mmc2 = {
  2743. .master = &am33xx_l3_s_hwmod,
  2744. .slave = &am33xx_mmc2_hwmod,
  2745. .clk = "l3s_gclk",
  2746. .addr = am33xx_mmc2_addr_space,
  2747. .user = OCP_USER_MPU,
  2748. };
  2749. /* l4 ls -> mcspi0 */
  2750. static struct omap_hwmod_addr_space am33xx_mcspi0_addr_space[] = {
  2751. {
  2752. .pa_start = 0x48030000,
  2753. .pa_end = 0x48030000 + SZ_1K - 1,
  2754. .flags = ADDR_TYPE_RT,
  2755. },
  2756. { }
  2757. };
  2758. static struct omap_hwmod_ocp_if am33xx_l4_ls__mcspi0 = {
  2759. .master = &am33xx_l4_ls_hwmod,
  2760. .slave = &am33xx_spi0_hwmod,
  2761. .clk = "l4ls_gclk",
  2762. .addr = am33xx_mcspi0_addr_space,
  2763. .user = OCP_USER_MPU,
  2764. };
  2765. /* l4 ls -> mcspi1 */
  2766. static struct omap_hwmod_addr_space am33xx_mcspi1_addr_space[] = {
  2767. {
  2768. .pa_start = 0x481A0000,
  2769. .pa_end = 0x481A0000 + SZ_1K - 1,
  2770. .flags = ADDR_TYPE_RT,
  2771. },
  2772. { }
  2773. };
  2774. static struct omap_hwmod_ocp_if am33xx_l4_ls__mcspi1 = {
  2775. .master = &am33xx_l4_ls_hwmod,
  2776. .slave = &am33xx_spi1_hwmod,
  2777. .clk = "l4ls_gclk",
  2778. .addr = am33xx_mcspi1_addr_space,
  2779. .user = OCP_USER_MPU,
  2780. };
  2781. /* l4 wkup -> timer1 */
  2782. static struct omap_hwmod_addr_space am33xx_timer1_addr_space[] = {
  2783. {
  2784. .pa_start = 0x44E31000,
  2785. .pa_end = 0x44E31000 + SZ_1K - 1,
  2786. .flags = ADDR_TYPE_RT
  2787. },
  2788. { }
  2789. };
  2790. static struct omap_hwmod_ocp_if am33xx_l4_wkup__timer1 = {
  2791. .master = &am33xx_l4_wkup_hwmod,
  2792. .slave = &am33xx_timer1_hwmod,
  2793. .clk = "dpll_core_m4_div2_ck",
  2794. .addr = am33xx_timer1_addr_space,
  2795. .user = OCP_USER_MPU,
  2796. };
  2797. /* l4 per -> timer2 */
  2798. static struct omap_hwmod_addr_space am33xx_timer2_addr_space[] = {
  2799. {
  2800. .pa_start = 0x48040000,
  2801. .pa_end = 0x48040000 + SZ_1K - 1,
  2802. .flags = ADDR_TYPE_RT
  2803. },
  2804. { }
  2805. };
  2806. static struct omap_hwmod_ocp_if am33xx_l4_ls__timer2 = {
  2807. .master = &am33xx_l4_ls_hwmod,
  2808. .slave = &am33xx_timer2_hwmod,
  2809. .clk = "l4ls_gclk",
  2810. .addr = am33xx_timer2_addr_space,
  2811. .user = OCP_USER_MPU,
  2812. };
  2813. /* l4 per -> timer3 */
  2814. static struct omap_hwmod_addr_space am33xx_timer3_addr_space[] = {
  2815. {
  2816. .pa_start = 0x48042000,
  2817. .pa_end = 0x48042000 + SZ_1K - 1,
  2818. .flags = ADDR_TYPE_RT
  2819. },
  2820. { }
  2821. };
  2822. static struct omap_hwmod_ocp_if am33xx_l4_ls__timer3 = {
  2823. .master = &am33xx_l4_ls_hwmod,
  2824. .slave = &am33xx_timer3_hwmod,
  2825. .clk = "l4ls_gclk",
  2826. .addr = am33xx_timer3_addr_space,
  2827. .user = OCP_USER_MPU,
  2828. };
  2829. /* l4 per -> timer4 */
  2830. static struct omap_hwmod_addr_space am33xx_timer4_addr_space[] = {
  2831. {
  2832. .pa_start = 0x48044000,
  2833. .pa_end = 0x48044000 + SZ_1K - 1,
  2834. .flags = ADDR_TYPE_RT
  2835. },
  2836. { }
  2837. };
  2838. static struct omap_hwmod_ocp_if am33xx_l4_ls__timer4 = {
  2839. .master = &am33xx_l4_ls_hwmod,
  2840. .slave = &am33xx_timer4_hwmod,
  2841. .clk = "l4ls_gclk",
  2842. .addr = am33xx_timer4_addr_space,
  2843. .user = OCP_USER_MPU,
  2844. };
  2845. /* l4 per -> timer5 */
  2846. static struct omap_hwmod_addr_space am33xx_timer5_addr_space[] = {
  2847. {
  2848. .pa_start = 0x48046000,
  2849. .pa_end = 0x48046000 + SZ_1K - 1,
  2850. .flags = ADDR_TYPE_RT
  2851. },
  2852. { }
  2853. };
  2854. static struct omap_hwmod_ocp_if am33xx_l4_ls__timer5 = {
  2855. .master = &am33xx_l4_ls_hwmod,
  2856. .slave = &am33xx_timer5_hwmod,
  2857. .clk = "l4ls_gclk",
  2858. .addr = am33xx_timer5_addr_space,
  2859. .user = OCP_USER_MPU,
  2860. };
  2861. /* l4 per -> timer6 */
  2862. static struct omap_hwmod_addr_space am33xx_timer6_addr_space[] = {
  2863. {
  2864. .pa_start = 0x48048000,
  2865. .pa_end = 0x48048000 + SZ_1K - 1,
  2866. .flags = ADDR_TYPE_RT
  2867. },
  2868. { }
  2869. };
  2870. static struct omap_hwmod_ocp_if am33xx_l4_ls__timer6 = {
  2871. .master = &am33xx_l4_ls_hwmod,
  2872. .slave = &am33xx_timer6_hwmod,
  2873. .clk = "l4ls_gclk",
  2874. .addr = am33xx_timer6_addr_space,
  2875. .user = OCP_USER_MPU,
  2876. };
  2877. /* l4 per -> timer7 */
  2878. static struct omap_hwmod_addr_space am33xx_timer7_addr_space[] = {
  2879. {
  2880. .pa_start = 0x4804A000,
  2881. .pa_end = 0x4804A000 + SZ_1K - 1,
  2882. .flags = ADDR_TYPE_RT
  2883. },
  2884. { }
  2885. };
  2886. static struct omap_hwmod_ocp_if am33xx_l4_ls__timer7 = {
  2887. .master = &am33xx_l4_ls_hwmod,
  2888. .slave = &am33xx_timer7_hwmod,
  2889. .clk = "l4ls_gclk",
  2890. .addr = am33xx_timer7_addr_space,
  2891. .user = OCP_USER_MPU,
  2892. };
  2893. /* l3 main -> tpcc */
  2894. static struct omap_hwmod_addr_space am33xx_tpcc_addr_space[] = {
  2895. {
  2896. .pa_start = 0x49000000,
  2897. .pa_end = 0x49000000 + SZ_32K - 1,
  2898. .flags = ADDR_TYPE_RT
  2899. },
  2900. { }
  2901. };
  2902. static struct omap_hwmod_ocp_if am33xx_l3_main__tpcc = {
  2903. .master = &am33xx_l3_main_hwmod,
  2904. .slave = &am33xx_tpcc_hwmod,
  2905. .clk = "l3_gclk",
  2906. .addr = am33xx_tpcc_addr_space,
  2907. .user = OCP_USER_MPU,
  2908. };
  2909. /* l3 main -> tpcc0 */
  2910. static struct omap_hwmod_addr_space am33xx_tptc0_addr_space[] = {
  2911. {
  2912. .pa_start = 0x49800000,
  2913. .pa_end = 0x49800000 + SZ_8K - 1,
  2914. .flags = ADDR_TYPE_RT,
  2915. },
  2916. { }
  2917. };
  2918. static struct omap_hwmod_ocp_if am33xx_l3_main__tptc0 = {
  2919. .master = &am33xx_l3_main_hwmod,
  2920. .slave = &am33xx_tptc0_hwmod,
  2921. .clk = "l3_gclk",
  2922. .addr = am33xx_tptc0_addr_space,
  2923. .user = OCP_USER_MPU,
  2924. };
  2925. /* l3 main -> tpcc1 */
  2926. static struct omap_hwmod_addr_space am33xx_tptc1_addr_space[] = {
  2927. {
  2928. .pa_start = 0x49900000,
  2929. .pa_end = 0x49900000 + SZ_8K - 1,
  2930. .flags = ADDR_TYPE_RT,
  2931. },
  2932. { }
  2933. };
  2934. static struct omap_hwmod_ocp_if am33xx_l3_main__tptc1 = {
  2935. .master = &am33xx_l3_main_hwmod,
  2936. .slave = &am33xx_tptc1_hwmod,
  2937. .clk = "l3_gclk",
  2938. .addr = am33xx_tptc1_addr_space,
  2939. .user = OCP_USER_MPU,
  2940. };
  2941. /* l3 main -> tpcc2 */
  2942. static struct omap_hwmod_addr_space am33xx_tptc2_addr_space[] = {
  2943. {
  2944. .pa_start = 0x49a00000,
  2945. .pa_end = 0x49a00000 + SZ_8K - 1,
  2946. .flags = ADDR_TYPE_RT,
  2947. },
  2948. { }
  2949. };
  2950. static struct omap_hwmod_ocp_if am33xx_l3_main__tptc2 = {
  2951. .master = &am33xx_l3_main_hwmod,
  2952. .slave = &am33xx_tptc2_hwmod,
  2953. .clk = "l3_gclk",
  2954. .addr = am33xx_tptc2_addr_space,
  2955. .user = OCP_USER_MPU,
  2956. };
  2957. /* l4 wkup -> uart1 */
  2958. static struct omap_hwmod_addr_space am33xx_uart1_addr_space[] = {
  2959. {
  2960. .pa_start = 0x44E09000,
  2961. .pa_end = 0x44E09000 + SZ_8K - 1,
  2962. .flags = ADDR_TYPE_RT,
  2963. },
  2964. { }
  2965. };
  2966. static struct omap_hwmod_ocp_if am33xx_l4_wkup__uart1 = {
  2967. .master = &am33xx_l4_wkup_hwmod,
  2968. .slave = &am33xx_uart1_hwmod,
  2969. .clk = "dpll_core_m4_div2_ck",
  2970. .addr = am33xx_uart1_addr_space,
  2971. .user = OCP_USER_MPU,
  2972. };
  2973. /* l4 ls -> uart2 */
  2974. static struct omap_hwmod_addr_space am33xx_uart2_addr_space[] = {
  2975. {
  2976. .pa_start = 0x48022000,
  2977. .pa_end = 0x48022000 + SZ_8K - 1,
  2978. .flags = ADDR_TYPE_RT,
  2979. },
  2980. { }
  2981. };
  2982. static struct omap_hwmod_ocp_if am33xx_l4_ls__uart2 = {
  2983. .master = &am33xx_l4_ls_hwmod,
  2984. .slave = &am33xx_uart2_hwmod,
  2985. .clk = "l4ls_gclk",
  2986. .addr = am33xx_uart2_addr_space,
  2987. .user = OCP_USER_MPU,
  2988. };
  2989. /* l4 ls -> uart3 */
  2990. static struct omap_hwmod_addr_space am33xx_uart3_addr_space[] = {
  2991. {
  2992. .pa_start = 0x48024000,
  2993. .pa_end = 0x48024000 + SZ_8K - 1,
  2994. .flags = ADDR_TYPE_RT,
  2995. },
  2996. { }
  2997. };
  2998. static struct omap_hwmod_ocp_if am33xx_l4_ls__uart3 = {
  2999. .master = &am33xx_l4_ls_hwmod,
  3000. .slave = &am33xx_uart3_hwmod,
  3001. .clk = "l4ls_gclk",
  3002. .addr = am33xx_uart3_addr_space,
  3003. .user = OCP_USER_MPU,
  3004. };
  3005. /* l4 ls -> uart4 */
  3006. static struct omap_hwmod_addr_space am33xx_uart4_addr_space[] = {
  3007. {
  3008. .pa_start = 0x481A6000,
  3009. .pa_end = 0x481A6000 + SZ_8K - 1,
  3010. .flags = ADDR_TYPE_RT,
  3011. },
  3012. { }
  3013. };
  3014. static struct omap_hwmod_ocp_if am33xx_l4_ls__uart4 = {
  3015. .master = &am33xx_l4_ls_hwmod,
  3016. .slave = &am33xx_uart4_hwmod,
  3017. .clk = "l4ls_gclk",
  3018. .addr = am33xx_uart4_addr_space,
  3019. .user = OCP_USER_MPU,
  3020. };
  3021. /* l4 ls -> uart5 */
  3022. static struct omap_hwmod_addr_space am33xx_uart5_addr_space[] = {
  3023. {
  3024. .pa_start = 0x481A8000,
  3025. .pa_end = 0x481A8000 + SZ_8K - 1,
  3026. .flags = ADDR_TYPE_RT,
  3027. },
  3028. { }
  3029. };
  3030. static struct omap_hwmod_ocp_if am33xx_l4_ls__uart5 = {
  3031. .master = &am33xx_l4_ls_hwmod,
  3032. .slave = &am33xx_uart5_hwmod,
  3033. .clk = "l4ls_gclk",
  3034. .addr = am33xx_uart5_addr_space,
  3035. .user = OCP_USER_MPU,
  3036. };
  3037. /* l4 ls -> uart6 */
  3038. static struct omap_hwmod_addr_space am33xx_uart6_addr_space[] = {
  3039. {
  3040. .pa_start = 0x481aa000,
  3041. .pa_end = 0x481aa000 + SZ_8K - 1,
  3042. .flags = ADDR_TYPE_RT,
  3043. },
  3044. { }
  3045. };
  3046. static struct omap_hwmod_ocp_if am33xx_l4_ls__uart6 = {
  3047. .master = &am33xx_l4_ls_hwmod,
  3048. .slave = &am33xx_uart6_hwmod,
  3049. .clk = "l4ls_gclk",
  3050. .addr = am33xx_uart6_addr_space,
  3051. .user = OCP_USER_MPU,
  3052. };
  3053. /* l4 wkup -> wd_timer1 */
  3054. static struct omap_hwmod_addr_space am33xx_wd_timer1_addrs[] = {
  3055. {
  3056. .pa_start = 0x44e35000,
  3057. .pa_end = 0x44e35000 + SZ_4K - 1,
  3058. .flags = ADDR_TYPE_RT
  3059. },
  3060. { }
  3061. };
  3062. static struct omap_hwmod_ocp_if am33xx_l4_wkup__wd_timer1 = {
  3063. .master = &am33xx_l4_wkup_hwmod,
  3064. .slave = &am33xx_wd_timer1_hwmod,
  3065. .clk = "dpll_core_m4_div2_ck",
  3066. .addr = am33xx_wd_timer1_addrs,
  3067. .user = OCP_USER_MPU,
  3068. };
  3069. /* usbss */
  3070. /* l3 s -> USBSS interface */
  3071. static struct omap_hwmod_addr_space am33xx_usbss_addr_space[] = {
  3072. {
  3073. .name = "usbss",
  3074. .pa_start = 0x47400000,
  3075. .pa_end = 0x47400000 + SZ_4K - 1,
  3076. .flags = ADDR_TYPE_RT
  3077. },
  3078. {
  3079. .name = "musb0",
  3080. .pa_start = 0x47401000,
  3081. .pa_end = 0x47401000 + SZ_2K - 1,
  3082. .flags = ADDR_TYPE_RT
  3083. },
  3084. {
  3085. .name = "musb1",
  3086. .pa_start = 0x47401800,
  3087. .pa_end = 0x47401800 + SZ_2K - 1,
  3088. .flags = ADDR_TYPE_RT
  3089. },
  3090. { }
  3091. };
  3092. static struct omap_hwmod_ocp_if am33xx_l3_s__usbss = {
  3093. .master = &am33xx_l3_s_hwmod,
  3094. .slave = &am33xx_usbss_hwmod,
  3095. .clk = "l3s_gclk",
  3096. .addr = am33xx_usbss_addr_space,
  3097. .user = OCP_USER_MPU,
  3098. .flags = OCPIF_SWSUP_IDLE,
  3099. };
  3100. /* l3 main -> ocmc */
  3101. static struct omap_hwmod_ocp_if am33xx_l3_main__ocmc = {
  3102. .master = &am33xx_l3_main_hwmod,
  3103. .slave = &am33xx_ocmcram_hwmod,
  3104. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3105. };
  3106. /* l3 main -> sha0 HIB2 */
  3107. static struct omap_hwmod_addr_space am33xx_sha0_addrs[] = {
  3108. {
  3109. .pa_start = 0x53100000,
  3110. .pa_end = 0x53100000 + SZ_512 - 1,
  3111. .flags = ADDR_TYPE_RT
  3112. },
  3113. { }
  3114. };
  3115. static struct omap_hwmod_ocp_if am33xx_l3_main__sha0 = {
  3116. .master = &am33xx_l3_main_hwmod,
  3117. .slave = &am33xx_sha0_hwmod,
  3118. .clk = "sha0_fck",
  3119. .addr = am33xx_sha0_addrs,
  3120. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3121. };
  3122. /* l3 main -> AES0 HIB2 */
  3123. static struct omap_hwmod_addr_space am33xx_aes0_addrs[] = {
  3124. {
  3125. .pa_start = 0x53500000,
  3126. .pa_end = 0x53500000 + SZ_1M - 1,
  3127. .flags = ADDR_TYPE_RT
  3128. },
  3129. { }
  3130. };
  3131. static struct omap_hwmod_ocp_if am33xx_l3_main__aes0 = {
  3132. .master = &am33xx_l3_main_hwmod,
  3133. .slave = &am33xx_aes0_hwmod,
  3134. .clk = "aes0_fck",
  3135. .addr = am33xx_aes0_addrs,
  3136. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3137. };
  3138. static struct omap_hwmod_ocp_if *am33xx_hwmod_ocp_ifs[] __initdata = {
  3139. &am33xx_l4_fw__emif_fw,
  3140. &am33xx_l3_main__emif,
  3141. &am33xx_mpu__l3_main,
  3142. &am33xx_mpu__prcm,
  3143. &am33xx_l3_s__l4_ls,
  3144. &am33xx_l3_s__l4_wkup,
  3145. &am33xx_l3_s__l4_fw,
  3146. &am33xx_l3_main__l4_hs,
  3147. &am33xx_l3_main__l3_s,
  3148. &am33xx_l3_main__l3_instr,
  3149. &am33xx_l3_main__gfx,
  3150. &am33xx_l3_s__l3_main,
  3151. &am33xx_pruss__l3_main,
  3152. &am33xx_wkup_m3__l4_wkup,
  3153. &am33xx_gfx__l3_main,
  3154. &am33xx_l4_wkup__wkup_m3,
  3155. &am33xx_l4_wkup__control,
  3156. &am33xx_l4_wkup__smartreflex0,
  3157. &am33xx_l4_wkup__smartreflex1,
  3158. &am33xx_l4_wkup__uart1,
  3159. &am33xx_l4_wkup__timer1,
  3160. &am33xx_l4_wkup__rtc,
  3161. &am33xx_l4_wkup__i2c1,
  3162. &am33xx_l4_wkup__gpio0,
  3163. &am33xx_l4_wkup__adc_tsc,
  3164. &am33xx_l4_wkup__wd_timer1,
  3165. &am33xx_l4_hs__pruss,
  3166. &am33xx_l4_per__dcan0,
  3167. &am33xx_l4_per__dcan1,
  3168. &am33xx_l4_per__gpio1,
  3169. &am33xx_l4_per__gpio2,
  3170. &am33xx_l4_per__gpio3,
  3171. &am33xx_l4_per__i2c2,
  3172. &am33xx_l4_per__i2c3,
  3173. &am33xx_l4_per__mailbox,
  3174. &am33xx_l4_ls__mcasp0,
  3175. &am33xx_l3_s__mcasp0_data,
  3176. &am33xx_l4_ls__mcasp1,
  3177. &am33xx_l3_s__mcasp1_data,
  3178. &am33xx_l4_ls__mmc0,
  3179. &am33xx_l4_ls__mmc1,
  3180. &am33xx_l3_s__mmc2,
  3181. &am33xx_l4_ls__timer2,
  3182. &am33xx_l4_ls__timer3,
  3183. &am33xx_l4_ls__timer4,
  3184. &am33xx_l4_ls__timer5,
  3185. &am33xx_l4_ls__timer6,
  3186. &am33xx_l4_ls__timer7,
  3187. &am33xx_l3_main__tpcc,
  3188. &am33xx_l4_ls__uart2,
  3189. &am33xx_l4_ls__uart3,
  3190. &am33xx_l4_ls__uart4,
  3191. &am33xx_l4_ls__uart5,
  3192. &am33xx_l4_ls__uart6,
  3193. &am33xx_l4_ls__spinlock,
  3194. &am33xx_l4_ls__elm,
  3195. &am33xx_l4_ls__epwmss0,
  3196. &am33xx_epwmss0__ecap0,
  3197. &am33xx_epwmss0__eqep0,
  3198. &am33xx_epwmss0__ehrpwm0,
  3199. &am33xx_l4_ls__epwmss1,
  3200. &am33xx_epwmss1__ecap1,
  3201. &am33xx_epwmss1__eqep1,
  3202. &am33xx_epwmss1__ehrpwm1,
  3203. &am33xx_l4_ls__epwmss2,
  3204. &am33xx_epwmss2__ecap2,
  3205. &am33xx_epwmss2__eqep2,
  3206. &am33xx_epwmss2__ehrpwm2,
  3207. &am33xx_l3_s__gpmc,
  3208. &am33xx_l3_main__lcdc,
  3209. &am33xx_l4_ls__mcspi0,
  3210. &am33xx_l4_ls__mcspi1,
  3211. &am33xx_l3_main__tptc0,
  3212. &am33xx_l3_main__tptc1,
  3213. &am33xx_l3_main__tptc2,
  3214. &am33xx_l3_main__ocmc,
  3215. &am33xx_l3_s__usbss,
  3216. &am33xx_l4_hs__cpgmac0,
  3217. &am33xx_cpgmac0__mdio,
  3218. &am33xx_l3_main__sha0,
  3219. &am33xx_l3_main__aes0,
  3220. NULL,
  3221. };
  3222. int __init am33xx_hwmod_init(void)
  3223. {
  3224. omap_hwmod_init();
  3225. return omap_hwmod_register_links(am33xx_hwmod_ocp_ifs);
  3226. }