omap_hwmod_33xx_data.c 80 KB

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