omap_hwmod_7xx_data.c 67 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724
  1. /*
  2. * Hardware modules present on the DRA7xx chips
  3. *
  4. * Copyright (C) 2013 Texas Instruments Incorporated - http://www.ti.com
  5. *
  6. * Paul Walmsley
  7. * Benoit Cousson
  8. *
  9. * This file is automatically generated from the OMAP hardware databases.
  10. * We respectfully ask that any modifications to this file be coordinated
  11. * with the public linux-omap@vger.kernel.org mailing list and the
  12. * authors above to ensure that the autogeneration scripts are kept
  13. * up-to-date with the file contents.
  14. *
  15. * This program is free software; you can redistribute it and/or modify
  16. * it under the terms of the GNU General Public License version 2 as
  17. * published by the Free Software Foundation.
  18. */
  19. #include <linux/io.h>
  20. #include <linux/platform_data/gpio-omap.h>
  21. #include <linux/power/smartreflex.h>
  22. #include <linux/i2c-omap.h>
  23. #include <linux/omap-dma.h>
  24. #include <linux/platform_data/spi-omap2-mcspi.h>
  25. #include <linux/platform_data/asoc-ti-mcbsp.h>
  26. #include <plat/dmtimer.h>
  27. #include "omap_hwmod.h"
  28. #include "omap_hwmod_common_data.h"
  29. #include "cm1_7xx.h"
  30. #include "cm2_7xx.h"
  31. #include "prm7xx.h"
  32. #include "i2c.h"
  33. #include "mmc.h"
  34. #include "wd_timer.h"
  35. /* Base offset for all DRA7XX interrupts external to MPUSS */
  36. #define DRA7XX_IRQ_GIC_START 32
  37. /* Base offset for all DRA7XX dma requests */
  38. #define DRA7XX_DMA_REQ_START 1
  39. /*
  40. * IP blocks
  41. */
  42. /*
  43. * 'l3' class
  44. * instance(s): l3_instr, l3_main_1, l3_main_2
  45. */
  46. static struct omap_hwmod_class dra7xx_l3_hwmod_class = {
  47. .name = "l3",
  48. };
  49. /* l3_instr */
  50. static struct omap_hwmod dra7xx_l3_instr_hwmod = {
  51. .name = "l3_instr",
  52. .class = &dra7xx_l3_hwmod_class,
  53. .clkdm_name = "l3instr_clkdm",
  54. .prcm = {
  55. .omap4 = {
  56. .clkctrl_offs = DRA7XX_CM_L3INSTR_L3_INSTR_CLKCTRL_OFFSET,
  57. .context_offs = DRA7XX_RM_L3INSTR_L3_INSTR_CONTEXT_OFFSET,
  58. .modulemode = MODULEMODE_HWCTRL,
  59. },
  60. },
  61. };
  62. /* l3_main_1 */
  63. static struct omap_hwmod dra7xx_l3_main_1_hwmod = {
  64. .name = "l3_main_1",
  65. .class = &dra7xx_l3_hwmod_class,
  66. .clkdm_name = "l3main1_clkdm",
  67. .prcm = {
  68. .omap4 = {
  69. .clkctrl_offs = DRA7XX_CM_L3MAIN1_L3_MAIN_1_CLKCTRL_OFFSET,
  70. .context_offs = DRA7XX_RM_L3MAIN1_L3_MAIN_1_CONTEXT_OFFSET,
  71. },
  72. },
  73. };
  74. /* l3_main_2 */
  75. static struct omap_hwmod dra7xx_l3_main_2_hwmod = {
  76. .name = "l3_main_2",
  77. .class = &dra7xx_l3_hwmod_class,
  78. .clkdm_name = "l3instr_clkdm",
  79. .prcm = {
  80. .omap4 = {
  81. .clkctrl_offs = DRA7XX_CM_L3INSTR_L3_MAIN_2_CLKCTRL_OFFSET,
  82. .context_offs = DRA7XX_RM_L3INSTR_L3_MAIN_2_CONTEXT_OFFSET,
  83. .modulemode = MODULEMODE_HWCTRL,
  84. },
  85. },
  86. };
  87. /*
  88. * 'l4' class
  89. * instance(s): l4_cfg, l4_per1, l4_per2, l4_per3, l4_wkup
  90. */
  91. static struct omap_hwmod_class dra7xx_l4_hwmod_class = {
  92. .name = "l4",
  93. };
  94. /* l4_cfg */
  95. static struct omap_hwmod dra7xx_l4_cfg_hwmod = {
  96. .name = "l4_cfg",
  97. .class = &dra7xx_l4_hwmod_class,
  98. .clkdm_name = "l4cfg_clkdm",
  99. .prcm = {
  100. .omap4 = {
  101. .clkctrl_offs = DRA7XX_CM_L4CFG_L4_CFG_CLKCTRL_OFFSET,
  102. .context_offs = DRA7XX_RM_L4CFG_L4_CFG_CONTEXT_OFFSET,
  103. },
  104. },
  105. };
  106. /* l4_per1 */
  107. static struct omap_hwmod dra7xx_l4_per1_hwmod = {
  108. .name = "l4_per1",
  109. .class = &dra7xx_l4_hwmod_class,
  110. .clkdm_name = "l4per_clkdm",
  111. .prcm = {
  112. .omap4 = {
  113. .clkctrl_offs = DRA7XX_CM_L4PER_L4_PER1_CLKCTRL_OFFSET,
  114. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  115. },
  116. },
  117. };
  118. /* l4_per2 */
  119. static struct omap_hwmod dra7xx_l4_per2_hwmod = {
  120. .name = "l4_per2",
  121. .class = &dra7xx_l4_hwmod_class,
  122. .clkdm_name = "l4per2_clkdm",
  123. .prcm = {
  124. .omap4 = {
  125. .clkctrl_offs = DRA7XX_CM_L4PER2_L4_PER2_CLKCTRL_OFFSET,
  126. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  127. },
  128. },
  129. };
  130. /* l4_per3 */
  131. static struct omap_hwmod dra7xx_l4_per3_hwmod = {
  132. .name = "l4_per3",
  133. .class = &dra7xx_l4_hwmod_class,
  134. .clkdm_name = "l4per3_clkdm",
  135. .prcm = {
  136. .omap4 = {
  137. .clkctrl_offs = DRA7XX_CM_L4PER3_L4_PER3_CLKCTRL_OFFSET,
  138. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  139. },
  140. },
  141. };
  142. /* l4_wkup */
  143. static struct omap_hwmod dra7xx_l4_wkup_hwmod = {
  144. .name = "l4_wkup",
  145. .class = &dra7xx_l4_hwmod_class,
  146. .clkdm_name = "wkupaon_clkdm",
  147. .prcm = {
  148. .omap4 = {
  149. .clkctrl_offs = DRA7XX_CM_WKUPAON_L4_WKUP_CLKCTRL_OFFSET,
  150. .context_offs = DRA7XX_RM_WKUPAON_L4_WKUP_CONTEXT_OFFSET,
  151. },
  152. },
  153. };
  154. /*
  155. * 'atl' class
  156. *
  157. */
  158. static struct omap_hwmod_class dra7xx_atl_hwmod_class = {
  159. .name = "atl",
  160. };
  161. /* atl */
  162. static struct omap_hwmod dra7xx_atl_hwmod = {
  163. .name = "atl",
  164. .class = &dra7xx_atl_hwmod_class,
  165. .clkdm_name = "atl_clkdm",
  166. .main_clk = "atl_gfclk_mux",
  167. .prcm = {
  168. .omap4 = {
  169. .clkctrl_offs = DRA7XX_CM_ATL_ATL_CLKCTRL_OFFSET,
  170. .context_offs = DRA7XX_RM_ATL_ATL_CONTEXT_OFFSET,
  171. .modulemode = MODULEMODE_SWCTRL,
  172. },
  173. },
  174. };
  175. /*
  176. * 'bb2d' class
  177. *
  178. */
  179. static struct omap_hwmod_class dra7xx_bb2d_hwmod_class = {
  180. .name = "bb2d",
  181. };
  182. /* bb2d */
  183. static struct omap_hwmod dra7xx_bb2d_hwmod = {
  184. .name = "bb2d",
  185. .class = &dra7xx_bb2d_hwmod_class,
  186. .clkdm_name = "dss_clkdm",
  187. .main_clk = "dpll_core_h24x2_ck",
  188. .prcm = {
  189. .omap4 = {
  190. .clkctrl_offs = DRA7XX_CM_DSS_BB2D_CLKCTRL_OFFSET,
  191. .context_offs = DRA7XX_RM_DSS_BB2D_CONTEXT_OFFSET,
  192. .modulemode = MODULEMODE_SWCTRL,
  193. },
  194. },
  195. };
  196. /*
  197. * 'counter' class
  198. *
  199. */
  200. static struct omap_hwmod_class_sysconfig dra7xx_counter_sysc = {
  201. .rev_offs = 0x0000,
  202. .sysc_offs = 0x0010,
  203. .sysc_flags = SYSC_HAS_SIDLEMODE,
  204. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  205. SIDLE_SMART_WKUP),
  206. .sysc_fields = &omap_hwmod_sysc_type1,
  207. };
  208. static struct omap_hwmod_class dra7xx_counter_hwmod_class = {
  209. .name = "counter",
  210. .sysc = &dra7xx_counter_sysc,
  211. };
  212. /* counter_32k */
  213. static struct omap_hwmod dra7xx_counter_32k_hwmod = {
  214. .name = "counter_32k",
  215. .class = &dra7xx_counter_hwmod_class,
  216. .clkdm_name = "wkupaon_clkdm",
  217. .flags = HWMOD_SWSUP_SIDLE,
  218. .main_clk = "wkupaon_iclk_mux",
  219. .prcm = {
  220. .omap4 = {
  221. .clkctrl_offs = DRA7XX_CM_WKUPAON_COUNTER_32K_CLKCTRL_OFFSET,
  222. .context_offs = DRA7XX_RM_WKUPAON_COUNTER_32K_CONTEXT_OFFSET,
  223. },
  224. },
  225. };
  226. /*
  227. * 'ctrl_module' class
  228. *
  229. */
  230. static struct omap_hwmod_class dra7xx_ctrl_module_hwmod_class = {
  231. .name = "ctrl_module",
  232. };
  233. /* ctrl_module_wkup */
  234. static struct omap_hwmod dra7xx_ctrl_module_wkup_hwmod = {
  235. .name = "ctrl_module_wkup",
  236. .class = &dra7xx_ctrl_module_hwmod_class,
  237. .clkdm_name = "wkupaon_clkdm",
  238. .prcm = {
  239. .omap4 = {
  240. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  241. },
  242. },
  243. };
  244. /*
  245. * 'dcan' class
  246. *
  247. */
  248. static struct omap_hwmod_class dra7xx_dcan_hwmod_class = {
  249. .name = "dcan",
  250. };
  251. /* dcan1 */
  252. static struct omap_hwmod dra7xx_dcan1_hwmod = {
  253. .name = "dcan1",
  254. .class = &dra7xx_dcan_hwmod_class,
  255. .clkdm_name = "wkupaon_clkdm",
  256. .main_clk = "dcan1_sys_clk_mux",
  257. .prcm = {
  258. .omap4 = {
  259. .clkctrl_offs = DRA7XX_CM_WKUPAON_DCAN1_CLKCTRL_OFFSET,
  260. .context_offs = DRA7XX_RM_WKUPAON_DCAN1_CONTEXT_OFFSET,
  261. .modulemode = MODULEMODE_SWCTRL,
  262. },
  263. },
  264. };
  265. /* dcan2 */
  266. static struct omap_hwmod dra7xx_dcan2_hwmod = {
  267. .name = "dcan2",
  268. .class = &dra7xx_dcan_hwmod_class,
  269. .clkdm_name = "l4per2_clkdm",
  270. .main_clk = "sys_clkin1",
  271. .prcm = {
  272. .omap4 = {
  273. .clkctrl_offs = DRA7XX_CM_L4PER2_DCAN2_CLKCTRL_OFFSET,
  274. .context_offs = DRA7XX_RM_L4PER2_DCAN2_CONTEXT_OFFSET,
  275. .modulemode = MODULEMODE_SWCTRL,
  276. },
  277. },
  278. };
  279. /*
  280. * 'dma' class
  281. *
  282. */
  283. static struct omap_hwmod_class_sysconfig dra7xx_dma_sysc = {
  284. .rev_offs = 0x0000,
  285. .sysc_offs = 0x002c,
  286. .syss_offs = 0x0028,
  287. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  288. SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
  289. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  290. SYSS_HAS_RESET_STATUS),
  291. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  292. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  293. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  294. .sysc_fields = &omap_hwmod_sysc_type1,
  295. };
  296. static struct omap_hwmod_class dra7xx_dma_hwmod_class = {
  297. .name = "dma",
  298. .sysc = &dra7xx_dma_sysc,
  299. };
  300. /* dma dev_attr */
  301. static struct omap_dma_dev_attr dma_dev_attr = {
  302. .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY |
  303. IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY,
  304. .lch_count = 32,
  305. };
  306. /* dma_system */
  307. static struct omap_hwmod_irq_info dra7xx_dma_system_irqs[] = {
  308. { .name = "0", .irq = 12 + DRA7XX_IRQ_GIC_START },
  309. { .name = "1", .irq = 13 + DRA7XX_IRQ_GIC_START },
  310. { .name = "2", .irq = 14 + DRA7XX_IRQ_GIC_START },
  311. { .name = "3", .irq = 15 + DRA7XX_IRQ_GIC_START },
  312. { .irq = -1 }
  313. };
  314. static struct omap_hwmod dra7xx_dma_system_hwmod = {
  315. .name = "dma_system",
  316. .class = &dra7xx_dma_hwmod_class,
  317. .clkdm_name = "dma_clkdm",
  318. .mpu_irqs = dra7xx_dma_system_irqs,
  319. .main_clk = "l3_iclk_div",
  320. .prcm = {
  321. .omap4 = {
  322. .clkctrl_offs = DRA7XX_CM_DMA_DMA_SYSTEM_CLKCTRL_OFFSET,
  323. .context_offs = DRA7XX_RM_DMA_DMA_SYSTEM_CONTEXT_OFFSET,
  324. },
  325. },
  326. .dev_attr = &dma_dev_attr,
  327. };
  328. /*
  329. * 'dss' class
  330. *
  331. */
  332. static struct omap_hwmod_class_sysconfig dra7xx_dss_sysc = {
  333. .rev_offs = 0x0000,
  334. .syss_offs = 0x0014,
  335. .sysc_flags = SYSS_HAS_RESET_STATUS,
  336. };
  337. static struct omap_hwmod_class dra7xx_dss_hwmod_class = {
  338. .name = "dss",
  339. .sysc = &dra7xx_dss_sysc,
  340. .reset = omap_dss_reset,
  341. };
  342. /* dss */
  343. static struct omap_hwmod_dma_info dra7xx_dss_sdma_reqs[] = {
  344. { .dma_req = 75 + DRA7XX_DMA_REQ_START },
  345. { .dma_req = -1 }
  346. };
  347. static struct omap_hwmod_opt_clk dss_opt_clks[] = {
  348. { .role = "dss_clk", .clk = "dss_dss_clk" },
  349. { .role = "hdmi_phy_clk", .clk = "dss_48mhz_clk" },
  350. { .role = "32khz_clk", .clk = "dss_32khz_clk" },
  351. { .role = "video2_clk", .clk = "dss_video2_clk" },
  352. { .role = "video1_clk", .clk = "dss_video1_clk" },
  353. { .role = "hdmi_clk", .clk = "dss_hdmi_clk" },
  354. };
  355. static struct omap_hwmod dra7xx_dss_hwmod = {
  356. .name = "dss_core",
  357. .class = &dra7xx_dss_hwmod_class,
  358. .clkdm_name = "dss_clkdm",
  359. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  360. .sdma_reqs = dra7xx_dss_sdma_reqs,
  361. .main_clk = "dss_dss_clk",
  362. .prcm = {
  363. .omap4 = {
  364. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  365. .context_offs = DRA7XX_RM_DSS_DSS_CONTEXT_OFFSET,
  366. .modulemode = MODULEMODE_SWCTRL,
  367. },
  368. },
  369. .opt_clks = dss_opt_clks,
  370. .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
  371. };
  372. /*
  373. * 'dispc' class
  374. * display controller
  375. */
  376. static struct omap_hwmod_class_sysconfig dra7xx_dispc_sysc = {
  377. .rev_offs = 0x0000,
  378. .sysc_offs = 0x0010,
  379. .syss_offs = 0x0014,
  380. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  381. SYSC_HAS_ENAWAKEUP | SYSC_HAS_MIDLEMODE |
  382. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  383. SYSS_HAS_RESET_STATUS),
  384. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  385. MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
  386. .sysc_fields = &omap_hwmod_sysc_type1,
  387. };
  388. static struct omap_hwmod_class dra7xx_dispc_hwmod_class = {
  389. .name = "dispc",
  390. .sysc = &dra7xx_dispc_sysc,
  391. };
  392. /* dss_dispc */
  393. /* dss_dispc dev_attr */
  394. static struct omap_dss_dispc_dev_attr dss_dispc_dev_attr = {
  395. .has_framedonetv_irq = 1,
  396. .manager_count = 4,
  397. };
  398. static struct omap_hwmod dra7xx_dss_dispc_hwmod = {
  399. .name = "dss_dispc",
  400. .class = &dra7xx_dispc_hwmod_class,
  401. .clkdm_name = "dss_clkdm",
  402. .main_clk = "dss_dss_clk",
  403. .prcm = {
  404. .omap4 = {
  405. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  406. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  407. },
  408. },
  409. .dev_attr = &dss_dispc_dev_attr,
  410. };
  411. /*
  412. * 'hdmi' class
  413. * hdmi controller
  414. */
  415. static struct omap_hwmod_class_sysconfig dra7xx_hdmi_sysc = {
  416. .rev_offs = 0x0000,
  417. .sysc_offs = 0x0010,
  418. .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  419. SYSC_HAS_SOFTRESET),
  420. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  421. SIDLE_SMART_WKUP),
  422. .sysc_fields = &omap_hwmod_sysc_type2,
  423. };
  424. static struct omap_hwmod_class dra7xx_hdmi_hwmod_class = {
  425. .name = "hdmi",
  426. .sysc = &dra7xx_hdmi_sysc,
  427. };
  428. /* dss_hdmi */
  429. static struct omap_hwmod_opt_clk dss_hdmi_opt_clks[] = {
  430. { .role = "sys_clk", .clk = "dss_hdmi_clk" },
  431. };
  432. static struct omap_hwmod dra7xx_dss_hdmi_hwmod = {
  433. .name = "dss_hdmi",
  434. .class = &dra7xx_hdmi_hwmod_class,
  435. .clkdm_name = "dss_clkdm",
  436. .main_clk = "dss_48mhz_clk",
  437. .prcm = {
  438. .omap4 = {
  439. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  440. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  441. },
  442. },
  443. .opt_clks = dss_hdmi_opt_clks,
  444. .opt_clks_cnt = ARRAY_SIZE(dss_hdmi_opt_clks),
  445. };
  446. /*
  447. * 'elm' class
  448. *
  449. */
  450. static struct omap_hwmod_class_sysconfig dra7xx_elm_sysc = {
  451. .rev_offs = 0x0000,
  452. .sysc_offs = 0x0010,
  453. .syss_offs = 0x0014,
  454. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  455. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  456. SYSS_HAS_RESET_STATUS),
  457. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  458. SIDLE_SMART_WKUP),
  459. .sysc_fields = &omap_hwmod_sysc_type1,
  460. };
  461. static struct omap_hwmod_class dra7xx_elm_hwmod_class = {
  462. .name = "elm",
  463. .sysc = &dra7xx_elm_sysc,
  464. };
  465. /* elm */
  466. static struct omap_hwmod dra7xx_elm_hwmod = {
  467. .name = "elm",
  468. .class = &dra7xx_elm_hwmod_class,
  469. .clkdm_name = "l4per_clkdm",
  470. .main_clk = "l3_iclk_div",
  471. .prcm = {
  472. .omap4 = {
  473. .clkctrl_offs = DRA7XX_CM_L4PER_ELM_CLKCTRL_OFFSET,
  474. .context_offs = DRA7XX_RM_L4PER_ELM_CONTEXT_OFFSET,
  475. },
  476. },
  477. };
  478. /*
  479. * 'gpio' class
  480. *
  481. */
  482. static struct omap_hwmod_class_sysconfig dra7xx_gpio_sysc = {
  483. .rev_offs = 0x0000,
  484. .sysc_offs = 0x0010,
  485. .syss_offs = 0x0114,
  486. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  487. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  488. SYSS_HAS_RESET_STATUS),
  489. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  490. SIDLE_SMART_WKUP),
  491. .sysc_fields = &omap_hwmod_sysc_type1,
  492. };
  493. static struct omap_hwmod_class dra7xx_gpio_hwmod_class = {
  494. .name = "gpio",
  495. .sysc = &dra7xx_gpio_sysc,
  496. .rev = 2,
  497. };
  498. /* gpio dev_attr */
  499. static struct omap_gpio_dev_attr gpio_dev_attr = {
  500. .bank_width = 32,
  501. .dbck_flag = true,
  502. };
  503. /* gpio1 */
  504. static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
  505. { .role = "dbclk", .clk = "gpio1_dbclk" },
  506. };
  507. static struct omap_hwmod dra7xx_gpio1_hwmod = {
  508. .name = "gpio1",
  509. .class = &dra7xx_gpio_hwmod_class,
  510. .clkdm_name = "wkupaon_clkdm",
  511. .main_clk = "wkupaon_iclk_mux",
  512. .prcm = {
  513. .omap4 = {
  514. .clkctrl_offs = DRA7XX_CM_WKUPAON_GPIO1_CLKCTRL_OFFSET,
  515. .context_offs = DRA7XX_RM_WKUPAON_GPIO1_CONTEXT_OFFSET,
  516. .modulemode = MODULEMODE_HWCTRL,
  517. },
  518. },
  519. .opt_clks = gpio1_opt_clks,
  520. .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
  521. .dev_attr = &gpio_dev_attr,
  522. };
  523. /* gpio2 */
  524. static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
  525. { .role = "dbclk", .clk = "gpio2_dbclk" },
  526. };
  527. static struct omap_hwmod dra7xx_gpio2_hwmod = {
  528. .name = "gpio2",
  529. .class = &dra7xx_gpio_hwmod_class,
  530. .clkdm_name = "l4per_clkdm",
  531. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  532. .main_clk = "l3_iclk_div",
  533. .prcm = {
  534. .omap4 = {
  535. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO2_CLKCTRL_OFFSET,
  536. .context_offs = DRA7XX_RM_L4PER_GPIO2_CONTEXT_OFFSET,
  537. .modulemode = MODULEMODE_HWCTRL,
  538. },
  539. },
  540. .opt_clks = gpio2_opt_clks,
  541. .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
  542. .dev_attr = &gpio_dev_attr,
  543. };
  544. /* gpio3 */
  545. static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
  546. { .role = "dbclk", .clk = "gpio3_dbclk" },
  547. };
  548. static struct omap_hwmod dra7xx_gpio3_hwmod = {
  549. .name = "gpio3",
  550. .class = &dra7xx_gpio_hwmod_class,
  551. .clkdm_name = "l4per_clkdm",
  552. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  553. .main_clk = "l3_iclk_div",
  554. .prcm = {
  555. .omap4 = {
  556. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO3_CLKCTRL_OFFSET,
  557. .context_offs = DRA7XX_RM_L4PER_GPIO3_CONTEXT_OFFSET,
  558. .modulemode = MODULEMODE_HWCTRL,
  559. },
  560. },
  561. .opt_clks = gpio3_opt_clks,
  562. .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
  563. .dev_attr = &gpio_dev_attr,
  564. };
  565. /* gpio4 */
  566. static struct omap_hwmod_opt_clk gpio4_opt_clks[] = {
  567. { .role = "dbclk", .clk = "gpio4_dbclk" },
  568. };
  569. static struct omap_hwmod dra7xx_gpio4_hwmod = {
  570. .name = "gpio4",
  571. .class = &dra7xx_gpio_hwmod_class,
  572. .clkdm_name = "l4per_clkdm",
  573. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  574. .main_clk = "l3_iclk_div",
  575. .prcm = {
  576. .omap4 = {
  577. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO4_CLKCTRL_OFFSET,
  578. .context_offs = DRA7XX_RM_L4PER_GPIO4_CONTEXT_OFFSET,
  579. .modulemode = MODULEMODE_HWCTRL,
  580. },
  581. },
  582. .opt_clks = gpio4_opt_clks,
  583. .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks),
  584. .dev_attr = &gpio_dev_attr,
  585. };
  586. /* gpio5 */
  587. static struct omap_hwmod_opt_clk gpio5_opt_clks[] = {
  588. { .role = "dbclk", .clk = "gpio5_dbclk" },
  589. };
  590. static struct omap_hwmod dra7xx_gpio5_hwmod = {
  591. .name = "gpio5",
  592. .class = &dra7xx_gpio_hwmod_class,
  593. .clkdm_name = "l4per_clkdm",
  594. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  595. .main_clk = "l3_iclk_div",
  596. .prcm = {
  597. .omap4 = {
  598. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO5_CLKCTRL_OFFSET,
  599. .context_offs = DRA7XX_RM_L4PER_GPIO5_CONTEXT_OFFSET,
  600. .modulemode = MODULEMODE_HWCTRL,
  601. },
  602. },
  603. .opt_clks = gpio5_opt_clks,
  604. .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks),
  605. .dev_attr = &gpio_dev_attr,
  606. };
  607. /* gpio6 */
  608. static struct omap_hwmod_opt_clk gpio6_opt_clks[] = {
  609. { .role = "dbclk", .clk = "gpio6_dbclk" },
  610. };
  611. static struct omap_hwmod dra7xx_gpio6_hwmod = {
  612. .name = "gpio6",
  613. .class = &dra7xx_gpio_hwmod_class,
  614. .clkdm_name = "l4per_clkdm",
  615. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  616. .main_clk = "l3_iclk_div",
  617. .prcm = {
  618. .omap4 = {
  619. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO6_CLKCTRL_OFFSET,
  620. .context_offs = DRA7XX_RM_L4PER_GPIO6_CONTEXT_OFFSET,
  621. .modulemode = MODULEMODE_HWCTRL,
  622. },
  623. },
  624. .opt_clks = gpio6_opt_clks,
  625. .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks),
  626. .dev_attr = &gpio_dev_attr,
  627. };
  628. /* gpio7 */
  629. static struct omap_hwmod_opt_clk gpio7_opt_clks[] = {
  630. { .role = "dbclk", .clk = "gpio7_dbclk" },
  631. };
  632. static struct omap_hwmod dra7xx_gpio7_hwmod = {
  633. .name = "gpio7",
  634. .class = &dra7xx_gpio_hwmod_class,
  635. .clkdm_name = "l4per_clkdm",
  636. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  637. .main_clk = "l3_iclk_div",
  638. .prcm = {
  639. .omap4 = {
  640. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO7_CLKCTRL_OFFSET,
  641. .context_offs = DRA7XX_RM_L4PER_GPIO7_CONTEXT_OFFSET,
  642. .modulemode = MODULEMODE_HWCTRL,
  643. },
  644. },
  645. .opt_clks = gpio7_opt_clks,
  646. .opt_clks_cnt = ARRAY_SIZE(gpio7_opt_clks),
  647. .dev_attr = &gpio_dev_attr,
  648. };
  649. /* gpio8 */
  650. static struct omap_hwmod_opt_clk gpio8_opt_clks[] = {
  651. { .role = "dbclk", .clk = "gpio8_dbclk" },
  652. };
  653. static struct omap_hwmod dra7xx_gpio8_hwmod = {
  654. .name = "gpio8",
  655. .class = &dra7xx_gpio_hwmod_class,
  656. .clkdm_name = "l4per_clkdm",
  657. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  658. .main_clk = "l3_iclk_div",
  659. .prcm = {
  660. .omap4 = {
  661. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO8_CLKCTRL_OFFSET,
  662. .context_offs = DRA7XX_RM_L4PER_GPIO8_CONTEXT_OFFSET,
  663. .modulemode = MODULEMODE_HWCTRL,
  664. },
  665. },
  666. .opt_clks = gpio8_opt_clks,
  667. .opt_clks_cnt = ARRAY_SIZE(gpio8_opt_clks),
  668. .dev_attr = &gpio_dev_attr,
  669. };
  670. /*
  671. * 'gpmc' class
  672. *
  673. */
  674. static struct omap_hwmod_class_sysconfig dra7xx_gpmc_sysc = {
  675. .rev_offs = 0x0000,
  676. .sysc_offs = 0x0010,
  677. .syss_offs = 0x0014,
  678. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
  679. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  680. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  681. SIDLE_SMART_WKUP),
  682. .sysc_fields = &omap_hwmod_sysc_type1,
  683. };
  684. static struct omap_hwmod_class dra7xx_gpmc_hwmod_class = {
  685. .name = "gpmc",
  686. .sysc = &dra7xx_gpmc_sysc,
  687. };
  688. /* gpmc */
  689. static struct omap_hwmod dra7xx_gpmc_hwmod = {
  690. .name = "gpmc",
  691. .class = &dra7xx_gpmc_hwmod_class,
  692. .clkdm_name = "l3main1_clkdm",
  693. .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
  694. .main_clk = "l3_iclk_div",
  695. .prcm = {
  696. .omap4 = {
  697. .clkctrl_offs = DRA7XX_CM_L3MAIN1_GPMC_CLKCTRL_OFFSET,
  698. .context_offs = DRA7XX_RM_L3MAIN1_GPMC_CONTEXT_OFFSET,
  699. .modulemode = MODULEMODE_HWCTRL,
  700. },
  701. },
  702. };
  703. /*
  704. * 'hdq1w' class
  705. *
  706. */
  707. static struct omap_hwmod_class_sysconfig dra7xx_hdq1w_sysc = {
  708. .rev_offs = 0x0000,
  709. .sysc_offs = 0x0014,
  710. .syss_offs = 0x0018,
  711. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SOFTRESET |
  712. SYSS_HAS_RESET_STATUS),
  713. .sysc_fields = &omap_hwmod_sysc_type1,
  714. };
  715. static struct omap_hwmod_class dra7xx_hdq1w_hwmod_class = {
  716. .name = "hdq1w",
  717. .sysc = &dra7xx_hdq1w_sysc,
  718. };
  719. /* hdq1w */
  720. static struct omap_hwmod dra7xx_hdq1w_hwmod = {
  721. .name = "hdq1w",
  722. .class = &dra7xx_hdq1w_hwmod_class,
  723. .clkdm_name = "l4per_clkdm",
  724. .flags = HWMOD_INIT_NO_RESET,
  725. .main_clk = "func_12m_fclk",
  726. .prcm = {
  727. .omap4 = {
  728. .clkctrl_offs = DRA7XX_CM_L4PER_HDQ1W_CLKCTRL_OFFSET,
  729. .context_offs = DRA7XX_RM_L4PER_HDQ1W_CONTEXT_OFFSET,
  730. .modulemode = MODULEMODE_SWCTRL,
  731. },
  732. },
  733. };
  734. /*
  735. * 'i2c' class
  736. *
  737. */
  738. static struct omap_hwmod_class_sysconfig dra7xx_i2c_sysc = {
  739. .sysc_offs = 0x0010,
  740. .syss_offs = 0x0090,
  741. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  742. SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
  743. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  744. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  745. SIDLE_SMART_WKUP),
  746. .clockact = CLOCKACT_TEST_ICLK,
  747. .sysc_fields = &omap_hwmod_sysc_type1,
  748. };
  749. static struct omap_hwmod_class dra7xx_i2c_hwmod_class = {
  750. .name = "i2c",
  751. .sysc = &dra7xx_i2c_sysc,
  752. .reset = &omap_i2c_reset,
  753. .rev = OMAP_I2C_IP_VERSION_2,
  754. };
  755. /* i2c dev_attr */
  756. static struct omap_i2c_dev_attr i2c_dev_attr = {
  757. .flags = OMAP_I2C_FLAG_BUS_SHIFT_NONE,
  758. };
  759. /* i2c1 */
  760. static struct omap_hwmod dra7xx_i2c1_hwmod = {
  761. .name = "i2c1",
  762. .class = &dra7xx_i2c_hwmod_class,
  763. .clkdm_name = "l4per_clkdm",
  764. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  765. .main_clk = "func_96m_fclk",
  766. .prcm = {
  767. .omap4 = {
  768. .clkctrl_offs = DRA7XX_CM_L4PER_I2C1_CLKCTRL_OFFSET,
  769. .context_offs = DRA7XX_RM_L4PER_I2C1_CONTEXT_OFFSET,
  770. .modulemode = MODULEMODE_SWCTRL,
  771. },
  772. },
  773. .dev_attr = &i2c_dev_attr,
  774. };
  775. /* i2c2 */
  776. static struct omap_hwmod dra7xx_i2c2_hwmod = {
  777. .name = "i2c2",
  778. .class = &dra7xx_i2c_hwmod_class,
  779. .clkdm_name = "l4per_clkdm",
  780. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  781. .main_clk = "func_96m_fclk",
  782. .prcm = {
  783. .omap4 = {
  784. .clkctrl_offs = DRA7XX_CM_L4PER_I2C2_CLKCTRL_OFFSET,
  785. .context_offs = DRA7XX_RM_L4PER_I2C2_CONTEXT_OFFSET,
  786. .modulemode = MODULEMODE_SWCTRL,
  787. },
  788. },
  789. .dev_attr = &i2c_dev_attr,
  790. };
  791. /* i2c3 */
  792. static struct omap_hwmod dra7xx_i2c3_hwmod = {
  793. .name = "i2c3",
  794. .class = &dra7xx_i2c_hwmod_class,
  795. .clkdm_name = "l4per_clkdm",
  796. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  797. .main_clk = "func_96m_fclk",
  798. .prcm = {
  799. .omap4 = {
  800. .clkctrl_offs = DRA7XX_CM_L4PER_I2C3_CLKCTRL_OFFSET,
  801. .context_offs = DRA7XX_RM_L4PER_I2C3_CONTEXT_OFFSET,
  802. .modulemode = MODULEMODE_SWCTRL,
  803. },
  804. },
  805. .dev_attr = &i2c_dev_attr,
  806. };
  807. /* i2c4 */
  808. static struct omap_hwmod dra7xx_i2c4_hwmod = {
  809. .name = "i2c4",
  810. .class = &dra7xx_i2c_hwmod_class,
  811. .clkdm_name = "l4per_clkdm",
  812. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  813. .main_clk = "func_96m_fclk",
  814. .prcm = {
  815. .omap4 = {
  816. .clkctrl_offs = DRA7XX_CM_L4PER_I2C4_CLKCTRL_OFFSET,
  817. .context_offs = DRA7XX_RM_L4PER_I2C4_CONTEXT_OFFSET,
  818. .modulemode = MODULEMODE_SWCTRL,
  819. },
  820. },
  821. .dev_attr = &i2c_dev_attr,
  822. };
  823. /* i2c5 */
  824. static struct omap_hwmod dra7xx_i2c5_hwmod = {
  825. .name = "i2c5",
  826. .class = &dra7xx_i2c_hwmod_class,
  827. .clkdm_name = "ipu_clkdm",
  828. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  829. .main_clk = "func_96m_fclk",
  830. .prcm = {
  831. .omap4 = {
  832. .clkctrl_offs = DRA7XX_CM_IPU_I2C5_CLKCTRL_OFFSET,
  833. .context_offs = DRA7XX_RM_IPU_I2C5_CONTEXT_OFFSET,
  834. .modulemode = MODULEMODE_SWCTRL,
  835. },
  836. },
  837. .dev_attr = &i2c_dev_attr,
  838. };
  839. /*
  840. * 'mcspi' class
  841. *
  842. */
  843. static struct omap_hwmod_class_sysconfig dra7xx_mcspi_sysc = {
  844. .rev_offs = 0x0000,
  845. .sysc_offs = 0x0010,
  846. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  847. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  848. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  849. SIDLE_SMART_WKUP),
  850. .sysc_fields = &omap_hwmod_sysc_type2,
  851. };
  852. static struct omap_hwmod_class dra7xx_mcspi_hwmod_class = {
  853. .name = "mcspi",
  854. .sysc = &dra7xx_mcspi_sysc,
  855. .rev = OMAP4_MCSPI_REV,
  856. };
  857. /* mcspi1 */
  858. /* mcspi1 dev_attr */
  859. static struct omap2_mcspi_dev_attr mcspi1_dev_attr = {
  860. .num_chipselect = 4,
  861. };
  862. static struct omap_hwmod dra7xx_mcspi1_hwmod = {
  863. .name = "mcspi1",
  864. .class = &dra7xx_mcspi_hwmod_class,
  865. .clkdm_name = "l4per_clkdm",
  866. .main_clk = "func_48m_fclk",
  867. .prcm = {
  868. .omap4 = {
  869. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI1_CLKCTRL_OFFSET,
  870. .context_offs = DRA7XX_RM_L4PER_MCSPI1_CONTEXT_OFFSET,
  871. .modulemode = MODULEMODE_SWCTRL,
  872. },
  873. },
  874. .dev_attr = &mcspi1_dev_attr,
  875. };
  876. /* mcspi2 */
  877. /* mcspi2 dev_attr */
  878. static struct omap2_mcspi_dev_attr mcspi2_dev_attr = {
  879. .num_chipselect = 2,
  880. };
  881. static struct omap_hwmod dra7xx_mcspi2_hwmod = {
  882. .name = "mcspi2",
  883. .class = &dra7xx_mcspi_hwmod_class,
  884. .clkdm_name = "l4per_clkdm",
  885. .main_clk = "func_48m_fclk",
  886. .prcm = {
  887. .omap4 = {
  888. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI2_CLKCTRL_OFFSET,
  889. .context_offs = DRA7XX_RM_L4PER_MCSPI2_CONTEXT_OFFSET,
  890. .modulemode = MODULEMODE_SWCTRL,
  891. },
  892. },
  893. .dev_attr = &mcspi2_dev_attr,
  894. };
  895. /* mcspi3 */
  896. /* mcspi3 dev_attr */
  897. static struct omap2_mcspi_dev_attr mcspi3_dev_attr = {
  898. .num_chipselect = 2,
  899. };
  900. static struct omap_hwmod dra7xx_mcspi3_hwmod = {
  901. .name = "mcspi3",
  902. .class = &dra7xx_mcspi_hwmod_class,
  903. .clkdm_name = "l4per_clkdm",
  904. .main_clk = "func_48m_fclk",
  905. .prcm = {
  906. .omap4 = {
  907. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI3_CLKCTRL_OFFSET,
  908. .context_offs = DRA7XX_RM_L4PER_MCSPI3_CONTEXT_OFFSET,
  909. .modulemode = MODULEMODE_SWCTRL,
  910. },
  911. },
  912. .dev_attr = &mcspi3_dev_attr,
  913. };
  914. /* mcspi4 */
  915. /* mcspi4 dev_attr */
  916. static struct omap2_mcspi_dev_attr mcspi4_dev_attr = {
  917. .num_chipselect = 1,
  918. };
  919. static struct omap_hwmod dra7xx_mcspi4_hwmod = {
  920. .name = "mcspi4",
  921. .class = &dra7xx_mcspi_hwmod_class,
  922. .clkdm_name = "l4per_clkdm",
  923. .main_clk = "func_48m_fclk",
  924. .prcm = {
  925. .omap4 = {
  926. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI4_CLKCTRL_OFFSET,
  927. .context_offs = DRA7XX_RM_L4PER_MCSPI4_CONTEXT_OFFSET,
  928. .modulemode = MODULEMODE_SWCTRL,
  929. },
  930. },
  931. .dev_attr = &mcspi4_dev_attr,
  932. };
  933. /*
  934. * 'mmc' class
  935. *
  936. */
  937. static struct omap_hwmod_class_sysconfig dra7xx_mmc_sysc = {
  938. .rev_offs = 0x0000,
  939. .sysc_offs = 0x0010,
  940. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
  941. SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  942. SYSC_HAS_SOFTRESET),
  943. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  944. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  945. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  946. .sysc_fields = &omap_hwmod_sysc_type2,
  947. };
  948. static struct omap_hwmod_class dra7xx_mmc_hwmod_class = {
  949. .name = "mmc",
  950. .sysc = &dra7xx_mmc_sysc,
  951. };
  952. /* mmc1 */
  953. static struct omap_hwmod_opt_clk mmc1_opt_clks[] = {
  954. { .role = "clk32k", .clk = "mmc1_clk32k" },
  955. };
  956. /* mmc1 dev_attr */
  957. static struct omap_mmc_dev_attr mmc1_dev_attr = {
  958. .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
  959. };
  960. static struct omap_hwmod dra7xx_mmc1_hwmod = {
  961. .name = "mmc1",
  962. .class = &dra7xx_mmc_hwmod_class,
  963. .clkdm_name = "l3init_clkdm",
  964. .main_clk = "mmc1_fclk_div",
  965. .prcm = {
  966. .omap4 = {
  967. .clkctrl_offs = DRA7XX_CM_L3INIT_MMC1_CLKCTRL_OFFSET,
  968. .context_offs = DRA7XX_RM_L3INIT_MMC1_CONTEXT_OFFSET,
  969. .modulemode = MODULEMODE_SWCTRL,
  970. },
  971. },
  972. .opt_clks = mmc1_opt_clks,
  973. .opt_clks_cnt = ARRAY_SIZE(mmc1_opt_clks),
  974. .dev_attr = &mmc1_dev_attr,
  975. };
  976. /* mmc2 */
  977. static struct omap_hwmod_opt_clk mmc2_opt_clks[] = {
  978. { .role = "clk32k", .clk = "mmc2_clk32k" },
  979. };
  980. static struct omap_hwmod dra7xx_mmc2_hwmod = {
  981. .name = "mmc2",
  982. .class = &dra7xx_mmc_hwmod_class,
  983. .clkdm_name = "l3init_clkdm",
  984. .main_clk = "mmc2_fclk_div",
  985. .prcm = {
  986. .omap4 = {
  987. .clkctrl_offs = DRA7XX_CM_L3INIT_MMC2_CLKCTRL_OFFSET,
  988. .context_offs = DRA7XX_RM_L3INIT_MMC2_CONTEXT_OFFSET,
  989. .modulemode = MODULEMODE_SWCTRL,
  990. },
  991. },
  992. .opt_clks = mmc2_opt_clks,
  993. .opt_clks_cnt = ARRAY_SIZE(mmc2_opt_clks),
  994. };
  995. /* mmc3 */
  996. static struct omap_hwmod_opt_clk mmc3_opt_clks[] = {
  997. { .role = "clk32k", .clk = "mmc3_clk32k" },
  998. };
  999. static struct omap_hwmod dra7xx_mmc3_hwmod = {
  1000. .name = "mmc3",
  1001. .class = &dra7xx_mmc_hwmod_class,
  1002. .clkdm_name = "l4per_clkdm",
  1003. .main_clk = "mmc3_gfclk_div",
  1004. .prcm = {
  1005. .omap4 = {
  1006. .clkctrl_offs = DRA7XX_CM_L4PER_MMC3_CLKCTRL_OFFSET,
  1007. .context_offs = DRA7XX_RM_L4PER_MMC3_CONTEXT_OFFSET,
  1008. .modulemode = MODULEMODE_SWCTRL,
  1009. },
  1010. },
  1011. .opt_clks = mmc3_opt_clks,
  1012. .opt_clks_cnt = ARRAY_SIZE(mmc3_opt_clks),
  1013. };
  1014. /* mmc4 */
  1015. static struct omap_hwmod_opt_clk mmc4_opt_clks[] = {
  1016. { .role = "clk32k", .clk = "mmc4_clk32k" },
  1017. };
  1018. static struct omap_hwmod dra7xx_mmc4_hwmod = {
  1019. .name = "mmc4",
  1020. .class = &dra7xx_mmc_hwmod_class,
  1021. .clkdm_name = "l4per_clkdm",
  1022. .main_clk = "mmc4_gfclk_div",
  1023. .prcm = {
  1024. .omap4 = {
  1025. .clkctrl_offs = DRA7XX_CM_L4PER_MMC4_CLKCTRL_OFFSET,
  1026. .context_offs = DRA7XX_RM_L4PER_MMC4_CONTEXT_OFFSET,
  1027. .modulemode = MODULEMODE_SWCTRL,
  1028. },
  1029. },
  1030. .opt_clks = mmc4_opt_clks,
  1031. .opt_clks_cnt = ARRAY_SIZE(mmc4_opt_clks),
  1032. };
  1033. /*
  1034. * 'mpu' class
  1035. *
  1036. */
  1037. static struct omap_hwmod_class dra7xx_mpu_hwmod_class = {
  1038. .name = "mpu",
  1039. };
  1040. /* mpu */
  1041. static struct omap_hwmod dra7xx_mpu_hwmod = {
  1042. .name = "mpu",
  1043. .class = &dra7xx_mpu_hwmod_class,
  1044. .clkdm_name = "mpu_clkdm",
  1045. .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
  1046. .main_clk = "dpll_mpu_m2_ck",
  1047. .prcm = {
  1048. .omap4 = {
  1049. .clkctrl_offs = DRA7XX_CM_MPU_MPU_CLKCTRL_OFFSET,
  1050. .context_offs = DRA7XX_RM_MPU_MPU_CONTEXT_OFFSET,
  1051. },
  1052. },
  1053. };
  1054. /*
  1055. * 'ocp2scp' class
  1056. *
  1057. */
  1058. static struct omap_hwmod_class_sysconfig dra7xx_ocp2scp_sysc = {
  1059. .rev_offs = 0x0000,
  1060. .sysc_offs = 0x0010,
  1061. .syss_offs = 0x0014,
  1062. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
  1063. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1064. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1065. SIDLE_SMART_WKUP),
  1066. .sysc_fields = &omap_hwmod_sysc_type1,
  1067. };
  1068. static struct omap_hwmod_class dra7xx_ocp2scp_hwmod_class = {
  1069. .name = "ocp2scp",
  1070. .sysc = &dra7xx_ocp2scp_sysc,
  1071. };
  1072. /* ocp2scp1 */
  1073. static struct omap_hwmod dra7xx_ocp2scp1_hwmod = {
  1074. .name = "ocp2scp1",
  1075. .class = &dra7xx_ocp2scp_hwmod_class,
  1076. .clkdm_name = "l3init_clkdm",
  1077. .main_clk = "l4_root_clk_div",
  1078. .prcm = {
  1079. .omap4 = {
  1080. .clkctrl_offs = DRA7XX_CM_L3INIT_OCP2SCP1_CLKCTRL_OFFSET,
  1081. .context_offs = DRA7XX_RM_L3INIT_OCP2SCP1_CONTEXT_OFFSET,
  1082. .modulemode = MODULEMODE_HWCTRL,
  1083. },
  1084. },
  1085. };
  1086. /*
  1087. * 'qspi' class
  1088. *
  1089. */
  1090. static struct omap_hwmod_class_sysconfig dra7xx_qspi_sysc = {
  1091. .sysc_offs = 0x0010,
  1092. .sysc_flags = SYSC_HAS_SIDLEMODE,
  1093. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1094. SIDLE_SMART_WKUP),
  1095. .sysc_fields = &omap_hwmod_sysc_type2,
  1096. };
  1097. static struct omap_hwmod_class dra7xx_qspi_hwmod_class = {
  1098. .name = "qspi",
  1099. .sysc = &dra7xx_qspi_sysc,
  1100. };
  1101. /* qspi */
  1102. static struct omap_hwmod dra7xx_qspi_hwmod = {
  1103. .name = "qspi",
  1104. .class = &dra7xx_qspi_hwmod_class,
  1105. .clkdm_name = "l4per2_clkdm",
  1106. .main_clk = "qspi_gfclk_div",
  1107. .prcm = {
  1108. .omap4 = {
  1109. .clkctrl_offs = DRA7XX_CM_L4PER2_QSPI_CLKCTRL_OFFSET,
  1110. .context_offs = DRA7XX_RM_L4PER2_QSPI_CONTEXT_OFFSET,
  1111. .modulemode = MODULEMODE_SWCTRL,
  1112. },
  1113. },
  1114. };
  1115. /*
  1116. * 'sata' class
  1117. *
  1118. */
  1119. static struct omap_hwmod_class_sysconfig dra7xx_sata_sysc = {
  1120. .sysc_offs = 0x0000,
  1121. .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
  1122. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1123. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  1124. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  1125. .sysc_fields = &omap_hwmod_sysc_type2,
  1126. };
  1127. static struct omap_hwmod_class dra7xx_sata_hwmod_class = {
  1128. .name = "sata",
  1129. .sysc = &dra7xx_sata_sysc,
  1130. };
  1131. /* sata */
  1132. static struct omap_hwmod_opt_clk sata_opt_clks[] = {
  1133. { .role = "ref_clk", .clk = "sata_ref_clk" },
  1134. };
  1135. static struct omap_hwmod dra7xx_sata_hwmod = {
  1136. .name = "sata",
  1137. .class = &dra7xx_sata_hwmod_class,
  1138. .clkdm_name = "l3init_clkdm",
  1139. .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  1140. .main_clk = "func_48m_fclk",
  1141. .prcm = {
  1142. .omap4 = {
  1143. .clkctrl_offs = DRA7XX_CM_L3INIT_SATA_CLKCTRL_OFFSET,
  1144. .context_offs = DRA7XX_RM_L3INIT_SATA_CONTEXT_OFFSET,
  1145. .modulemode = MODULEMODE_SWCTRL,
  1146. },
  1147. },
  1148. .opt_clks = sata_opt_clks,
  1149. .opt_clks_cnt = ARRAY_SIZE(sata_opt_clks),
  1150. };
  1151. /*
  1152. * 'smartreflex' class
  1153. *
  1154. */
  1155. /* The IP is not compliant to type1 / type2 scheme */
  1156. static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_smartreflex = {
  1157. .sidle_shift = 24,
  1158. .enwkup_shift = 26,
  1159. };
  1160. static struct omap_hwmod_class_sysconfig dra7xx_smartreflex_sysc = {
  1161. .sysc_offs = 0x0038,
  1162. .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE),
  1163. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1164. SIDLE_SMART_WKUP),
  1165. .sysc_fields = &omap_hwmod_sysc_type_smartreflex,
  1166. };
  1167. static struct omap_hwmod_class dra7xx_smartreflex_hwmod_class = {
  1168. .name = "smartreflex",
  1169. .sysc = &dra7xx_smartreflex_sysc,
  1170. .rev = 2,
  1171. };
  1172. /* smartreflex_core */
  1173. /* smartreflex_core dev_attr */
  1174. static struct omap_smartreflex_dev_attr smartreflex_core_dev_attr = {
  1175. .sensor_voltdm_name = "core",
  1176. };
  1177. static struct omap_hwmod dra7xx_smartreflex_core_hwmod = {
  1178. .name = "smartreflex_core",
  1179. .class = &dra7xx_smartreflex_hwmod_class,
  1180. .clkdm_name = "coreaon_clkdm",
  1181. .main_clk = "wkupaon_iclk_mux",
  1182. .prcm = {
  1183. .omap4 = {
  1184. .clkctrl_offs = DRA7XX_CM_COREAON_SMARTREFLEX_CORE_CLKCTRL_OFFSET,
  1185. .context_offs = DRA7XX_RM_COREAON_SMARTREFLEX_CORE_CONTEXT_OFFSET,
  1186. .modulemode = MODULEMODE_SWCTRL,
  1187. },
  1188. },
  1189. .dev_attr = &smartreflex_core_dev_attr,
  1190. };
  1191. /* smartreflex_mpu */
  1192. /* smartreflex_mpu dev_attr */
  1193. static struct omap_smartreflex_dev_attr smartreflex_mpu_dev_attr = {
  1194. .sensor_voltdm_name = "mpu",
  1195. };
  1196. static struct omap_hwmod dra7xx_smartreflex_mpu_hwmod = {
  1197. .name = "smartreflex_mpu",
  1198. .class = &dra7xx_smartreflex_hwmod_class,
  1199. .clkdm_name = "coreaon_clkdm",
  1200. .main_clk = "wkupaon_iclk_mux",
  1201. .prcm = {
  1202. .omap4 = {
  1203. .clkctrl_offs = DRA7XX_CM_COREAON_SMARTREFLEX_MPU_CLKCTRL_OFFSET,
  1204. .context_offs = DRA7XX_RM_COREAON_SMARTREFLEX_MPU_CONTEXT_OFFSET,
  1205. .modulemode = MODULEMODE_SWCTRL,
  1206. },
  1207. },
  1208. .dev_attr = &smartreflex_mpu_dev_attr,
  1209. };
  1210. /*
  1211. * 'spinlock' class
  1212. *
  1213. */
  1214. static struct omap_hwmod_class_sysconfig dra7xx_spinlock_sysc = {
  1215. .rev_offs = 0x0000,
  1216. .sysc_offs = 0x0010,
  1217. .syss_offs = 0x0014,
  1218. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  1219. SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
  1220. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1221. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1222. SIDLE_SMART_WKUP),
  1223. .sysc_fields = &omap_hwmod_sysc_type1,
  1224. };
  1225. static struct omap_hwmod_class dra7xx_spinlock_hwmod_class = {
  1226. .name = "spinlock",
  1227. .sysc = &dra7xx_spinlock_sysc,
  1228. };
  1229. /* spinlock */
  1230. static struct omap_hwmod dra7xx_spinlock_hwmod = {
  1231. .name = "spinlock",
  1232. .class = &dra7xx_spinlock_hwmod_class,
  1233. .clkdm_name = "l4cfg_clkdm",
  1234. .main_clk = "l3_iclk_div",
  1235. .prcm = {
  1236. .omap4 = {
  1237. .clkctrl_offs = DRA7XX_CM_L4CFG_SPINLOCK_CLKCTRL_OFFSET,
  1238. .context_offs = DRA7XX_RM_L4CFG_SPINLOCK_CONTEXT_OFFSET,
  1239. },
  1240. },
  1241. };
  1242. /*
  1243. * 'timer' class
  1244. *
  1245. * This class contains several variants: ['timer_1ms', 'timer_secure',
  1246. * 'timer']
  1247. */
  1248. static struct omap_hwmod_class_sysconfig dra7xx_timer_1ms_sysc = {
  1249. .rev_offs = 0x0000,
  1250. .sysc_offs = 0x0010,
  1251. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  1252. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1253. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1254. SIDLE_SMART_WKUP),
  1255. .sysc_fields = &omap_hwmod_sysc_type2,
  1256. };
  1257. static struct omap_hwmod_class dra7xx_timer_1ms_hwmod_class = {
  1258. .name = "timer",
  1259. .sysc = &dra7xx_timer_1ms_sysc,
  1260. };
  1261. static struct omap_hwmod_class_sysconfig dra7xx_timer_secure_sysc = {
  1262. .rev_offs = 0x0000,
  1263. .sysc_offs = 0x0010,
  1264. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  1265. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1266. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1267. SIDLE_SMART_WKUP),
  1268. .sysc_fields = &omap_hwmod_sysc_type2,
  1269. };
  1270. static struct omap_hwmod_class dra7xx_timer_secure_hwmod_class = {
  1271. .name = "timer",
  1272. .sysc = &dra7xx_timer_secure_sysc,
  1273. };
  1274. static struct omap_hwmod_class_sysconfig dra7xx_timer_sysc = {
  1275. .rev_offs = 0x0000,
  1276. .sysc_offs = 0x0010,
  1277. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  1278. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1279. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1280. SIDLE_SMART_WKUP),
  1281. .sysc_fields = &omap_hwmod_sysc_type2,
  1282. };
  1283. static struct omap_hwmod_class dra7xx_timer_hwmod_class = {
  1284. .name = "timer",
  1285. .sysc = &dra7xx_timer_sysc,
  1286. };
  1287. /* timer1 */
  1288. static struct omap_hwmod dra7xx_timer1_hwmod = {
  1289. .name = "timer1",
  1290. .class = &dra7xx_timer_1ms_hwmod_class,
  1291. .clkdm_name = "wkupaon_clkdm",
  1292. .main_clk = "timer1_gfclk_mux",
  1293. .prcm = {
  1294. .omap4 = {
  1295. .clkctrl_offs = DRA7XX_CM_WKUPAON_TIMER1_CLKCTRL_OFFSET,
  1296. .context_offs = DRA7XX_RM_WKUPAON_TIMER1_CONTEXT_OFFSET,
  1297. .modulemode = MODULEMODE_SWCTRL,
  1298. },
  1299. },
  1300. };
  1301. /* timer2 */
  1302. static struct omap_hwmod dra7xx_timer2_hwmod = {
  1303. .name = "timer2",
  1304. .class = &dra7xx_timer_1ms_hwmod_class,
  1305. .clkdm_name = "l4per_clkdm",
  1306. .main_clk = "timer2_gfclk_mux",
  1307. .prcm = {
  1308. .omap4 = {
  1309. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER2_CLKCTRL_OFFSET,
  1310. .context_offs = DRA7XX_RM_L4PER_TIMER2_CONTEXT_OFFSET,
  1311. .modulemode = MODULEMODE_SWCTRL,
  1312. },
  1313. },
  1314. };
  1315. /* timer3 */
  1316. static struct omap_hwmod dra7xx_timer3_hwmod = {
  1317. .name = "timer3",
  1318. .class = &dra7xx_timer_hwmod_class,
  1319. .clkdm_name = "l4per_clkdm",
  1320. .main_clk = "timer3_gfclk_mux",
  1321. .prcm = {
  1322. .omap4 = {
  1323. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER3_CLKCTRL_OFFSET,
  1324. .context_offs = DRA7XX_RM_L4PER_TIMER3_CONTEXT_OFFSET,
  1325. .modulemode = MODULEMODE_SWCTRL,
  1326. },
  1327. },
  1328. };
  1329. /* timer4 */
  1330. static struct omap_hwmod dra7xx_timer4_hwmod = {
  1331. .name = "timer4",
  1332. .class = &dra7xx_timer_secure_hwmod_class,
  1333. .clkdm_name = "l4per_clkdm",
  1334. .main_clk = "timer4_gfclk_mux",
  1335. .prcm = {
  1336. .omap4 = {
  1337. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER4_CLKCTRL_OFFSET,
  1338. .context_offs = DRA7XX_RM_L4PER_TIMER4_CONTEXT_OFFSET,
  1339. .modulemode = MODULEMODE_SWCTRL,
  1340. },
  1341. },
  1342. };
  1343. /* timer5 */
  1344. static struct omap_hwmod dra7xx_timer5_hwmod = {
  1345. .name = "timer5",
  1346. .class = &dra7xx_timer_hwmod_class,
  1347. .clkdm_name = "ipu_clkdm",
  1348. .main_clk = "timer5_gfclk_mux",
  1349. .prcm = {
  1350. .omap4 = {
  1351. .clkctrl_offs = DRA7XX_CM_IPU_TIMER5_CLKCTRL_OFFSET,
  1352. .context_offs = DRA7XX_RM_IPU_TIMER5_CONTEXT_OFFSET,
  1353. .modulemode = MODULEMODE_SWCTRL,
  1354. },
  1355. },
  1356. };
  1357. /* timer6 */
  1358. static struct omap_hwmod dra7xx_timer6_hwmod = {
  1359. .name = "timer6",
  1360. .class = &dra7xx_timer_hwmod_class,
  1361. .clkdm_name = "ipu_clkdm",
  1362. .main_clk = "timer6_gfclk_mux",
  1363. .prcm = {
  1364. .omap4 = {
  1365. .clkctrl_offs = DRA7XX_CM_IPU_TIMER6_CLKCTRL_OFFSET,
  1366. .context_offs = DRA7XX_RM_IPU_TIMER6_CONTEXT_OFFSET,
  1367. .modulemode = MODULEMODE_SWCTRL,
  1368. },
  1369. },
  1370. };
  1371. /* timer7 */
  1372. static struct omap_hwmod dra7xx_timer7_hwmod = {
  1373. .name = "timer7",
  1374. .class = &dra7xx_timer_hwmod_class,
  1375. .clkdm_name = "ipu_clkdm",
  1376. .main_clk = "timer7_gfclk_mux",
  1377. .prcm = {
  1378. .omap4 = {
  1379. .clkctrl_offs = DRA7XX_CM_IPU_TIMER7_CLKCTRL_OFFSET,
  1380. .context_offs = DRA7XX_RM_IPU_TIMER7_CONTEXT_OFFSET,
  1381. .modulemode = MODULEMODE_SWCTRL,
  1382. },
  1383. },
  1384. };
  1385. /* timer8 */
  1386. static struct omap_hwmod dra7xx_timer8_hwmod = {
  1387. .name = "timer8",
  1388. .class = &dra7xx_timer_hwmod_class,
  1389. .clkdm_name = "ipu_clkdm",
  1390. .main_clk = "timer8_gfclk_mux",
  1391. .prcm = {
  1392. .omap4 = {
  1393. .clkctrl_offs = DRA7XX_CM_IPU_TIMER8_CLKCTRL_OFFSET,
  1394. .context_offs = DRA7XX_RM_IPU_TIMER8_CONTEXT_OFFSET,
  1395. .modulemode = MODULEMODE_SWCTRL,
  1396. },
  1397. },
  1398. };
  1399. /* timer9 */
  1400. static struct omap_hwmod dra7xx_timer9_hwmod = {
  1401. .name = "timer9",
  1402. .class = &dra7xx_timer_hwmod_class,
  1403. .clkdm_name = "l4per_clkdm",
  1404. .main_clk = "timer9_gfclk_mux",
  1405. .prcm = {
  1406. .omap4 = {
  1407. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER9_CLKCTRL_OFFSET,
  1408. .context_offs = DRA7XX_RM_L4PER_TIMER9_CONTEXT_OFFSET,
  1409. .modulemode = MODULEMODE_SWCTRL,
  1410. },
  1411. },
  1412. };
  1413. /* timer10 */
  1414. static struct omap_hwmod dra7xx_timer10_hwmod = {
  1415. .name = "timer10",
  1416. .class = &dra7xx_timer_1ms_hwmod_class,
  1417. .clkdm_name = "l4per_clkdm",
  1418. .main_clk = "timer10_gfclk_mux",
  1419. .prcm = {
  1420. .omap4 = {
  1421. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER10_CLKCTRL_OFFSET,
  1422. .context_offs = DRA7XX_RM_L4PER_TIMER10_CONTEXT_OFFSET,
  1423. .modulemode = MODULEMODE_SWCTRL,
  1424. },
  1425. },
  1426. };
  1427. /* timer11 */
  1428. static struct omap_hwmod dra7xx_timer11_hwmod = {
  1429. .name = "timer11",
  1430. .class = &dra7xx_timer_hwmod_class,
  1431. .clkdm_name = "l4per_clkdm",
  1432. .main_clk = "timer11_gfclk_mux",
  1433. .prcm = {
  1434. .omap4 = {
  1435. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER11_CLKCTRL_OFFSET,
  1436. .context_offs = DRA7XX_RM_L4PER_TIMER11_CONTEXT_OFFSET,
  1437. .modulemode = MODULEMODE_SWCTRL,
  1438. },
  1439. },
  1440. };
  1441. /*
  1442. * 'uart' class
  1443. *
  1444. */
  1445. static struct omap_hwmod_class_sysconfig dra7xx_uart_sysc = {
  1446. .rev_offs = 0x0050,
  1447. .sysc_offs = 0x0054,
  1448. .syss_offs = 0x0058,
  1449. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  1450. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  1451. SYSS_HAS_RESET_STATUS),
  1452. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1453. SIDLE_SMART_WKUP),
  1454. .sysc_fields = &omap_hwmod_sysc_type1,
  1455. };
  1456. static struct omap_hwmod_class dra7xx_uart_hwmod_class = {
  1457. .name = "uart",
  1458. .sysc = &dra7xx_uart_sysc,
  1459. };
  1460. /* uart1 */
  1461. static struct omap_hwmod dra7xx_uart1_hwmod = {
  1462. .name = "uart1",
  1463. .class = &dra7xx_uart_hwmod_class,
  1464. .clkdm_name = "l4per_clkdm",
  1465. .main_clk = "uart1_gfclk_mux",
  1466. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1467. .prcm = {
  1468. .omap4 = {
  1469. .clkctrl_offs = DRA7XX_CM_L4PER_UART1_CLKCTRL_OFFSET,
  1470. .context_offs = DRA7XX_RM_L4PER_UART1_CONTEXT_OFFSET,
  1471. .modulemode = MODULEMODE_SWCTRL,
  1472. },
  1473. },
  1474. };
  1475. /* uart2 */
  1476. static struct omap_hwmod dra7xx_uart2_hwmod = {
  1477. .name = "uart2",
  1478. .class = &dra7xx_uart_hwmod_class,
  1479. .clkdm_name = "l4per_clkdm",
  1480. .main_clk = "uart2_gfclk_mux",
  1481. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1482. .prcm = {
  1483. .omap4 = {
  1484. .clkctrl_offs = DRA7XX_CM_L4PER_UART2_CLKCTRL_OFFSET,
  1485. .context_offs = DRA7XX_RM_L4PER_UART2_CONTEXT_OFFSET,
  1486. .modulemode = MODULEMODE_SWCTRL,
  1487. },
  1488. },
  1489. };
  1490. /* uart3 */
  1491. static struct omap_hwmod dra7xx_uart3_hwmod = {
  1492. .name = "uart3",
  1493. .class = &dra7xx_uart_hwmod_class,
  1494. .clkdm_name = "l4per_clkdm",
  1495. .main_clk = "uart3_gfclk_mux",
  1496. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1497. .prcm = {
  1498. .omap4 = {
  1499. .clkctrl_offs = DRA7XX_CM_L4PER_UART3_CLKCTRL_OFFSET,
  1500. .context_offs = DRA7XX_RM_L4PER_UART3_CONTEXT_OFFSET,
  1501. .modulemode = MODULEMODE_SWCTRL,
  1502. },
  1503. },
  1504. };
  1505. /* uart4 */
  1506. static struct omap_hwmod dra7xx_uart4_hwmod = {
  1507. .name = "uart4",
  1508. .class = &dra7xx_uart_hwmod_class,
  1509. .clkdm_name = "l4per_clkdm",
  1510. .main_clk = "uart4_gfclk_mux",
  1511. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1512. .prcm = {
  1513. .omap4 = {
  1514. .clkctrl_offs = DRA7XX_CM_L4PER_UART4_CLKCTRL_OFFSET,
  1515. .context_offs = DRA7XX_RM_L4PER_UART4_CONTEXT_OFFSET,
  1516. .modulemode = MODULEMODE_SWCTRL,
  1517. },
  1518. },
  1519. };
  1520. /* uart5 */
  1521. static struct omap_hwmod dra7xx_uart5_hwmod = {
  1522. .name = "uart5",
  1523. .class = &dra7xx_uart_hwmod_class,
  1524. .clkdm_name = "l4per_clkdm",
  1525. .main_clk = "uart5_gfclk_mux",
  1526. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1527. .prcm = {
  1528. .omap4 = {
  1529. .clkctrl_offs = DRA7XX_CM_L4PER_UART5_CLKCTRL_OFFSET,
  1530. .context_offs = DRA7XX_RM_L4PER_UART5_CONTEXT_OFFSET,
  1531. .modulemode = MODULEMODE_SWCTRL,
  1532. },
  1533. },
  1534. };
  1535. /* uart6 */
  1536. static struct omap_hwmod dra7xx_uart6_hwmod = {
  1537. .name = "uart6",
  1538. .class = &dra7xx_uart_hwmod_class,
  1539. .clkdm_name = "ipu_clkdm",
  1540. .main_clk = "uart6_gfclk_mux",
  1541. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1542. .prcm = {
  1543. .omap4 = {
  1544. .clkctrl_offs = DRA7XX_CM_IPU_UART6_CLKCTRL_OFFSET,
  1545. .context_offs = DRA7XX_RM_IPU_UART6_CONTEXT_OFFSET,
  1546. .modulemode = MODULEMODE_SWCTRL,
  1547. },
  1548. },
  1549. };
  1550. /*
  1551. * 'usb_otg_ss' class
  1552. *
  1553. */
  1554. static struct omap_hwmod_class dra7xx_usb_otg_ss_hwmod_class = {
  1555. .name = "usb_otg_ss",
  1556. };
  1557. /* usb_otg_ss1 */
  1558. static struct omap_hwmod_opt_clk usb_otg_ss1_opt_clks[] = {
  1559. { .role = "refclk960m", .clk = "usb_otg_ss1_refclk960m" },
  1560. };
  1561. static struct omap_hwmod dra7xx_usb_otg_ss1_hwmod = {
  1562. .name = "usb_otg_ss1",
  1563. .class = &dra7xx_usb_otg_ss_hwmod_class,
  1564. .clkdm_name = "l3init_clkdm",
  1565. .main_clk = "dpll_core_h13x2_ck",
  1566. .prcm = {
  1567. .omap4 = {
  1568. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS1_CLKCTRL_OFFSET,
  1569. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS1_CONTEXT_OFFSET,
  1570. .modulemode = MODULEMODE_HWCTRL,
  1571. },
  1572. },
  1573. .opt_clks = usb_otg_ss1_opt_clks,
  1574. .opt_clks_cnt = ARRAY_SIZE(usb_otg_ss1_opt_clks),
  1575. };
  1576. /* usb_otg_ss2 */
  1577. static struct omap_hwmod_opt_clk usb_otg_ss2_opt_clks[] = {
  1578. { .role = "refclk960m", .clk = "usb_otg_ss2_refclk960m" },
  1579. };
  1580. static struct omap_hwmod dra7xx_usb_otg_ss2_hwmod = {
  1581. .name = "usb_otg_ss2",
  1582. .class = &dra7xx_usb_otg_ss_hwmod_class,
  1583. .clkdm_name = "l3init_clkdm",
  1584. .main_clk = "dpll_core_h13x2_ck",
  1585. .prcm = {
  1586. .omap4 = {
  1587. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS2_CLKCTRL_OFFSET,
  1588. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS2_CONTEXT_OFFSET,
  1589. .modulemode = MODULEMODE_HWCTRL,
  1590. },
  1591. },
  1592. .opt_clks = usb_otg_ss2_opt_clks,
  1593. .opt_clks_cnt = ARRAY_SIZE(usb_otg_ss2_opt_clks),
  1594. };
  1595. /* usb_otg_ss3 */
  1596. static struct omap_hwmod dra7xx_usb_otg_ss3_hwmod = {
  1597. .name = "usb_otg_ss3",
  1598. .class = &dra7xx_usb_otg_ss_hwmod_class,
  1599. .clkdm_name = "l3init_clkdm",
  1600. .main_clk = "dpll_core_h13x2_ck",
  1601. .prcm = {
  1602. .omap4 = {
  1603. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS3_CLKCTRL_OFFSET,
  1604. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS3_CONTEXT_OFFSET,
  1605. .modulemode = MODULEMODE_HWCTRL,
  1606. },
  1607. },
  1608. };
  1609. /* usb_otg_ss4 */
  1610. static struct omap_hwmod dra7xx_usb_otg_ss4_hwmod = {
  1611. .name = "usb_otg_ss4",
  1612. .class = &dra7xx_usb_otg_ss_hwmod_class,
  1613. .clkdm_name = "l3init_clkdm",
  1614. .main_clk = "dpll_core_h13x2_ck",
  1615. .prcm = {
  1616. .omap4 = {
  1617. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS4_CLKCTRL_OFFSET,
  1618. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS4_CONTEXT_OFFSET,
  1619. .modulemode = MODULEMODE_HWCTRL,
  1620. },
  1621. },
  1622. };
  1623. /*
  1624. * 'vcp' class
  1625. *
  1626. */
  1627. static struct omap_hwmod_class dra7xx_vcp_hwmod_class = {
  1628. .name = "vcp",
  1629. };
  1630. /* vcp1 */
  1631. static struct omap_hwmod dra7xx_vcp1_hwmod = {
  1632. .name = "vcp1",
  1633. .class = &dra7xx_vcp_hwmod_class,
  1634. .clkdm_name = "l3main1_clkdm",
  1635. .main_clk = "l3_iclk_div",
  1636. .prcm = {
  1637. .omap4 = {
  1638. .clkctrl_offs = DRA7XX_CM_L3MAIN1_VCP1_CLKCTRL_OFFSET,
  1639. .context_offs = DRA7XX_RM_L3MAIN1_VCP1_CONTEXT_OFFSET,
  1640. },
  1641. },
  1642. };
  1643. /* vcp2 */
  1644. static struct omap_hwmod dra7xx_vcp2_hwmod = {
  1645. .name = "vcp2",
  1646. .class = &dra7xx_vcp_hwmod_class,
  1647. .clkdm_name = "l3main1_clkdm",
  1648. .main_clk = "l3_iclk_div",
  1649. .prcm = {
  1650. .omap4 = {
  1651. .clkctrl_offs = DRA7XX_CM_L3MAIN1_VCP2_CLKCTRL_OFFSET,
  1652. .context_offs = DRA7XX_RM_L3MAIN1_VCP2_CONTEXT_OFFSET,
  1653. },
  1654. },
  1655. };
  1656. /*
  1657. * 'wd_timer' class
  1658. *
  1659. */
  1660. static struct omap_hwmod_class_sysconfig dra7xx_wd_timer_sysc = {
  1661. .rev_offs = 0x0000,
  1662. .sysc_offs = 0x0010,
  1663. .syss_offs = 0x0014,
  1664. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_SIDLEMODE |
  1665. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1666. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1667. SIDLE_SMART_WKUP),
  1668. .sysc_fields = &omap_hwmod_sysc_type1,
  1669. };
  1670. static struct omap_hwmod_class dra7xx_wd_timer_hwmod_class = {
  1671. .name = "wd_timer",
  1672. .sysc = &dra7xx_wd_timer_sysc,
  1673. .pre_shutdown = &omap2_wd_timer_disable,
  1674. .reset = &omap2_wd_timer_reset,
  1675. };
  1676. /* wd_timer2 */
  1677. static struct omap_hwmod dra7xx_wd_timer2_hwmod = {
  1678. .name = "wd_timer2",
  1679. .class = &dra7xx_wd_timer_hwmod_class,
  1680. .clkdm_name = "wkupaon_clkdm",
  1681. .main_clk = "sys_32k_ck",
  1682. .prcm = {
  1683. .omap4 = {
  1684. .clkctrl_offs = DRA7XX_CM_WKUPAON_WD_TIMER2_CLKCTRL_OFFSET,
  1685. .context_offs = DRA7XX_RM_WKUPAON_WD_TIMER2_CONTEXT_OFFSET,
  1686. .modulemode = MODULEMODE_SWCTRL,
  1687. },
  1688. },
  1689. };
  1690. /*
  1691. * Interfaces
  1692. */
  1693. /* l3_main_2 -> l3_instr */
  1694. static struct omap_hwmod_ocp_if dra7xx_l3_main_2__l3_instr = {
  1695. .master = &dra7xx_l3_main_2_hwmod,
  1696. .slave = &dra7xx_l3_instr_hwmod,
  1697. .clk = "l3_iclk_div",
  1698. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1699. };
  1700. /* l4_cfg -> l3_main_1 */
  1701. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__l3_main_1 = {
  1702. .master = &dra7xx_l4_cfg_hwmod,
  1703. .slave = &dra7xx_l3_main_1_hwmod,
  1704. .clk = "l3_iclk_div",
  1705. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1706. };
  1707. /* mpu -> l3_main_1 */
  1708. static struct omap_hwmod_ocp_if dra7xx_mpu__l3_main_1 = {
  1709. .master = &dra7xx_mpu_hwmod,
  1710. .slave = &dra7xx_l3_main_1_hwmod,
  1711. .clk = "l3_iclk_div",
  1712. .user = OCP_USER_MPU,
  1713. };
  1714. /* l3_main_1 -> l3_main_2 */
  1715. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l3_main_2 = {
  1716. .master = &dra7xx_l3_main_1_hwmod,
  1717. .slave = &dra7xx_l3_main_2_hwmod,
  1718. .clk = "l3_iclk_div",
  1719. .user = OCP_USER_MPU,
  1720. };
  1721. /* l4_cfg -> l3_main_2 */
  1722. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__l3_main_2 = {
  1723. .master = &dra7xx_l4_cfg_hwmod,
  1724. .slave = &dra7xx_l3_main_2_hwmod,
  1725. .clk = "l3_iclk_div",
  1726. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1727. };
  1728. /* l3_main_1 -> l4_cfg */
  1729. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_cfg = {
  1730. .master = &dra7xx_l3_main_1_hwmod,
  1731. .slave = &dra7xx_l4_cfg_hwmod,
  1732. .clk = "l3_iclk_div",
  1733. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1734. };
  1735. /* l3_main_1 -> l4_per1 */
  1736. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per1 = {
  1737. .master = &dra7xx_l3_main_1_hwmod,
  1738. .slave = &dra7xx_l4_per1_hwmod,
  1739. .clk = "l3_iclk_div",
  1740. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1741. };
  1742. /* l3_main_1 -> l4_per2 */
  1743. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per2 = {
  1744. .master = &dra7xx_l3_main_1_hwmod,
  1745. .slave = &dra7xx_l4_per2_hwmod,
  1746. .clk = "l3_iclk_div",
  1747. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1748. };
  1749. /* l3_main_1 -> l4_per3 */
  1750. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per3 = {
  1751. .master = &dra7xx_l3_main_1_hwmod,
  1752. .slave = &dra7xx_l4_per3_hwmod,
  1753. .clk = "l3_iclk_div",
  1754. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1755. };
  1756. /* l3_main_1 -> l4_wkup */
  1757. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_wkup = {
  1758. .master = &dra7xx_l3_main_1_hwmod,
  1759. .slave = &dra7xx_l4_wkup_hwmod,
  1760. .clk = "wkupaon_iclk_mux",
  1761. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1762. };
  1763. /* l4_per2 -> atl */
  1764. static struct omap_hwmod_ocp_if dra7xx_l4_per2__atl = {
  1765. .master = &dra7xx_l4_per2_hwmod,
  1766. .slave = &dra7xx_atl_hwmod,
  1767. .clk = "l3_iclk_div",
  1768. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1769. };
  1770. /* l3_main_1 -> bb2d */
  1771. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__bb2d = {
  1772. .master = &dra7xx_l3_main_1_hwmod,
  1773. .slave = &dra7xx_bb2d_hwmod,
  1774. .clk = "l3_iclk_div",
  1775. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1776. };
  1777. /* l4_wkup -> counter_32k */
  1778. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__counter_32k = {
  1779. .master = &dra7xx_l4_wkup_hwmod,
  1780. .slave = &dra7xx_counter_32k_hwmod,
  1781. .clk = "wkupaon_iclk_mux",
  1782. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1783. };
  1784. /* l4_wkup -> ctrl_module_wkup */
  1785. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__ctrl_module_wkup = {
  1786. .master = &dra7xx_l4_wkup_hwmod,
  1787. .slave = &dra7xx_ctrl_module_wkup_hwmod,
  1788. .clk = "wkupaon_iclk_mux",
  1789. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1790. };
  1791. /* l4_wkup -> dcan1 */
  1792. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__dcan1 = {
  1793. .master = &dra7xx_l4_wkup_hwmod,
  1794. .slave = &dra7xx_dcan1_hwmod,
  1795. .clk = "wkupaon_iclk_mux",
  1796. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1797. };
  1798. /* l4_per2 -> dcan2 */
  1799. static struct omap_hwmod_ocp_if dra7xx_l4_per2__dcan2 = {
  1800. .master = &dra7xx_l4_per2_hwmod,
  1801. .slave = &dra7xx_dcan2_hwmod,
  1802. .clk = "l3_iclk_div",
  1803. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1804. };
  1805. static struct omap_hwmod_addr_space dra7xx_dma_system_addrs[] = {
  1806. {
  1807. .pa_start = 0x4a056000,
  1808. .pa_end = 0x4a056fff,
  1809. .flags = ADDR_TYPE_RT
  1810. },
  1811. { }
  1812. };
  1813. /* l4_cfg -> dma_system */
  1814. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__dma_system = {
  1815. .master = &dra7xx_l4_cfg_hwmod,
  1816. .slave = &dra7xx_dma_system_hwmod,
  1817. .clk = "l3_iclk_div",
  1818. .addr = dra7xx_dma_system_addrs,
  1819. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1820. };
  1821. static struct omap_hwmod_addr_space dra7xx_dss_addrs[] = {
  1822. {
  1823. .name = "family",
  1824. .pa_start = 0x58000000,
  1825. .pa_end = 0x5800007f,
  1826. .flags = ADDR_TYPE_RT
  1827. },
  1828. };
  1829. /* l3_main_1 -> dss */
  1830. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__dss = {
  1831. .master = &dra7xx_l3_main_1_hwmod,
  1832. .slave = &dra7xx_dss_hwmod,
  1833. .clk = "l3_iclk_div",
  1834. .addr = dra7xx_dss_addrs,
  1835. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1836. };
  1837. static struct omap_hwmod_addr_space dra7xx_dss_dispc_addrs[] = {
  1838. {
  1839. .name = "dispc",
  1840. .pa_start = 0x58001000,
  1841. .pa_end = 0x58001fff,
  1842. .flags = ADDR_TYPE_RT
  1843. },
  1844. };
  1845. /* l3_main_1 -> dispc */
  1846. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__dispc = {
  1847. .master = &dra7xx_l3_main_1_hwmod,
  1848. .slave = &dra7xx_dss_dispc_hwmod,
  1849. .clk = "l3_iclk_div",
  1850. .addr = dra7xx_dss_dispc_addrs,
  1851. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1852. };
  1853. static struct omap_hwmod_addr_space dra7xx_dss_hdmi_addrs[] = {
  1854. {
  1855. .name = "hdmi_wp",
  1856. .pa_start = 0x58040000,
  1857. .pa_end = 0x580400ff,
  1858. .flags = ADDR_TYPE_RT
  1859. },
  1860. { }
  1861. };
  1862. /* l3_main_1 -> dispc */
  1863. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__hdmi = {
  1864. .master = &dra7xx_l3_main_1_hwmod,
  1865. .slave = &dra7xx_dss_hdmi_hwmod,
  1866. .clk = "l3_iclk_div",
  1867. .addr = dra7xx_dss_hdmi_addrs,
  1868. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1869. };
  1870. static struct omap_hwmod_addr_space dra7xx_elm_addrs[] = {
  1871. {
  1872. .pa_start = 0x48078000,
  1873. .pa_end = 0x48078fff,
  1874. .flags = ADDR_TYPE_RT
  1875. },
  1876. { }
  1877. };
  1878. /* l4_per1 -> elm */
  1879. static struct omap_hwmod_ocp_if dra7xx_l4_per1__elm = {
  1880. .master = &dra7xx_l4_per1_hwmod,
  1881. .slave = &dra7xx_elm_hwmod,
  1882. .clk = "l3_iclk_div",
  1883. .addr = dra7xx_elm_addrs,
  1884. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1885. };
  1886. /* l4_wkup -> gpio1 */
  1887. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__gpio1 = {
  1888. .master = &dra7xx_l4_wkup_hwmod,
  1889. .slave = &dra7xx_gpio1_hwmod,
  1890. .clk = "wkupaon_iclk_mux",
  1891. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1892. };
  1893. /* l4_per1 -> gpio2 */
  1894. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio2 = {
  1895. .master = &dra7xx_l4_per1_hwmod,
  1896. .slave = &dra7xx_gpio2_hwmod,
  1897. .clk = "l3_iclk_div",
  1898. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1899. };
  1900. /* l4_per1 -> gpio3 */
  1901. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio3 = {
  1902. .master = &dra7xx_l4_per1_hwmod,
  1903. .slave = &dra7xx_gpio3_hwmod,
  1904. .clk = "l3_iclk_div",
  1905. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1906. };
  1907. /* l4_per1 -> gpio4 */
  1908. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio4 = {
  1909. .master = &dra7xx_l4_per1_hwmod,
  1910. .slave = &dra7xx_gpio4_hwmod,
  1911. .clk = "l3_iclk_div",
  1912. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1913. };
  1914. /* l4_per1 -> gpio5 */
  1915. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio5 = {
  1916. .master = &dra7xx_l4_per1_hwmod,
  1917. .slave = &dra7xx_gpio5_hwmod,
  1918. .clk = "l3_iclk_div",
  1919. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1920. };
  1921. /* l4_per1 -> gpio6 */
  1922. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio6 = {
  1923. .master = &dra7xx_l4_per1_hwmod,
  1924. .slave = &dra7xx_gpio6_hwmod,
  1925. .clk = "l3_iclk_div",
  1926. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1927. };
  1928. /* l4_per1 -> gpio7 */
  1929. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio7 = {
  1930. .master = &dra7xx_l4_per1_hwmod,
  1931. .slave = &dra7xx_gpio7_hwmod,
  1932. .clk = "l3_iclk_div",
  1933. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1934. };
  1935. /* l4_per1 -> gpio8 */
  1936. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio8 = {
  1937. .master = &dra7xx_l4_per1_hwmod,
  1938. .slave = &dra7xx_gpio8_hwmod,
  1939. .clk = "l3_iclk_div",
  1940. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1941. };
  1942. static struct omap_hwmod_addr_space dra7xx_gpmc_addrs[] = {
  1943. {
  1944. .pa_start = 0x50000000,
  1945. .pa_end = 0x500003ff,
  1946. .flags = ADDR_TYPE_RT
  1947. },
  1948. { }
  1949. };
  1950. /* l3_main_1 -> gpmc */
  1951. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__gpmc = {
  1952. .master = &dra7xx_l3_main_1_hwmod,
  1953. .slave = &dra7xx_gpmc_hwmod,
  1954. .clk = "l3_iclk_div",
  1955. .addr = dra7xx_gpmc_addrs,
  1956. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1957. };
  1958. static struct omap_hwmod_addr_space dra7xx_hdq1w_addrs[] = {
  1959. {
  1960. .pa_start = 0x480b2000,
  1961. .pa_end = 0x480b201f,
  1962. .flags = ADDR_TYPE_RT
  1963. },
  1964. { }
  1965. };
  1966. /* l4_per1 -> hdq1w */
  1967. static struct omap_hwmod_ocp_if dra7xx_l4_per1__hdq1w = {
  1968. .master = &dra7xx_l4_per1_hwmod,
  1969. .slave = &dra7xx_hdq1w_hwmod,
  1970. .clk = "l3_iclk_div",
  1971. .addr = dra7xx_hdq1w_addrs,
  1972. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1973. };
  1974. /* l4_per1 -> i2c1 */
  1975. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c1 = {
  1976. .master = &dra7xx_l4_per1_hwmod,
  1977. .slave = &dra7xx_i2c1_hwmod,
  1978. .clk = "l3_iclk_div",
  1979. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1980. };
  1981. /* l4_per1 -> i2c2 */
  1982. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c2 = {
  1983. .master = &dra7xx_l4_per1_hwmod,
  1984. .slave = &dra7xx_i2c2_hwmod,
  1985. .clk = "l3_iclk_div",
  1986. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1987. };
  1988. /* l4_per1 -> i2c3 */
  1989. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c3 = {
  1990. .master = &dra7xx_l4_per1_hwmod,
  1991. .slave = &dra7xx_i2c3_hwmod,
  1992. .clk = "l3_iclk_div",
  1993. .user = OCP_USER_MPU | OCP_USER_SDMA,
  1994. };
  1995. /* l4_per1 -> i2c4 */
  1996. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c4 = {
  1997. .master = &dra7xx_l4_per1_hwmod,
  1998. .slave = &dra7xx_i2c4_hwmod,
  1999. .clk = "l3_iclk_div",
  2000. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2001. };
  2002. /* l4_per1 -> i2c5 */
  2003. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c5 = {
  2004. .master = &dra7xx_l4_per1_hwmod,
  2005. .slave = &dra7xx_i2c5_hwmod,
  2006. .clk = "l3_iclk_div",
  2007. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2008. };
  2009. /* l4_per1 -> mcspi1 */
  2010. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi1 = {
  2011. .master = &dra7xx_l4_per1_hwmod,
  2012. .slave = &dra7xx_mcspi1_hwmod,
  2013. .clk = "l3_iclk_div",
  2014. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2015. };
  2016. /* l4_per1 -> mcspi2 */
  2017. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi2 = {
  2018. .master = &dra7xx_l4_per1_hwmod,
  2019. .slave = &dra7xx_mcspi2_hwmod,
  2020. .clk = "l3_iclk_div",
  2021. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2022. };
  2023. /* l4_per1 -> mcspi3 */
  2024. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi3 = {
  2025. .master = &dra7xx_l4_per1_hwmod,
  2026. .slave = &dra7xx_mcspi3_hwmod,
  2027. .clk = "l3_iclk_div",
  2028. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2029. };
  2030. /* l4_per1 -> mcspi4 */
  2031. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi4 = {
  2032. .master = &dra7xx_l4_per1_hwmod,
  2033. .slave = &dra7xx_mcspi4_hwmod,
  2034. .clk = "l3_iclk_div",
  2035. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2036. };
  2037. /* l4_per1 -> mmc1 */
  2038. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc1 = {
  2039. .master = &dra7xx_l4_per1_hwmod,
  2040. .slave = &dra7xx_mmc1_hwmod,
  2041. .clk = "l3_iclk_div",
  2042. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2043. };
  2044. /* l4_per1 -> mmc2 */
  2045. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc2 = {
  2046. .master = &dra7xx_l4_per1_hwmod,
  2047. .slave = &dra7xx_mmc2_hwmod,
  2048. .clk = "l3_iclk_div",
  2049. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2050. };
  2051. /* l4_per1 -> mmc3 */
  2052. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc3 = {
  2053. .master = &dra7xx_l4_per1_hwmod,
  2054. .slave = &dra7xx_mmc3_hwmod,
  2055. .clk = "l3_iclk_div",
  2056. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2057. };
  2058. /* l4_per1 -> mmc4 */
  2059. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc4 = {
  2060. .master = &dra7xx_l4_per1_hwmod,
  2061. .slave = &dra7xx_mmc4_hwmod,
  2062. .clk = "l3_iclk_div",
  2063. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2064. };
  2065. /* l4_cfg -> mpu */
  2066. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__mpu = {
  2067. .master = &dra7xx_l4_cfg_hwmod,
  2068. .slave = &dra7xx_mpu_hwmod,
  2069. .clk = "l3_iclk_div",
  2070. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2071. };
  2072. static struct omap_hwmod_addr_space dra7xx_ocp2scp1_addrs[] = {
  2073. {
  2074. .pa_start = 0x4a080000,
  2075. .pa_end = 0x4a08001f,
  2076. .flags = ADDR_TYPE_RT
  2077. },
  2078. { }
  2079. };
  2080. /* l4_cfg -> ocp2scp1 */
  2081. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__ocp2scp1 = {
  2082. .master = &dra7xx_l4_cfg_hwmod,
  2083. .slave = &dra7xx_ocp2scp1_hwmod,
  2084. .clk = "l4_root_clk_div",
  2085. .addr = dra7xx_ocp2scp1_addrs,
  2086. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2087. };
  2088. static struct omap_hwmod_addr_space dra7xx_qspi_addrs[] = {
  2089. {
  2090. .pa_start = 0x4b300000,
  2091. .pa_end = 0x4b30007f,
  2092. .flags = ADDR_TYPE_RT
  2093. },
  2094. { }
  2095. };
  2096. /* l3_main_1 -> qspi */
  2097. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__qspi = {
  2098. .master = &dra7xx_l3_main_1_hwmod,
  2099. .slave = &dra7xx_qspi_hwmod,
  2100. .clk = "l3_iclk_div",
  2101. .addr = dra7xx_qspi_addrs,
  2102. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2103. };
  2104. static struct omap_hwmod_addr_space dra7xx_sata_addrs[] = {
  2105. {
  2106. .name = "sysc",
  2107. .pa_start = 0x4a141100,
  2108. .pa_end = 0x4a141107,
  2109. .flags = ADDR_TYPE_RT
  2110. },
  2111. { }
  2112. };
  2113. /* l4_cfg -> sata */
  2114. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__sata = {
  2115. .master = &dra7xx_l4_cfg_hwmod,
  2116. .slave = &dra7xx_sata_hwmod,
  2117. .clk = "l3_iclk_div",
  2118. .addr = dra7xx_sata_addrs,
  2119. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2120. };
  2121. static struct omap_hwmod_addr_space dra7xx_smartreflex_core_addrs[] = {
  2122. {
  2123. .pa_start = 0x4a0dd000,
  2124. .pa_end = 0x4a0dd07f,
  2125. .flags = ADDR_TYPE_RT
  2126. },
  2127. { }
  2128. };
  2129. /* l4_cfg -> smartreflex_core */
  2130. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__smartreflex_core = {
  2131. .master = &dra7xx_l4_cfg_hwmod,
  2132. .slave = &dra7xx_smartreflex_core_hwmod,
  2133. .clk = "l4_root_clk_div",
  2134. .addr = dra7xx_smartreflex_core_addrs,
  2135. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2136. };
  2137. static struct omap_hwmod_addr_space dra7xx_smartreflex_mpu_addrs[] = {
  2138. {
  2139. .pa_start = 0x4a0d9000,
  2140. .pa_end = 0x4a0d907f,
  2141. .flags = ADDR_TYPE_RT
  2142. },
  2143. { }
  2144. };
  2145. /* l4_cfg -> smartreflex_mpu */
  2146. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__smartreflex_mpu = {
  2147. .master = &dra7xx_l4_cfg_hwmod,
  2148. .slave = &dra7xx_smartreflex_mpu_hwmod,
  2149. .clk = "l4_root_clk_div",
  2150. .addr = dra7xx_smartreflex_mpu_addrs,
  2151. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2152. };
  2153. static struct omap_hwmod_addr_space dra7xx_spinlock_addrs[] = {
  2154. {
  2155. .pa_start = 0x4a0f6000,
  2156. .pa_end = 0x4a0f6fff,
  2157. .flags = ADDR_TYPE_RT
  2158. },
  2159. { }
  2160. };
  2161. /* l4_cfg -> spinlock */
  2162. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__spinlock = {
  2163. .master = &dra7xx_l4_cfg_hwmod,
  2164. .slave = &dra7xx_spinlock_hwmod,
  2165. .clk = "l3_iclk_div",
  2166. .addr = dra7xx_spinlock_addrs,
  2167. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2168. };
  2169. /* l4_wkup -> timer1 */
  2170. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__timer1 = {
  2171. .master = &dra7xx_l4_wkup_hwmod,
  2172. .slave = &dra7xx_timer1_hwmod,
  2173. .clk = "wkupaon_iclk_mux",
  2174. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2175. };
  2176. /* l4_per1 -> timer2 */
  2177. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer2 = {
  2178. .master = &dra7xx_l4_per1_hwmod,
  2179. .slave = &dra7xx_timer2_hwmod,
  2180. .clk = "l3_iclk_div",
  2181. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2182. };
  2183. /* l4_per1 -> timer3 */
  2184. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer3 = {
  2185. .master = &dra7xx_l4_per1_hwmod,
  2186. .slave = &dra7xx_timer3_hwmod,
  2187. .clk = "l3_iclk_div",
  2188. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2189. };
  2190. /* l4_per1 -> timer4 */
  2191. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer4 = {
  2192. .master = &dra7xx_l4_per1_hwmod,
  2193. .slave = &dra7xx_timer4_hwmod,
  2194. .clk = "l3_iclk_div",
  2195. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2196. };
  2197. /* l4_per3 -> timer5 */
  2198. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer5 = {
  2199. .master = &dra7xx_l4_per3_hwmod,
  2200. .slave = &dra7xx_timer5_hwmod,
  2201. .clk = "l3_iclk_div",
  2202. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2203. };
  2204. /* l4_per3 -> timer6 */
  2205. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer6 = {
  2206. .master = &dra7xx_l4_per3_hwmod,
  2207. .slave = &dra7xx_timer6_hwmod,
  2208. .clk = "l3_iclk_div",
  2209. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2210. };
  2211. /* l4_per3 -> timer7 */
  2212. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer7 = {
  2213. .master = &dra7xx_l4_per3_hwmod,
  2214. .slave = &dra7xx_timer7_hwmod,
  2215. .clk = "l3_iclk_div",
  2216. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2217. };
  2218. /* l4_per3 -> timer8 */
  2219. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer8 = {
  2220. .master = &dra7xx_l4_per3_hwmod,
  2221. .slave = &dra7xx_timer8_hwmod,
  2222. .clk = "l3_iclk_div",
  2223. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2224. };
  2225. /* l4_per1 -> timer9 */
  2226. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer9 = {
  2227. .master = &dra7xx_l4_per1_hwmod,
  2228. .slave = &dra7xx_timer9_hwmod,
  2229. .clk = "l3_iclk_div",
  2230. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2231. };
  2232. /* l4_per1 -> timer10 */
  2233. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer10 = {
  2234. .master = &dra7xx_l4_per1_hwmod,
  2235. .slave = &dra7xx_timer10_hwmod,
  2236. .clk = "l3_iclk_div",
  2237. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2238. };
  2239. /* l4_per1 -> timer11 */
  2240. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer11 = {
  2241. .master = &dra7xx_l4_per1_hwmod,
  2242. .slave = &dra7xx_timer11_hwmod,
  2243. .clk = "l3_iclk_div",
  2244. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2245. };
  2246. /* l4_per1 -> uart1 */
  2247. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart1 = {
  2248. .master = &dra7xx_l4_per1_hwmod,
  2249. .slave = &dra7xx_uart1_hwmod,
  2250. .clk = "l3_iclk_div",
  2251. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2252. };
  2253. /* l4_per1 -> uart2 */
  2254. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart2 = {
  2255. .master = &dra7xx_l4_per1_hwmod,
  2256. .slave = &dra7xx_uart2_hwmod,
  2257. .clk = "l3_iclk_div",
  2258. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2259. };
  2260. /* l4_per1 -> uart3 */
  2261. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart3 = {
  2262. .master = &dra7xx_l4_per1_hwmod,
  2263. .slave = &dra7xx_uart3_hwmod,
  2264. .clk = "l3_iclk_div",
  2265. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2266. };
  2267. /* l4_per1 -> uart4 */
  2268. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart4 = {
  2269. .master = &dra7xx_l4_per1_hwmod,
  2270. .slave = &dra7xx_uart4_hwmod,
  2271. .clk = "l3_iclk_div",
  2272. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2273. };
  2274. /* l4_per1 -> uart5 */
  2275. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart5 = {
  2276. .master = &dra7xx_l4_per1_hwmod,
  2277. .slave = &dra7xx_uart5_hwmod,
  2278. .clk = "l3_iclk_div",
  2279. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2280. };
  2281. /* l4_per1 -> uart6 */
  2282. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart6 = {
  2283. .master = &dra7xx_l4_per1_hwmod,
  2284. .slave = &dra7xx_uart6_hwmod,
  2285. .clk = "l3_iclk_div",
  2286. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2287. };
  2288. /* l4_per3 -> usb_otg_ss1 */
  2289. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss1 = {
  2290. .master = &dra7xx_l4_per3_hwmod,
  2291. .slave = &dra7xx_usb_otg_ss1_hwmod,
  2292. .clk = "dpll_core_h13x2_ck",
  2293. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2294. };
  2295. /* l4_per3 -> usb_otg_ss2 */
  2296. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss2 = {
  2297. .master = &dra7xx_l4_per3_hwmod,
  2298. .slave = &dra7xx_usb_otg_ss2_hwmod,
  2299. .clk = "dpll_core_h13x2_ck",
  2300. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2301. };
  2302. /* l4_per3 -> usb_otg_ss3 */
  2303. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss3 = {
  2304. .master = &dra7xx_l4_per3_hwmod,
  2305. .slave = &dra7xx_usb_otg_ss3_hwmod,
  2306. .clk = "dpll_core_h13x2_ck",
  2307. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2308. };
  2309. /* l4_per3 -> usb_otg_ss4 */
  2310. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss4 = {
  2311. .master = &dra7xx_l4_per3_hwmod,
  2312. .slave = &dra7xx_usb_otg_ss4_hwmod,
  2313. .clk = "dpll_core_h13x2_ck",
  2314. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2315. };
  2316. /* l3_main_1 -> vcp1 */
  2317. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__vcp1 = {
  2318. .master = &dra7xx_l3_main_1_hwmod,
  2319. .slave = &dra7xx_vcp1_hwmod,
  2320. .clk = "l3_iclk_div",
  2321. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2322. };
  2323. /* l4_per2 -> vcp1 */
  2324. static struct omap_hwmod_ocp_if dra7xx_l4_per2__vcp1 = {
  2325. .master = &dra7xx_l4_per2_hwmod,
  2326. .slave = &dra7xx_vcp1_hwmod,
  2327. .clk = "l3_iclk_div",
  2328. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2329. };
  2330. /* l3_main_1 -> vcp2 */
  2331. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__vcp2 = {
  2332. .master = &dra7xx_l3_main_1_hwmod,
  2333. .slave = &dra7xx_vcp2_hwmod,
  2334. .clk = "l3_iclk_div",
  2335. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2336. };
  2337. /* l4_per2 -> vcp2 */
  2338. static struct omap_hwmod_ocp_if dra7xx_l4_per2__vcp2 = {
  2339. .master = &dra7xx_l4_per2_hwmod,
  2340. .slave = &dra7xx_vcp2_hwmod,
  2341. .clk = "l3_iclk_div",
  2342. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2343. };
  2344. /* l4_wkup -> wd_timer2 */
  2345. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__wd_timer2 = {
  2346. .master = &dra7xx_l4_wkup_hwmod,
  2347. .slave = &dra7xx_wd_timer2_hwmod,
  2348. .clk = "wkupaon_iclk_mux",
  2349. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2350. };
  2351. static struct omap_hwmod_ocp_if *dra7xx_hwmod_ocp_ifs[] __initdata = {
  2352. &dra7xx_l3_main_2__l3_instr,
  2353. &dra7xx_l4_cfg__l3_main_1,
  2354. &dra7xx_mpu__l3_main_1,
  2355. &dra7xx_l3_main_1__l3_main_2,
  2356. &dra7xx_l4_cfg__l3_main_2,
  2357. &dra7xx_l3_main_1__l4_cfg,
  2358. &dra7xx_l3_main_1__l4_per1,
  2359. &dra7xx_l3_main_1__l4_per2,
  2360. &dra7xx_l3_main_1__l4_per3,
  2361. &dra7xx_l3_main_1__l4_wkup,
  2362. &dra7xx_l4_per2__atl,
  2363. &dra7xx_l3_main_1__bb2d,
  2364. &dra7xx_l4_wkup__counter_32k,
  2365. &dra7xx_l4_wkup__ctrl_module_wkup,
  2366. &dra7xx_l4_wkup__dcan1,
  2367. &dra7xx_l4_per2__dcan2,
  2368. &dra7xx_l4_cfg__dma_system,
  2369. &dra7xx_l3_main_1__dss,
  2370. &dra7xx_l3_main_1__dispc,
  2371. &dra7xx_l3_main_1__hdmi,
  2372. &dra7xx_l4_per1__elm,
  2373. &dra7xx_l4_wkup__gpio1,
  2374. &dra7xx_l4_per1__gpio2,
  2375. &dra7xx_l4_per1__gpio3,
  2376. &dra7xx_l4_per1__gpio4,
  2377. &dra7xx_l4_per1__gpio5,
  2378. &dra7xx_l4_per1__gpio6,
  2379. &dra7xx_l4_per1__gpio7,
  2380. &dra7xx_l4_per1__gpio8,
  2381. &dra7xx_l3_main_1__gpmc,
  2382. &dra7xx_l4_per1__hdq1w,
  2383. &dra7xx_l4_per1__i2c1,
  2384. &dra7xx_l4_per1__i2c2,
  2385. &dra7xx_l4_per1__i2c3,
  2386. &dra7xx_l4_per1__i2c4,
  2387. &dra7xx_l4_per1__i2c5,
  2388. &dra7xx_l4_per1__mcspi1,
  2389. &dra7xx_l4_per1__mcspi2,
  2390. &dra7xx_l4_per1__mcspi3,
  2391. &dra7xx_l4_per1__mcspi4,
  2392. &dra7xx_l4_per1__mmc1,
  2393. &dra7xx_l4_per1__mmc2,
  2394. &dra7xx_l4_per1__mmc3,
  2395. &dra7xx_l4_per1__mmc4,
  2396. &dra7xx_l4_cfg__mpu,
  2397. &dra7xx_l4_cfg__ocp2scp1,
  2398. &dra7xx_l3_main_1__qspi,
  2399. &dra7xx_l4_cfg__sata,
  2400. &dra7xx_l4_cfg__smartreflex_core,
  2401. &dra7xx_l4_cfg__smartreflex_mpu,
  2402. &dra7xx_l4_cfg__spinlock,
  2403. &dra7xx_l4_wkup__timer1,
  2404. &dra7xx_l4_per1__timer2,
  2405. &dra7xx_l4_per1__timer3,
  2406. &dra7xx_l4_per1__timer4,
  2407. &dra7xx_l4_per3__timer5,
  2408. &dra7xx_l4_per3__timer6,
  2409. &dra7xx_l4_per3__timer7,
  2410. &dra7xx_l4_per3__timer8,
  2411. &dra7xx_l4_per1__timer9,
  2412. &dra7xx_l4_per1__timer10,
  2413. &dra7xx_l4_per1__timer11,
  2414. &dra7xx_l4_per1__uart1,
  2415. &dra7xx_l4_per1__uart2,
  2416. &dra7xx_l4_per1__uart3,
  2417. &dra7xx_l4_per1__uart4,
  2418. &dra7xx_l4_per1__uart5,
  2419. &dra7xx_l4_per1__uart6,
  2420. &dra7xx_l4_per3__usb_otg_ss1,
  2421. &dra7xx_l4_per3__usb_otg_ss2,
  2422. &dra7xx_l4_per3__usb_otg_ss3,
  2423. &dra7xx_l4_per3__usb_otg_ss4,
  2424. &dra7xx_l3_main_1__vcp1,
  2425. &dra7xx_l4_per2__vcp1,
  2426. &dra7xx_l3_main_1__vcp2,
  2427. &dra7xx_l4_per2__vcp2,
  2428. &dra7xx_l4_wkup__wd_timer2,
  2429. NULL,
  2430. };
  2431. int __init dra7xx_hwmod_init(void)
  2432. {
  2433. omap_hwmod_init();
  2434. return omap_hwmod_register_links(dra7xx_hwmod_ocp_ifs);
  2435. }