omap_hwmod_7xx_data.c 82 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341
  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/platform_data/hsmmc-omap.h>
  22. #include <linux/power/smartreflex.h>
  23. #include <linux/i2c-omap.h>
  24. #include <linux/omap-dma.h>
  25. #include <linux/platform_data/spi-omap2-mcspi.h>
  26. #include <linux/platform_data/asoc-ti-mcbsp.h>
  27. #include <plat/dmtimer.h>
  28. #include "omap_hwmod.h"
  29. #include "omap_hwmod_common_data.h"
  30. #include "cm1_7xx.h"
  31. #include "cm2_7xx.h"
  32. #include "prm7xx.h"
  33. #include "i2c.h"
  34. #include "wd_timer.h"
  35. #include "soc.h"
  36. /* Base offset for all DRA7XX interrupts external to MPUSS */
  37. #define DRA7XX_IRQ_GIC_START 32
  38. /* Base offset for all DRA7XX dma requests */
  39. #define DRA7XX_DMA_REQ_START 1
  40. /*
  41. * IP blocks
  42. */
  43. /*
  44. * 'l3' class
  45. * instance(s): l3_instr, l3_main_1, l3_main_2
  46. */
  47. static struct omap_hwmod_class dra7xx_l3_hwmod_class = {
  48. .name = "l3",
  49. };
  50. /* l3_instr */
  51. static struct omap_hwmod dra7xx_l3_instr_hwmod = {
  52. .name = "l3_instr",
  53. .class = &dra7xx_l3_hwmod_class,
  54. .clkdm_name = "l3instr_clkdm",
  55. .prcm = {
  56. .omap4 = {
  57. .clkctrl_offs = DRA7XX_CM_L3INSTR_L3_INSTR_CLKCTRL_OFFSET,
  58. .context_offs = DRA7XX_RM_L3INSTR_L3_INSTR_CONTEXT_OFFSET,
  59. .modulemode = MODULEMODE_HWCTRL,
  60. },
  61. },
  62. };
  63. /* l3_main_1 */
  64. static struct omap_hwmod dra7xx_l3_main_1_hwmod = {
  65. .name = "l3_main_1",
  66. .class = &dra7xx_l3_hwmod_class,
  67. .clkdm_name = "l3main1_clkdm",
  68. .prcm = {
  69. .omap4 = {
  70. .clkctrl_offs = DRA7XX_CM_L3MAIN1_L3_MAIN_1_CLKCTRL_OFFSET,
  71. .context_offs = DRA7XX_RM_L3MAIN1_L3_MAIN_1_CONTEXT_OFFSET,
  72. },
  73. },
  74. };
  75. /* l3_main_2 */
  76. static struct omap_hwmod dra7xx_l3_main_2_hwmod = {
  77. .name = "l3_main_2",
  78. .class = &dra7xx_l3_hwmod_class,
  79. .clkdm_name = "l3instr_clkdm",
  80. .prcm = {
  81. .omap4 = {
  82. .clkctrl_offs = DRA7XX_CM_L3INSTR_L3_MAIN_2_CLKCTRL_OFFSET,
  83. .context_offs = DRA7XX_RM_L3INSTR_L3_MAIN_2_CONTEXT_OFFSET,
  84. .modulemode = MODULEMODE_HWCTRL,
  85. },
  86. },
  87. };
  88. /*
  89. * 'l4' class
  90. * instance(s): l4_cfg, l4_per1, l4_per2, l4_per3, l4_wkup
  91. */
  92. static struct omap_hwmod_class dra7xx_l4_hwmod_class = {
  93. .name = "l4",
  94. };
  95. /* l4_cfg */
  96. static struct omap_hwmod dra7xx_l4_cfg_hwmod = {
  97. .name = "l4_cfg",
  98. .class = &dra7xx_l4_hwmod_class,
  99. .clkdm_name = "l4cfg_clkdm",
  100. .prcm = {
  101. .omap4 = {
  102. .clkctrl_offs = DRA7XX_CM_L4CFG_L4_CFG_CLKCTRL_OFFSET,
  103. .context_offs = DRA7XX_RM_L4CFG_L4_CFG_CONTEXT_OFFSET,
  104. },
  105. },
  106. };
  107. /* l4_per1 */
  108. static struct omap_hwmod dra7xx_l4_per1_hwmod = {
  109. .name = "l4_per1",
  110. .class = &dra7xx_l4_hwmod_class,
  111. .clkdm_name = "l4per_clkdm",
  112. .prcm = {
  113. .omap4 = {
  114. .clkctrl_offs = DRA7XX_CM_L4PER_L4_PER1_CLKCTRL_OFFSET,
  115. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  116. },
  117. },
  118. };
  119. /* l4_per2 */
  120. static struct omap_hwmod dra7xx_l4_per2_hwmod = {
  121. .name = "l4_per2",
  122. .class = &dra7xx_l4_hwmod_class,
  123. .clkdm_name = "l4per2_clkdm",
  124. .prcm = {
  125. .omap4 = {
  126. .clkctrl_offs = DRA7XX_CM_L4PER2_L4_PER2_CLKCTRL_OFFSET,
  127. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  128. },
  129. },
  130. };
  131. /* l4_per3 */
  132. static struct omap_hwmod dra7xx_l4_per3_hwmod = {
  133. .name = "l4_per3",
  134. .class = &dra7xx_l4_hwmod_class,
  135. .clkdm_name = "l4per3_clkdm",
  136. .prcm = {
  137. .omap4 = {
  138. .clkctrl_offs = DRA7XX_CM_L4PER3_L4_PER3_CLKCTRL_OFFSET,
  139. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  140. },
  141. },
  142. };
  143. /* l4_wkup */
  144. static struct omap_hwmod dra7xx_l4_wkup_hwmod = {
  145. .name = "l4_wkup",
  146. .class = &dra7xx_l4_hwmod_class,
  147. .clkdm_name = "wkupaon_clkdm",
  148. .prcm = {
  149. .omap4 = {
  150. .clkctrl_offs = DRA7XX_CM_WKUPAON_L4_WKUP_CLKCTRL_OFFSET,
  151. .context_offs = DRA7XX_RM_WKUPAON_L4_WKUP_CONTEXT_OFFSET,
  152. },
  153. },
  154. };
  155. /*
  156. * 'atl' class
  157. *
  158. */
  159. static struct omap_hwmod_class dra7xx_atl_hwmod_class = {
  160. .name = "atl",
  161. };
  162. /* atl */
  163. static struct omap_hwmod dra7xx_atl_hwmod = {
  164. .name = "atl",
  165. .class = &dra7xx_atl_hwmod_class,
  166. .clkdm_name = "atl_clkdm",
  167. .main_clk = "atl_gfclk_mux",
  168. .prcm = {
  169. .omap4 = {
  170. .clkctrl_offs = DRA7XX_CM_ATL_ATL_CLKCTRL_OFFSET,
  171. .context_offs = DRA7XX_RM_ATL_ATL_CONTEXT_OFFSET,
  172. .modulemode = MODULEMODE_SWCTRL,
  173. },
  174. },
  175. };
  176. /*
  177. * 'bb2d' class
  178. *
  179. */
  180. static struct omap_hwmod_class dra7xx_bb2d_hwmod_class = {
  181. .name = "bb2d",
  182. };
  183. /* bb2d */
  184. static struct omap_hwmod dra7xx_bb2d_hwmod = {
  185. .name = "bb2d",
  186. .class = &dra7xx_bb2d_hwmod_class,
  187. .clkdm_name = "dss_clkdm",
  188. .main_clk = "dpll_core_h24x2_ck",
  189. .prcm = {
  190. .omap4 = {
  191. .clkctrl_offs = DRA7XX_CM_DSS_BB2D_CLKCTRL_OFFSET,
  192. .context_offs = DRA7XX_RM_DSS_BB2D_CONTEXT_OFFSET,
  193. .modulemode = MODULEMODE_SWCTRL,
  194. },
  195. },
  196. };
  197. /*
  198. * 'counter' class
  199. *
  200. */
  201. static struct omap_hwmod_class_sysconfig dra7xx_counter_sysc = {
  202. .rev_offs = 0x0000,
  203. .sysc_offs = 0x0010,
  204. .sysc_flags = SYSC_HAS_SIDLEMODE,
  205. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  206. SIDLE_SMART_WKUP),
  207. .sysc_fields = &omap_hwmod_sysc_type1,
  208. };
  209. static struct omap_hwmod_class dra7xx_counter_hwmod_class = {
  210. .name = "counter",
  211. .sysc = &dra7xx_counter_sysc,
  212. };
  213. /* counter_32k */
  214. static struct omap_hwmod dra7xx_counter_32k_hwmod = {
  215. .name = "counter_32k",
  216. .class = &dra7xx_counter_hwmod_class,
  217. .clkdm_name = "wkupaon_clkdm",
  218. .flags = HWMOD_SWSUP_SIDLE,
  219. .main_clk = "wkupaon_iclk_mux",
  220. .prcm = {
  221. .omap4 = {
  222. .clkctrl_offs = DRA7XX_CM_WKUPAON_COUNTER_32K_CLKCTRL_OFFSET,
  223. .context_offs = DRA7XX_RM_WKUPAON_COUNTER_32K_CONTEXT_OFFSET,
  224. },
  225. },
  226. };
  227. /*
  228. * 'ctrl_module' class
  229. *
  230. */
  231. static struct omap_hwmod_class dra7xx_ctrl_module_hwmod_class = {
  232. .name = "ctrl_module",
  233. };
  234. /* ctrl_module_wkup */
  235. static struct omap_hwmod dra7xx_ctrl_module_wkup_hwmod = {
  236. .name = "ctrl_module_wkup",
  237. .class = &dra7xx_ctrl_module_hwmod_class,
  238. .clkdm_name = "wkupaon_clkdm",
  239. .prcm = {
  240. .omap4 = {
  241. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  242. },
  243. },
  244. };
  245. /*
  246. * 'gmac' class
  247. * cpsw/gmac sub system
  248. */
  249. static struct omap_hwmod_class_sysconfig dra7xx_gmac_sysc = {
  250. .rev_offs = 0x0,
  251. .sysc_offs = 0x8,
  252. .syss_offs = 0x4,
  253. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE |
  254. SYSS_HAS_RESET_STATUS),
  255. .idlemodes = (SIDLE_FORCE | SIDLE_NO | MSTANDBY_FORCE |
  256. MSTANDBY_NO),
  257. .sysc_fields = &omap_hwmod_sysc_type3,
  258. };
  259. static struct omap_hwmod_class dra7xx_gmac_hwmod_class = {
  260. .name = "gmac",
  261. .sysc = &dra7xx_gmac_sysc,
  262. };
  263. static struct omap_hwmod dra7xx_gmac_hwmod = {
  264. .name = "gmac",
  265. .class = &dra7xx_gmac_hwmod_class,
  266. .clkdm_name = "gmac_clkdm",
  267. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  268. .main_clk = "dpll_gmac_ck",
  269. .mpu_rt_idx = 1,
  270. .prcm = {
  271. .omap4 = {
  272. .clkctrl_offs = DRA7XX_CM_GMAC_GMAC_CLKCTRL_OFFSET,
  273. .context_offs = DRA7XX_RM_GMAC_GMAC_CONTEXT_OFFSET,
  274. .modulemode = MODULEMODE_SWCTRL,
  275. },
  276. },
  277. };
  278. /*
  279. * 'mdio' class
  280. */
  281. static struct omap_hwmod_class dra7xx_mdio_hwmod_class = {
  282. .name = "davinci_mdio",
  283. };
  284. static struct omap_hwmod dra7xx_mdio_hwmod = {
  285. .name = "davinci_mdio",
  286. .class = &dra7xx_mdio_hwmod_class,
  287. .clkdm_name = "gmac_clkdm",
  288. .main_clk = "dpll_gmac_ck",
  289. };
  290. /*
  291. * 'dcan' class
  292. *
  293. */
  294. static struct omap_hwmod_class dra7xx_dcan_hwmod_class = {
  295. .name = "dcan",
  296. };
  297. /* dcan1 */
  298. static struct omap_hwmod dra7xx_dcan1_hwmod = {
  299. .name = "dcan1",
  300. .class = &dra7xx_dcan_hwmod_class,
  301. .clkdm_name = "wkupaon_clkdm",
  302. .main_clk = "dcan1_sys_clk_mux",
  303. .prcm = {
  304. .omap4 = {
  305. .clkctrl_offs = DRA7XX_CM_WKUPAON_DCAN1_CLKCTRL_OFFSET,
  306. .context_offs = DRA7XX_RM_WKUPAON_DCAN1_CONTEXT_OFFSET,
  307. .modulemode = MODULEMODE_SWCTRL,
  308. },
  309. },
  310. };
  311. /* dcan2 */
  312. static struct omap_hwmod dra7xx_dcan2_hwmod = {
  313. .name = "dcan2",
  314. .class = &dra7xx_dcan_hwmod_class,
  315. .clkdm_name = "l4per2_clkdm",
  316. .main_clk = "sys_clkin1",
  317. .prcm = {
  318. .omap4 = {
  319. .clkctrl_offs = DRA7XX_CM_L4PER2_DCAN2_CLKCTRL_OFFSET,
  320. .context_offs = DRA7XX_RM_L4PER2_DCAN2_CONTEXT_OFFSET,
  321. .modulemode = MODULEMODE_SWCTRL,
  322. },
  323. },
  324. };
  325. /*
  326. * 'dma' class
  327. *
  328. */
  329. static struct omap_hwmod_class_sysconfig dra7xx_dma_sysc = {
  330. .rev_offs = 0x0000,
  331. .sysc_offs = 0x002c,
  332. .syss_offs = 0x0028,
  333. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  334. SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
  335. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  336. SYSS_HAS_RESET_STATUS),
  337. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  338. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  339. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  340. .sysc_fields = &omap_hwmod_sysc_type1,
  341. };
  342. static struct omap_hwmod_class dra7xx_dma_hwmod_class = {
  343. .name = "dma",
  344. .sysc = &dra7xx_dma_sysc,
  345. };
  346. /* dma dev_attr */
  347. static struct omap_dma_dev_attr dma_dev_attr = {
  348. .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY |
  349. IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY,
  350. .lch_count = 32,
  351. };
  352. /* dma_system */
  353. static struct omap_hwmod dra7xx_dma_system_hwmod = {
  354. .name = "dma_system",
  355. .class = &dra7xx_dma_hwmod_class,
  356. .clkdm_name = "dma_clkdm",
  357. .main_clk = "l3_iclk_div",
  358. .prcm = {
  359. .omap4 = {
  360. .clkctrl_offs = DRA7XX_CM_DMA_DMA_SYSTEM_CLKCTRL_OFFSET,
  361. .context_offs = DRA7XX_RM_DMA_DMA_SYSTEM_CONTEXT_OFFSET,
  362. },
  363. },
  364. .dev_attr = &dma_dev_attr,
  365. };
  366. /*
  367. * 'dss' class
  368. *
  369. */
  370. static struct omap_hwmod_class_sysconfig dra7xx_dss_sysc = {
  371. .rev_offs = 0x0000,
  372. .syss_offs = 0x0014,
  373. .sysc_flags = SYSS_HAS_RESET_STATUS,
  374. };
  375. static struct omap_hwmod_class dra7xx_dss_hwmod_class = {
  376. .name = "dss",
  377. .sysc = &dra7xx_dss_sysc,
  378. .reset = omap_dss_reset,
  379. };
  380. /* dss */
  381. static struct omap_hwmod_dma_info dra7xx_dss_sdma_reqs[] = {
  382. { .dma_req = 75 + DRA7XX_DMA_REQ_START },
  383. { .dma_req = -1 }
  384. };
  385. static struct omap_hwmod_opt_clk dss_opt_clks[] = {
  386. { .role = "dss_clk", .clk = "dss_dss_clk" },
  387. { .role = "hdmi_phy_clk", .clk = "dss_48mhz_clk" },
  388. { .role = "32khz_clk", .clk = "dss_32khz_clk" },
  389. { .role = "video2_clk", .clk = "dss_video2_clk" },
  390. { .role = "video1_clk", .clk = "dss_video1_clk" },
  391. { .role = "hdmi_clk", .clk = "dss_hdmi_clk" },
  392. };
  393. static struct omap_hwmod dra7xx_dss_hwmod = {
  394. .name = "dss_core",
  395. .class = &dra7xx_dss_hwmod_class,
  396. .clkdm_name = "dss_clkdm",
  397. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  398. .sdma_reqs = dra7xx_dss_sdma_reqs,
  399. .main_clk = "dss_dss_clk",
  400. .prcm = {
  401. .omap4 = {
  402. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  403. .context_offs = DRA7XX_RM_DSS_DSS_CONTEXT_OFFSET,
  404. .modulemode = MODULEMODE_SWCTRL,
  405. },
  406. },
  407. .opt_clks = dss_opt_clks,
  408. .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
  409. };
  410. /*
  411. * 'dispc' class
  412. * display controller
  413. */
  414. static struct omap_hwmod_class_sysconfig dra7xx_dispc_sysc = {
  415. .rev_offs = 0x0000,
  416. .sysc_offs = 0x0010,
  417. .syss_offs = 0x0014,
  418. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  419. SYSC_HAS_ENAWAKEUP | SYSC_HAS_MIDLEMODE |
  420. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  421. SYSS_HAS_RESET_STATUS),
  422. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  423. MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
  424. .sysc_fields = &omap_hwmod_sysc_type1,
  425. };
  426. static struct omap_hwmod_class dra7xx_dispc_hwmod_class = {
  427. .name = "dispc",
  428. .sysc = &dra7xx_dispc_sysc,
  429. };
  430. /* dss_dispc */
  431. /* dss_dispc dev_attr */
  432. static struct omap_dss_dispc_dev_attr dss_dispc_dev_attr = {
  433. .has_framedonetv_irq = 1,
  434. .manager_count = 4,
  435. };
  436. static struct omap_hwmod dra7xx_dss_dispc_hwmod = {
  437. .name = "dss_dispc",
  438. .class = &dra7xx_dispc_hwmod_class,
  439. .clkdm_name = "dss_clkdm",
  440. .main_clk = "dss_dss_clk",
  441. .prcm = {
  442. .omap4 = {
  443. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  444. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  445. },
  446. },
  447. .dev_attr = &dss_dispc_dev_attr,
  448. };
  449. /*
  450. * 'hdmi' class
  451. * hdmi controller
  452. */
  453. static struct omap_hwmod_class_sysconfig dra7xx_hdmi_sysc = {
  454. .rev_offs = 0x0000,
  455. .sysc_offs = 0x0010,
  456. .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  457. SYSC_HAS_SOFTRESET),
  458. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  459. SIDLE_SMART_WKUP),
  460. .sysc_fields = &omap_hwmod_sysc_type2,
  461. };
  462. static struct omap_hwmod_class dra7xx_hdmi_hwmod_class = {
  463. .name = "hdmi",
  464. .sysc = &dra7xx_hdmi_sysc,
  465. };
  466. /* dss_hdmi */
  467. static struct omap_hwmod_opt_clk dss_hdmi_opt_clks[] = {
  468. { .role = "sys_clk", .clk = "dss_hdmi_clk" },
  469. };
  470. static struct omap_hwmod dra7xx_dss_hdmi_hwmod = {
  471. .name = "dss_hdmi",
  472. .class = &dra7xx_hdmi_hwmod_class,
  473. .clkdm_name = "dss_clkdm",
  474. .main_clk = "dss_48mhz_clk",
  475. .prcm = {
  476. .omap4 = {
  477. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  478. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  479. },
  480. },
  481. .opt_clks = dss_hdmi_opt_clks,
  482. .opt_clks_cnt = ARRAY_SIZE(dss_hdmi_opt_clks),
  483. };
  484. /*
  485. * 'elm' class
  486. *
  487. */
  488. static struct omap_hwmod_class_sysconfig dra7xx_elm_sysc = {
  489. .rev_offs = 0x0000,
  490. .sysc_offs = 0x0010,
  491. .syss_offs = 0x0014,
  492. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  493. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  494. SYSS_HAS_RESET_STATUS),
  495. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  496. SIDLE_SMART_WKUP),
  497. .sysc_fields = &omap_hwmod_sysc_type1,
  498. };
  499. static struct omap_hwmod_class dra7xx_elm_hwmod_class = {
  500. .name = "elm",
  501. .sysc = &dra7xx_elm_sysc,
  502. };
  503. /* elm */
  504. static struct omap_hwmod dra7xx_elm_hwmod = {
  505. .name = "elm",
  506. .class = &dra7xx_elm_hwmod_class,
  507. .clkdm_name = "l4per_clkdm",
  508. .main_clk = "l3_iclk_div",
  509. .prcm = {
  510. .omap4 = {
  511. .clkctrl_offs = DRA7XX_CM_L4PER_ELM_CLKCTRL_OFFSET,
  512. .context_offs = DRA7XX_RM_L4PER_ELM_CONTEXT_OFFSET,
  513. },
  514. },
  515. };
  516. /*
  517. * 'gpio' class
  518. *
  519. */
  520. static struct omap_hwmod_class_sysconfig dra7xx_gpio_sysc = {
  521. .rev_offs = 0x0000,
  522. .sysc_offs = 0x0010,
  523. .syss_offs = 0x0114,
  524. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  525. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  526. SYSS_HAS_RESET_STATUS),
  527. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  528. SIDLE_SMART_WKUP),
  529. .sysc_fields = &omap_hwmod_sysc_type1,
  530. };
  531. static struct omap_hwmod_class dra7xx_gpio_hwmod_class = {
  532. .name = "gpio",
  533. .sysc = &dra7xx_gpio_sysc,
  534. .rev = 2,
  535. };
  536. /* gpio dev_attr */
  537. static struct omap_gpio_dev_attr gpio_dev_attr = {
  538. .bank_width = 32,
  539. .dbck_flag = true,
  540. };
  541. /* gpio1 */
  542. static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
  543. { .role = "dbclk", .clk = "gpio1_dbclk" },
  544. };
  545. static struct omap_hwmod dra7xx_gpio1_hwmod = {
  546. .name = "gpio1",
  547. .class = &dra7xx_gpio_hwmod_class,
  548. .clkdm_name = "wkupaon_clkdm",
  549. .main_clk = "wkupaon_iclk_mux",
  550. .prcm = {
  551. .omap4 = {
  552. .clkctrl_offs = DRA7XX_CM_WKUPAON_GPIO1_CLKCTRL_OFFSET,
  553. .context_offs = DRA7XX_RM_WKUPAON_GPIO1_CONTEXT_OFFSET,
  554. .modulemode = MODULEMODE_HWCTRL,
  555. },
  556. },
  557. .opt_clks = gpio1_opt_clks,
  558. .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
  559. .dev_attr = &gpio_dev_attr,
  560. };
  561. /* gpio2 */
  562. static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
  563. { .role = "dbclk", .clk = "gpio2_dbclk" },
  564. };
  565. static struct omap_hwmod dra7xx_gpio2_hwmod = {
  566. .name = "gpio2",
  567. .class = &dra7xx_gpio_hwmod_class,
  568. .clkdm_name = "l4per_clkdm",
  569. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  570. .main_clk = "l3_iclk_div",
  571. .prcm = {
  572. .omap4 = {
  573. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO2_CLKCTRL_OFFSET,
  574. .context_offs = DRA7XX_RM_L4PER_GPIO2_CONTEXT_OFFSET,
  575. .modulemode = MODULEMODE_HWCTRL,
  576. },
  577. },
  578. .opt_clks = gpio2_opt_clks,
  579. .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
  580. .dev_attr = &gpio_dev_attr,
  581. };
  582. /* gpio3 */
  583. static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
  584. { .role = "dbclk", .clk = "gpio3_dbclk" },
  585. };
  586. static struct omap_hwmod dra7xx_gpio3_hwmod = {
  587. .name = "gpio3",
  588. .class = &dra7xx_gpio_hwmod_class,
  589. .clkdm_name = "l4per_clkdm",
  590. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  591. .main_clk = "l3_iclk_div",
  592. .prcm = {
  593. .omap4 = {
  594. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO3_CLKCTRL_OFFSET,
  595. .context_offs = DRA7XX_RM_L4PER_GPIO3_CONTEXT_OFFSET,
  596. .modulemode = MODULEMODE_HWCTRL,
  597. },
  598. },
  599. .opt_clks = gpio3_opt_clks,
  600. .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
  601. .dev_attr = &gpio_dev_attr,
  602. };
  603. /* gpio4 */
  604. static struct omap_hwmod_opt_clk gpio4_opt_clks[] = {
  605. { .role = "dbclk", .clk = "gpio4_dbclk" },
  606. };
  607. static struct omap_hwmod dra7xx_gpio4_hwmod = {
  608. .name = "gpio4",
  609. .class = &dra7xx_gpio_hwmod_class,
  610. .clkdm_name = "l4per_clkdm",
  611. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  612. .main_clk = "l3_iclk_div",
  613. .prcm = {
  614. .omap4 = {
  615. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO4_CLKCTRL_OFFSET,
  616. .context_offs = DRA7XX_RM_L4PER_GPIO4_CONTEXT_OFFSET,
  617. .modulemode = MODULEMODE_HWCTRL,
  618. },
  619. },
  620. .opt_clks = gpio4_opt_clks,
  621. .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks),
  622. .dev_attr = &gpio_dev_attr,
  623. };
  624. /* gpio5 */
  625. static struct omap_hwmod_opt_clk gpio5_opt_clks[] = {
  626. { .role = "dbclk", .clk = "gpio5_dbclk" },
  627. };
  628. static struct omap_hwmod dra7xx_gpio5_hwmod = {
  629. .name = "gpio5",
  630. .class = &dra7xx_gpio_hwmod_class,
  631. .clkdm_name = "l4per_clkdm",
  632. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  633. .main_clk = "l3_iclk_div",
  634. .prcm = {
  635. .omap4 = {
  636. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO5_CLKCTRL_OFFSET,
  637. .context_offs = DRA7XX_RM_L4PER_GPIO5_CONTEXT_OFFSET,
  638. .modulemode = MODULEMODE_HWCTRL,
  639. },
  640. },
  641. .opt_clks = gpio5_opt_clks,
  642. .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks),
  643. .dev_attr = &gpio_dev_attr,
  644. };
  645. /* gpio6 */
  646. static struct omap_hwmod_opt_clk gpio6_opt_clks[] = {
  647. { .role = "dbclk", .clk = "gpio6_dbclk" },
  648. };
  649. static struct omap_hwmod dra7xx_gpio6_hwmod = {
  650. .name = "gpio6",
  651. .class = &dra7xx_gpio_hwmod_class,
  652. .clkdm_name = "l4per_clkdm",
  653. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  654. .main_clk = "l3_iclk_div",
  655. .prcm = {
  656. .omap4 = {
  657. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO6_CLKCTRL_OFFSET,
  658. .context_offs = DRA7XX_RM_L4PER_GPIO6_CONTEXT_OFFSET,
  659. .modulemode = MODULEMODE_HWCTRL,
  660. },
  661. },
  662. .opt_clks = gpio6_opt_clks,
  663. .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks),
  664. .dev_attr = &gpio_dev_attr,
  665. };
  666. /* gpio7 */
  667. static struct omap_hwmod_opt_clk gpio7_opt_clks[] = {
  668. { .role = "dbclk", .clk = "gpio7_dbclk" },
  669. };
  670. static struct omap_hwmod dra7xx_gpio7_hwmod = {
  671. .name = "gpio7",
  672. .class = &dra7xx_gpio_hwmod_class,
  673. .clkdm_name = "l4per_clkdm",
  674. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  675. .main_clk = "l3_iclk_div",
  676. .prcm = {
  677. .omap4 = {
  678. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO7_CLKCTRL_OFFSET,
  679. .context_offs = DRA7XX_RM_L4PER_GPIO7_CONTEXT_OFFSET,
  680. .modulemode = MODULEMODE_HWCTRL,
  681. },
  682. },
  683. .opt_clks = gpio7_opt_clks,
  684. .opt_clks_cnt = ARRAY_SIZE(gpio7_opt_clks),
  685. .dev_attr = &gpio_dev_attr,
  686. };
  687. /* gpio8 */
  688. static struct omap_hwmod_opt_clk gpio8_opt_clks[] = {
  689. { .role = "dbclk", .clk = "gpio8_dbclk" },
  690. };
  691. static struct omap_hwmod dra7xx_gpio8_hwmod = {
  692. .name = "gpio8",
  693. .class = &dra7xx_gpio_hwmod_class,
  694. .clkdm_name = "l4per_clkdm",
  695. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  696. .main_clk = "l3_iclk_div",
  697. .prcm = {
  698. .omap4 = {
  699. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO8_CLKCTRL_OFFSET,
  700. .context_offs = DRA7XX_RM_L4PER_GPIO8_CONTEXT_OFFSET,
  701. .modulemode = MODULEMODE_HWCTRL,
  702. },
  703. },
  704. .opt_clks = gpio8_opt_clks,
  705. .opt_clks_cnt = ARRAY_SIZE(gpio8_opt_clks),
  706. .dev_attr = &gpio_dev_attr,
  707. };
  708. /*
  709. * 'gpmc' class
  710. *
  711. */
  712. static struct omap_hwmod_class_sysconfig dra7xx_gpmc_sysc = {
  713. .rev_offs = 0x0000,
  714. .sysc_offs = 0x0010,
  715. .syss_offs = 0x0014,
  716. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
  717. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  718. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  719. SIDLE_SMART_WKUP),
  720. .sysc_fields = &omap_hwmod_sysc_type1,
  721. };
  722. static struct omap_hwmod_class dra7xx_gpmc_hwmod_class = {
  723. .name = "gpmc",
  724. .sysc = &dra7xx_gpmc_sysc,
  725. };
  726. /* gpmc */
  727. static struct omap_hwmod dra7xx_gpmc_hwmod = {
  728. .name = "gpmc",
  729. .class = &dra7xx_gpmc_hwmod_class,
  730. .clkdm_name = "l3main1_clkdm",
  731. .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET |
  732. HWMOD_SWSUP_SIDLE),
  733. .main_clk = "l3_iclk_div",
  734. .prcm = {
  735. .omap4 = {
  736. .clkctrl_offs = DRA7XX_CM_L3MAIN1_GPMC_CLKCTRL_OFFSET,
  737. .context_offs = DRA7XX_RM_L3MAIN1_GPMC_CONTEXT_OFFSET,
  738. .modulemode = MODULEMODE_HWCTRL,
  739. },
  740. },
  741. };
  742. /*
  743. * 'hdq1w' class
  744. *
  745. */
  746. static struct omap_hwmod_class_sysconfig dra7xx_hdq1w_sysc = {
  747. .rev_offs = 0x0000,
  748. .sysc_offs = 0x0014,
  749. .syss_offs = 0x0018,
  750. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SOFTRESET |
  751. SYSS_HAS_RESET_STATUS),
  752. .sysc_fields = &omap_hwmod_sysc_type1,
  753. };
  754. static struct omap_hwmod_class dra7xx_hdq1w_hwmod_class = {
  755. .name = "hdq1w",
  756. .sysc = &dra7xx_hdq1w_sysc,
  757. };
  758. /* hdq1w */
  759. static struct omap_hwmod dra7xx_hdq1w_hwmod = {
  760. .name = "hdq1w",
  761. .class = &dra7xx_hdq1w_hwmod_class,
  762. .clkdm_name = "l4per_clkdm",
  763. .flags = HWMOD_INIT_NO_RESET,
  764. .main_clk = "func_12m_fclk",
  765. .prcm = {
  766. .omap4 = {
  767. .clkctrl_offs = DRA7XX_CM_L4PER_HDQ1W_CLKCTRL_OFFSET,
  768. .context_offs = DRA7XX_RM_L4PER_HDQ1W_CONTEXT_OFFSET,
  769. .modulemode = MODULEMODE_SWCTRL,
  770. },
  771. },
  772. };
  773. /*
  774. * 'i2c' class
  775. *
  776. */
  777. static struct omap_hwmod_class_sysconfig dra7xx_i2c_sysc = {
  778. .sysc_offs = 0x0010,
  779. .syss_offs = 0x0090,
  780. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  781. SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
  782. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  783. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  784. SIDLE_SMART_WKUP),
  785. .clockact = CLOCKACT_TEST_ICLK,
  786. .sysc_fields = &omap_hwmod_sysc_type1,
  787. };
  788. static struct omap_hwmod_class dra7xx_i2c_hwmod_class = {
  789. .name = "i2c",
  790. .sysc = &dra7xx_i2c_sysc,
  791. .reset = &omap_i2c_reset,
  792. .rev = OMAP_I2C_IP_VERSION_2,
  793. };
  794. /* i2c dev_attr */
  795. static struct omap_i2c_dev_attr i2c_dev_attr = {
  796. .flags = OMAP_I2C_FLAG_BUS_SHIFT_NONE,
  797. };
  798. /* i2c1 */
  799. static struct omap_hwmod dra7xx_i2c1_hwmod = {
  800. .name = "i2c1",
  801. .class = &dra7xx_i2c_hwmod_class,
  802. .clkdm_name = "l4per_clkdm",
  803. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  804. .main_clk = "func_96m_fclk",
  805. .prcm = {
  806. .omap4 = {
  807. .clkctrl_offs = DRA7XX_CM_L4PER_I2C1_CLKCTRL_OFFSET,
  808. .context_offs = DRA7XX_RM_L4PER_I2C1_CONTEXT_OFFSET,
  809. .modulemode = MODULEMODE_SWCTRL,
  810. },
  811. },
  812. .dev_attr = &i2c_dev_attr,
  813. };
  814. /* i2c2 */
  815. static struct omap_hwmod dra7xx_i2c2_hwmod = {
  816. .name = "i2c2",
  817. .class = &dra7xx_i2c_hwmod_class,
  818. .clkdm_name = "l4per_clkdm",
  819. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  820. .main_clk = "func_96m_fclk",
  821. .prcm = {
  822. .omap4 = {
  823. .clkctrl_offs = DRA7XX_CM_L4PER_I2C2_CLKCTRL_OFFSET,
  824. .context_offs = DRA7XX_RM_L4PER_I2C2_CONTEXT_OFFSET,
  825. .modulemode = MODULEMODE_SWCTRL,
  826. },
  827. },
  828. .dev_attr = &i2c_dev_attr,
  829. };
  830. /* i2c3 */
  831. static struct omap_hwmod dra7xx_i2c3_hwmod = {
  832. .name = "i2c3",
  833. .class = &dra7xx_i2c_hwmod_class,
  834. .clkdm_name = "l4per_clkdm",
  835. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  836. .main_clk = "func_96m_fclk",
  837. .prcm = {
  838. .omap4 = {
  839. .clkctrl_offs = DRA7XX_CM_L4PER_I2C3_CLKCTRL_OFFSET,
  840. .context_offs = DRA7XX_RM_L4PER_I2C3_CONTEXT_OFFSET,
  841. .modulemode = MODULEMODE_SWCTRL,
  842. },
  843. },
  844. .dev_attr = &i2c_dev_attr,
  845. };
  846. /* i2c4 */
  847. static struct omap_hwmod dra7xx_i2c4_hwmod = {
  848. .name = "i2c4",
  849. .class = &dra7xx_i2c_hwmod_class,
  850. .clkdm_name = "l4per_clkdm",
  851. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  852. .main_clk = "func_96m_fclk",
  853. .prcm = {
  854. .omap4 = {
  855. .clkctrl_offs = DRA7XX_CM_L4PER_I2C4_CLKCTRL_OFFSET,
  856. .context_offs = DRA7XX_RM_L4PER_I2C4_CONTEXT_OFFSET,
  857. .modulemode = MODULEMODE_SWCTRL,
  858. },
  859. },
  860. .dev_attr = &i2c_dev_attr,
  861. };
  862. /* i2c5 */
  863. static struct omap_hwmod dra7xx_i2c5_hwmod = {
  864. .name = "i2c5",
  865. .class = &dra7xx_i2c_hwmod_class,
  866. .clkdm_name = "ipu_clkdm",
  867. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  868. .main_clk = "func_96m_fclk",
  869. .prcm = {
  870. .omap4 = {
  871. .clkctrl_offs = DRA7XX_CM_IPU_I2C5_CLKCTRL_OFFSET,
  872. .context_offs = DRA7XX_RM_IPU_I2C5_CONTEXT_OFFSET,
  873. .modulemode = MODULEMODE_SWCTRL,
  874. },
  875. },
  876. .dev_attr = &i2c_dev_attr,
  877. };
  878. /*
  879. * 'mailbox' class
  880. *
  881. */
  882. static struct omap_hwmod_class_sysconfig dra7xx_mailbox_sysc = {
  883. .rev_offs = 0x0000,
  884. .sysc_offs = 0x0010,
  885. .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  886. SYSC_HAS_SOFTRESET),
  887. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  888. .sysc_fields = &omap_hwmod_sysc_type2,
  889. };
  890. static struct omap_hwmod_class dra7xx_mailbox_hwmod_class = {
  891. .name = "mailbox",
  892. .sysc = &dra7xx_mailbox_sysc,
  893. };
  894. /* mailbox1 */
  895. static struct omap_hwmod dra7xx_mailbox1_hwmod = {
  896. .name = "mailbox1",
  897. .class = &dra7xx_mailbox_hwmod_class,
  898. .clkdm_name = "l4cfg_clkdm",
  899. .prcm = {
  900. .omap4 = {
  901. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX1_CLKCTRL_OFFSET,
  902. .context_offs = DRA7XX_RM_L4CFG_MAILBOX1_CONTEXT_OFFSET,
  903. },
  904. },
  905. };
  906. /* mailbox2 */
  907. static struct omap_hwmod dra7xx_mailbox2_hwmod = {
  908. .name = "mailbox2",
  909. .class = &dra7xx_mailbox_hwmod_class,
  910. .clkdm_name = "l4cfg_clkdm",
  911. .prcm = {
  912. .omap4 = {
  913. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX2_CLKCTRL_OFFSET,
  914. .context_offs = DRA7XX_RM_L4CFG_MAILBOX2_CONTEXT_OFFSET,
  915. },
  916. },
  917. };
  918. /* mailbox3 */
  919. static struct omap_hwmod dra7xx_mailbox3_hwmod = {
  920. .name = "mailbox3",
  921. .class = &dra7xx_mailbox_hwmod_class,
  922. .clkdm_name = "l4cfg_clkdm",
  923. .prcm = {
  924. .omap4 = {
  925. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX3_CLKCTRL_OFFSET,
  926. .context_offs = DRA7XX_RM_L4CFG_MAILBOX3_CONTEXT_OFFSET,
  927. },
  928. },
  929. };
  930. /* mailbox4 */
  931. static struct omap_hwmod dra7xx_mailbox4_hwmod = {
  932. .name = "mailbox4",
  933. .class = &dra7xx_mailbox_hwmod_class,
  934. .clkdm_name = "l4cfg_clkdm",
  935. .prcm = {
  936. .omap4 = {
  937. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX4_CLKCTRL_OFFSET,
  938. .context_offs = DRA7XX_RM_L4CFG_MAILBOX4_CONTEXT_OFFSET,
  939. },
  940. },
  941. };
  942. /* mailbox5 */
  943. static struct omap_hwmod dra7xx_mailbox5_hwmod = {
  944. .name = "mailbox5",
  945. .class = &dra7xx_mailbox_hwmod_class,
  946. .clkdm_name = "l4cfg_clkdm",
  947. .prcm = {
  948. .omap4 = {
  949. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX5_CLKCTRL_OFFSET,
  950. .context_offs = DRA7XX_RM_L4CFG_MAILBOX5_CONTEXT_OFFSET,
  951. },
  952. },
  953. };
  954. /* mailbox6 */
  955. static struct omap_hwmod dra7xx_mailbox6_hwmod = {
  956. .name = "mailbox6",
  957. .class = &dra7xx_mailbox_hwmod_class,
  958. .clkdm_name = "l4cfg_clkdm",
  959. .prcm = {
  960. .omap4 = {
  961. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX6_CLKCTRL_OFFSET,
  962. .context_offs = DRA7XX_RM_L4CFG_MAILBOX6_CONTEXT_OFFSET,
  963. },
  964. },
  965. };
  966. /* mailbox7 */
  967. static struct omap_hwmod dra7xx_mailbox7_hwmod = {
  968. .name = "mailbox7",
  969. .class = &dra7xx_mailbox_hwmod_class,
  970. .clkdm_name = "l4cfg_clkdm",
  971. .prcm = {
  972. .omap4 = {
  973. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX7_CLKCTRL_OFFSET,
  974. .context_offs = DRA7XX_RM_L4CFG_MAILBOX7_CONTEXT_OFFSET,
  975. },
  976. },
  977. };
  978. /* mailbox8 */
  979. static struct omap_hwmod dra7xx_mailbox8_hwmod = {
  980. .name = "mailbox8",
  981. .class = &dra7xx_mailbox_hwmod_class,
  982. .clkdm_name = "l4cfg_clkdm",
  983. .prcm = {
  984. .omap4 = {
  985. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX8_CLKCTRL_OFFSET,
  986. .context_offs = DRA7XX_RM_L4CFG_MAILBOX8_CONTEXT_OFFSET,
  987. },
  988. },
  989. };
  990. /* mailbox9 */
  991. static struct omap_hwmod dra7xx_mailbox9_hwmod = {
  992. .name = "mailbox9",
  993. .class = &dra7xx_mailbox_hwmod_class,
  994. .clkdm_name = "l4cfg_clkdm",
  995. .prcm = {
  996. .omap4 = {
  997. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX9_CLKCTRL_OFFSET,
  998. .context_offs = DRA7XX_RM_L4CFG_MAILBOX9_CONTEXT_OFFSET,
  999. },
  1000. },
  1001. };
  1002. /* mailbox10 */
  1003. static struct omap_hwmod dra7xx_mailbox10_hwmod = {
  1004. .name = "mailbox10",
  1005. .class = &dra7xx_mailbox_hwmod_class,
  1006. .clkdm_name = "l4cfg_clkdm",
  1007. .prcm = {
  1008. .omap4 = {
  1009. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX10_CLKCTRL_OFFSET,
  1010. .context_offs = DRA7XX_RM_L4CFG_MAILBOX10_CONTEXT_OFFSET,
  1011. },
  1012. },
  1013. };
  1014. /* mailbox11 */
  1015. static struct omap_hwmod dra7xx_mailbox11_hwmod = {
  1016. .name = "mailbox11",
  1017. .class = &dra7xx_mailbox_hwmod_class,
  1018. .clkdm_name = "l4cfg_clkdm",
  1019. .prcm = {
  1020. .omap4 = {
  1021. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX11_CLKCTRL_OFFSET,
  1022. .context_offs = DRA7XX_RM_L4CFG_MAILBOX11_CONTEXT_OFFSET,
  1023. },
  1024. },
  1025. };
  1026. /* mailbox12 */
  1027. static struct omap_hwmod dra7xx_mailbox12_hwmod = {
  1028. .name = "mailbox12",
  1029. .class = &dra7xx_mailbox_hwmod_class,
  1030. .clkdm_name = "l4cfg_clkdm",
  1031. .prcm = {
  1032. .omap4 = {
  1033. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX12_CLKCTRL_OFFSET,
  1034. .context_offs = DRA7XX_RM_L4CFG_MAILBOX12_CONTEXT_OFFSET,
  1035. },
  1036. },
  1037. };
  1038. /* mailbox13 */
  1039. static struct omap_hwmod dra7xx_mailbox13_hwmod = {
  1040. .name = "mailbox13",
  1041. .class = &dra7xx_mailbox_hwmod_class,
  1042. .clkdm_name = "l4cfg_clkdm",
  1043. .prcm = {
  1044. .omap4 = {
  1045. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX13_CLKCTRL_OFFSET,
  1046. .context_offs = DRA7XX_RM_L4CFG_MAILBOX13_CONTEXT_OFFSET,
  1047. },
  1048. },
  1049. };
  1050. /*
  1051. * 'mcspi' class
  1052. *
  1053. */
  1054. static struct omap_hwmod_class_sysconfig dra7xx_mcspi_sysc = {
  1055. .rev_offs = 0x0000,
  1056. .sysc_offs = 0x0010,
  1057. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  1058. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1059. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1060. SIDLE_SMART_WKUP),
  1061. .sysc_fields = &omap_hwmod_sysc_type2,
  1062. };
  1063. static struct omap_hwmod_class dra7xx_mcspi_hwmod_class = {
  1064. .name = "mcspi",
  1065. .sysc = &dra7xx_mcspi_sysc,
  1066. .rev = OMAP4_MCSPI_REV,
  1067. };
  1068. /* mcspi1 */
  1069. /* mcspi1 dev_attr */
  1070. static struct omap2_mcspi_dev_attr mcspi1_dev_attr = {
  1071. .num_chipselect = 4,
  1072. };
  1073. static struct omap_hwmod dra7xx_mcspi1_hwmod = {
  1074. .name = "mcspi1",
  1075. .class = &dra7xx_mcspi_hwmod_class,
  1076. .clkdm_name = "l4per_clkdm",
  1077. .main_clk = "func_48m_fclk",
  1078. .prcm = {
  1079. .omap4 = {
  1080. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI1_CLKCTRL_OFFSET,
  1081. .context_offs = DRA7XX_RM_L4PER_MCSPI1_CONTEXT_OFFSET,
  1082. .modulemode = MODULEMODE_SWCTRL,
  1083. },
  1084. },
  1085. .dev_attr = &mcspi1_dev_attr,
  1086. };
  1087. /* mcspi2 */
  1088. /* mcspi2 dev_attr */
  1089. static struct omap2_mcspi_dev_attr mcspi2_dev_attr = {
  1090. .num_chipselect = 2,
  1091. };
  1092. static struct omap_hwmod dra7xx_mcspi2_hwmod = {
  1093. .name = "mcspi2",
  1094. .class = &dra7xx_mcspi_hwmod_class,
  1095. .clkdm_name = "l4per_clkdm",
  1096. .main_clk = "func_48m_fclk",
  1097. .prcm = {
  1098. .omap4 = {
  1099. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI2_CLKCTRL_OFFSET,
  1100. .context_offs = DRA7XX_RM_L4PER_MCSPI2_CONTEXT_OFFSET,
  1101. .modulemode = MODULEMODE_SWCTRL,
  1102. },
  1103. },
  1104. .dev_attr = &mcspi2_dev_attr,
  1105. };
  1106. /* mcspi3 */
  1107. /* mcspi3 dev_attr */
  1108. static struct omap2_mcspi_dev_attr mcspi3_dev_attr = {
  1109. .num_chipselect = 2,
  1110. };
  1111. static struct omap_hwmod dra7xx_mcspi3_hwmod = {
  1112. .name = "mcspi3",
  1113. .class = &dra7xx_mcspi_hwmod_class,
  1114. .clkdm_name = "l4per_clkdm",
  1115. .main_clk = "func_48m_fclk",
  1116. .prcm = {
  1117. .omap4 = {
  1118. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI3_CLKCTRL_OFFSET,
  1119. .context_offs = DRA7XX_RM_L4PER_MCSPI3_CONTEXT_OFFSET,
  1120. .modulemode = MODULEMODE_SWCTRL,
  1121. },
  1122. },
  1123. .dev_attr = &mcspi3_dev_attr,
  1124. };
  1125. /* mcspi4 */
  1126. /* mcspi4 dev_attr */
  1127. static struct omap2_mcspi_dev_attr mcspi4_dev_attr = {
  1128. .num_chipselect = 1,
  1129. };
  1130. static struct omap_hwmod dra7xx_mcspi4_hwmod = {
  1131. .name = "mcspi4",
  1132. .class = &dra7xx_mcspi_hwmod_class,
  1133. .clkdm_name = "l4per_clkdm",
  1134. .main_clk = "func_48m_fclk",
  1135. .prcm = {
  1136. .omap4 = {
  1137. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI4_CLKCTRL_OFFSET,
  1138. .context_offs = DRA7XX_RM_L4PER_MCSPI4_CONTEXT_OFFSET,
  1139. .modulemode = MODULEMODE_SWCTRL,
  1140. },
  1141. },
  1142. .dev_attr = &mcspi4_dev_attr,
  1143. };
  1144. /*
  1145. * 'mmc' class
  1146. *
  1147. */
  1148. static struct omap_hwmod_class_sysconfig dra7xx_mmc_sysc = {
  1149. .rev_offs = 0x0000,
  1150. .sysc_offs = 0x0010,
  1151. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
  1152. SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  1153. SYSC_HAS_SOFTRESET),
  1154. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1155. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  1156. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  1157. .sysc_fields = &omap_hwmod_sysc_type2,
  1158. };
  1159. static struct omap_hwmod_class dra7xx_mmc_hwmod_class = {
  1160. .name = "mmc",
  1161. .sysc = &dra7xx_mmc_sysc,
  1162. };
  1163. /* mmc1 */
  1164. static struct omap_hwmod_opt_clk mmc1_opt_clks[] = {
  1165. { .role = "clk32k", .clk = "mmc1_clk32k" },
  1166. };
  1167. /* mmc1 dev_attr */
  1168. static struct omap_hsmmc_dev_attr mmc1_dev_attr = {
  1169. .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
  1170. };
  1171. static struct omap_hwmod dra7xx_mmc1_hwmod = {
  1172. .name = "mmc1",
  1173. .class = &dra7xx_mmc_hwmod_class,
  1174. .clkdm_name = "l3init_clkdm",
  1175. .main_clk = "mmc1_fclk_div",
  1176. .prcm = {
  1177. .omap4 = {
  1178. .clkctrl_offs = DRA7XX_CM_L3INIT_MMC1_CLKCTRL_OFFSET,
  1179. .context_offs = DRA7XX_RM_L3INIT_MMC1_CONTEXT_OFFSET,
  1180. .modulemode = MODULEMODE_SWCTRL,
  1181. },
  1182. },
  1183. .opt_clks = mmc1_opt_clks,
  1184. .opt_clks_cnt = ARRAY_SIZE(mmc1_opt_clks),
  1185. .dev_attr = &mmc1_dev_attr,
  1186. };
  1187. /* mmc2 */
  1188. static struct omap_hwmod_opt_clk mmc2_opt_clks[] = {
  1189. { .role = "clk32k", .clk = "mmc2_clk32k" },
  1190. };
  1191. static struct omap_hwmod dra7xx_mmc2_hwmod = {
  1192. .name = "mmc2",
  1193. .class = &dra7xx_mmc_hwmod_class,
  1194. .clkdm_name = "l3init_clkdm",
  1195. .main_clk = "mmc2_fclk_div",
  1196. .prcm = {
  1197. .omap4 = {
  1198. .clkctrl_offs = DRA7XX_CM_L3INIT_MMC2_CLKCTRL_OFFSET,
  1199. .context_offs = DRA7XX_RM_L3INIT_MMC2_CONTEXT_OFFSET,
  1200. .modulemode = MODULEMODE_SWCTRL,
  1201. },
  1202. },
  1203. .opt_clks = mmc2_opt_clks,
  1204. .opt_clks_cnt = ARRAY_SIZE(mmc2_opt_clks),
  1205. };
  1206. /* mmc3 */
  1207. static struct omap_hwmod_opt_clk mmc3_opt_clks[] = {
  1208. { .role = "clk32k", .clk = "mmc3_clk32k" },
  1209. };
  1210. static struct omap_hwmod dra7xx_mmc3_hwmod = {
  1211. .name = "mmc3",
  1212. .class = &dra7xx_mmc_hwmod_class,
  1213. .clkdm_name = "l4per_clkdm",
  1214. .main_clk = "mmc3_gfclk_div",
  1215. .prcm = {
  1216. .omap4 = {
  1217. .clkctrl_offs = DRA7XX_CM_L4PER_MMC3_CLKCTRL_OFFSET,
  1218. .context_offs = DRA7XX_RM_L4PER_MMC3_CONTEXT_OFFSET,
  1219. .modulemode = MODULEMODE_SWCTRL,
  1220. },
  1221. },
  1222. .opt_clks = mmc3_opt_clks,
  1223. .opt_clks_cnt = ARRAY_SIZE(mmc3_opt_clks),
  1224. };
  1225. /* mmc4 */
  1226. static struct omap_hwmod_opt_clk mmc4_opt_clks[] = {
  1227. { .role = "clk32k", .clk = "mmc4_clk32k" },
  1228. };
  1229. static struct omap_hwmod dra7xx_mmc4_hwmod = {
  1230. .name = "mmc4",
  1231. .class = &dra7xx_mmc_hwmod_class,
  1232. .clkdm_name = "l4per_clkdm",
  1233. .main_clk = "mmc4_gfclk_div",
  1234. .prcm = {
  1235. .omap4 = {
  1236. .clkctrl_offs = DRA7XX_CM_L4PER_MMC4_CLKCTRL_OFFSET,
  1237. .context_offs = DRA7XX_RM_L4PER_MMC4_CONTEXT_OFFSET,
  1238. .modulemode = MODULEMODE_SWCTRL,
  1239. },
  1240. },
  1241. .opt_clks = mmc4_opt_clks,
  1242. .opt_clks_cnt = ARRAY_SIZE(mmc4_opt_clks),
  1243. };
  1244. /*
  1245. * 'mpu' class
  1246. *
  1247. */
  1248. static struct omap_hwmod_class dra7xx_mpu_hwmod_class = {
  1249. .name = "mpu",
  1250. };
  1251. /* mpu */
  1252. static struct omap_hwmod dra7xx_mpu_hwmod = {
  1253. .name = "mpu",
  1254. .class = &dra7xx_mpu_hwmod_class,
  1255. .clkdm_name = "mpu_clkdm",
  1256. .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
  1257. .main_clk = "dpll_mpu_m2_ck",
  1258. .prcm = {
  1259. .omap4 = {
  1260. .clkctrl_offs = DRA7XX_CM_MPU_MPU_CLKCTRL_OFFSET,
  1261. .context_offs = DRA7XX_RM_MPU_MPU_CONTEXT_OFFSET,
  1262. },
  1263. },
  1264. };
  1265. /*
  1266. * 'ocp2scp' class
  1267. *
  1268. */
  1269. static struct omap_hwmod_class_sysconfig dra7xx_ocp2scp_sysc = {
  1270. .rev_offs = 0x0000,
  1271. .sysc_offs = 0x0010,
  1272. .syss_offs = 0x0014,
  1273. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
  1274. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1275. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1276. SIDLE_SMART_WKUP),
  1277. .sysc_fields = &omap_hwmod_sysc_type1,
  1278. };
  1279. static struct omap_hwmod_class dra7xx_ocp2scp_hwmod_class = {
  1280. .name = "ocp2scp",
  1281. .sysc = &dra7xx_ocp2scp_sysc,
  1282. };
  1283. /* ocp2scp1 */
  1284. static struct omap_hwmod dra7xx_ocp2scp1_hwmod = {
  1285. .name = "ocp2scp1",
  1286. .class = &dra7xx_ocp2scp_hwmod_class,
  1287. .clkdm_name = "l3init_clkdm",
  1288. .main_clk = "l4_root_clk_div",
  1289. .prcm = {
  1290. .omap4 = {
  1291. .clkctrl_offs = DRA7XX_CM_L3INIT_OCP2SCP1_CLKCTRL_OFFSET,
  1292. .context_offs = DRA7XX_RM_L3INIT_OCP2SCP1_CONTEXT_OFFSET,
  1293. .modulemode = MODULEMODE_HWCTRL,
  1294. },
  1295. },
  1296. };
  1297. /* ocp2scp3 */
  1298. static struct omap_hwmod dra7xx_ocp2scp3_hwmod = {
  1299. .name = "ocp2scp3",
  1300. .class = &dra7xx_ocp2scp_hwmod_class,
  1301. .clkdm_name = "l3init_clkdm",
  1302. .main_clk = "l4_root_clk_div",
  1303. .prcm = {
  1304. .omap4 = {
  1305. .clkctrl_offs = DRA7XX_CM_L3INIT_OCP2SCP3_CLKCTRL_OFFSET,
  1306. .context_offs = DRA7XX_RM_L3INIT_OCP2SCP3_CONTEXT_OFFSET,
  1307. .modulemode = MODULEMODE_HWCTRL,
  1308. },
  1309. },
  1310. };
  1311. /*
  1312. * 'PCIE' class
  1313. *
  1314. */
  1315. static struct omap_hwmod_class dra7xx_pciess_hwmod_class = {
  1316. .name = "pcie",
  1317. };
  1318. /* pcie1 */
  1319. static struct omap_hwmod dra7xx_pciess1_hwmod = {
  1320. .name = "pcie1",
  1321. .class = &dra7xx_pciess_hwmod_class,
  1322. .clkdm_name = "pcie_clkdm",
  1323. .main_clk = "l4_root_clk_div",
  1324. .prcm = {
  1325. .omap4 = {
  1326. .clkctrl_offs = DRA7XX_CM_L3INIT_PCIESS1_CLKCTRL_OFFSET,
  1327. .context_offs = DRA7XX_RM_L3INIT_PCIESS1_CONTEXT_OFFSET,
  1328. .modulemode = MODULEMODE_SWCTRL,
  1329. },
  1330. },
  1331. };
  1332. /* pcie2 */
  1333. static struct omap_hwmod dra7xx_pciess2_hwmod = {
  1334. .name = "pcie2",
  1335. .class = &dra7xx_pciess_hwmod_class,
  1336. .clkdm_name = "pcie_clkdm",
  1337. .main_clk = "l4_root_clk_div",
  1338. .prcm = {
  1339. .omap4 = {
  1340. .clkctrl_offs = DRA7XX_CM_L3INIT_PCIESS2_CLKCTRL_OFFSET,
  1341. .context_offs = DRA7XX_RM_L3INIT_PCIESS2_CONTEXT_OFFSET,
  1342. .modulemode = MODULEMODE_SWCTRL,
  1343. },
  1344. },
  1345. };
  1346. /*
  1347. * 'qspi' class
  1348. *
  1349. */
  1350. static struct omap_hwmod_class_sysconfig dra7xx_qspi_sysc = {
  1351. .sysc_offs = 0x0010,
  1352. .sysc_flags = SYSC_HAS_SIDLEMODE,
  1353. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1354. SIDLE_SMART_WKUP),
  1355. .sysc_fields = &omap_hwmod_sysc_type2,
  1356. };
  1357. static struct omap_hwmod_class dra7xx_qspi_hwmod_class = {
  1358. .name = "qspi",
  1359. .sysc = &dra7xx_qspi_sysc,
  1360. };
  1361. /* qspi */
  1362. static struct omap_hwmod dra7xx_qspi_hwmod = {
  1363. .name = "qspi",
  1364. .class = &dra7xx_qspi_hwmod_class,
  1365. .clkdm_name = "l4per2_clkdm",
  1366. .main_clk = "qspi_gfclk_div",
  1367. .prcm = {
  1368. .omap4 = {
  1369. .clkctrl_offs = DRA7XX_CM_L4PER2_QSPI_CLKCTRL_OFFSET,
  1370. .context_offs = DRA7XX_RM_L4PER2_QSPI_CONTEXT_OFFSET,
  1371. .modulemode = MODULEMODE_SWCTRL,
  1372. },
  1373. },
  1374. };
  1375. /*
  1376. * 'rtcss' class
  1377. *
  1378. */
  1379. static struct omap_hwmod_class_sysconfig dra7xx_rtcss_sysc = {
  1380. .sysc_offs = 0x0078,
  1381. .sysc_flags = SYSC_HAS_SIDLEMODE,
  1382. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1383. SIDLE_SMART_WKUP),
  1384. .sysc_fields = &omap_hwmod_sysc_type3,
  1385. };
  1386. static struct omap_hwmod_class dra7xx_rtcss_hwmod_class = {
  1387. .name = "rtcss",
  1388. .sysc = &dra7xx_rtcss_sysc,
  1389. };
  1390. /* rtcss */
  1391. static struct omap_hwmod dra7xx_rtcss_hwmod = {
  1392. .name = "rtcss",
  1393. .class = &dra7xx_rtcss_hwmod_class,
  1394. .clkdm_name = "rtc_clkdm",
  1395. .main_clk = "sys_32k_ck",
  1396. .prcm = {
  1397. .omap4 = {
  1398. .clkctrl_offs = DRA7XX_CM_RTC_RTCSS_CLKCTRL_OFFSET,
  1399. .context_offs = DRA7XX_RM_RTC_RTCSS_CONTEXT_OFFSET,
  1400. .modulemode = MODULEMODE_SWCTRL,
  1401. },
  1402. },
  1403. };
  1404. /*
  1405. * 'sata' class
  1406. *
  1407. */
  1408. static struct omap_hwmod_class_sysconfig dra7xx_sata_sysc = {
  1409. .sysc_offs = 0x0000,
  1410. .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
  1411. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1412. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  1413. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  1414. .sysc_fields = &omap_hwmod_sysc_type2,
  1415. };
  1416. static struct omap_hwmod_class dra7xx_sata_hwmod_class = {
  1417. .name = "sata",
  1418. .sysc = &dra7xx_sata_sysc,
  1419. };
  1420. /* sata */
  1421. static struct omap_hwmod dra7xx_sata_hwmod = {
  1422. .name = "sata",
  1423. .class = &dra7xx_sata_hwmod_class,
  1424. .clkdm_name = "l3init_clkdm",
  1425. .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  1426. .main_clk = "func_48m_fclk",
  1427. .mpu_rt_idx = 1,
  1428. .prcm = {
  1429. .omap4 = {
  1430. .clkctrl_offs = DRA7XX_CM_L3INIT_SATA_CLKCTRL_OFFSET,
  1431. .context_offs = DRA7XX_RM_L3INIT_SATA_CONTEXT_OFFSET,
  1432. .modulemode = MODULEMODE_SWCTRL,
  1433. },
  1434. },
  1435. };
  1436. /*
  1437. * 'smartreflex' class
  1438. *
  1439. */
  1440. /* The IP is not compliant to type1 / type2 scheme */
  1441. static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_smartreflex = {
  1442. .sidle_shift = 24,
  1443. .enwkup_shift = 26,
  1444. };
  1445. static struct omap_hwmod_class_sysconfig dra7xx_smartreflex_sysc = {
  1446. .sysc_offs = 0x0038,
  1447. .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE),
  1448. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1449. SIDLE_SMART_WKUP),
  1450. .sysc_fields = &omap_hwmod_sysc_type_smartreflex,
  1451. };
  1452. static struct omap_hwmod_class dra7xx_smartreflex_hwmod_class = {
  1453. .name = "smartreflex",
  1454. .sysc = &dra7xx_smartreflex_sysc,
  1455. .rev = 2,
  1456. };
  1457. /* smartreflex_core */
  1458. /* smartreflex_core dev_attr */
  1459. static struct omap_smartreflex_dev_attr smartreflex_core_dev_attr = {
  1460. .sensor_voltdm_name = "core",
  1461. };
  1462. static struct omap_hwmod dra7xx_smartreflex_core_hwmod = {
  1463. .name = "smartreflex_core",
  1464. .class = &dra7xx_smartreflex_hwmod_class,
  1465. .clkdm_name = "coreaon_clkdm",
  1466. .main_clk = "wkupaon_iclk_mux",
  1467. .prcm = {
  1468. .omap4 = {
  1469. .clkctrl_offs = DRA7XX_CM_COREAON_SMARTREFLEX_CORE_CLKCTRL_OFFSET,
  1470. .context_offs = DRA7XX_RM_COREAON_SMARTREFLEX_CORE_CONTEXT_OFFSET,
  1471. .modulemode = MODULEMODE_SWCTRL,
  1472. },
  1473. },
  1474. .dev_attr = &smartreflex_core_dev_attr,
  1475. };
  1476. /* smartreflex_mpu */
  1477. /* smartreflex_mpu dev_attr */
  1478. static struct omap_smartreflex_dev_attr smartreflex_mpu_dev_attr = {
  1479. .sensor_voltdm_name = "mpu",
  1480. };
  1481. static struct omap_hwmod dra7xx_smartreflex_mpu_hwmod = {
  1482. .name = "smartreflex_mpu",
  1483. .class = &dra7xx_smartreflex_hwmod_class,
  1484. .clkdm_name = "coreaon_clkdm",
  1485. .main_clk = "wkupaon_iclk_mux",
  1486. .prcm = {
  1487. .omap4 = {
  1488. .clkctrl_offs = DRA7XX_CM_COREAON_SMARTREFLEX_MPU_CLKCTRL_OFFSET,
  1489. .context_offs = DRA7XX_RM_COREAON_SMARTREFLEX_MPU_CONTEXT_OFFSET,
  1490. .modulemode = MODULEMODE_SWCTRL,
  1491. },
  1492. },
  1493. .dev_attr = &smartreflex_mpu_dev_attr,
  1494. };
  1495. /*
  1496. * 'spinlock' class
  1497. *
  1498. */
  1499. static struct omap_hwmod_class_sysconfig dra7xx_spinlock_sysc = {
  1500. .rev_offs = 0x0000,
  1501. .sysc_offs = 0x0010,
  1502. .syss_offs = 0x0014,
  1503. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  1504. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  1505. SYSS_HAS_RESET_STATUS),
  1506. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1507. .sysc_fields = &omap_hwmod_sysc_type1,
  1508. };
  1509. static struct omap_hwmod_class dra7xx_spinlock_hwmod_class = {
  1510. .name = "spinlock",
  1511. .sysc = &dra7xx_spinlock_sysc,
  1512. };
  1513. /* spinlock */
  1514. static struct omap_hwmod dra7xx_spinlock_hwmod = {
  1515. .name = "spinlock",
  1516. .class = &dra7xx_spinlock_hwmod_class,
  1517. .clkdm_name = "l4cfg_clkdm",
  1518. .main_clk = "l3_iclk_div",
  1519. .prcm = {
  1520. .omap4 = {
  1521. .clkctrl_offs = DRA7XX_CM_L4CFG_SPINLOCK_CLKCTRL_OFFSET,
  1522. .context_offs = DRA7XX_RM_L4CFG_SPINLOCK_CONTEXT_OFFSET,
  1523. },
  1524. },
  1525. };
  1526. /*
  1527. * 'timer' class
  1528. *
  1529. * This class contains several variants: ['timer_1ms', 'timer_secure',
  1530. * 'timer']
  1531. */
  1532. static struct omap_hwmod_class_sysconfig dra7xx_timer_1ms_sysc = {
  1533. .rev_offs = 0x0000,
  1534. .sysc_offs = 0x0010,
  1535. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  1536. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1537. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1538. SIDLE_SMART_WKUP),
  1539. .sysc_fields = &omap_hwmod_sysc_type2,
  1540. };
  1541. static struct omap_hwmod_class dra7xx_timer_1ms_hwmod_class = {
  1542. .name = "timer",
  1543. .sysc = &dra7xx_timer_1ms_sysc,
  1544. };
  1545. static struct omap_hwmod_class_sysconfig dra7xx_timer_secure_sysc = {
  1546. .rev_offs = 0x0000,
  1547. .sysc_offs = 0x0010,
  1548. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  1549. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1550. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1551. SIDLE_SMART_WKUP),
  1552. .sysc_fields = &omap_hwmod_sysc_type2,
  1553. };
  1554. static struct omap_hwmod_class dra7xx_timer_secure_hwmod_class = {
  1555. .name = "timer",
  1556. .sysc = &dra7xx_timer_secure_sysc,
  1557. };
  1558. static struct omap_hwmod_class_sysconfig dra7xx_timer_sysc = {
  1559. .rev_offs = 0x0000,
  1560. .sysc_offs = 0x0010,
  1561. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  1562. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1563. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1564. SIDLE_SMART_WKUP),
  1565. .sysc_fields = &omap_hwmod_sysc_type2,
  1566. };
  1567. static struct omap_hwmod_class dra7xx_timer_hwmod_class = {
  1568. .name = "timer",
  1569. .sysc = &dra7xx_timer_sysc,
  1570. };
  1571. /* timer1 */
  1572. static struct omap_hwmod dra7xx_timer1_hwmod = {
  1573. .name = "timer1",
  1574. .class = &dra7xx_timer_1ms_hwmod_class,
  1575. .clkdm_name = "wkupaon_clkdm",
  1576. .main_clk = "timer1_gfclk_mux",
  1577. .prcm = {
  1578. .omap4 = {
  1579. .clkctrl_offs = DRA7XX_CM_WKUPAON_TIMER1_CLKCTRL_OFFSET,
  1580. .context_offs = DRA7XX_RM_WKUPAON_TIMER1_CONTEXT_OFFSET,
  1581. .modulemode = MODULEMODE_SWCTRL,
  1582. },
  1583. },
  1584. };
  1585. /* timer2 */
  1586. static struct omap_hwmod dra7xx_timer2_hwmod = {
  1587. .name = "timer2",
  1588. .class = &dra7xx_timer_1ms_hwmod_class,
  1589. .clkdm_name = "l4per_clkdm",
  1590. .main_clk = "timer2_gfclk_mux",
  1591. .prcm = {
  1592. .omap4 = {
  1593. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER2_CLKCTRL_OFFSET,
  1594. .context_offs = DRA7XX_RM_L4PER_TIMER2_CONTEXT_OFFSET,
  1595. .modulemode = MODULEMODE_SWCTRL,
  1596. },
  1597. },
  1598. };
  1599. /* timer3 */
  1600. static struct omap_hwmod dra7xx_timer3_hwmod = {
  1601. .name = "timer3",
  1602. .class = &dra7xx_timer_hwmod_class,
  1603. .clkdm_name = "l4per_clkdm",
  1604. .main_clk = "timer3_gfclk_mux",
  1605. .prcm = {
  1606. .omap4 = {
  1607. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER3_CLKCTRL_OFFSET,
  1608. .context_offs = DRA7XX_RM_L4PER_TIMER3_CONTEXT_OFFSET,
  1609. .modulemode = MODULEMODE_SWCTRL,
  1610. },
  1611. },
  1612. };
  1613. /* timer4 */
  1614. static struct omap_hwmod dra7xx_timer4_hwmod = {
  1615. .name = "timer4",
  1616. .class = &dra7xx_timer_secure_hwmod_class,
  1617. .clkdm_name = "l4per_clkdm",
  1618. .main_clk = "timer4_gfclk_mux",
  1619. .prcm = {
  1620. .omap4 = {
  1621. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER4_CLKCTRL_OFFSET,
  1622. .context_offs = DRA7XX_RM_L4PER_TIMER4_CONTEXT_OFFSET,
  1623. .modulemode = MODULEMODE_SWCTRL,
  1624. },
  1625. },
  1626. };
  1627. /* timer5 */
  1628. static struct omap_hwmod dra7xx_timer5_hwmod = {
  1629. .name = "timer5",
  1630. .class = &dra7xx_timer_hwmod_class,
  1631. .clkdm_name = "ipu_clkdm",
  1632. .main_clk = "timer5_gfclk_mux",
  1633. .prcm = {
  1634. .omap4 = {
  1635. .clkctrl_offs = DRA7XX_CM_IPU_TIMER5_CLKCTRL_OFFSET,
  1636. .context_offs = DRA7XX_RM_IPU_TIMER5_CONTEXT_OFFSET,
  1637. .modulemode = MODULEMODE_SWCTRL,
  1638. },
  1639. },
  1640. };
  1641. /* timer6 */
  1642. static struct omap_hwmod dra7xx_timer6_hwmod = {
  1643. .name = "timer6",
  1644. .class = &dra7xx_timer_hwmod_class,
  1645. .clkdm_name = "ipu_clkdm",
  1646. .main_clk = "timer6_gfclk_mux",
  1647. .prcm = {
  1648. .omap4 = {
  1649. .clkctrl_offs = DRA7XX_CM_IPU_TIMER6_CLKCTRL_OFFSET,
  1650. .context_offs = DRA7XX_RM_IPU_TIMER6_CONTEXT_OFFSET,
  1651. .modulemode = MODULEMODE_SWCTRL,
  1652. },
  1653. },
  1654. };
  1655. /* timer7 */
  1656. static struct omap_hwmod dra7xx_timer7_hwmod = {
  1657. .name = "timer7",
  1658. .class = &dra7xx_timer_hwmod_class,
  1659. .clkdm_name = "ipu_clkdm",
  1660. .main_clk = "timer7_gfclk_mux",
  1661. .prcm = {
  1662. .omap4 = {
  1663. .clkctrl_offs = DRA7XX_CM_IPU_TIMER7_CLKCTRL_OFFSET,
  1664. .context_offs = DRA7XX_RM_IPU_TIMER7_CONTEXT_OFFSET,
  1665. .modulemode = MODULEMODE_SWCTRL,
  1666. },
  1667. },
  1668. };
  1669. /* timer8 */
  1670. static struct omap_hwmod dra7xx_timer8_hwmod = {
  1671. .name = "timer8",
  1672. .class = &dra7xx_timer_hwmod_class,
  1673. .clkdm_name = "ipu_clkdm",
  1674. .main_clk = "timer8_gfclk_mux",
  1675. .prcm = {
  1676. .omap4 = {
  1677. .clkctrl_offs = DRA7XX_CM_IPU_TIMER8_CLKCTRL_OFFSET,
  1678. .context_offs = DRA7XX_RM_IPU_TIMER8_CONTEXT_OFFSET,
  1679. .modulemode = MODULEMODE_SWCTRL,
  1680. },
  1681. },
  1682. };
  1683. /* timer9 */
  1684. static struct omap_hwmod dra7xx_timer9_hwmod = {
  1685. .name = "timer9",
  1686. .class = &dra7xx_timer_hwmod_class,
  1687. .clkdm_name = "l4per_clkdm",
  1688. .main_clk = "timer9_gfclk_mux",
  1689. .prcm = {
  1690. .omap4 = {
  1691. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER9_CLKCTRL_OFFSET,
  1692. .context_offs = DRA7XX_RM_L4PER_TIMER9_CONTEXT_OFFSET,
  1693. .modulemode = MODULEMODE_SWCTRL,
  1694. },
  1695. },
  1696. };
  1697. /* timer10 */
  1698. static struct omap_hwmod dra7xx_timer10_hwmod = {
  1699. .name = "timer10",
  1700. .class = &dra7xx_timer_1ms_hwmod_class,
  1701. .clkdm_name = "l4per_clkdm",
  1702. .main_clk = "timer10_gfclk_mux",
  1703. .prcm = {
  1704. .omap4 = {
  1705. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER10_CLKCTRL_OFFSET,
  1706. .context_offs = DRA7XX_RM_L4PER_TIMER10_CONTEXT_OFFSET,
  1707. .modulemode = MODULEMODE_SWCTRL,
  1708. },
  1709. },
  1710. };
  1711. /* timer11 */
  1712. static struct omap_hwmod dra7xx_timer11_hwmod = {
  1713. .name = "timer11",
  1714. .class = &dra7xx_timer_hwmod_class,
  1715. .clkdm_name = "l4per_clkdm",
  1716. .main_clk = "timer11_gfclk_mux",
  1717. .prcm = {
  1718. .omap4 = {
  1719. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER11_CLKCTRL_OFFSET,
  1720. .context_offs = DRA7XX_RM_L4PER_TIMER11_CONTEXT_OFFSET,
  1721. .modulemode = MODULEMODE_SWCTRL,
  1722. },
  1723. },
  1724. };
  1725. /*
  1726. * 'uart' class
  1727. *
  1728. */
  1729. static struct omap_hwmod_class_sysconfig dra7xx_uart_sysc = {
  1730. .rev_offs = 0x0050,
  1731. .sysc_offs = 0x0054,
  1732. .syss_offs = 0x0058,
  1733. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  1734. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  1735. SYSS_HAS_RESET_STATUS),
  1736. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1737. SIDLE_SMART_WKUP),
  1738. .sysc_fields = &omap_hwmod_sysc_type1,
  1739. };
  1740. static struct omap_hwmod_class dra7xx_uart_hwmod_class = {
  1741. .name = "uart",
  1742. .sysc = &dra7xx_uart_sysc,
  1743. };
  1744. /* uart1 */
  1745. static struct omap_hwmod dra7xx_uart1_hwmod = {
  1746. .name = "uart1",
  1747. .class = &dra7xx_uart_hwmod_class,
  1748. .clkdm_name = "l4per_clkdm",
  1749. .main_clk = "uart1_gfclk_mux",
  1750. .flags = HWMOD_SWSUP_SIDLE_ACT | DEBUG_OMAP2UART1_FLAGS,
  1751. .prcm = {
  1752. .omap4 = {
  1753. .clkctrl_offs = DRA7XX_CM_L4PER_UART1_CLKCTRL_OFFSET,
  1754. .context_offs = DRA7XX_RM_L4PER_UART1_CONTEXT_OFFSET,
  1755. .modulemode = MODULEMODE_SWCTRL,
  1756. },
  1757. },
  1758. };
  1759. /* uart2 */
  1760. static struct omap_hwmod dra7xx_uart2_hwmod = {
  1761. .name = "uart2",
  1762. .class = &dra7xx_uart_hwmod_class,
  1763. .clkdm_name = "l4per_clkdm",
  1764. .main_clk = "uart2_gfclk_mux",
  1765. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1766. .prcm = {
  1767. .omap4 = {
  1768. .clkctrl_offs = DRA7XX_CM_L4PER_UART2_CLKCTRL_OFFSET,
  1769. .context_offs = DRA7XX_RM_L4PER_UART2_CONTEXT_OFFSET,
  1770. .modulemode = MODULEMODE_SWCTRL,
  1771. },
  1772. },
  1773. };
  1774. /* uart3 */
  1775. static struct omap_hwmod dra7xx_uart3_hwmod = {
  1776. .name = "uart3",
  1777. .class = &dra7xx_uart_hwmod_class,
  1778. .clkdm_name = "l4per_clkdm",
  1779. .main_clk = "uart3_gfclk_mux",
  1780. .flags = HWMOD_SWSUP_SIDLE_ACT | DEBUG_OMAP4UART3_FLAGS,
  1781. .prcm = {
  1782. .omap4 = {
  1783. .clkctrl_offs = DRA7XX_CM_L4PER_UART3_CLKCTRL_OFFSET,
  1784. .context_offs = DRA7XX_RM_L4PER_UART3_CONTEXT_OFFSET,
  1785. .modulemode = MODULEMODE_SWCTRL,
  1786. },
  1787. },
  1788. };
  1789. /* uart4 */
  1790. static struct omap_hwmod dra7xx_uart4_hwmod = {
  1791. .name = "uart4",
  1792. .class = &dra7xx_uart_hwmod_class,
  1793. .clkdm_name = "l4per_clkdm",
  1794. .main_clk = "uart4_gfclk_mux",
  1795. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1796. .prcm = {
  1797. .omap4 = {
  1798. .clkctrl_offs = DRA7XX_CM_L4PER_UART4_CLKCTRL_OFFSET,
  1799. .context_offs = DRA7XX_RM_L4PER_UART4_CONTEXT_OFFSET,
  1800. .modulemode = MODULEMODE_SWCTRL,
  1801. },
  1802. },
  1803. };
  1804. /* uart5 */
  1805. static struct omap_hwmod dra7xx_uart5_hwmod = {
  1806. .name = "uart5",
  1807. .class = &dra7xx_uart_hwmod_class,
  1808. .clkdm_name = "l4per_clkdm",
  1809. .main_clk = "uart5_gfclk_mux",
  1810. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1811. .prcm = {
  1812. .omap4 = {
  1813. .clkctrl_offs = DRA7XX_CM_L4PER_UART5_CLKCTRL_OFFSET,
  1814. .context_offs = DRA7XX_RM_L4PER_UART5_CONTEXT_OFFSET,
  1815. .modulemode = MODULEMODE_SWCTRL,
  1816. },
  1817. },
  1818. };
  1819. /* uart6 */
  1820. static struct omap_hwmod dra7xx_uart6_hwmod = {
  1821. .name = "uart6",
  1822. .class = &dra7xx_uart_hwmod_class,
  1823. .clkdm_name = "ipu_clkdm",
  1824. .main_clk = "uart6_gfclk_mux",
  1825. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1826. .prcm = {
  1827. .omap4 = {
  1828. .clkctrl_offs = DRA7XX_CM_IPU_UART6_CLKCTRL_OFFSET,
  1829. .context_offs = DRA7XX_RM_IPU_UART6_CONTEXT_OFFSET,
  1830. .modulemode = MODULEMODE_SWCTRL,
  1831. },
  1832. },
  1833. };
  1834. /* uart7 */
  1835. static struct omap_hwmod dra7xx_uart7_hwmod = {
  1836. .name = "uart7",
  1837. .class = &dra7xx_uart_hwmod_class,
  1838. .clkdm_name = "l4per2_clkdm",
  1839. .main_clk = "uart7_gfclk_mux",
  1840. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1841. .prcm = {
  1842. .omap4 = {
  1843. .clkctrl_offs = DRA7XX_CM_L4PER2_UART7_CLKCTRL_OFFSET,
  1844. .context_offs = DRA7XX_RM_L4PER2_UART7_CONTEXT_OFFSET,
  1845. .modulemode = MODULEMODE_SWCTRL,
  1846. },
  1847. },
  1848. };
  1849. /* uart8 */
  1850. static struct omap_hwmod dra7xx_uart8_hwmod = {
  1851. .name = "uart8",
  1852. .class = &dra7xx_uart_hwmod_class,
  1853. .clkdm_name = "l4per2_clkdm",
  1854. .main_clk = "uart8_gfclk_mux",
  1855. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1856. .prcm = {
  1857. .omap4 = {
  1858. .clkctrl_offs = DRA7XX_CM_L4PER2_UART8_CLKCTRL_OFFSET,
  1859. .context_offs = DRA7XX_RM_L4PER2_UART8_CONTEXT_OFFSET,
  1860. .modulemode = MODULEMODE_SWCTRL,
  1861. },
  1862. },
  1863. };
  1864. /* uart9 */
  1865. static struct omap_hwmod dra7xx_uart9_hwmod = {
  1866. .name = "uart9",
  1867. .class = &dra7xx_uart_hwmod_class,
  1868. .clkdm_name = "l4per2_clkdm",
  1869. .main_clk = "uart9_gfclk_mux",
  1870. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1871. .prcm = {
  1872. .omap4 = {
  1873. .clkctrl_offs = DRA7XX_CM_L4PER2_UART9_CLKCTRL_OFFSET,
  1874. .context_offs = DRA7XX_RM_L4PER2_UART9_CONTEXT_OFFSET,
  1875. .modulemode = MODULEMODE_SWCTRL,
  1876. },
  1877. },
  1878. };
  1879. /* uart10 */
  1880. static struct omap_hwmod dra7xx_uart10_hwmod = {
  1881. .name = "uart10",
  1882. .class = &dra7xx_uart_hwmod_class,
  1883. .clkdm_name = "wkupaon_clkdm",
  1884. .main_clk = "uart10_gfclk_mux",
  1885. .flags = HWMOD_SWSUP_SIDLE_ACT,
  1886. .prcm = {
  1887. .omap4 = {
  1888. .clkctrl_offs = DRA7XX_CM_WKUPAON_UART10_CLKCTRL_OFFSET,
  1889. .context_offs = DRA7XX_RM_WKUPAON_UART10_CONTEXT_OFFSET,
  1890. .modulemode = MODULEMODE_SWCTRL,
  1891. },
  1892. },
  1893. };
  1894. /*
  1895. * 'usb_otg_ss' class
  1896. *
  1897. */
  1898. static struct omap_hwmod_class_sysconfig dra7xx_usb_otg_ss_sysc = {
  1899. .rev_offs = 0x0000,
  1900. .sysc_offs = 0x0010,
  1901. .sysc_flags = (SYSC_HAS_DMADISABLE | SYSC_HAS_MIDLEMODE |
  1902. SYSC_HAS_SIDLEMODE),
  1903. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1904. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  1905. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  1906. .sysc_fields = &omap_hwmod_sysc_type2,
  1907. };
  1908. static struct omap_hwmod_class dra7xx_usb_otg_ss_hwmod_class = {
  1909. .name = "usb_otg_ss",
  1910. .sysc = &dra7xx_usb_otg_ss_sysc,
  1911. };
  1912. /* usb_otg_ss1 */
  1913. static struct omap_hwmod_opt_clk usb_otg_ss1_opt_clks[] = {
  1914. { .role = "refclk960m", .clk = "usb_otg_ss1_refclk960m" },
  1915. };
  1916. static struct omap_hwmod dra7xx_usb_otg_ss1_hwmod = {
  1917. .name = "usb_otg_ss1",
  1918. .class = &dra7xx_usb_otg_ss_hwmod_class,
  1919. .clkdm_name = "l3init_clkdm",
  1920. .main_clk = "dpll_core_h13x2_ck",
  1921. .prcm = {
  1922. .omap4 = {
  1923. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS1_CLKCTRL_OFFSET,
  1924. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS1_CONTEXT_OFFSET,
  1925. .modulemode = MODULEMODE_HWCTRL,
  1926. },
  1927. },
  1928. .opt_clks = usb_otg_ss1_opt_clks,
  1929. .opt_clks_cnt = ARRAY_SIZE(usb_otg_ss1_opt_clks),
  1930. };
  1931. /* usb_otg_ss2 */
  1932. static struct omap_hwmod_opt_clk usb_otg_ss2_opt_clks[] = {
  1933. { .role = "refclk960m", .clk = "usb_otg_ss2_refclk960m" },
  1934. };
  1935. static struct omap_hwmod dra7xx_usb_otg_ss2_hwmod = {
  1936. .name = "usb_otg_ss2",
  1937. .class = &dra7xx_usb_otg_ss_hwmod_class,
  1938. .clkdm_name = "l3init_clkdm",
  1939. .main_clk = "dpll_core_h13x2_ck",
  1940. .prcm = {
  1941. .omap4 = {
  1942. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS2_CLKCTRL_OFFSET,
  1943. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS2_CONTEXT_OFFSET,
  1944. .modulemode = MODULEMODE_HWCTRL,
  1945. },
  1946. },
  1947. .opt_clks = usb_otg_ss2_opt_clks,
  1948. .opt_clks_cnt = ARRAY_SIZE(usb_otg_ss2_opt_clks),
  1949. };
  1950. /* usb_otg_ss3 */
  1951. static struct omap_hwmod dra7xx_usb_otg_ss3_hwmod = {
  1952. .name = "usb_otg_ss3",
  1953. .class = &dra7xx_usb_otg_ss_hwmod_class,
  1954. .clkdm_name = "l3init_clkdm",
  1955. .main_clk = "dpll_core_h13x2_ck",
  1956. .prcm = {
  1957. .omap4 = {
  1958. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS3_CLKCTRL_OFFSET,
  1959. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS3_CONTEXT_OFFSET,
  1960. .modulemode = MODULEMODE_HWCTRL,
  1961. },
  1962. },
  1963. };
  1964. /* usb_otg_ss4 */
  1965. static struct omap_hwmod dra7xx_usb_otg_ss4_hwmod = {
  1966. .name = "usb_otg_ss4",
  1967. .class = &dra7xx_usb_otg_ss_hwmod_class,
  1968. .clkdm_name = "l3init_clkdm",
  1969. .main_clk = "dpll_core_h13x2_ck",
  1970. .prcm = {
  1971. .omap4 = {
  1972. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS4_CLKCTRL_OFFSET,
  1973. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS4_CONTEXT_OFFSET,
  1974. .modulemode = MODULEMODE_HWCTRL,
  1975. },
  1976. },
  1977. };
  1978. /*
  1979. * 'vcp' class
  1980. *
  1981. */
  1982. static struct omap_hwmod_class dra7xx_vcp_hwmod_class = {
  1983. .name = "vcp",
  1984. };
  1985. /* vcp1 */
  1986. static struct omap_hwmod dra7xx_vcp1_hwmod = {
  1987. .name = "vcp1",
  1988. .class = &dra7xx_vcp_hwmod_class,
  1989. .clkdm_name = "l3main1_clkdm",
  1990. .main_clk = "l3_iclk_div",
  1991. .prcm = {
  1992. .omap4 = {
  1993. .clkctrl_offs = DRA7XX_CM_L3MAIN1_VCP1_CLKCTRL_OFFSET,
  1994. .context_offs = DRA7XX_RM_L3MAIN1_VCP1_CONTEXT_OFFSET,
  1995. },
  1996. },
  1997. };
  1998. /* vcp2 */
  1999. static struct omap_hwmod dra7xx_vcp2_hwmod = {
  2000. .name = "vcp2",
  2001. .class = &dra7xx_vcp_hwmod_class,
  2002. .clkdm_name = "l3main1_clkdm",
  2003. .main_clk = "l3_iclk_div",
  2004. .prcm = {
  2005. .omap4 = {
  2006. .clkctrl_offs = DRA7XX_CM_L3MAIN1_VCP2_CLKCTRL_OFFSET,
  2007. .context_offs = DRA7XX_RM_L3MAIN1_VCP2_CONTEXT_OFFSET,
  2008. },
  2009. },
  2010. };
  2011. /*
  2012. * 'wd_timer' class
  2013. *
  2014. */
  2015. static struct omap_hwmod_class_sysconfig dra7xx_wd_timer_sysc = {
  2016. .rev_offs = 0x0000,
  2017. .sysc_offs = 0x0010,
  2018. .syss_offs = 0x0014,
  2019. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_SIDLEMODE |
  2020. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  2021. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2022. SIDLE_SMART_WKUP),
  2023. .sysc_fields = &omap_hwmod_sysc_type1,
  2024. };
  2025. static struct omap_hwmod_class dra7xx_wd_timer_hwmod_class = {
  2026. .name = "wd_timer",
  2027. .sysc = &dra7xx_wd_timer_sysc,
  2028. .pre_shutdown = &omap2_wd_timer_disable,
  2029. .reset = &omap2_wd_timer_reset,
  2030. };
  2031. /* wd_timer2 */
  2032. static struct omap_hwmod dra7xx_wd_timer2_hwmod = {
  2033. .name = "wd_timer2",
  2034. .class = &dra7xx_wd_timer_hwmod_class,
  2035. .clkdm_name = "wkupaon_clkdm",
  2036. .main_clk = "sys_32k_ck",
  2037. .prcm = {
  2038. .omap4 = {
  2039. .clkctrl_offs = DRA7XX_CM_WKUPAON_WD_TIMER2_CLKCTRL_OFFSET,
  2040. .context_offs = DRA7XX_RM_WKUPAON_WD_TIMER2_CONTEXT_OFFSET,
  2041. .modulemode = MODULEMODE_SWCTRL,
  2042. },
  2043. },
  2044. };
  2045. /*
  2046. * Interfaces
  2047. */
  2048. /* l3_main_2 -> l3_instr */
  2049. static struct omap_hwmod_ocp_if dra7xx_l3_main_2__l3_instr = {
  2050. .master = &dra7xx_l3_main_2_hwmod,
  2051. .slave = &dra7xx_l3_instr_hwmod,
  2052. .clk = "l3_iclk_div",
  2053. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2054. };
  2055. /* l4_cfg -> l3_main_1 */
  2056. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__l3_main_1 = {
  2057. .master = &dra7xx_l4_cfg_hwmod,
  2058. .slave = &dra7xx_l3_main_1_hwmod,
  2059. .clk = "l3_iclk_div",
  2060. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2061. };
  2062. /* mpu -> l3_main_1 */
  2063. static struct omap_hwmod_ocp_if dra7xx_mpu__l3_main_1 = {
  2064. .master = &dra7xx_mpu_hwmod,
  2065. .slave = &dra7xx_l3_main_1_hwmod,
  2066. .clk = "l3_iclk_div",
  2067. .user = OCP_USER_MPU,
  2068. };
  2069. /* l3_main_1 -> l3_main_2 */
  2070. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l3_main_2 = {
  2071. .master = &dra7xx_l3_main_1_hwmod,
  2072. .slave = &dra7xx_l3_main_2_hwmod,
  2073. .clk = "l3_iclk_div",
  2074. .user = OCP_USER_MPU,
  2075. };
  2076. /* l4_cfg -> l3_main_2 */
  2077. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__l3_main_2 = {
  2078. .master = &dra7xx_l4_cfg_hwmod,
  2079. .slave = &dra7xx_l3_main_2_hwmod,
  2080. .clk = "l3_iclk_div",
  2081. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2082. };
  2083. /* l3_main_1 -> l4_cfg */
  2084. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_cfg = {
  2085. .master = &dra7xx_l3_main_1_hwmod,
  2086. .slave = &dra7xx_l4_cfg_hwmod,
  2087. .clk = "l3_iclk_div",
  2088. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2089. };
  2090. /* l3_main_1 -> l4_per1 */
  2091. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per1 = {
  2092. .master = &dra7xx_l3_main_1_hwmod,
  2093. .slave = &dra7xx_l4_per1_hwmod,
  2094. .clk = "l3_iclk_div",
  2095. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2096. };
  2097. /* l3_main_1 -> l4_per2 */
  2098. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per2 = {
  2099. .master = &dra7xx_l3_main_1_hwmod,
  2100. .slave = &dra7xx_l4_per2_hwmod,
  2101. .clk = "l3_iclk_div",
  2102. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2103. };
  2104. /* l3_main_1 -> l4_per3 */
  2105. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per3 = {
  2106. .master = &dra7xx_l3_main_1_hwmod,
  2107. .slave = &dra7xx_l4_per3_hwmod,
  2108. .clk = "l3_iclk_div",
  2109. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2110. };
  2111. /* l3_main_1 -> l4_wkup */
  2112. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_wkup = {
  2113. .master = &dra7xx_l3_main_1_hwmod,
  2114. .slave = &dra7xx_l4_wkup_hwmod,
  2115. .clk = "wkupaon_iclk_mux",
  2116. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2117. };
  2118. /* l4_per2 -> atl */
  2119. static struct omap_hwmod_ocp_if dra7xx_l4_per2__atl = {
  2120. .master = &dra7xx_l4_per2_hwmod,
  2121. .slave = &dra7xx_atl_hwmod,
  2122. .clk = "l3_iclk_div",
  2123. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2124. };
  2125. /* l3_main_1 -> bb2d */
  2126. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__bb2d = {
  2127. .master = &dra7xx_l3_main_1_hwmod,
  2128. .slave = &dra7xx_bb2d_hwmod,
  2129. .clk = "l3_iclk_div",
  2130. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2131. };
  2132. /* l4_wkup -> counter_32k */
  2133. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__counter_32k = {
  2134. .master = &dra7xx_l4_wkup_hwmod,
  2135. .slave = &dra7xx_counter_32k_hwmod,
  2136. .clk = "wkupaon_iclk_mux",
  2137. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2138. };
  2139. /* l4_wkup -> ctrl_module_wkup */
  2140. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__ctrl_module_wkup = {
  2141. .master = &dra7xx_l4_wkup_hwmod,
  2142. .slave = &dra7xx_ctrl_module_wkup_hwmod,
  2143. .clk = "wkupaon_iclk_mux",
  2144. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2145. };
  2146. static struct omap_hwmod_ocp_if dra7xx_l4_per2__cpgmac0 = {
  2147. .master = &dra7xx_l4_per2_hwmod,
  2148. .slave = &dra7xx_gmac_hwmod,
  2149. .clk = "dpll_gmac_ck",
  2150. .user = OCP_USER_MPU,
  2151. };
  2152. static struct omap_hwmod_ocp_if dra7xx_gmac__mdio = {
  2153. .master = &dra7xx_gmac_hwmod,
  2154. .slave = &dra7xx_mdio_hwmod,
  2155. .user = OCP_USER_MPU,
  2156. };
  2157. /* l4_wkup -> dcan1 */
  2158. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__dcan1 = {
  2159. .master = &dra7xx_l4_wkup_hwmod,
  2160. .slave = &dra7xx_dcan1_hwmod,
  2161. .clk = "wkupaon_iclk_mux",
  2162. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2163. };
  2164. /* l4_per2 -> dcan2 */
  2165. static struct omap_hwmod_ocp_if dra7xx_l4_per2__dcan2 = {
  2166. .master = &dra7xx_l4_per2_hwmod,
  2167. .slave = &dra7xx_dcan2_hwmod,
  2168. .clk = "l3_iclk_div",
  2169. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2170. };
  2171. static struct omap_hwmod_addr_space dra7xx_dma_system_addrs[] = {
  2172. {
  2173. .pa_start = 0x4a056000,
  2174. .pa_end = 0x4a056fff,
  2175. .flags = ADDR_TYPE_RT
  2176. },
  2177. { }
  2178. };
  2179. /* l4_cfg -> dma_system */
  2180. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__dma_system = {
  2181. .master = &dra7xx_l4_cfg_hwmod,
  2182. .slave = &dra7xx_dma_system_hwmod,
  2183. .clk = "l3_iclk_div",
  2184. .addr = dra7xx_dma_system_addrs,
  2185. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2186. };
  2187. static struct omap_hwmod_addr_space dra7xx_dss_addrs[] = {
  2188. {
  2189. .name = "family",
  2190. .pa_start = 0x58000000,
  2191. .pa_end = 0x5800007f,
  2192. .flags = ADDR_TYPE_RT
  2193. },
  2194. };
  2195. /* l3_main_1 -> dss */
  2196. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__dss = {
  2197. .master = &dra7xx_l3_main_1_hwmod,
  2198. .slave = &dra7xx_dss_hwmod,
  2199. .clk = "l3_iclk_div",
  2200. .addr = dra7xx_dss_addrs,
  2201. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2202. };
  2203. static struct omap_hwmod_addr_space dra7xx_dss_dispc_addrs[] = {
  2204. {
  2205. .name = "dispc",
  2206. .pa_start = 0x58001000,
  2207. .pa_end = 0x58001fff,
  2208. .flags = ADDR_TYPE_RT
  2209. },
  2210. };
  2211. /* l3_main_1 -> dispc */
  2212. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__dispc = {
  2213. .master = &dra7xx_l3_main_1_hwmod,
  2214. .slave = &dra7xx_dss_dispc_hwmod,
  2215. .clk = "l3_iclk_div",
  2216. .addr = dra7xx_dss_dispc_addrs,
  2217. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2218. };
  2219. static struct omap_hwmod_addr_space dra7xx_dss_hdmi_addrs[] = {
  2220. {
  2221. .name = "hdmi_wp",
  2222. .pa_start = 0x58040000,
  2223. .pa_end = 0x580400ff,
  2224. .flags = ADDR_TYPE_RT
  2225. },
  2226. { }
  2227. };
  2228. /* l3_main_1 -> dispc */
  2229. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__hdmi = {
  2230. .master = &dra7xx_l3_main_1_hwmod,
  2231. .slave = &dra7xx_dss_hdmi_hwmod,
  2232. .clk = "l3_iclk_div",
  2233. .addr = dra7xx_dss_hdmi_addrs,
  2234. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2235. };
  2236. static struct omap_hwmod_addr_space dra7xx_elm_addrs[] = {
  2237. {
  2238. .pa_start = 0x48078000,
  2239. .pa_end = 0x48078fff,
  2240. .flags = ADDR_TYPE_RT
  2241. },
  2242. { }
  2243. };
  2244. /* l4_per1 -> elm */
  2245. static struct omap_hwmod_ocp_if dra7xx_l4_per1__elm = {
  2246. .master = &dra7xx_l4_per1_hwmod,
  2247. .slave = &dra7xx_elm_hwmod,
  2248. .clk = "l3_iclk_div",
  2249. .addr = dra7xx_elm_addrs,
  2250. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2251. };
  2252. /* l4_wkup -> gpio1 */
  2253. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__gpio1 = {
  2254. .master = &dra7xx_l4_wkup_hwmod,
  2255. .slave = &dra7xx_gpio1_hwmod,
  2256. .clk = "wkupaon_iclk_mux",
  2257. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2258. };
  2259. /* l4_per1 -> gpio2 */
  2260. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio2 = {
  2261. .master = &dra7xx_l4_per1_hwmod,
  2262. .slave = &dra7xx_gpio2_hwmod,
  2263. .clk = "l3_iclk_div",
  2264. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2265. };
  2266. /* l4_per1 -> gpio3 */
  2267. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio3 = {
  2268. .master = &dra7xx_l4_per1_hwmod,
  2269. .slave = &dra7xx_gpio3_hwmod,
  2270. .clk = "l3_iclk_div",
  2271. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2272. };
  2273. /* l4_per1 -> gpio4 */
  2274. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio4 = {
  2275. .master = &dra7xx_l4_per1_hwmod,
  2276. .slave = &dra7xx_gpio4_hwmod,
  2277. .clk = "l3_iclk_div",
  2278. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2279. };
  2280. /* l4_per1 -> gpio5 */
  2281. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio5 = {
  2282. .master = &dra7xx_l4_per1_hwmod,
  2283. .slave = &dra7xx_gpio5_hwmod,
  2284. .clk = "l3_iclk_div",
  2285. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2286. };
  2287. /* l4_per1 -> gpio6 */
  2288. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio6 = {
  2289. .master = &dra7xx_l4_per1_hwmod,
  2290. .slave = &dra7xx_gpio6_hwmod,
  2291. .clk = "l3_iclk_div",
  2292. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2293. };
  2294. /* l4_per1 -> gpio7 */
  2295. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio7 = {
  2296. .master = &dra7xx_l4_per1_hwmod,
  2297. .slave = &dra7xx_gpio7_hwmod,
  2298. .clk = "l3_iclk_div",
  2299. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2300. };
  2301. /* l4_per1 -> gpio8 */
  2302. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio8 = {
  2303. .master = &dra7xx_l4_per1_hwmod,
  2304. .slave = &dra7xx_gpio8_hwmod,
  2305. .clk = "l3_iclk_div",
  2306. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2307. };
  2308. static struct omap_hwmod_addr_space dra7xx_gpmc_addrs[] = {
  2309. {
  2310. .pa_start = 0x50000000,
  2311. .pa_end = 0x500003ff,
  2312. .flags = ADDR_TYPE_RT
  2313. },
  2314. { }
  2315. };
  2316. /* l3_main_1 -> gpmc */
  2317. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__gpmc = {
  2318. .master = &dra7xx_l3_main_1_hwmod,
  2319. .slave = &dra7xx_gpmc_hwmod,
  2320. .clk = "l3_iclk_div",
  2321. .addr = dra7xx_gpmc_addrs,
  2322. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2323. };
  2324. static struct omap_hwmod_addr_space dra7xx_hdq1w_addrs[] = {
  2325. {
  2326. .pa_start = 0x480b2000,
  2327. .pa_end = 0x480b201f,
  2328. .flags = ADDR_TYPE_RT
  2329. },
  2330. { }
  2331. };
  2332. /* l4_per1 -> hdq1w */
  2333. static struct omap_hwmod_ocp_if dra7xx_l4_per1__hdq1w = {
  2334. .master = &dra7xx_l4_per1_hwmod,
  2335. .slave = &dra7xx_hdq1w_hwmod,
  2336. .clk = "l3_iclk_div",
  2337. .addr = dra7xx_hdq1w_addrs,
  2338. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2339. };
  2340. /* l4_per1 -> i2c1 */
  2341. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c1 = {
  2342. .master = &dra7xx_l4_per1_hwmod,
  2343. .slave = &dra7xx_i2c1_hwmod,
  2344. .clk = "l3_iclk_div",
  2345. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2346. };
  2347. /* l4_per1 -> i2c2 */
  2348. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c2 = {
  2349. .master = &dra7xx_l4_per1_hwmod,
  2350. .slave = &dra7xx_i2c2_hwmod,
  2351. .clk = "l3_iclk_div",
  2352. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2353. };
  2354. /* l4_per1 -> i2c3 */
  2355. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c3 = {
  2356. .master = &dra7xx_l4_per1_hwmod,
  2357. .slave = &dra7xx_i2c3_hwmod,
  2358. .clk = "l3_iclk_div",
  2359. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2360. };
  2361. /* l4_per1 -> i2c4 */
  2362. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c4 = {
  2363. .master = &dra7xx_l4_per1_hwmod,
  2364. .slave = &dra7xx_i2c4_hwmod,
  2365. .clk = "l3_iclk_div",
  2366. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2367. };
  2368. /* l4_per1 -> i2c5 */
  2369. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c5 = {
  2370. .master = &dra7xx_l4_per1_hwmod,
  2371. .slave = &dra7xx_i2c5_hwmod,
  2372. .clk = "l3_iclk_div",
  2373. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2374. };
  2375. /* l4_cfg -> mailbox1 */
  2376. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__mailbox1 = {
  2377. .master = &dra7xx_l4_cfg_hwmod,
  2378. .slave = &dra7xx_mailbox1_hwmod,
  2379. .clk = "l3_iclk_div",
  2380. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2381. };
  2382. /* l4_per3 -> mailbox2 */
  2383. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox2 = {
  2384. .master = &dra7xx_l4_per3_hwmod,
  2385. .slave = &dra7xx_mailbox2_hwmod,
  2386. .clk = "l3_iclk_div",
  2387. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2388. };
  2389. /* l4_per3 -> mailbox3 */
  2390. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox3 = {
  2391. .master = &dra7xx_l4_per3_hwmod,
  2392. .slave = &dra7xx_mailbox3_hwmod,
  2393. .clk = "l3_iclk_div",
  2394. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2395. };
  2396. /* l4_per3 -> mailbox4 */
  2397. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox4 = {
  2398. .master = &dra7xx_l4_per3_hwmod,
  2399. .slave = &dra7xx_mailbox4_hwmod,
  2400. .clk = "l3_iclk_div",
  2401. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2402. };
  2403. /* l4_per3 -> mailbox5 */
  2404. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox5 = {
  2405. .master = &dra7xx_l4_per3_hwmod,
  2406. .slave = &dra7xx_mailbox5_hwmod,
  2407. .clk = "l3_iclk_div",
  2408. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2409. };
  2410. /* l4_per3 -> mailbox6 */
  2411. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox6 = {
  2412. .master = &dra7xx_l4_per3_hwmod,
  2413. .slave = &dra7xx_mailbox6_hwmod,
  2414. .clk = "l3_iclk_div",
  2415. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2416. };
  2417. /* l4_per3 -> mailbox7 */
  2418. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox7 = {
  2419. .master = &dra7xx_l4_per3_hwmod,
  2420. .slave = &dra7xx_mailbox7_hwmod,
  2421. .clk = "l3_iclk_div",
  2422. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2423. };
  2424. /* l4_per3 -> mailbox8 */
  2425. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox8 = {
  2426. .master = &dra7xx_l4_per3_hwmod,
  2427. .slave = &dra7xx_mailbox8_hwmod,
  2428. .clk = "l3_iclk_div",
  2429. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2430. };
  2431. /* l4_per3 -> mailbox9 */
  2432. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox9 = {
  2433. .master = &dra7xx_l4_per3_hwmod,
  2434. .slave = &dra7xx_mailbox9_hwmod,
  2435. .clk = "l3_iclk_div",
  2436. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2437. };
  2438. /* l4_per3 -> mailbox10 */
  2439. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox10 = {
  2440. .master = &dra7xx_l4_per3_hwmod,
  2441. .slave = &dra7xx_mailbox10_hwmod,
  2442. .clk = "l3_iclk_div",
  2443. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2444. };
  2445. /* l4_per3 -> mailbox11 */
  2446. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox11 = {
  2447. .master = &dra7xx_l4_per3_hwmod,
  2448. .slave = &dra7xx_mailbox11_hwmod,
  2449. .clk = "l3_iclk_div",
  2450. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2451. };
  2452. /* l4_per3 -> mailbox12 */
  2453. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox12 = {
  2454. .master = &dra7xx_l4_per3_hwmod,
  2455. .slave = &dra7xx_mailbox12_hwmod,
  2456. .clk = "l3_iclk_div",
  2457. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2458. };
  2459. /* l4_per3 -> mailbox13 */
  2460. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox13 = {
  2461. .master = &dra7xx_l4_per3_hwmod,
  2462. .slave = &dra7xx_mailbox13_hwmod,
  2463. .clk = "l3_iclk_div",
  2464. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2465. };
  2466. /* l4_per1 -> mcspi1 */
  2467. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi1 = {
  2468. .master = &dra7xx_l4_per1_hwmod,
  2469. .slave = &dra7xx_mcspi1_hwmod,
  2470. .clk = "l3_iclk_div",
  2471. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2472. };
  2473. /* l4_per1 -> mcspi2 */
  2474. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi2 = {
  2475. .master = &dra7xx_l4_per1_hwmod,
  2476. .slave = &dra7xx_mcspi2_hwmod,
  2477. .clk = "l3_iclk_div",
  2478. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2479. };
  2480. /* l4_per1 -> mcspi3 */
  2481. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi3 = {
  2482. .master = &dra7xx_l4_per1_hwmod,
  2483. .slave = &dra7xx_mcspi3_hwmod,
  2484. .clk = "l3_iclk_div",
  2485. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2486. };
  2487. /* l4_per1 -> mcspi4 */
  2488. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi4 = {
  2489. .master = &dra7xx_l4_per1_hwmod,
  2490. .slave = &dra7xx_mcspi4_hwmod,
  2491. .clk = "l3_iclk_div",
  2492. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2493. };
  2494. /* l4_per1 -> mmc1 */
  2495. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc1 = {
  2496. .master = &dra7xx_l4_per1_hwmod,
  2497. .slave = &dra7xx_mmc1_hwmod,
  2498. .clk = "l3_iclk_div",
  2499. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2500. };
  2501. /* l4_per1 -> mmc2 */
  2502. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc2 = {
  2503. .master = &dra7xx_l4_per1_hwmod,
  2504. .slave = &dra7xx_mmc2_hwmod,
  2505. .clk = "l3_iclk_div",
  2506. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2507. };
  2508. /* l4_per1 -> mmc3 */
  2509. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc3 = {
  2510. .master = &dra7xx_l4_per1_hwmod,
  2511. .slave = &dra7xx_mmc3_hwmod,
  2512. .clk = "l3_iclk_div",
  2513. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2514. };
  2515. /* l4_per1 -> mmc4 */
  2516. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc4 = {
  2517. .master = &dra7xx_l4_per1_hwmod,
  2518. .slave = &dra7xx_mmc4_hwmod,
  2519. .clk = "l3_iclk_div",
  2520. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2521. };
  2522. /* l4_cfg -> mpu */
  2523. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__mpu = {
  2524. .master = &dra7xx_l4_cfg_hwmod,
  2525. .slave = &dra7xx_mpu_hwmod,
  2526. .clk = "l3_iclk_div",
  2527. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2528. };
  2529. /* l4_cfg -> ocp2scp1 */
  2530. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__ocp2scp1 = {
  2531. .master = &dra7xx_l4_cfg_hwmod,
  2532. .slave = &dra7xx_ocp2scp1_hwmod,
  2533. .clk = "l4_root_clk_div",
  2534. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2535. };
  2536. /* l4_cfg -> ocp2scp3 */
  2537. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__ocp2scp3 = {
  2538. .master = &dra7xx_l4_cfg_hwmod,
  2539. .slave = &dra7xx_ocp2scp3_hwmod,
  2540. .clk = "l4_root_clk_div",
  2541. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2542. };
  2543. /* l3_main_1 -> pciess1 */
  2544. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__pciess1 = {
  2545. .master = &dra7xx_l3_main_1_hwmod,
  2546. .slave = &dra7xx_pciess1_hwmod,
  2547. .clk = "l3_iclk_div",
  2548. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2549. };
  2550. /* l4_cfg -> pciess1 */
  2551. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__pciess1 = {
  2552. .master = &dra7xx_l4_cfg_hwmod,
  2553. .slave = &dra7xx_pciess1_hwmod,
  2554. .clk = "l4_root_clk_div",
  2555. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2556. };
  2557. /* l3_main_1 -> pciess2 */
  2558. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__pciess2 = {
  2559. .master = &dra7xx_l3_main_1_hwmod,
  2560. .slave = &dra7xx_pciess2_hwmod,
  2561. .clk = "l3_iclk_div",
  2562. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2563. };
  2564. /* l4_cfg -> pciess2 */
  2565. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__pciess2 = {
  2566. .master = &dra7xx_l4_cfg_hwmod,
  2567. .slave = &dra7xx_pciess2_hwmod,
  2568. .clk = "l4_root_clk_div",
  2569. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2570. };
  2571. static struct omap_hwmod_addr_space dra7xx_qspi_addrs[] = {
  2572. {
  2573. .pa_start = 0x4b300000,
  2574. .pa_end = 0x4b30007f,
  2575. .flags = ADDR_TYPE_RT
  2576. },
  2577. { }
  2578. };
  2579. /* l3_main_1 -> qspi */
  2580. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__qspi = {
  2581. .master = &dra7xx_l3_main_1_hwmod,
  2582. .slave = &dra7xx_qspi_hwmod,
  2583. .clk = "l3_iclk_div",
  2584. .addr = dra7xx_qspi_addrs,
  2585. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2586. };
  2587. /* l4_per3 -> rtcss */
  2588. static struct omap_hwmod_ocp_if dra7xx_l4_per3__rtcss = {
  2589. .master = &dra7xx_l4_per3_hwmod,
  2590. .slave = &dra7xx_rtcss_hwmod,
  2591. .clk = "l4_root_clk_div",
  2592. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2593. };
  2594. static struct omap_hwmod_addr_space dra7xx_sata_addrs[] = {
  2595. {
  2596. .name = "sysc",
  2597. .pa_start = 0x4a141100,
  2598. .pa_end = 0x4a141107,
  2599. .flags = ADDR_TYPE_RT
  2600. },
  2601. { }
  2602. };
  2603. /* l4_cfg -> sata */
  2604. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__sata = {
  2605. .master = &dra7xx_l4_cfg_hwmod,
  2606. .slave = &dra7xx_sata_hwmod,
  2607. .clk = "l3_iclk_div",
  2608. .addr = dra7xx_sata_addrs,
  2609. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2610. };
  2611. static struct omap_hwmod_addr_space dra7xx_smartreflex_core_addrs[] = {
  2612. {
  2613. .pa_start = 0x4a0dd000,
  2614. .pa_end = 0x4a0dd07f,
  2615. .flags = ADDR_TYPE_RT
  2616. },
  2617. { }
  2618. };
  2619. /* l4_cfg -> smartreflex_core */
  2620. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__smartreflex_core = {
  2621. .master = &dra7xx_l4_cfg_hwmod,
  2622. .slave = &dra7xx_smartreflex_core_hwmod,
  2623. .clk = "l4_root_clk_div",
  2624. .addr = dra7xx_smartreflex_core_addrs,
  2625. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2626. };
  2627. static struct omap_hwmod_addr_space dra7xx_smartreflex_mpu_addrs[] = {
  2628. {
  2629. .pa_start = 0x4a0d9000,
  2630. .pa_end = 0x4a0d907f,
  2631. .flags = ADDR_TYPE_RT
  2632. },
  2633. { }
  2634. };
  2635. /* l4_cfg -> smartreflex_mpu */
  2636. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__smartreflex_mpu = {
  2637. .master = &dra7xx_l4_cfg_hwmod,
  2638. .slave = &dra7xx_smartreflex_mpu_hwmod,
  2639. .clk = "l4_root_clk_div",
  2640. .addr = dra7xx_smartreflex_mpu_addrs,
  2641. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2642. };
  2643. static struct omap_hwmod_addr_space dra7xx_spinlock_addrs[] = {
  2644. {
  2645. .pa_start = 0x4a0f6000,
  2646. .pa_end = 0x4a0f6fff,
  2647. .flags = ADDR_TYPE_RT
  2648. },
  2649. { }
  2650. };
  2651. /* l4_cfg -> spinlock */
  2652. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__spinlock = {
  2653. .master = &dra7xx_l4_cfg_hwmod,
  2654. .slave = &dra7xx_spinlock_hwmod,
  2655. .clk = "l3_iclk_div",
  2656. .addr = dra7xx_spinlock_addrs,
  2657. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2658. };
  2659. /* l4_wkup -> timer1 */
  2660. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__timer1 = {
  2661. .master = &dra7xx_l4_wkup_hwmod,
  2662. .slave = &dra7xx_timer1_hwmod,
  2663. .clk = "wkupaon_iclk_mux",
  2664. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2665. };
  2666. /* l4_per1 -> timer2 */
  2667. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer2 = {
  2668. .master = &dra7xx_l4_per1_hwmod,
  2669. .slave = &dra7xx_timer2_hwmod,
  2670. .clk = "l3_iclk_div",
  2671. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2672. };
  2673. /* l4_per1 -> timer3 */
  2674. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer3 = {
  2675. .master = &dra7xx_l4_per1_hwmod,
  2676. .slave = &dra7xx_timer3_hwmod,
  2677. .clk = "l3_iclk_div",
  2678. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2679. };
  2680. /* l4_per1 -> timer4 */
  2681. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer4 = {
  2682. .master = &dra7xx_l4_per1_hwmod,
  2683. .slave = &dra7xx_timer4_hwmod,
  2684. .clk = "l3_iclk_div",
  2685. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2686. };
  2687. /* l4_per3 -> timer5 */
  2688. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer5 = {
  2689. .master = &dra7xx_l4_per3_hwmod,
  2690. .slave = &dra7xx_timer5_hwmod,
  2691. .clk = "l3_iclk_div",
  2692. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2693. };
  2694. /* l4_per3 -> timer6 */
  2695. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer6 = {
  2696. .master = &dra7xx_l4_per3_hwmod,
  2697. .slave = &dra7xx_timer6_hwmod,
  2698. .clk = "l3_iclk_div",
  2699. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2700. };
  2701. /* l4_per3 -> timer7 */
  2702. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer7 = {
  2703. .master = &dra7xx_l4_per3_hwmod,
  2704. .slave = &dra7xx_timer7_hwmod,
  2705. .clk = "l3_iclk_div",
  2706. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2707. };
  2708. /* l4_per3 -> timer8 */
  2709. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer8 = {
  2710. .master = &dra7xx_l4_per3_hwmod,
  2711. .slave = &dra7xx_timer8_hwmod,
  2712. .clk = "l3_iclk_div",
  2713. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2714. };
  2715. /* l4_per1 -> timer9 */
  2716. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer9 = {
  2717. .master = &dra7xx_l4_per1_hwmod,
  2718. .slave = &dra7xx_timer9_hwmod,
  2719. .clk = "l3_iclk_div",
  2720. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2721. };
  2722. /* l4_per1 -> timer10 */
  2723. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer10 = {
  2724. .master = &dra7xx_l4_per1_hwmod,
  2725. .slave = &dra7xx_timer10_hwmod,
  2726. .clk = "l3_iclk_div",
  2727. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2728. };
  2729. /* l4_per1 -> timer11 */
  2730. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer11 = {
  2731. .master = &dra7xx_l4_per1_hwmod,
  2732. .slave = &dra7xx_timer11_hwmod,
  2733. .clk = "l3_iclk_div",
  2734. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2735. };
  2736. /* l4_per1 -> uart1 */
  2737. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart1 = {
  2738. .master = &dra7xx_l4_per1_hwmod,
  2739. .slave = &dra7xx_uart1_hwmod,
  2740. .clk = "l3_iclk_div",
  2741. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2742. };
  2743. /* l4_per1 -> uart2 */
  2744. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart2 = {
  2745. .master = &dra7xx_l4_per1_hwmod,
  2746. .slave = &dra7xx_uart2_hwmod,
  2747. .clk = "l3_iclk_div",
  2748. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2749. };
  2750. /* l4_per1 -> uart3 */
  2751. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart3 = {
  2752. .master = &dra7xx_l4_per1_hwmod,
  2753. .slave = &dra7xx_uart3_hwmod,
  2754. .clk = "l3_iclk_div",
  2755. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2756. };
  2757. /* l4_per1 -> uart4 */
  2758. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart4 = {
  2759. .master = &dra7xx_l4_per1_hwmod,
  2760. .slave = &dra7xx_uart4_hwmod,
  2761. .clk = "l3_iclk_div",
  2762. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2763. };
  2764. /* l4_per1 -> uart5 */
  2765. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart5 = {
  2766. .master = &dra7xx_l4_per1_hwmod,
  2767. .slave = &dra7xx_uart5_hwmod,
  2768. .clk = "l3_iclk_div",
  2769. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2770. };
  2771. /* l4_per1 -> uart6 */
  2772. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart6 = {
  2773. .master = &dra7xx_l4_per1_hwmod,
  2774. .slave = &dra7xx_uart6_hwmod,
  2775. .clk = "l3_iclk_div",
  2776. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2777. };
  2778. /* l4_per2 -> uart7 */
  2779. static struct omap_hwmod_ocp_if dra7xx_l4_per2__uart7 = {
  2780. .master = &dra7xx_l4_per2_hwmod,
  2781. .slave = &dra7xx_uart7_hwmod,
  2782. .clk = "l3_iclk_div",
  2783. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2784. };
  2785. /* l4_per2 -> uart8 */
  2786. static struct omap_hwmod_ocp_if dra7xx_l4_per2__uart8 = {
  2787. .master = &dra7xx_l4_per2_hwmod,
  2788. .slave = &dra7xx_uart8_hwmod,
  2789. .clk = "l3_iclk_div",
  2790. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2791. };
  2792. /* l4_per2 -> uart9 */
  2793. static struct omap_hwmod_ocp_if dra7xx_l4_per2__uart9 = {
  2794. .master = &dra7xx_l4_per2_hwmod,
  2795. .slave = &dra7xx_uart9_hwmod,
  2796. .clk = "l3_iclk_div",
  2797. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2798. };
  2799. /* l4_wkup -> uart10 */
  2800. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__uart10 = {
  2801. .master = &dra7xx_l4_wkup_hwmod,
  2802. .slave = &dra7xx_uart10_hwmod,
  2803. .clk = "wkupaon_iclk_mux",
  2804. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2805. };
  2806. /* l4_per3 -> usb_otg_ss1 */
  2807. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss1 = {
  2808. .master = &dra7xx_l4_per3_hwmod,
  2809. .slave = &dra7xx_usb_otg_ss1_hwmod,
  2810. .clk = "dpll_core_h13x2_ck",
  2811. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2812. };
  2813. /* l4_per3 -> usb_otg_ss2 */
  2814. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss2 = {
  2815. .master = &dra7xx_l4_per3_hwmod,
  2816. .slave = &dra7xx_usb_otg_ss2_hwmod,
  2817. .clk = "dpll_core_h13x2_ck",
  2818. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2819. };
  2820. /* l4_per3 -> usb_otg_ss3 */
  2821. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss3 = {
  2822. .master = &dra7xx_l4_per3_hwmod,
  2823. .slave = &dra7xx_usb_otg_ss3_hwmod,
  2824. .clk = "dpll_core_h13x2_ck",
  2825. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2826. };
  2827. /* l4_per3 -> usb_otg_ss4 */
  2828. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss4 = {
  2829. .master = &dra7xx_l4_per3_hwmod,
  2830. .slave = &dra7xx_usb_otg_ss4_hwmod,
  2831. .clk = "dpll_core_h13x2_ck",
  2832. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2833. };
  2834. /* l3_main_1 -> vcp1 */
  2835. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__vcp1 = {
  2836. .master = &dra7xx_l3_main_1_hwmod,
  2837. .slave = &dra7xx_vcp1_hwmod,
  2838. .clk = "l3_iclk_div",
  2839. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2840. };
  2841. /* l4_per2 -> vcp1 */
  2842. static struct omap_hwmod_ocp_if dra7xx_l4_per2__vcp1 = {
  2843. .master = &dra7xx_l4_per2_hwmod,
  2844. .slave = &dra7xx_vcp1_hwmod,
  2845. .clk = "l3_iclk_div",
  2846. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2847. };
  2848. /* l3_main_1 -> vcp2 */
  2849. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__vcp2 = {
  2850. .master = &dra7xx_l3_main_1_hwmod,
  2851. .slave = &dra7xx_vcp2_hwmod,
  2852. .clk = "l3_iclk_div",
  2853. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2854. };
  2855. /* l4_per2 -> vcp2 */
  2856. static struct omap_hwmod_ocp_if dra7xx_l4_per2__vcp2 = {
  2857. .master = &dra7xx_l4_per2_hwmod,
  2858. .slave = &dra7xx_vcp2_hwmod,
  2859. .clk = "l3_iclk_div",
  2860. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2861. };
  2862. /* l4_wkup -> wd_timer2 */
  2863. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__wd_timer2 = {
  2864. .master = &dra7xx_l4_wkup_hwmod,
  2865. .slave = &dra7xx_wd_timer2_hwmod,
  2866. .clk = "wkupaon_iclk_mux",
  2867. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2868. };
  2869. static struct omap_hwmod_ocp_if *dra7xx_hwmod_ocp_ifs[] __initdata = {
  2870. &dra7xx_l3_main_2__l3_instr,
  2871. &dra7xx_l4_cfg__l3_main_1,
  2872. &dra7xx_mpu__l3_main_1,
  2873. &dra7xx_l3_main_1__l3_main_2,
  2874. &dra7xx_l4_cfg__l3_main_2,
  2875. &dra7xx_l3_main_1__l4_cfg,
  2876. &dra7xx_l3_main_1__l4_per1,
  2877. &dra7xx_l3_main_1__l4_per2,
  2878. &dra7xx_l3_main_1__l4_per3,
  2879. &dra7xx_l3_main_1__l4_wkup,
  2880. &dra7xx_l4_per2__atl,
  2881. &dra7xx_l3_main_1__bb2d,
  2882. &dra7xx_l4_wkup__counter_32k,
  2883. &dra7xx_l4_wkup__ctrl_module_wkup,
  2884. &dra7xx_l4_wkup__dcan1,
  2885. &dra7xx_l4_per2__dcan2,
  2886. &dra7xx_l4_per2__cpgmac0,
  2887. &dra7xx_gmac__mdio,
  2888. &dra7xx_l4_cfg__dma_system,
  2889. &dra7xx_l3_main_1__dss,
  2890. &dra7xx_l3_main_1__dispc,
  2891. &dra7xx_l3_main_1__hdmi,
  2892. &dra7xx_l4_per1__elm,
  2893. &dra7xx_l4_wkup__gpio1,
  2894. &dra7xx_l4_per1__gpio2,
  2895. &dra7xx_l4_per1__gpio3,
  2896. &dra7xx_l4_per1__gpio4,
  2897. &dra7xx_l4_per1__gpio5,
  2898. &dra7xx_l4_per1__gpio6,
  2899. &dra7xx_l4_per1__gpio7,
  2900. &dra7xx_l4_per1__gpio8,
  2901. &dra7xx_l3_main_1__gpmc,
  2902. &dra7xx_l4_per1__hdq1w,
  2903. &dra7xx_l4_per1__i2c1,
  2904. &dra7xx_l4_per1__i2c2,
  2905. &dra7xx_l4_per1__i2c3,
  2906. &dra7xx_l4_per1__i2c4,
  2907. &dra7xx_l4_per1__i2c5,
  2908. &dra7xx_l4_cfg__mailbox1,
  2909. &dra7xx_l4_per3__mailbox2,
  2910. &dra7xx_l4_per3__mailbox3,
  2911. &dra7xx_l4_per3__mailbox4,
  2912. &dra7xx_l4_per3__mailbox5,
  2913. &dra7xx_l4_per3__mailbox6,
  2914. &dra7xx_l4_per3__mailbox7,
  2915. &dra7xx_l4_per3__mailbox8,
  2916. &dra7xx_l4_per3__mailbox9,
  2917. &dra7xx_l4_per3__mailbox10,
  2918. &dra7xx_l4_per3__mailbox11,
  2919. &dra7xx_l4_per3__mailbox12,
  2920. &dra7xx_l4_per3__mailbox13,
  2921. &dra7xx_l4_per1__mcspi1,
  2922. &dra7xx_l4_per1__mcspi2,
  2923. &dra7xx_l4_per1__mcspi3,
  2924. &dra7xx_l4_per1__mcspi4,
  2925. &dra7xx_l4_per1__mmc1,
  2926. &dra7xx_l4_per1__mmc2,
  2927. &dra7xx_l4_per1__mmc3,
  2928. &dra7xx_l4_per1__mmc4,
  2929. &dra7xx_l4_cfg__mpu,
  2930. &dra7xx_l4_cfg__ocp2scp1,
  2931. &dra7xx_l4_cfg__ocp2scp3,
  2932. &dra7xx_l3_main_1__pciess1,
  2933. &dra7xx_l4_cfg__pciess1,
  2934. &dra7xx_l3_main_1__pciess2,
  2935. &dra7xx_l4_cfg__pciess2,
  2936. &dra7xx_l3_main_1__qspi,
  2937. &dra7xx_l4_per3__rtcss,
  2938. &dra7xx_l4_cfg__sata,
  2939. &dra7xx_l4_cfg__smartreflex_core,
  2940. &dra7xx_l4_cfg__smartreflex_mpu,
  2941. &dra7xx_l4_cfg__spinlock,
  2942. &dra7xx_l4_wkup__timer1,
  2943. &dra7xx_l4_per1__timer2,
  2944. &dra7xx_l4_per1__timer3,
  2945. &dra7xx_l4_per1__timer4,
  2946. &dra7xx_l4_per3__timer5,
  2947. &dra7xx_l4_per3__timer6,
  2948. &dra7xx_l4_per3__timer7,
  2949. &dra7xx_l4_per3__timer8,
  2950. &dra7xx_l4_per1__timer9,
  2951. &dra7xx_l4_per1__timer10,
  2952. &dra7xx_l4_per1__timer11,
  2953. &dra7xx_l4_per1__uart1,
  2954. &dra7xx_l4_per1__uart2,
  2955. &dra7xx_l4_per1__uart3,
  2956. &dra7xx_l4_per1__uart4,
  2957. &dra7xx_l4_per1__uart5,
  2958. &dra7xx_l4_per1__uart6,
  2959. &dra7xx_l4_per2__uart7,
  2960. &dra7xx_l4_per2__uart8,
  2961. &dra7xx_l4_per2__uart9,
  2962. &dra7xx_l4_wkup__uart10,
  2963. &dra7xx_l4_per3__usb_otg_ss1,
  2964. &dra7xx_l4_per3__usb_otg_ss2,
  2965. &dra7xx_l4_per3__usb_otg_ss3,
  2966. &dra7xx_l3_main_1__vcp1,
  2967. &dra7xx_l4_per2__vcp1,
  2968. &dra7xx_l3_main_1__vcp2,
  2969. &dra7xx_l4_per2__vcp2,
  2970. &dra7xx_l4_wkup__wd_timer2,
  2971. NULL,
  2972. };
  2973. static struct omap_hwmod_ocp_if *dra74x_hwmod_ocp_ifs[] __initdata = {
  2974. &dra7xx_l4_per3__usb_otg_ss4,
  2975. NULL,
  2976. };
  2977. static struct omap_hwmod_ocp_if *dra72x_hwmod_ocp_ifs[] __initdata = {
  2978. NULL,
  2979. };
  2980. int __init dra7xx_hwmod_init(void)
  2981. {
  2982. int ret;
  2983. omap_hwmod_init();
  2984. ret = omap_hwmod_register_links(dra7xx_hwmod_ocp_ifs);
  2985. if (!ret && soc_is_dra74x())
  2986. return omap_hwmod_register_links(dra74x_hwmod_ocp_ifs);
  2987. else if (!ret && soc_is_dra72x())
  2988. return omap_hwmod_register_links(dra72x_hwmod_ocp_ifs);
  2989. return ret;
  2990. }