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