omap_hwmod_33xx_data.c 79 KB

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