omap_hwmod_7xx_data.c 117 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648
  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/hsmmc-omap.h>
  21. #include <linux/power/smartreflex.h>
  22. #include <linux/platform_data/i2c-omap.h>
  23. #include <linux/omap-dma.h>
  24. #include "omap_hwmod.h"
  25. #include "omap_hwmod_common_data.h"
  26. #include "cm1_7xx.h"
  27. #include "cm2_7xx.h"
  28. #include "prm7xx.h"
  29. #include "i2c.h"
  30. #include "wd_timer.h"
  31. #include "soc.h"
  32. /* Base offset for all DRA7XX interrupts external to MPUSS */
  33. #define DRA7XX_IRQ_GIC_START 32
  34. /* Base offset for all DRA7XX dma requests */
  35. #define DRA7XX_DMA_REQ_START 1
  36. /*
  37. * IP blocks
  38. */
  39. /*
  40. * 'dmm' class
  41. * instance(s): dmm
  42. */
  43. static struct omap_hwmod_class dra7xx_dmm_hwmod_class = {
  44. .name = "dmm",
  45. };
  46. /* dmm */
  47. static struct omap_hwmod dra7xx_dmm_hwmod = {
  48. .name = "dmm",
  49. .class = &dra7xx_dmm_hwmod_class,
  50. .clkdm_name = "emif_clkdm",
  51. .prcm = {
  52. .omap4 = {
  53. .clkctrl_offs = DRA7XX_CM_EMIF_DMM_CLKCTRL_OFFSET,
  54. .context_offs = DRA7XX_RM_EMIF_DMM_CONTEXT_OFFSET,
  55. },
  56. },
  57. };
  58. /*
  59. * 'l3' class
  60. * instance(s): l3_instr, l3_main_1, l3_main_2
  61. */
  62. static struct omap_hwmod_class dra7xx_l3_hwmod_class = {
  63. .name = "l3",
  64. };
  65. /* l3_instr */
  66. static struct omap_hwmod dra7xx_l3_instr_hwmod = {
  67. .name = "l3_instr",
  68. .class = &dra7xx_l3_hwmod_class,
  69. .clkdm_name = "l3instr_clkdm",
  70. .prcm = {
  71. .omap4 = {
  72. .clkctrl_offs = DRA7XX_CM_L3INSTR_L3_INSTR_CLKCTRL_OFFSET,
  73. .context_offs = DRA7XX_RM_L3INSTR_L3_INSTR_CONTEXT_OFFSET,
  74. .modulemode = MODULEMODE_HWCTRL,
  75. },
  76. },
  77. };
  78. /* l3_main_1 */
  79. static struct omap_hwmod dra7xx_l3_main_1_hwmod = {
  80. .name = "l3_main_1",
  81. .class = &dra7xx_l3_hwmod_class,
  82. .clkdm_name = "l3main1_clkdm",
  83. .prcm = {
  84. .omap4 = {
  85. .clkctrl_offs = DRA7XX_CM_L3MAIN1_L3_MAIN_1_CLKCTRL_OFFSET,
  86. .context_offs = DRA7XX_RM_L3MAIN1_L3_MAIN_1_CONTEXT_OFFSET,
  87. },
  88. },
  89. };
  90. /* l3_main_2 */
  91. static struct omap_hwmod dra7xx_l3_main_2_hwmod = {
  92. .name = "l3_main_2",
  93. .class = &dra7xx_l3_hwmod_class,
  94. .clkdm_name = "l3instr_clkdm",
  95. .prcm = {
  96. .omap4 = {
  97. .clkctrl_offs = DRA7XX_CM_L3INSTR_L3_MAIN_2_CLKCTRL_OFFSET,
  98. .context_offs = DRA7XX_RM_L3INSTR_L3_MAIN_2_CONTEXT_OFFSET,
  99. .modulemode = MODULEMODE_HWCTRL,
  100. },
  101. },
  102. };
  103. /*
  104. * 'l4' class
  105. * instance(s): l4_cfg, l4_per1, l4_per2, l4_per3, l4_wkup
  106. */
  107. static struct omap_hwmod_class dra7xx_l4_hwmod_class = {
  108. .name = "l4",
  109. };
  110. /* l4_cfg */
  111. static struct omap_hwmod dra7xx_l4_cfg_hwmod = {
  112. .name = "l4_cfg",
  113. .class = &dra7xx_l4_hwmod_class,
  114. .clkdm_name = "l4cfg_clkdm",
  115. .prcm = {
  116. .omap4 = {
  117. .clkctrl_offs = DRA7XX_CM_L4CFG_L4_CFG_CLKCTRL_OFFSET,
  118. .context_offs = DRA7XX_RM_L4CFG_L4_CFG_CONTEXT_OFFSET,
  119. },
  120. },
  121. };
  122. /* l4_per1 */
  123. static struct omap_hwmod dra7xx_l4_per1_hwmod = {
  124. .name = "l4_per1",
  125. .class = &dra7xx_l4_hwmod_class,
  126. .clkdm_name = "l4per_clkdm",
  127. .prcm = {
  128. .omap4 = {
  129. .clkctrl_offs = DRA7XX_CM_L4PER_L4_PER1_CLKCTRL_OFFSET,
  130. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  131. },
  132. },
  133. };
  134. /* l4_per2 */
  135. static struct omap_hwmod dra7xx_l4_per2_hwmod = {
  136. .name = "l4_per2",
  137. .class = &dra7xx_l4_hwmod_class,
  138. .clkdm_name = "l4per2_clkdm",
  139. .prcm = {
  140. .omap4 = {
  141. .clkctrl_offs = DRA7XX_CM_L4PER2_L4_PER2_CLKCTRL_OFFSET,
  142. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  143. },
  144. },
  145. };
  146. /* l4_per3 */
  147. static struct omap_hwmod dra7xx_l4_per3_hwmod = {
  148. .name = "l4_per3",
  149. .class = &dra7xx_l4_hwmod_class,
  150. .clkdm_name = "l4per3_clkdm",
  151. .prcm = {
  152. .omap4 = {
  153. .clkctrl_offs = DRA7XX_CM_L4PER3_L4_PER3_CLKCTRL_OFFSET,
  154. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  155. },
  156. },
  157. };
  158. /* l4_wkup */
  159. static struct omap_hwmod dra7xx_l4_wkup_hwmod = {
  160. .name = "l4_wkup",
  161. .class = &dra7xx_l4_hwmod_class,
  162. .clkdm_name = "wkupaon_clkdm",
  163. .prcm = {
  164. .omap4 = {
  165. .clkctrl_offs = DRA7XX_CM_WKUPAON_L4_WKUP_CLKCTRL_OFFSET,
  166. .context_offs = DRA7XX_RM_WKUPAON_L4_WKUP_CONTEXT_OFFSET,
  167. },
  168. },
  169. };
  170. /*
  171. * 'atl' class
  172. *
  173. */
  174. static struct omap_hwmod_class dra7xx_atl_hwmod_class = {
  175. .name = "atl",
  176. };
  177. /* atl */
  178. static struct omap_hwmod dra7xx_atl_hwmod = {
  179. .name = "atl",
  180. .class = &dra7xx_atl_hwmod_class,
  181. .clkdm_name = "atl_clkdm",
  182. .main_clk = "atl_gfclk_mux",
  183. .prcm = {
  184. .omap4 = {
  185. .clkctrl_offs = DRA7XX_CM_ATL_ATL_CLKCTRL_OFFSET,
  186. .context_offs = DRA7XX_RM_ATL_ATL_CONTEXT_OFFSET,
  187. .modulemode = MODULEMODE_SWCTRL,
  188. },
  189. },
  190. };
  191. /*
  192. * 'bb2d' class
  193. *
  194. */
  195. static struct omap_hwmod_class dra7xx_bb2d_hwmod_class = {
  196. .name = "bb2d",
  197. };
  198. /* bb2d */
  199. static struct omap_hwmod dra7xx_bb2d_hwmod = {
  200. .name = "bb2d",
  201. .class = &dra7xx_bb2d_hwmod_class,
  202. .clkdm_name = "dss_clkdm",
  203. .main_clk = "dpll_core_h24x2_ck",
  204. .prcm = {
  205. .omap4 = {
  206. .clkctrl_offs = DRA7XX_CM_DSS_BB2D_CLKCTRL_OFFSET,
  207. .context_offs = DRA7XX_RM_DSS_BB2D_CONTEXT_OFFSET,
  208. .modulemode = MODULEMODE_SWCTRL,
  209. },
  210. },
  211. };
  212. /*
  213. * 'vpe' class
  214. *
  215. */
  216. static struct omap_hwmod_class_sysconfig dra7xx_vpe_sysc = {
  217. .rev_offs = -ENODEV,
  218. .sysc_offs = 0x0010,
  219. .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
  220. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  221. MSTANDBY_FORCE | MSTANDBY_NO |
  222. MSTANDBY_SMART),
  223. .sysc_fields = &omap_hwmod_sysc_type2,
  224. };
  225. static struct omap_hwmod_class dra7xx_vpe_hwmod_class = {
  226. .name = "vpe",
  227. .sysc = &dra7xx_vpe_sysc,
  228. };
  229. /* vpe */
  230. static struct omap_hwmod dra7xx_vpe_hwmod = {
  231. .name = "vpe",
  232. .class = &dra7xx_vpe_hwmod_class,
  233. .clkdm_name = "vpe_clkdm",
  234. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  235. .prcm = {
  236. .omap4 = {
  237. .clkctrl_offs = DRA7XX_CM_VPE_VPE_CLKCTRL_OFFSET,
  238. .context_offs = DRA7XX_RM_VPE_VPE_CONTEXT_OFFSET,
  239. .modulemode = MODULEMODE_HWCTRL,
  240. },
  241. },
  242. };
  243. /*
  244. * 'vip' class
  245. *
  246. */
  247. static struct omap_hwmod_class_sysconfig dra7xx_vip_sysc = {
  248. .rev_offs = -ENODEV,
  249. .sysc_offs = 0x0010,
  250. .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
  251. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  252. MSTANDBY_FORCE | MSTANDBY_NO |
  253. MSTANDBY_SMART),
  254. .sysc_fields = &omap_hwmod_sysc_type2,
  255. };
  256. static struct omap_hwmod_class dra7xx_vip_hwmod_class = {
  257. .name = "vip",
  258. .sysc = &dra7xx_vip_sysc,
  259. };
  260. /* vip1 */
  261. static struct omap_hwmod dra7xx_vip1_hwmod = {
  262. .name = "vip1",
  263. .class = &dra7xx_vip_hwmod_class,
  264. .clkdm_name = "cam_clkdm",
  265. .main_clk = "vip1_gclk_mux",
  266. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  267. .prcm = {
  268. .omap4 = {
  269. .clkctrl_offs = DRA7XX_CM_CAM_VIP1_CLKCTRL_OFFSET,
  270. .context_offs = DRA7XX_RM_CAM_VIP1_CONTEXT_OFFSET,
  271. .modulemode = MODULEMODE_HWCTRL,
  272. },
  273. },
  274. };
  275. /* vip2 */
  276. static struct omap_hwmod dra7xx_vip2_hwmod = {
  277. .name = "vip2",
  278. .class = &dra7xx_vip_hwmod_class,
  279. .clkdm_name = "cam_clkdm",
  280. .main_clk = "vip2_gclk_mux",
  281. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  282. .prcm = {
  283. .omap4 = {
  284. .clkctrl_offs = DRA7XX_CM_CAM_VIP2_CLKCTRL_OFFSET,
  285. .context_offs = DRA7XX_RM_CAM_VIP2_CONTEXT_OFFSET,
  286. .modulemode = MODULEMODE_HWCTRL,
  287. },
  288. },
  289. };
  290. /* vip3 */
  291. static struct omap_hwmod dra7xx_vip3_hwmod = {
  292. .name = "vip3",
  293. .class = &dra7xx_vip_hwmod_class,
  294. .clkdm_name = "cam_clkdm",
  295. .main_clk = "vip3_gclk_mux",
  296. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  297. .prcm = {
  298. .omap4 = {
  299. .clkctrl_offs = DRA7XX_CM_CAM_VIP3_CLKCTRL_OFFSET,
  300. .context_offs = DRA7XX_RM_CAM_VIP3_CONTEXT_OFFSET,
  301. .modulemode = MODULEMODE_HWCTRL,
  302. },
  303. },
  304. };
  305. /*
  306. * 'cal' class
  307. *
  308. */
  309. static struct omap_hwmod_class_sysconfig dra7xx_cal_sysc = {
  310. .rev_offs = 0x0000,
  311. .sysc_offs = 0x0010,
  312. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_RESET_STATUS |
  313. SYSC_HAS_SOFTRESET | SYSC_HAS_MIDLEMODE),
  314. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  315. MSTANDBY_FORCE | MSTANDBY_NO),
  316. .sysc_fields = &omap_hwmod_sysc_type2,
  317. };
  318. static struct omap_hwmod_class dra7xx_cal_hwmod_class = {
  319. .name = "cal",
  320. .sysc = &dra7xx_cal_sysc,
  321. };
  322. /* cal */
  323. static struct omap_hwmod dra7xx_cal_hwmod = {
  324. .name = "cal",
  325. .class = &dra7xx_cal_hwmod_class,
  326. .clkdm_name = "cam_clkdm",
  327. .main_clk = "vip2_gclk_mux",
  328. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  329. .prcm = {
  330. .omap4 = {
  331. .clkctrl_offs = DRA7XX_CM_CAM_VIP2_CLKCTRL_OFFSET,
  332. .context_offs = DRA7XX_RM_CAM_VIP2_CONTEXT_OFFSET,
  333. .modulemode = MODULEMODE_HWCTRL,
  334. },
  335. },
  336. };
  337. static struct omap_hwmod dra76x_cal_hwmod = {
  338. .name = "cal",
  339. .class = &dra7xx_cal_hwmod_class,
  340. .clkdm_name = "cam_clkdm",
  341. .main_clk = "vip3_gclk_mux",
  342. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  343. .prcm = {
  344. .omap4 = {
  345. .clkctrl_offs = DRA7XX_CM_CAM_VIP3_CLKCTRL_OFFSET,
  346. .context_offs = DRA7XX_RM_CAM_VIP3_CONTEXT_OFFSET,
  347. .modulemode = MODULEMODE_HWCTRL,
  348. },
  349. },
  350. };
  351. /*
  352. * 'counter' class
  353. *
  354. */
  355. static struct omap_hwmod_class_sysconfig dra7xx_counter_sysc = {
  356. .rev_offs = 0x0000,
  357. .sysc_offs = 0x0010,
  358. .sysc_flags = SYSC_HAS_SIDLEMODE,
  359. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  360. SIDLE_SMART_WKUP),
  361. .sysc_fields = &omap_hwmod_sysc_type1,
  362. };
  363. static struct omap_hwmod_class dra7xx_counter_hwmod_class = {
  364. .name = "counter",
  365. .sysc = &dra7xx_counter_sysc,
  366. };
  367. /* counter_32k */
  368. static struct omap_hwmod dra7xx_counter_32k_hwmod = {
  369. .name = "counter_32k",
  370. .class = &dra7xx_counter_hwmod_class,
  371. .clkdm_name = "wkupaon_clkdm",
  372. .flags = HWMOD_SWSUP_SIDLE,
  373. .main_clk = "wkupaon_iclk_mux",
  374. .prcm = {
  375. .omap4 = {
  376. .clkctrl_offs = DRA7XX_CM_WKUPAON_COUNTER_32K_CLKCTRL_OFFSET,
  377. .context_offs = DRA7XX_RM_WKUPAON_COUNTER_32K_CONTEXT_OFFSET,
  378. },
  379. },
  380. };
  381. /*
  382. * 'ctrl_module' class
  383. *
  384. */
  385. static struct omap_hwmod_class dra7xx_ctrl_module_hwmod_class = {
  386. .name = "ctrl_module",
  387. };
  388. /* ctrl_module_wkup */
  389. static struct omap_hwmod dra7xx_ctrl_module_wkup_hwmod = {
  390. .name = "ctrl_module_wkup",
  391. .class = &dra7xx_ctrl_module_hwmod_class,
  392. .clkdm_name = "wkupaon_clkdm",
  393. .prcm = {
  394. .omap4 = {
  395. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  396. },
  397. },
  398. };
  399. /*
  400. * 'gmac' class
  401. * cpsw/gmac sub system
  402. */
  403. static struct omap_hwmod_class_sysconfig dra7xx_gmac_sysc = {
  404. .rev_offs = 0x0,
  405. .sysc_offs = 0x8,
  406. .syss_offs = 0x4,
  407. .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE |
  408. SYSS_HAS_RESET_STATUS),
  409. .idlemodes = (SIDLE_FORCE | SIDLE_NO | MSTANDBY_FORCE |
  410. MSTANDBY_NO),
  411. .sysc_fields = &omap_hwmod_sysc_type3,
  412. };
  413. static struct omap_hwmod_class dra7xx_gmac_hwmod_class = {
  414. .name = "gmac",
  415. .sysc = &dra7xx_gmac_sysc,
  416. };
  417. static struct omap_hwmod dra7xx_gmac_hwmod = {
  418. .name = "gmac",
  419. .class = &dra7xx_gmac_hwmod_class,
  420. .clkdm_name = "gmac_clkdm",
  421. .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
  422. .main_clk = "dpll_gmac_ck",
  423. .mpu_rt_idx = 1,
  424. .prcm = {
  425. .omap4 = {
  426. .clkctrl_offs = DRA7XX_CM_GMAC_GMAC_CLKCTRL_OFFSET,
  427. .context_offs = DRA7XX_RM_GMAC_GMAC_CONTEXT_OFFSET,
  428. .modulemode = MODULEMODE_SWCTRL,
  429. },
  430. },
  431. };
  432. /*
  433. * 'mdio' class
  434. */
  435. static struct omap_hwmod_class dra7xx_mdio_hwmod_class = {
  436. .name = "davinci_mdio",
  437. };
  438. static struct omap_hwmod dra7xx_mdio_hwmod = {
  439. .name = "davinci_mdio",
  440. .class = &dra7xx_mdio_hwmod_class,
  441. .clkdm_name = "gmac_clkdm",
  442. .main_clk = "dpll_gmac_ck",
  443. };
  444. /*
  445. * 'dcan' class
  446. *
  447. */
  448. static struct omap_hwmod_class dra7xx_dcan_hwmod_class = {
  449. .name = "dcan",
  450. };
  451. /* dcan1 */
  452. static struct omap_hwmod dra7xx_dcan1_hwmod = {
  453. .name = "dcan1",
  454. .class = &dra7xx_dcan_hwmod_class,
  455. .clkdm_name = "wkupaon_clkdm",
  456. .main_clk = "dcan1_sys_clk_mux",
  457. .flags = HWMOD_CLKDM_NOAUTO,
  458. .prcm = {
  459. .omap4 = {
  460. .clkctrl_offs = DRA7XX_CM_WKUPAON_DCAN1_CLKCTRL_OFFSET,
  461. .context_offs = DRA7XX_RM_WKUPAON_DCAN1_CONTEXT_OFFSET,
  462. .modulemode = MODULEMODE_SWCTRL,
  463. },
  464. },
  465. };
  466. /* dcan2 */
  467. static struct omap_hwmod dra7xx_dcan2_hwmod = {
  468. .name = "dcan2",
  469. .class = &dra7xx_dcan_hwmod_class,
  470. .clkdm_name = "l4per2_clkdm",
  471. .main_clk = "sys_clkin1",
  472. .flags = HWMOD_CLKDM_NOAUTO,
  473. .prcm = {
  474. .omap4 = {
  475. .clkctrl_offs = DRA7XX_CM_L4PER2_DCAN2_CLKCTRL_OFFSET,
  476. .context_offs = DRA7XX_RM_L4PER2_DCAN2_CONTEXT_OFFSET,
  477. .modulemode = MODULEMODE_SWCTRL,
  478. },
  479. },
  480. };
  481. /* pwmss */
  482. static struct omap_hwmod_class_sysconfig dra7xx_epwmss_sysc = {
  483. .rev_offs = 0x0,
  484. .sysc_offs = 0x4,
  485. .sysc_flags = SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  486. SYSC_HAS_RESET_STATUS,
  487. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  488. .sysc_fields = &omap_hwmod_sysc_type2,
  489. };
  490. /*
  491. * epwmss class
  492. */
  493. static struct omap_hwmod_class dra7xx_epwmss_hwmod_class = {
  494. .name = "epwmss",
  495. .sysc = &dra7xx_epwmss_sysc,
  496. };
  497. /* epwmss0 */
  498. static struct omap_hwmod dra7xx_epwmss0_hwmod = {
  499. .name = "epwmss0",
  500. .class = &dra7xx_epwmss_hwmod_class,
  501. .clkdm_name = "l4per2_clkdm",
  502. .main_clk = "l4_root_clk_div",
  503. .prcm = {
  504. .omap4 = {
  505. .modulemode = MODULEMODE_SWCTRL,
  506. .clkctrl_offs = DRA7XX_CM_L4PER2_PWMSS1_CLKCTRL_OFFSET,
  507. .context_offs = DRA7XX_RM_L4PER2_PWMSS1_CONTEXT_OFFSET,
  508. },
  509. },
  510. };
  511. /* epwmss1 */
  512. static struct omap_hwmod dra7xx_epwmss1_hwmod = {
  513. .name = "epwmss1",
  514. .class = &dra7xx_epwmss_hwmod_class,
  515. .clkdm_name = "l4per2_clkdm",
  516. .main_clk = "l4_root_clk_div",
  517. .prcm = {
  518. .omap4 = {
  519. .modulemode = MODULEMODE_SWCTRL,
  520. .clkctrl_offs = DRA7XX_CM_L4PER2_PWMSS2_CLKCTRL_OFFSET,
  521. .context_offs = DRA7XX_RM_L4PER2_PWMSS2_CONTEXT_OFFSET,
  522. },
  523. },
  524. };
  525. /* epwmss2 */
  526. static struct omap_hwmod dra7xx_epwmss2_hwmod = {
  527. .name = "epwmss2",
  528. .class = &dra7xx_epwmss_hwmod_class,
  529. .clkdm_name = "l4per2_clkdm",
  530. .main_clk = "l4_root_clk_div",
  531. .prcm = {
  532. .omap4 = {
  533. .modulemode = MODULEMODE_SWCTRL,
  534. .clkctrl_offs = DRA7XX_CM_L4PER2_PWMSS3_CLKCTRL_OFFSET,
  535. .context_offs = DRA7XX_RM_L4PER2_PWMSS3_CONTEXT_OFFSET,
  536. },
  537. },
  538. };
  539. /*
  540. * 'dma' class
  541. *
  542. */
  543. static struct omap_hwmod_class_sysconfig dra7xx_dma_sysc = {
  544. .rev_offs = 0x0000,
  545. .sysc_offs = 0x002c,
  546. .syss_offs = 0x0028,
  547. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  548. SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
  549. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  550. SYSS_HAS_RESET_STATUS),
  551. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  552. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  553. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  554. .sysc_fields = &omap_hwmod_sysc_type1,
  555. };
  556. static struct omap_hwmod_class dra7xx_dma_hwmod_class = {
  557. .name = "dma",
  558. .sysc = &dra7xx_dma_sysc,
  559. };
  560. /* dma dev_attr */
  561. static struct omap_dma_dev_attr dma_dev_attr = {
  562. .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY |
  563. IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY,
  564. .lch_count = 32,
  565. };
  566. /* dma_system */
  567. static struct omap_hwmod dra7xx_dma_system_hwmod = {
  568. .name = "dma_system",
  569. .class = &dra7xx_dma_hwmod_class,
  570. .clkdm_name = "dma_clkdm",
  571. .main_clk = "l3_iclk_div",
  572. .prcm = {
  573. .omap4 = {
  574. .clkctrl_offs = DRA7XX_CM_DMA_DMA_SYSTEM_CLKCTRL_OFFSET,
  575. .context_offs = DRA7XX_RM_DMA_DMA_SYSTEM_CONTEXT_OFFSET,
  576. },
  577. },
  578. .dev_attr = &dma_dev_attr,
  579. };
  580. /*
  581. * 'tpcc' class
  582. *
  583. */
  584. static struct omap_hwmod_class dra7xx_tpcc_hwmod_class = {
  585. .name = "tpcc",
  586. };
  587. static struct omap_hwmod dra7xx_tpcc_hwmod = {
  588. .name = "tpcc",
  589. .class = &dra7xx_tpcc_hwmod_class,
  590. .clkdm_name = "l3main1_clkdm",
  591. .main_clk = "l3_iclk_div",
  592. .prcm = {
  593. .omap4 = {
  594. .clkctrl_offs = DRA7XX_CM_L3MAIN1_TPCC_CLKCTRL_OFFSET,
  595. .context_offs = DRA7XX_RM_L3MAIN1_TPCC_CONTEXT_OFFSET,
  596. },
  597. },
  598. };
  599. /*
  600. * 'tptc' class
  601. *
  602. */
  603. static struct omap_hwmod_class dra7xx_tptc_hwmod_class = {
  604. .name = "tptc",
  605. };
  606. /* tptc0 */
  607. static struct omap_hwmod dra7xx_tptc0_hwmod = {
  608. .name = "tptc0",
  609. .class = &dra7xx_tptc_hwmod_class,
  610. .clkdm_name = "l3main1_clkdm",
  611. .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  612. .main_clk = "l3_iclk_div",
  613. .prcm = {
  614. .omap4 = {
  615. .clkctrl_offs = DRA7XX_CM_L3MAIN1_TPTC1_CLKCTRL_OFFSET,
  616. .context_offs = DRA7XX_RM_L3MAIN1_TPTC1_CONTEXT_OFFSET,
  617. .modulemode = MODULEMODE_HWCTRL,
  618. },
  619. },
  620. };
  621. /* tptc1 */
  622. static struct omap_hwmod dra7xx_tptc1_hwmod = {
  623. .name = "tptc1",
  624. .class = &dra7xx_tptc_hwmod_class,
  625. .clkdm_name = "l3main1_clkdm",
  626. .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  627. .main_clk = "l3_iclk_div",
  628. .prcm = {
  629. .omap4 = {
  630. .clkctrl_offs = DRA7XX_CM_L3MAIN1_TPTC2_CLKCTRL_OFFSET,
  631. .context_offs = DRA7XX_RM_L3MAIN1_TPTC2_CONTEXT_OFFSET,
  632. .modulemode = MODULEMODE_HWCTRL,
  633. },
  634. },
  635. };
  636. /*
  637. * 'dsp' class
  638. * dsp sub-system
  639. */
  640. static struct omap_hwmod_class dra7xx_dsp_hwmod_class = {
  641. .name = "dsp",
  642. };
  643. static struct omap_hwmod_rst_info dra7xx_dsp_resets[] = {
  644. { .name = "dsp", .rst_shift = 0 },
  645. };
  646. /* dsp1 processor */
  647. static struct omap_hwmod dra7xx_dsp1_hwmod = {
  648. .name = "dsp1",
  649. .class = &dra7xx_dsp_hwmod_class,
  650. .clkdm_name = "dsp1_clkdm",
  651. .rst_lines = dra7xx_dsp_resets,
  652. .rst_lines_cnt = ARRAY_SIZE(dra7xx_dsp_resets),
  653. .main_clk = "dpll_dsp_m2_ck",
  654. .prcm = {
  655. .omap4 = {
  656. .clkctrl_offs = DRA7XX_CM_DSP1_DSP1_CLKCTRL_OFFSET,
  657. .rstctrl_offs = DRA7XX_RM_DSP1_RSTCTRL_OFFSET,
  658. .context_offs = DRA7XX_RM_DSP1_DSP1_CONTEXT_OFFSET,
  659. },
  660. },
  661. };
  662. /* dsp2 processor */
  663. static struct omap_hwmod dra7xx_dsp2_hwmod = {
  664. .name = "dsp2",
  665. .class = &dra7xx_dsp_hwmod_class,
  666. .clkdm_name = "dsp2_clkdm",
  667. .rst_lines = dra7xx_dsp_resets,
  668. .rst_lines_cnt = ARRAY_SIZE(dra7xx_dsp_resets),
  669. .main_clk = "dpll_dsp_m2_ck",
  670. .prcm = {
  671. .omap4 = {
  672. .clkctrl_offs = DRA7XX_CM_DSP2_DSP2_CLKCTRL_OFFSET,
  673. .rstctrl_offs = DRA7XX_RM_DSP2_RSTCTRL_OFFSET,
  674. .context_offs = DRA7XX_RM_DSP2_DSP2_CONTEXT_OFFSET,
  675. },
  676. },
  677. };
  678. /*
  679. * 'dss' class
  680. *
  681. */
  682. static struct omap_hwmod_class_sysconfig dra7xx_dss_sysc = {
  683. .rev_offs = 0x0000,
  684. .syss_offs = 0x0014,
  685. .sysc_flags = SYSS_HAS_RESET_STATUS,
  686. };
  687. static struct omap_hwmod_class dra7xx_dss_hwmod_class = {
  688. .name = "dss",
  689. .sysc = &dra7xx_dss_sysc,
  690. .reset = omap_dss_reset,
  691. };
  692. /* dss */
  693. static struct omap_hwmod_opt_clk dss_opt_clks[] = {
  694. { .role = "dss_clk", .clk = "dss_dss_clk" },
  695. { .role = "hdmi_phy_clk", .clk = "dss_48mhz_clk" },
  696. { .role = "32khz_clk", .clk = "dss_32khz_clk" },
  697. { .role = "video2_clk", .clk = "dss_video2_clk" },
  698. { .role = "video1_clk", .clk = "dss_video1_clk" },
  699. { .role = "hdmi_clk", .clk = "dss_hdmi_clk" },
  700. { .role = "hdcp_clk", .clk = "dss_deshdcp_clk" },
  701. };
  702. static struct omap_hwmod dra7xx_dss_hwmod = {
  703. .name = "dss_core",
  704. .class = &dra7xx_dss_hwmod_class,
  705. .clkdm_name = "dss_clkdm",
  706. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  707. .main_clk = "dss_dss_clk",
  708. .prcm = {
  709. .omap4 = {
  710. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  711. .context_offs = DRA7XX_RM_DSS_DSS_CONTEXT_OFFSET,
  712. .modulemode = MODULEMODE_SWCTRL,
  713. },
  714. },
  715. .opt_clks = dss_opt_clks,
  716. .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
  717. };
  718. /*
  719. * 'dispc' class
  720. * display controller
  721. */
  722. static struct omap_hwmod_class_sysconfig dra7xx_dispc_sysc = {
  723. .rev_offs = 0x0000,
  724. .sysc_offs = 0x0010,
  725. .syss_offs = 0x0014,
  726. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  727. SYSC_HAS_ENAWAKEUP | SYSC_HAS_MIDLEMODE |
  728. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  729. SYSS_HAS_RESET_STATUS),
  730. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  731. MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
  732. .sysc_fields = &omap_hwmod_sysc_type1,
  733. };
  734. static struct omap_hwmod_class dra7xx_dispc_hwmod_class = {
  735. .name = "dispc",
  736. .sysc = &dra7xx_dispc_sysc,
  737. };
  738. /* dss_dispc */
  739. /* dss_dispc dev_attr */
  740. static struct omap_dss_dispc_dev_attr dss_dispc_dev_attr = {
  741. .has_framedonetv_irq = 1,
  742. .manager_count = 4,
  743. };
  744. static struct omap_hwmod dra7xx_dss_dispc_hwmod = {
  745. .name = "dss_dispc",
  746. .class = &dra7xx_dispc_hwmod_class,
  747. .clkdm_name = "dss_clkdm",
  748. .main_clk = "dss_dss_clk",
  749. .prcm = {
  750. .omap4 = {
  751. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  752. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  753. },
  754. },
  755. .dev_attr = &dss_dispc_dev_attr,
  756. .parent_hwmod = &dra7xx_dss_hwmod,
  757. };
  758. /*
  759. * 'hdmi' class
  760. * hdmi controller
  761. */
  762. static struct omap_hwmod_class_sysconfig dra7xx_hdmi_sysc = {
  763. .rev_offs = 0x0000,
  764. .sysc_offs = 0x0010,
  765. .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  766. SYSC_HAS_SOFTRESET),
  767. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  768. SIDLE_SMART_WKUP),
  769. .sysc_fields = &omap_hwmod_sysc_type2,
  770. };
  771. static struct omap_hwmod_class dra7xx_hdmi_hwmod_class = {
  772. .name = "hdmi",
  773. .sysc = &dra7xx_hdmi_sysc,
  774. };
  775. /* dss_hdmi */
  776. static struct omap_hwmod_opt_clk dss_hdmi_opt_clks[] = {
  777. { .role = "sys_clk", .clk = "dss_hdmi_clk" },
  778. };
  779. static struct omap_hwmod dra7xx_dss_hdmi_hwmod = {
  780. .name = "dss_hdmi",
  781. .class = &dra7xx_hdmi_hwmod_class,
  782. .clkdm_name = "dss_clkdm",
  783. .main_clk = "dss_48mhz_clk",
  784. .prcm = {
  785. .omap4 = {
  786. .clkctrl_offs = DRA7XX_CM_DSS_DSS_CLKCTRL_OFFSET,
  787. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  788. },
  789. },
  790. .opt_clks = dss_hdmi_opt_clks,
  791. .opt_clks_cnt = ARRAY_SIZE(dss_hdmi_opt_clks),
  792. .parent_hwmod = &dra7xx_dss_hwmod,
  793. };
  794. /* AES (the 'P' (public) device) */
  795. static struct omap_hwmod_class_sysconfig dra7xx_aes_sysc = {
  796. .rev_offs = 0x0080,
  797. .sysc_offs = 0x0084,
  798. .syss_offs = 0x0088,
  799. .sysc_flags = SYSS_HAS_RESET_STATUS,
  800. };
  801. static struct omap_hwmod_class dra7xx_aes_hwmod_class = {
  802. .name = "aes",
  803. .sysc = &dra7xx_aes_sysc,
  804. .rev = 2,
  805. };
  806. /* AES1 */
  807. static struct omap_hwmod dra7xx_aes1_hwmod = {
  808. .name = "aes1",
  809. .class = &dra7xx_aes_hwmod_class,
  810. .clkdm_name = "l4sec_clkdm",
  811. .main_clk = "l3_iclk_div",
  812. .prcm = {
  813. .omap4 = {
  814. .clkctrl_offs = DRA7XX_CM_L4SEC_AES1_CLKCTRL_OFFSET,
  815. .context_offs = DRA7XX_RM_L4SEC_AES1_CONTEXT_OFFSET,
  816. .modulemode = MODULEMODE_HWCTRL,
  817. },
  818. },
  819. };
  820. /* AES2 */
  821. static struct omap_hwmod dra7xx_aes2_hwmod = {
  822. .name = "aes2",
  823. .class = &dra7xx_aes_hwmod_class,
  824. .clkdm_name = "l4sec_clkdm",
  825. .main_clk = "l3_iclk_div",
  826. .prcm = {
  827. .omap4 = {
  828. .clkctrl_offs = DRA7XX_CM_L4SEC_AES2_CLKCTRL_OFFSET,
  829. .context_offs = DRA7XX_RM_L4SEC_AES2_CONTEXT_OFFSET,
  830. .modulemode = MODULEMODE_HWCTRL,
  831. },
  832. },
  833. };
  834. /* sha0 HIB2 (the 'P' (public) device) */
  835. static struct omap_hwmod_class_sysconfig dra7xx_sha0_sysc = {
  836. .rev_offs = 0x100,
  837. .sysc_offs = 0x110,
  838. .syss_offs = 0x114,
  839. .sysc_flags = SYSS_HAS_RESET_STATUS,
  840. };
  841. static struct omap_hwmod_class dra7xx_sha0_hwmod_class = {
  842. .name = "sham",
  843. .sysc = &dra7xx_sha0_sysc,
  844. .rev = 2,
  845. };
  846. struct omap_hwmod dra7xx_sha0_hwmod = {
  847. .name = "sham",
  848. .class = &dra7xx_sha0_hwmod_class,
  849. .clkdm_name = "l4sec_clkdm",
  850. .main_clk = "l3_iclk_div",
  851. .prcm = {
  852. .omap4 = {
  853. .clkctrl_offs = DRA7XX_CM_L4SEC_SHA2MD51_CLKCTRL_OFFSET,
  854. .context_offs = DRA7XX_RM_L4SEC_SHA2MD51_CONTEXT_OFFSET,
  855. .modulemode = MODULEMODE_HWCTRL,
  856. },
  857. },
  858. };
  859. /*
  860. * 'elm' class
  861. *
  862. */
  863. static struct omap_hwmod_class_sysconfig dra7xx_elm_sysc = {
  864. .rev_offs = 0x0000,
  865. .sysc_offs = 0x0010,
  866. .syss_offs = 0x0014,
  867. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  868. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  869. SYSS_HAS_RESET_STATUS),
  870. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  871. SIDLE_SMART_WKUP),
  872. .sysc_fields = &omap_hwmod_sysc_type1,
  873. };
  874. static struct omap_hwmod_class dra7xx_elm_hwmod_class = {
  875. .name = "elm",
  876. .sysc = &dra7xx_elm_sysc,
  877. };
  878. /* elm */
  879. static struct omap_hwmod dra7xx_elm_hwmod = {
  880. .name = "elm",
  881. .class = &dra7xx_elm_hwmod_class,
  882. .clkdm_name = "l4per_clkdm",
  883. .main_clk = "l3_iclk_div",
  884. .prcm = {
  885. .omap4 = {
  886. .clkctrl_offs = DRA7XX_CM_L4PER_ELM_CLKCTRL_OFFSET,
  887. .context_offs = DRA7XX_RM_L4PER_ELM_CONTEXT_OFFSET,
  888. },
  889. },
  890. };
  891. /*
  892. * 'gpio' class
  893. *
  894. */
  895. static struct omap_hwmod_class_sysconfig dra7xx_gpio_sysc = {
  896. .rev_offs = 0x0000,
  897. .sysc_offs = 0x0010,
  898. .syss_offs = 0x0114,
  899. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  900. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  901. SYSS_HAS_RESET_STATUS),
  902. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  903. SIDLE_SMART_WKUP),
  904. .sysc_fields = &omap_hwmod_sysc_type1,
  905. };
  906. static struct omap_hwmod_class dra7xx_gpio_hwmod_class = {
  907. .name = "gpio",
  908. .sysc = &dra7xx_gpio_sysc,
  909. .rev = 2,
  910. };
  911. /* gpio1 */
  912. static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
  913. { .role = "dbclk", .clk = "gpio1_dbclk" },
  914. };
  915. static struct omap_hwmod dra7xx_gpio1_hwmod = {
  916. .name = "gpio1",
  917. .class = &dra7xx_gpio_hwmod_class,
  918. .clkdm_name = "wkupaon_clkdm",
  919. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  920. .main_clk = "wkupaon_iclk_mux",
  921. .prcm = {
  922. .omap4 = {
  923. .clkctrl_offs = DRA7XX_CM_WKUPAON_GPIO1_CLKCTRL_OFFSET,
  924. .context_offs = DRA7XX_RM_WKUPAON_GPIO1_CONTEXT_OFFSET,
  925. .modulemode = MODULEMODE_HWCTRL,
  926. },
  927. },
  928. .opt_clks = gpio1_opt_clks,
  929. .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
  930. };
  931. /* gpio2 */
  932. static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
  933. { .role = "dbclk", .clk = "gpio2_dbclk" },
  934. };
  935. static struct omap_hwmod dra7xx_gpio2_hwmod = {
  936. .name = "gpio2",
  937. .class = &dra7xx_gpio_hwmod_class,
  938. .clkdm_name = "l4per_clkdm",
  939. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  940. .main_clk = "l3_iclk_div",
  941. .prcm = {
  942. .omap4 = {
  943. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO2_CLKCTRL_OFFSET,
  944. .context_offs = DRA7XX_RM_L4PER_GPIO2_CONTEXT_OFFSET,
  945. .modulemode = MODULEMODE_HWCTRL,
  946. },
  947. },
  948. .opt_clks = gpio2_opt_clks,
  949. .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
  950. };
  951. /* gpio3 */
  952. static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
  953. { .role = "dbclk", .clk = "gpio3_dbclk" },
  954. };
  955. static struct omap_hwmod dra7xx_gpio3_hwmod = {
  956. .name = "gpio3",
  957. .class = &dra7xx_gpio_hwmod_class,
  958. .clkdm_name = "l4per_clkdm",
  959. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  960. .main_clk = "l3_iclk_div",
  961. .prcm = {
  962. .omap4 = {
  963. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO3_CLKCTRL_OFFSET,
  964. .context_offs = DRA7XX_RM_L4PER_GPIO3_CONTEXT_OFFSET,
  965. .modulemode = MODULEMODE_HWCTRL,
  966. },
  967. },
  968. .opt_clks = gpio3_opt_clks,
  969. .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
  970. };
  971. /* gpio4 */
  972. static struct omap_hwmod_opt_clk gpio4_opt_clks[] = {
  973. { .role = "dbclk", .clk = "gpio4_dbclk" },
  974. };
  975. static struct omap_hwmod dra7xx_gpio4_hwmod = {
  976. .name = "gpio4",
  977. .class = &dra7xx_gpio_hwmod_class,
  978. .clkdm_name = "l4per_clkdm",
  979. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  980. .main_clk = "l3_iclk_div",
  981. .prcm = {
  982. .omap4 = {
  983. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO4_CLKCTRL_OFFSET,
  984. .context_offs = DRA7XX_RM_L4PER_GPIO4_CONTEXT_OFFSET,
  985. .modulemode = MODULEMODE_HWCTRL,
  986. },
  987. },
  988. .opt_clks = gpio4_opt_clks,
  989. .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks),
  990. };
  991. /* gpio5 */
  992. static struct omap_hwmod_opt_clk gpio5_opt_clks[] = {
  993. { .role = "dbclk", .clk = "gpio5_dbclk" },
  994. };
  995. static struct omap_hwmod dra7xx_gpio5_hwmod = {
  996. .name = "gpio5",
  997. .class = &dra7xx_gpio_hwmod_class,
  998. .clkdm_name = "l4per_clkdm",
  999. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  1000. .main_clk = "l3_iclk_div",
  1001. .prcm = {
  1002. .omap4 = {
  1003. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO5_CLKCTRL_OFFSET,
  1004. .context_offs = DRA7XX_RM_L4PER_GPIO5_CONTEXT_OFFSET,
  1005. .modulemode = MODULEMODE_HWCTRL,
  1006. },
  1007. },
  1008. .opt_clks = gpio5_opt_clks,
  1009. .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks),
  1010. };
  1011. /* gpio6 */
  1012. static struct omap_hwmod_opt_clk gpio6_opt_clks[] = {
  1013. { .role = "dbclk", .clk = "gpio6_dbclk" },
  1014. };
  1015. static struct omap_hwmod dra7xx_gpio6_hwmod = {
  1016. .name = "gpio6",
  1017. .class = &dra7xx_gpio_hwmod_class,
  1018. .clkdm_name = "l4per_clkdm",
  1019. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  1020. .main_clk = "l3_iclk_div",
  1021. .prcm = {
  1022. .omap4 = {
  1023. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO6_CLKCTRL_OFFSET,
  1024. .context_offs = DRA7XX_RM_L4PER_GPIO6_CONTEXT_OFFSET,
  1025. .modulemode = MODULEMODE_HWCTRL,
  1026. },
  1027. },
  1028. .opt_clks = gpio6_opt_clks,
  1029. .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks),
  1030. };
  1031. /* gpio7 */
  1032. static struct omap_hwmod_opt_clk gpio7_opt_clks[] = {
  1033. { .role = "dbclk", .clk = "gpio7_dbclk" },
  1034. };
  1035. static struct omap_hwmod dra7xx_gpio7_hwmod = {
  1036. .name = "gpio7",
  1037. .class = &dra7xx_gpio_hwmod_class,
  1038. .clkdm_name = "l4per_clkdm",
  1039. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  1040. .main_clk = "l3_iclk_div",
  1041. .prcm = {
  1042. .omap4 = {
  1043. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO7_CLKCTRL_OFFSET,
  1044. .context_offs = DRA7XX_RM_L4PER_GPIO7_CONTEXT_OFFSET,
  1045. .modulemode = MODULEMODE_HWCTRL,
  1046. },
  1047. },
  1048. .opt_clks = gpio7_opt_clks,
  1049. .opt_clks_cnt = ARRAY_SIZE(gpio7_opt_clks),
  1050. };
  1051. /* gpio8 */
  1052. static struct omap_hwmod_opt_clk gpio8_opt_clks[] = {
  1053. { .role = "dbclk", .clk = "gpio8_dbclk" },
  1054. };
  1055. static struct omap_hwmod dra7xx_gpio8_hwmod = {
  1056. .name = "gpio8",
  1057. .class = &dra7xx_gpio_hwmod_class,
  1058. .clkdm_name = "l4per_clkdm",
  1059. .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
  1060. .main_clk = "l3_iclk_div",
  1061. .prcm = {
  1062. .omap4 = {
  1063. .clkctrl_offs = DRA7XX_CM_L4PER_GPIO8_CLKCTRL_OFFSET,
  1064. .context_offs = DRA7XX_RM_L4PER_GPIO8_CONTEXT_OFFSET,
  1065. .modulemode = MODULEMODE_HWCTRL,
  1066. },
  1067. },
  1068. .opt_clks = gpio8_opt_clks,
  1069. .opt_clks_cnt = ARRAY_SIZE(gpio8_opt_clks),
  1070. };
  1071. /*
  1072. * 'gpmc' class
  1073. *
  1074. */
  1075. static struct omap_hwmod_class_sysconfig dra7xx_gpmc_sysc = {
  1076. .rev_offs = 0x0000,
  1077. .sysc_offs = 0x0010,
  1078. .syss_offs = 0x0014,
  1079. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
  1080. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1081. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1082. .sysc_fields = &omap_hwmod_sysc_type1,
  1083. };
  1084. static struct omap_hwmod_class dra7xx_gpmc_hwmod_class = {
  1085. .name = "gpmc",
  1086. .sysc = &dra7xx_gpmc_sysc,
  1087. };
  1088. /* gpmc */
  1089. static struct omap_hwmod dra7xx_gpmc_hwmod = {
  1090. .name = "gpmc",
  1091. .class = &dra7xx_gpmc_hwmod_class,
  1092. .clkdm_name = "l3main1_clkdm",
  1093. /* Skip reset for CONFIG_OMAP_GPMC_DEBUG for bootloader timings */
  1094. .flags = DEBUG_OMAP_GPMC_HWMOD_FLAGS,
  1095. .main_clk = "l3_iclk_div",
  1096. .prcm = {
  1097. .omap4 = {
  1098. .clkctrl_offs = DRA7XX_CM_L3MAIN1_GPMC_CLKCTRL_OFFSET,
  1099. .context_offs = DRA7XX_RM_L3MAIN1_GPMC_CONTEXT_OFFSET,
  1100. .modulemode = MODULEMODE_HWCTRL,
  1101. },
  1102. },
  1103. };
  1104. /*
  1105. * 'gpu' class
  1106. * 3d graphics accelerator
  1107. */
  1108. static struct omap_hwmod_class_sysconfig dra7xx_gpu_sysc = {
  1109. .rev_offs = 0xfe00,
  1110. .sysc_offs = 0xfe10,
  1111. .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
  1112. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1113. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  1114. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  1115. .sysc_fields = &omap_hwmod_sysc_type2,
  1116. };
  1117. static struct omap_hwmod_class dra7xx_gpu_hwmod_class = {
  1118. .name = "gpu",
  1119. .sysc = &dra7xx_gpu_sysc,
  1120. };
  1121. static struct omap_hwmod dra7xx_gpu_hwmod = {
  1122. .name = "gpu",
  1123. .class = &dra7xx_gpu_hwmod_class,
  1124. .clkdm_name = "gpu_clkdm",
  1125. .main_clk = "gpu_core_gclk_mux",
  1126. .prcm = {
  1127. .omap4 = {
  1128. .clkctrl_offs = DRA7XX_CM_GPU_GPU_CLKCTRL_OFFSET,
  1129. .context_offs = DRA7XX_RM_GPU_GPU_CONTEXT_OFFSET,
  1130. .modulemode = MODULEMODE_SWCTRL,
  1131. },
  1132. },
  1133. };
  1134. /*
  1135. * 'hdq1w' class
  1136. *
  1137. */
  1138. static struct omap_hwmod_class_sysconfig dra7xx_hdq1w_sysc = {
  1139. .rev_offs = 0x0000,
  1140. .sysc_offs = 0x0014,
  1141. .syss_offs = 0x0018,
  1142. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SOFTRESET |
  1143. SYSS_HAS_RESET_STATUS),
  1144. .sysc_fields = &omap_hwmod_sysc_type1,
  1145. };
  1146. static struct omap_hwmod_class dra7xx_hdq1w_hwmod_class = {
  1147. .name = "hdq1w",
  1148. .sysc = &dra7xx_hdq1w_sysc,
  1149. };
  1150. /* hdq1w */
  1151. static struct omap_hwmod dra7xx_hdq1w_hwmod = {
  1152. .name = "hdq1w",
  1153. .class = &dra7xx_hdq1w_hwmod_class,
  1154. .clkdm_name = "l4per_clkdm",
  1155. .flags = HWMOD_INIT_NO_RESET,
  1156. .main_clk = "func_12m_fclk",
  1157. .prcm = {
  1158. .omap4 = {
  1159. .clkctrl_offs = DRA7XX_CM_L4PER_HDQ1W_CLKCTRL_OFFSET,
  1160. .context_offs = DRA7XX_RM_L4PER_HDQ1W_CONTEXT_OFFSET,
  1161. .modulemode = MODULEMODE_SWCTRL,
  1162. },
  1163. },
  1164. };
  1165. /*
  1166. * 'i2c' class
  1167. *
  1168. */
  1169. static struct omap_hwmod_class_sysconfig dra7xx_i2c_sysc = {
  1170. .rev_offs = 0,
  1171. .sysc_offs = 0x0010,
  1172. .syss_offs = 0x0090,
  1173. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  1174. SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
  1175. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1176. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1177. SIDLE_SMART_WKUP),
  1178. .sysc_fields = &omap_hwmod_sysc_type1,
  1179. };
  1180. static struct omap_hwmod_class dra7xx_i2c_hwmod_class = {
  1181. .name = "i2c",
  1182. .sysc = &dra7xx_i2c_sysc,
  1183. .reset = &omap_i2c_reset,
  1184. .rev = OMAP_I2C_IP_VERSION_2,
  1185. };
  1186. /* i2c1 */
  1187. static struct omap_hwmod dra7xx_i2c1_hwmod = {
  1188. .name = "i2c1",
  1189. .class = &dra7xx_i2c_hwmod_class,
  1190. .clkdm_name = "l4per_clkdm",
  1191. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  1192. .main_clk = "func_96m_fclk",
  1193. .prcm = {
  1194. .omap4 = {
  1195. .clkctrl_offs = DRA7XX_CM_L4PER_I2C1_CLKCTRL_OFFSET,
  1196. .context_offs = DRA7XX_RM_L4PER_I2C1_CONTEXT_OFFSET,
  1197. .modulemode = MODULEMODE_SWCTRL,
  1198. },
  1199. },
  1200. };
  1201. /* i2c2 */
  1202. static struct omap_hwmod dra7xx_i2c2_hwmod = {
  1203. .name = "i2c2",
  1204. .class = &dra7xx_i2c_hwmod_class,
  1205. .clkdm_name = "l4per_clkdm",
  1206. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  1207. .main_clk = "func_96m_fclk",
  1208. .prcm = {
  1209. .omap4 = {
  1210. .clkctrl_offs = DRA7XX_CM_L4PER_I2C2_CLKCTRL_OFFSET,
  1211. .context_offs = DRA7XX_RM_L4PER_I2C2_CONTEXT_OFFSET,
  1212. .modulemode = MODULEMODE_SWCTRL,
  1213. },
  1214. },
  1215. };
  1216. /* i2c3 */
  1217. static struct omap_hwmod dra7xx_i2c3_hwmod = {
  1218. .name = "i2c3",
  1219. .class = &dra7xx_i2c_hwmod_class,
  1220. .clkdm_name = "l4per_clkdm",
  1221. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  1222. .main_clk = "func_96m_fclk",
  1223. .prcm = {
  1224. .omap4 = {
  1225. .clkctrl_offs = DRA7XX_CM_L4PER_I2C3_CLKCTRL_OFFSET,
  1226. .context_offs = DRA7XX_RM_L4PER_I2C3_CONTEXT_OFFSET,
  1227. .modulemode = MODULEMODE_SWCTRL,
  1228. },
  1229. },
  1230. };
  1231. /* i2c4 */
  1232. static struct omap_hwmod dra7xx_i2c4_hwmod = {
  1233. .name = "i2c4",
  1234. .class = &dra7xx_i2c_hwmod_class,
  1235. .clkdm_name = "l4per_clkdm",
  1236. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  1237. .main_clk = "func_96m_fclk",
  1238. .prcm = {
  1239. .omap4 = {
  1240. .clkctrl_offs = DRA7XX_CM_L4PER_I2C4_CLKCTRL_OFFSET,
  1241. .context_offs = DRA7XX_RM_L4PER_I2C4_CONTEXT_OFFSET,
  1242. .modulemode = MODULEMODE_SWCTRL,
  1243. },
  1244. },
  1245. };
  1246. /* i2c5 */
  1247. static struct omap_hwmod dra7xx_i2c5_hwmod = {
  1248. .name = "i2c5",
  1249. .class = &dra7xx_i2c_hwmod_class,
  1250. .clkdm_name = "ipu_clkdm",
  1251. .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
  1252. .main_clk = "func_96m_fclk",
  1253. .prcm = {
  1254. .omap4 = {
  1255. .clkctrl_offs = DRA7XX_CM_IPU_I2C5_CLKCTRL_OFFSET,
  1256. .context_offs = DRA7XX_RM_IPU_I2C5_CONTEXT_OFFSET,
  1257. .modulemode = MODULEMODE_SWCTRL,
  1258. },
  1259. },
  1260. };
  1261. /*
  1262. * 'ipu' class
  1263. * imaging processor unit
  1264. */
  1265. static struct omap_hwmod_class dra7xx_ipu_hwmod_class = {
  1266. .name = "ipu",
  1267. };
  1268. static struct omap_hwmod_rst_info dra7xx_ipu_resets[] = {
  1269. { .name = "cpu0", .rst_shift = 0 },
  1270. { .name = "cpu1", .rst_shift = 1 },
  1271. };
  1272. /* ipu1 processor */
  1273. static struct omap_hwmod dra7xx_ipu1_hwmod = {
  1274. .name = "ipu1",
  1275. .class = &dra7xx_ipu_hwmod_class,
  1276. .clkdm_name = "ipu1_clkdm",
  1277. .rst_lines = dra7xx_ipu_resets,
  1278. .rst_lines_cnt = ARRAY_SIZE(dra7xx_ipu_resets),
  1279. .main_clk = "ipu1_gfclk_mux",
  1280. .prcm = {
  1281. .omap4 = {
  1282. .clkctrl_offs = DRA7XX_CM_IPU1_IPU1_CLKCTRL_OFFSET,
  1283. .rstctrl_offs = DRA7XX_RM_IPU1_RSTCTRL_OFFSET,
  1284. .context_offs = DRA7XX_RM_IPU1_IPU1_CONTEXT_OFFSET,
  1285. },
  1286. },
  1287. };
  1288. /* ipu2 processor */
  1289. static struct omap_hwmod dra7xx_ipu2_hwmod = {
  1290. .name = "ipu2",
  1291. .class = &dra7xx_ipu_hwmod_class,
  1292. .clkdm_name = "ipu2_clkdm",
  1293. .rst_lines = dra7xx_ipu_resets,
  1294. .rst_lines_cnt = ARRAY_SIZE(dra7xx_ipu_resets),
  1295. .main_clk = "dpll_core_h22x2_ck",
  1296. .prcm = {
  1297. .omap4 = {
  1298. .clkctrl_offs = DRA7XX_CM_IPU2_IPU2_CLKCTRL_OFFSET,
  1299. .rstctrl_offs = DRA7XX_RM_IPU2_RSTCTRL_OFFSET,
  1300. .context_offs = DRA7XX_RM_IPU2_IPU2_CONTEXT_OFFSET,
  1301. },
  1302. },
  1303. };
  1304. /*
  1305. * 'mailbox' class
  1306. *
  1307. */
  1308. static struct omap_hwmod_class_sysconfig dra7xx_mailbox_sysc = {
  1309. .rev_offs = 0x0000,
  1310. .sysc_offs = 0x0010,
  1311. .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  1312. SYSC_HAS_SOFTRESET),
  1313. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1314. .sysc_fields = &omap_hwmod_sysc_type2,
  1315. };
  1316. static struct omap_hwmod_class dra7xx_mailbox_hwmod_class = {
  1317. .name = "mailbox",
  1318. .sysc = &dra7xx_mailbox_sysc,
  1319. };
  1320. /* mailbox1 */
  1321. static struct omap_hwmod dra7xx_mailbox1_hwmod = {
  1322. .name = "mailbox1",
  1323. .class = &dra7xx_mailbox_hwmod_class,
  1324. .clkdm_name = "l4cfg_clkdm",
  1325. .prcm = {
  1326. .omap4 = {
  1327. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX1_CLKCTRL_OFFSET,
  1328. .context_offs = DRA7XX_RM_L4CFG_MAILBOX1_CONTEXT_OFFSET,
  1329. },
  1330. },
  1331. };
  1332. /* mailbox2 */
  1333. static struct omap_hwmod dra7xx_mailbox2_hwmod = {
  1334. .name = "mailbox2",
  1335. .class = &dra7xx_mailbox_hwmod_class,
  1336. .clkdm_name = "l4cfg_clkdm",
  1337. .prcm = {
  1338. .omap4 = {
  1339. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX2_CLKCTRL_OFFSET,
  1340. .context_offs = DRA7XX_RM_L4CFG_MAILBOX2_CONTEXT_OFFSET,
  1341. },
  1342. },
  1343. };
  1344. /* mailbox3 */
  1345. static struct omap_hwmod dra7xx_mailbox3_hwmod = {
  1346. .name = "mailbox3",
  1347. .class = &dra7xx_mailbox_hwmod_class,
  1348. .clkdm_name = "l4cfg_clkdm",
  1349. .prcm = {
  1350. .omap4 = {
  1351. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX3_CLKCTRL_OFFSET,
  1352. .context_offs = DRA7XX_RM_L4CFG_MAILBOX3_CONTEXT_OFFSET,
  1353. },
  1354. },
  1355. };
  1356. /* mailbox4 */
  1357. static struct omap_hwmod dra7xx_mailbox4_hwmod = {
  1358. .name = "mailbox4",
  1359. .class = &dra7xx_mailbox_hwmod_class,
  1360. .clkdm_name = "l4cfg_clkdm",
  1361. .prcm = {
  1362. .omap4 = {
  1363. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX4_CLKCTRL_OFFSET,
  1364. .context_offs = DRA7XX_RM_L4CFG_MAILBOX4_CONTEXT_OFFSET,
  1365. },
  1366. },
  1367. };
  1368. /* mailbox5 */
  1369. static struct omap_hwmod dra7xx_mailbox5_hwmod = {
  1370. .name = "mailbox5",
  1371. .class = &dra7xx_mailbox_hwmod_class,
  1372. .clkdm_name = "l4cfg_clkdm",
  1373. .prcm = {
  1374. .omap4 = {
  1375. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX5_CLKCTRL_OFFSET,
  1376. .context_offs = DRA7XX_RM_L4CFG_MAILBOX5_CONTEXT_OFFSET,
  1377. },
  1378. },
  1379. };
  1380. /* mailbox6 */
  1381. static struct omap_hwmod dra7xx_mailbox6_hwmod = {
  1382. .name = "mailbox6",
  1383. .class = &dra7xx_mailbox_hwmod_class,
  1384. .clkdm_name = "l4cfg_clkdm",
  1385. .prcm = {
  1386. .omap4 = {
  1387. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX6_CLKCTRL_OFFSET,
  1388. .context_offs = DRA7XX_RM_L4CFG_MAILBOX6_CONTEXT_OFFSET,
  1389. },
  1390. },
  1391. };
  1392. /* mailbox7 */
  1393. static struct omap_hwmod dra7xx_mailbox7_hwmod = {
  1394. .name = "mailbox7",
  1395. .class = &dra7xx_mailbox_hwmod_class,
  1396. .clkdm_name = "l4cfg_clkdm",
  1397. .prcm = {
  1398. .omap4 = {
  1399. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX7_CLKCTRL_OFFSET,
  1400. .context_offs = DRA7XX_RM_L4CFG_MAILBOX7_CONTEXT_OFFSET,
  1401. },
  1402. },
  1403. };
  1404. /* mailbox8 */
  1405. static struct omap_hwmod dra7xx_mailbox8_hwmod = {
  1406. .name = "mailbox8",
  1407. .class = &dra7xx_mailbox_hwmod_class,
  1408. .clkdm_name = "l4cfg_clkdm",
  1409. .prcm = {
  1410. .omap4 = {
  1411. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX8_CLKCTRL_OFFSET,
  1412. .context_offs = DRA7XX_RM_L4CFG_MAILBOX8_CONTEXT_OFFSET,
  1413. },
  1414. },
  1415. };
  1416. /* mailbox9 */
  1417. static struct omap_hwmod dra7xx_mailbox9_hwmod = {
  1418. .name = "mailbox9",
  1419. .class = &dra7xx_mailbox_hwmod_class,
  1420. .clkdm_name = "l4cfg_clkdm",
  1421. .prcm = {
  1422. .omap4 = {
  1423. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX9_CLKCTRL_OFFSET,
  1424. .context_offs = DRA7XX_RM_L4CFG_MAILBOX9_CONTEXT_OFFSET,
  1425. },
  1426. },
  1427. };
  1428. /* mailbox10 */
  1429. static struct omap_hwmod dra7xx_mailbox10_hwmod = {
  1430. .name = "mailbox10",
  1431. .class = &dra7xx_mailbox_hwmod_class,
  1432. .clkdm_name = "l4cfg_clkdm",
  1433. .prcm = {
  1434. .omap4 = {
  1435. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX10_CLKCTRL_OFFSET,
  1436. .context_offs = DRA7XX_RM_L4CFG_MAILBOX10_CONTEXT_OFFSET,
  1437. },
  1438. },
  1439. };
  1440. /* mailbox11 */
  1441. static struct omap_hwmod dra7xx_mailbox11_hwmod = {
  1442. .name = "mailbox11",
  1443. .class = &dra7xx_mailbox_hwmod_class,
  1444. .clkdm_name = "l4cfg_clkdm",
  1445. .prcm = {
  1446. .omap4 = {
  1447. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX11_CLKCTRL_OFFSET,
  1448. .context_offs = DRA7XX_RM_L4CFG_MAILBOX11_CONTEXT_OFFSET,
  1449. },
  1450. },
  1451. };
  1452. /* mailbox12 */
  1453. static struct omap_hwmod dra7xx_mailbox12_hwmod = {
  1454. .name = "mailbox12",
  1455. .class = &dra7xx_mailbox_hwmod_class,
  1456. .clkdm_name = "l4cfg_clkdm",
  1457. .prcm = {
  1458. .omap4 = {
  1459. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX12_CLKCTRL_OFFSET,
  1460. .context_offs = DRA7XX_RM_L4CFG_MAILBOX12_CONTEXT_OFFSET,
  1461. },
  1462. },
  1463. };
  1464. /* mailbox13 */
  1465. static struct omap_hwmod dra7xx_mailbox13_hwmod = {
  1466. .name = "mailbox13",
  1467. .class = &dra7xx_mailbox_hwmod_class,
  1468. .clkdm_name = "l4cfg_clkdm",
  1469. .prcm = {
  1470. .omap4 = {
  1471. .clkctrl_offs = DRA7XX_CM_L4CFG_MAILBOX13_CLKCTRL_OFFSET,
  1472. .context_offs = DRA7XX_RM_L4CFG_MAILBOX13_CONTEXT_OFFSET,
  1473. },
  1474. },
  1475. };
  1476. /*
  1477. * 'mcspi' class
  1478. *
  1479. */
  1480. static struct omap_hwmod_class_sysconfig dra7xx_mcspi_sysc = {
  1481. .rev_offs = 0x0000,
  1482. .sysc_offs = 0x0010,
  1483. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  1484. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  1485. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1486. SIDLE_SMART_WKUP),
  1487. .sysc_fields = &omap_hwmod_sysc_type2,
  1488. };
  1489. static struct omap_hwmod_class dra7xx_mcspi_hwmod_class = {
  1490. .name = "mcspi",
  1491. .sysc = &dra7xx_mcspi_sysc,
  1492. };
  1493. /* mcspi1 */
  1494. static struct omap_hwmod dra7xx_mcspi1_hwmod = {
  1495. .name = "mcspi1",
  1496. .class = &dra7xx_mcspi_hwmod_class,
  1497. .clkdm_name = "l4per_clkdm",
  1498. .main_clk = "func_48m_fclk",
  1499. .prcm = {
  1500. .omap4 = {
  1501. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI1_CLKCTRL_OFFSET,
  1502. .context_offs = DRA7XX_RM_L4PER_MCSPI1_CONTEXT_OFFSET,
  1503. .modulemode = MODULEMODE_SWCTRL,
  1504. },
  1505. },
  1506. };
  1507. /* mcspi2 */
  1508. static struct omap_hwmod dra7xx_mcspi2_hwmod = {
  1509. .name = "mcspi2",
  1510. .class = &dra7xx_mcspi_hwmod_class,
  1511. .clkdm_name = "l4per_clkdm",
  1512. .main_clk = "func_48m_fclk",
  1513. .prcm = {
  1514. .omap4 = {
  1515. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI2_CLKCTRL_OFFSET,
  1516. .context_offs = DRA7XX_RM_L4PER_MCSPI2_CONTEXT_OFFSET,
  1517. .modulemode = MODULEMODE_SWCTRL,
  1518. },
  1519. },
  1520. };
  1521. /* mcspi3 */
  1522. static struct omap_hwmod dra7xx_mcspi3_hwmod = {
  1523. .name = "mcspi3",
  1524. .class = &dra7xx_mcspi_hwmod_class,
  1525. .clkdm_name = "l4per_clkdm",
  1526. .main_clk = "func_48m_fclk",
  1527. .prcm = {
  1528. .omap4 = {
  1529. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI3_CLKCTRL_OFFSET,
  1530. .context_offs = DRA7XX_RM_L4PER_MCSPI3_CONTEXT_OFFSET,
  1531. .modulemode = MODULEMODE_SWCTRL,
  1532. },
  1533. },
  1534. };
  1535. /* mcspi4 */
  1536. static struct omap_hwmod dra7xx_mcspi4_hwmod = {
  1537. .name = "mcspi4",
  1538. .class = &dra7xx_mcspi_hwmod_class,
  1539. .clkdm_name = "l4per_clkdm",
  1540. .main_clk = "func_48m_fclk",
  1541. .prcm = {
  1542. .omap4 = {
  1543. .clkctrl_offs = DRA7XX_CM_L4PER_MCSPI4_CLKCTRL_OFFSET,
  1544. .context_offs = DRA7XX_RM_L4PER_MCSPI4_CONTEXT_OFFSET,
  1545. .modulemode = MODULEMODE_SWCTRL,
  1546. },
  1547. },
  1548. };
  1549. /*
  1550. * 'mcasp' class
  1551. *
  1552. */
  1553. static struct omap_hwmod_class_sysconfig dra7xx_mcasp_sysc = {
  1554. .rev_offs = 0,
  1555. .sysc_offs = 0x0004,
  1556. .sysc_flags = SYSC_HAS_SIDLEMODE,
  1557. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1558. .sysc_fields = &omap_hwmod_sysc_type3,
  1559. };
  1560. static struct omap_hwmod_class dra7xx_mcasp_hwmod_class = {
  1561. .name = "mcasp",
  1562. .sysc = &dra7xx_mcasp_sysc,
  1563. };
  1564. /* mcasp1 */
  1565. static struct omap_hwmod_opt_clk mcasp1_opt_clks[] = {
  1566. { .role = "ahclkx", .clk = "mcasp1_ahclkx_mux" },
  1567. { .role = "ahclkr", .clk = "mcasp1_ahclkr_mux" },
  1568. };
  1569. static struct omap_hwmod dra7xx_mcasp1_hwmod = {
  1570. .name = "mcasp1",
  1571. .class = &dra7xx_mcasp_hwmod_class,
  1572. .clkdm_name = "ipu_clkdm",
  1573. .main_clk = "mcasp1_aux_gfclk_mux",
  1574. .flags = HWMOD_OPT_CLKS_NEEDED,
  1575. .prcm = {
  1576. .omap4 = {
  1577. .clkctrl_offs = DRA7XX_CM_IPU_MCASP1_CLKCTRL_OFFSET,
  1578. .context_offs = DRA7XX_RM_IPU_MCASP1_CONTEXT_OFFSET,
  1579. .modulemode = MODULEMODE_SWCTRL,
  1580. },
  1581. },
  1582. .opt_clks = mcasp1_opt_clks,
  1583. .opt_clks_cnt = ARRAY_SIZE(mcasp1_opt_clks),
  1584. };
  1585. /* mcasp2 */
  1586. static struct omap_hwmod_opt_clk mcasp2_opt_clks[] = {
  1587. { .role = "ahclkx", .clk = "mcasp2_ahclkx_mux" },
  1588. { .role = "ahclkr", .clk = "mcasp2_ahclkr_mux" },
  1589. };
  1590. static struct omap_hwmod dra7xx_mcasp2_hwmod = {
  1591. .name = "mcasp2",
  1592. .class = &dra7xx_mcasp_hwmod_class,
  1593. .clkdm_name = "l4per2_clkdm",
  1594. .main_clk = "mcasp2_aux_gfclk_mux",
  1595. .flags = HWMOD_OPT_CLKS_NEEDED,
  1596. .prcm = {
  1597. .omap4 = {
  1598. .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP2_CLKCTRL_OFFSET,
  1599. .context_offs = DRA7XX_RM_L4PER2_MCASP2_CONTEXT_OFFSET,
  1600. .modulemode = MODULEMODE_SWCTRL,
  1601. },
  1602. },
  1603. .opt_clks = mcasp2_opt_clks,
  1604. .opt_clks_cnt = ARRAY_SIZE(mcasp2_opt_clks),
  1605. };
  1606. /* mcasp3 */
  1607. static struct omap_hwmod_opt_clk mcasp3_opt_clks[] = {
  1608. { .role = "ahclkx", .clk = "mcasp3_ahclkx_mux" },
  1609. };
  1610. static struct omap_hwmod dra7xx_mcasp3_hwmod = {
  1611. .name = "mcasp3",
  1612. .class = &dra7xx_mcasp_hwmod_class,
  1613. .clkdm_name = "l4per2_clkdm",
  1614. .main_clk = "mcasp3_aux_gfclk_mux",
  1615. .flags = HWMOD_OPT_CLKS_NEEDED,
  1616. .prcm = {
  1617. .omap4 = {
  1618. .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP3_CLKCTRL_OFFSET,
  1619. .context_offs = DRA7XX_RM_L4PER2_MCASP3_CONTEXT_OFFSET,
  1620. .modulemode = MODULEMODE_SWCTRL,
  1621. },
  1622. },
  1623. .opt_clks = mcasp3_opt_clks,
  1624. .opt_clks_cnt = ARRAY_SIZE(mcasp3_opt_clks),
  1625. };
  1626. /* mcasp4 */
  1627. static struct omap_hwmod_opt_clk mcasp4_opt_clks[] = {
  1628. { .role = "ahclkx", .clk = "mcasp4_ahclkx_mux" },
  1629. };
  1630. static struct omap_hwmod dra7xx_mcasp4_hwmod = {
  1631. .name = "mcasp4",
  1632. .class = &dra7xx_mcasp_hwmod_class,
  1633. .clkdm_name = "l4per2_clkdm",
  1634. .main_clk = "mcasp4_aux_gfclk_mux",
  1635. .flags = HWMOD_OPT_CLKS_NEEDED,
  1636. .prcm = {
  1637. .omap4 = {
  1638. .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP4_CLKCTRL_OFFSET,
  1639. .context_offs = DRA7XX_RM_L4PER2_MCASP4_CONTEXT_OFFSET,
  1640. .modulemode = MODULEMODE_SWCTRL,
  1641. },
  1642. },
  1643. .opt_clks = mcasp4_opt_clks,
  1644. .opt_clks_cnt = ARRAY_SIZE(mcasp4_opt_clks),
  1645. };
  1646. /* mcasp5 */
  1647. static struct omap_hwmod_opt_clk mcasp5_opt_clks[] = {
  1648. { .role = "ahclkx", .clk = "mcasp5_ahclkx_mux" },
  1649. };
  1650. static struct omap_hwmod dra7xx_mcasp5_hwmod = {
  1651. .name = "mcasp5",
  1652. .class = &dra7xx_mcasp_hwmod_class,
  1653. .clkdm_name = "l4per2_clkdm",
  1654. .main_clk = "mcasp5_aux_gfclk_mux",
  1655. .flags = HWMOD_OPT_CLKS_NEEDED,
  1656. .prcm = {
  1657. .omap4 = {
  1658. .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP5_CLKCTRL_OFFSET,
  1659. .context_offs = DRA7XX_RM_L4PER2_MCASP5_CONTEXT_OFFSET,
  1660. .modulemode = MODULEMODE_SWCTRL,
  1661. },
  1662. },
  1663. .opt_clks = mcasp5_opt_clks,
  1664. .opt_clks_cnt = ARRAY_SIZE(mcasp5_opt_clks),
  1665. };
  1666. /* mcasp6 */
  1667. static struct omap_hwmod_opt_clk mcasp6_opt_clks[] = {
  1668. { .role = "ahclkx", .clk = "mcasp6_ahclkx_mux" },
  1669. };
  1670. static struct omap_hwmod dra7xx_mcasp6_hwmod = {
  1671. .name = "mcasp6",
  1672. .class = &dra7xx_mcasp_hwmod_class,
  1673. .clkdm_name = "l4per2_clkdm",
  1674. .main_clk = "mcasp6_aux_gfclk_mux",
  1675. .flags = HWMOD_OPT_CLKS_NEEDED,
  1676. .prcm = {
  1677. .omap4 = {
  1678. .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP6_CLKCTRL_OFFSET,
  1679. .context_offs = DRA7XX_RM_L4PER2_MCASP6_CONTEXT_OFFSET,
  1680. .modulemode = MODULEMODE_SWCTRL,
  1681. },
  1682. },
  1683. .opt_clks = mcasp6_opt_clks,
  1684. .opt_clks_cnt = ARRAY_SIZE(mcasp6_opt_clks),
  1685. };
  1686. /* mcasp7 */
  1687. static struct omap_hwmod_opt_clk mcasp7_opt_clks[] = {
  1688. { .role = "ahclkx", .clk = "mcasp7_ahclkx_mux" },
  1689. };
  1690. static struct omap_hwmod dra7xx_mcasp7_hwmod = {
  1691. .name = "mcasp7",
  1692. .class = &dra7xx_mcasp_hwmod_class,
  1693. .clkdm_name = "l4per2_clkdm",
  1694. .main_clk = "mcasp7_aux_gfclk_mux",
  1695. .flags = HWMOD_OPT_CLKS_NEEDED,
  1696. .prcm = {
  1697. .omap4 = {
  1698. .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP7_CLKCTRL_OFFSET,
  1699. .context_offs = DRA7XX_RM_L4PER2_MCASP7_CONTEXT_OFFSET,
  1700. .modulemode = MODULEMODE_SWCTRL,
  1701. },
  1702. },
  1703. .opt_clks = mcasp7_opt_clks,
  1704. .opt_clks_cnt = ARRAY_SIZE(mcasp7_opt_clks),
  1705. };
  1706. /* mcasp8 */
  1707. static struct omap_hwmod_opt_clk mcasp8_opt_clks[] = {
  1708. { .role = "ahclkx", .clk = "mcasp8_ahclkx_mux" },
  1709. };
  1710. static struct omap_hwmod dra7xx_mcasp8_hwmod = {
  1711. .name = "mcasp8",
  1712. .class = &dra7xx_mcasp_hwmod_class,
  1713. .clkdm_name = "l4per2_clkdm",
  1714. .main_clk = "mcasp8_aux_gfclk_mux",
  1715. .flags = HWMOD_OPT_CLKS_NEEDED,
  1716. .prcm = {
  1717. .omap4 = {
  1718. .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP8_CLKCTRL_OFFSET,
  1719. .context_offs = DRA7XX_RM_L4PER2_MCASP8_CONTEXT_OFFSET,
  1720. .modulemode = MODULEMODE_SWCTRL,
  1721. },
  1722. },
  1723. .opt_clks = mcasp8_opt_clks,
  1724. .opt_clks_cnt = ARRAY_SIZE(mcasp8_opt_clks),
  1725. };
  1726. /*
  1727. * 'mmc' class
  1728. *
  1729. */
  1730. static struct omap_hwmod_class_sysconfig dra7xx_mmc_sysc = {
  1731. .rev_offs = 0x0000,
  1732. .sysc_offs = 0x0010,
  1733. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
  1734. SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
  1735. SYSC_HAS_SOFTRESET),
  1736. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  1737. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  1738. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  1739. .sysc_fields = &omap_hwmod_sysc_type2,
  1740. };
  1741. static struct omap_hwmod_class dra7xx_mmc_hwmod_class = {
  1742. .name = "mmc",
  1743. .sysc = &dra7xx_mmc_sysc,
  1744. };
  1745. /* mmc1 */
  1746. static struct omap_hwmod_opt_clk mmc1_opt_clks[] = {
  1747. { .role = "clk32k", .clk = "mmc1_clk32k" },
  1748. };
  1749. /* mmc1 dev_attr */
  1750. static struct omap_hsmmc_dev_attr mmc1_dev_attr = {
  1751. .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
  1752. };
  1753. static struct omap_hwmod dra7xx_mmc1_hwmod = {
  1754. .name = "mmc1",
  1755. .class = &dra7xx_mmc_hwmod_class,
  1756. .clkdm_name = "l3init_clkdm",
  1757. .main_clk = "mmc1_fclk_div",
  1758. .prcm = {
  1759. .omap4 = {
  1760. .clkctrl_offs = DRA7XX_CM_L3INIT_MMC1_CLKCTRL_OFFSET,
  1761. .context_offs = DRA7XX_RM_L3INIT_MMC1_CONTEXT_OFFSET,
  1762. .modulemode = MODULEMODE_SWCTRL,
  1763. },
  1764. },
  1765. .opt_clks = mmc1_opt_clks,
  1766. .opt_clks_cnt = ARRAY_SIZE(mmc1_opt_clks),
  1767. .dev_attr = &mmc1_dev_attr,
  1768. };
  1769. /* mmc2 */
  1770. static struct omap_hwmod_opt_clk mmc2_opt_clks[] = {
  1771. { .role = "clk32k", .clk = "mmc2_clk32k" },
  1772. };
  1773. static struct omap_hwmod dra7xx_mmc2_hwmod = {
  1774. .name = "mmc2",
  1775. .class = &dra7xx_mmc_hwmod_class,
  1776. .clkdm_name = "l3init_clkdm",
  1777. .main_clk = "mmc2_fclk_div",
  1778. .prcm = {
  1779. .omap4 = {
  1780. .clkctrl_offs = DRA7XX_CM_L3INIT_MMC2_CLKCTRL_OFFSET,
  1781. .context_offs = DRA7XX_RM_L3INIT_MMC2_CONTEXT_OFFSET,
  1782. .modulemode = MODULEMODE_SWCTRL,
  1783. },
  1784. },
  1785. .opt_clks = mmc2_opt_clks,
  1786. .opt_clks_cnt = ARRAY_SIZE(mmc2_opt_clks),
  1787. };
  1788. /* mmc3 */
  1789. static struct omap_hwmod_opt_clk mmc3_opt_clks[] = {
  1790. { .role = "clk32k", .clk = "mmc3_clk32k" },
  1791. };
  1792. static struct omap_hwmod dra7xx_mmc3_hwmod = {
  1793. .name = "mmc3",
  1794. .class = &dra7xx_mmc_hwmod_class,
  1795. .clkdm_name = "l4per_clkdm",
  1796. .main_clk = "mmc3_gfclk_div",
  1797. .prcm = {
  1798. .omap4 = {
  1799. .clkctrl_offs = DRA7XX_CM_L4PER_MMC3_CLKCTRL_OFFSET,
  1800. .context_offs = DRA7XX_RM_L4PER_MMC3_CONTEXT_OFFSET,
  1801. .modulemode = MODULEMODE_SWCTRL,
  1802. },
  1803. },
  1804. .opt_clks = mmc3_opt_clks,
  1805. .opt_clks_cnt = ARRAY_SIZE(mmc3_opt_clks),
  1806. };
  1807. /* mmc4 */
  1808. static struct omap_hwmod_opt_clk mmc4_opt_clks[] = {
  1809. { .role = "clk32k", .clk = "mmc4_clk32k" },
  1810. };
  1811. static struct omap_hwmod dra7xx_mmc4_hwmod = {
  1812. .name = "mmc4",
  1813. .class = &dra7xx_mmc_hwmod_class,
  1814. .clkdm_name = "l4per_clkdm",
  1815. .main_clk = "mmc4_gfclk_div",
  1816. .prcm = {
  1817. .omap4 = {
  1818. .clkctrl_offs = DRA7XX_CM_L4PER_MMC4_CLKCTRL_OFFSET,
  1819. .context_offs = DRA7XX_RM_L4PER_MMC4_CONTEXT_OFFSET,
  1820. .modulemode = MODULEMODE_SWCTRL,
  1821. },
  1822. },
  1823. .opt_clks = mmc4_opt_clks,
  1824. .opt_clks_cnt = ARRAY_SIZE(mmc4_opt_clks),
  1825. };
  1826. /*
  1827. * 'mmu' class
  1828. * The memory management unit performs virtual to physical address translation
  1829. * for its requestors.
  1830. */
  1831. static struct omap_hwmod_class_sysconfig dra7xx_mmu_sysc = {
  1832. .rev_offs = 0x0000,
  1833. .sysc_offs = 0x0010,
  1834. .syss_offs = 0x0014,
  1835. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
  1836. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  1837. SYSS_HAS_RESET_STATUS),
  1838. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1839. .sysc_fields = &omap_hwmod_sysc_type1,
  1840. };
  1841. static struct omap_hwmod_class dra7xx_mmu_hwmod_class = {
  1842. .name = "mmu",
  1843. .sysc = &dra7xx_mmu_sysc,
  1844. };
  1845. /* DSP MMUs */
  1846. static struct omap_hwmod_rst_info dra7xx_mmu_dsp_resets[] = {
  1847. { .name = "mmu_cache", .rst_shift = 1 },
  1848. };
  1849. /* mmu0 - dsp1 */
  1850. static struct omap_hwmod dra7xx_mmu0_dsp1_hwmod = {
  1851. .name = "mmu0_dsp1",
  1852. .class = &dra7xx_mmu_hwmod_class,
  1853. .clkdm_name = "dsp1_clkdm",
  1854. .rst_lines = dra7xx_mmu_dsp_resets,
  1855. .rst_lines_cnt = ARRAY_SIZE(dra7xx_mmu_dsp_resets),
  1856. .main_clk = "dpll_dsp_m2_ck",
  1857. .prcm = {
  1858. .omap4 = {
  1859. .clkctrl_offs = DRA7XX_CM_DSP1_DSP1_CLKCTRL_OFFSET,
  1860. .rstctrl_offs = DRA7XX_RM_DSP1_RSTCTRL_OFFSET,
  1861. .context_offs = DRA7XX_RM_DSP1_DSP1_CONTEXT_OFFSET,
  1862. .modulemode = MODULEMODE_HWCTRL,
  1863. },
  1864. },
  1865. };
  1866. /* mmu1 - dsp1 */
  1867. static struct omap_hwmod dra7xx_mmu1_dsp1_hwmod = {
  1868. .name = "mmu1_dsp1",
  1869. .class = &dra7xx_mmu_hwmod_class,
  1870. .clkdm_name = "dsp1_clkdm",
  1871. .rst_lines = dra7xx_mmu_dsp_resets,
  1872. .rst_lines_cnt = ARRAY_SIZE(dra7xx_mmu_dsp_resets),
  1873. .main_clk = "dpll_dsp_m2_ck",
  1874. .prcm = {
  1875. .omap4 = {
  1876. .rstctrl_offs = DRA7XX_RM_DSP1_RSTCTRL_OFFSET,
  1877. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  1878. },
  1879. },
  1880. };
  1881. /* mmu0 - dsp2 */
  1882. static struct omap_hwmod dra7xx_mmu0_dsp2_hwmod = {
  1883. .name = "mmu0_dsp2",
  1884. .class = &dra7xx_mmu_hwmod_class,
  1885. .clkdm_name = "dsp2_clkdm",
  1886. .rst_lines = dra7xx_mmu_dsp_resets,
  1887. .rst_lines_cnt = ARRAY_SIZE(dra7xx_mmu_dsp_resets),
  1888. .main_clk = "dpll_dsp_m2_ck",
  1889. .prcm = {
  1890. .omap4 = {
  1891. .clkctrl_offs = DRA7XX_CM_DSP2_DSP2_CLKCTRL_OFFSET,
  1892. .rstctrl_offs = DRA7XX_RM_DSP2_RSTCTRL_OFFSET,
  1893. .context_offs = DRA7XX_RM_DSP2_DSP2_CONTEXT_OFFSET,
  1894. .modulemode = MODULEMODE_HWCTRL,
  1895. },
  1896. },
  1897. };
  1898. /* mmu1 - dsp2 */
  1899. static struct omap_hwmod dra7xx_mmu1_dsp2_hwmod = {
  1900. .name = "mmu1_dsp2",
  1901. .class = &dra7xx_mmu_hwmod_class,
  1902. .clkdm_name = "dsp2_clkdm",
  1903. .rst_lines = dra7xx_mmu_dsp_resets,
  1904. .rst_lines_cnt = ARRAY_SIZE(dra7xx_mmu_dsp_resets),
  1905. .main_clk = "dpll_dsp_m2_ck",
  1906. .prcm = {
  1907. .omap4 = {
  1908. .rstctrl_offs = DRA7XX_RM_DSP2_RSTCTRL_OFFSET,
  1909. .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
  1910. },
  1911. },
  1912. };
  1913. /* IPU MMUs */
  1914. static struct omap_hwmod_rst_info dra7xx_mmu_ipu_resets[] = {
  1915. { .name = "mmu_cache", .rst_shift = 2 },
  1916. };
  1917. /* mmu ipu1 */
  1918. static struct omap_hwmod dra7xx_mmu_ipu1_hwmod = {
  1919. .name = "mmu_ipu1",
  1920. .class = &dra7xx_mmu_hwmod_class,
  1921. .clkdm_name = "ipu1_clkdm",
  1922. .rst_lines = dra7xx_mmu_ipu_resets,
  1923. .rst_lines_cnt = ARRAY_SIZE(dra7xx_mmu_ipu_resets),
  1924. .main_clk = "ipu1_gfclk_mux",
  1925. .prcm = {
  1926. .omap4 = {
  1927. .clkctrl_offs = DRA7XX_CM_IPU1_IPU1_CLKCTRL_OFFSET,
  1928. .rstctrl_offs = DRA7XX_RM_IPU1_RSTCTRL_OFFSET,
  1929. .context_offs = DRA7XX_RM_IPU1_IPU1_CONTEXT_OFFSET,
  1930. .modulemode = MODULEMODE_HWCTRL,
  1931. },
  1932. },
  1933. };
  1934. /* mmu ipu2 */
  1935. static struct omap_hwmod dra7xx_mmu_ipu2_hwmod = {
  1936. .name = "mmu_ipu2",
  1937. .class = &dra7xx_mmu_hwmod_class,
  1938. .clkdm_name = "ipu2_clkdm",
  1939. .rst_lines = dra7xx_mmu_ipu_resets,
  1940. .rst_lines_cnt = ARRAY_SIZE(dra7xx_mmu_ipu_resets),
  1941. .main_clk = "dpll_core_h22x2_ck",
  1942. .prcm = {
  1943. .omap4 = {
  1944. .clkctrl_offs = DRA7XX_CM_IPU2_IPU2_CLKCTRL_OFFSET,
  1945. .rstctrl_offs = DRA7XX_RM_IPU2_RSTCTRL_OFFSET,
  1946. .context_offs = DRA7XX_RM_IPU2_IPU2_CONTEXT_OFFSET,
  1947. .modulemode = MODULEMODE_HWCTRL,
  1948. },
  1949. },
  1950. };
  1951. /*
  1952. * 'mpu' class
  1953. *
  1954. */
  1955. static struct omap_hwmod_class dra7xx_mpu_hwmod_class = {
  1956. .name = "mpu",
  1957. };
  1958. /* mpu */
  1959. static struct omap_hwmod dra7xx_mpu_hwmod = {
  1960. .name = "mpu",
  1961. .class = &dra7xx_mpu_hwmod_class,
  1962. .clkdm_name = "mpu_clkdm",
  1963. .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
  1964. .main_clk = "dpll_mpu_m2_ck",
  1965. .prcm = {
  1966. .omap4 = {
  1967. .clkctrl_offs = DRA7XX_CM_MPU_MPU_CLKCTRL_OFFSET,
  1968. .context_offs = DRA7XX_RM_MPU_MPU_CONTEXT_OFFSET,
  1969. },
  1970. },
  1971. };
  1972. /*
  1973. * 'ocp2scp' class
  1974. *
  1975. */
  1976. static struct omap_hwmod_class_sysconfig dra7xx_ocp2scp_sysc = {
  1977. .rev_offs = 0x0000,
  1978. .sysc_offs = 0x0010,
  1979. .syss_offs = 0x0014,
  1980. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
  1981. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  1982. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  1983. .sysc_fields = &omap_hwmod_sysc_type1,
  1984. };
  1985. static struct omap_hwmod_class dra7xx_ocp2scp_hwmod_class = {
  1986. .name = "ocp2scp",
  1987. .sysc = &dra7xx_ocp2scp_sysc,
  1988. };
  1989. /* ocp2scp1 */
  1990. static struct omap_hwmod dra7xx_ocp2scp1_hwmod = {
  1991. .name = "ocp2scp1",
  1992. .class = &dra7xx_ocp2scp_hwmod_class,
  1993. .clkdm_name = "l3init_clkdm",
  1994. .main_clk = "l4_root_clk_div",
  1995. .prcm = {
  1996. .omap4 = {
  1997. .clkctrl_offs = DRA7XX_CM_L3INIT_OCP2SCP1_CLKCTRL_OFFSET,
  1998. .context_offs = DRA7XX_RM_L3INIT_OCP2SCP1_CONTEXT_OFFSET,
  1999. .modulemode = MODULEMODE_HWCTRL,
  2000. },
  2001. },
  2002. };
  2003. /* ocp2scp3 */
  2004. static struct omap_hwmod dra7xx_ocp2scp3_hwmod = {
  2005. .name = "ocp2scp3",
  2006. .class = &dra7xx_ocp2scp_hwmod_class,
  2007. .clkdm_name = "l3init_clkdm",
  2008. .main_clk = "l4_root_clk_div",
  2009. .prcm = {
  2010. .omap4 = {
  2011. .clkctrl_offs = DRA7XX_CM_L3INIT_OCP2SCP3_CLKCTRL_OFFSET,
  2012. .context_offs = DRA7XX_RM_L3INIT_OCP2SCP3_CONTEXT_OFFSET,
  2013. .modulemode = MODULEMODE_HWCTRL,
  2014. },
  2015. },
  2016. };
  2017. /*
  2018. * 'PCIE' class
  2019. *
  2020. */
  2021. /*
  2022. * As noted in documentation for _reset() in omap_hwmod.c, the stock reset
  2023. * functionality of OMAP HWMOD layer does not deassert the hardreset lines
  2024. * associated with an IP automatically leaving the driver to handle that
  2025. * by itself. This does not work for PCIeSS which needs the reset lines
  2026. * deasserted for the driver to start accessing registers.
  2027. *
  2028. * We use a PCIeSS HWMOD class specific reset handler to deassert the hardreset
  2029. * lines after asserting them.
  2030. */
  2031. static int dra7xx_pciess_reset(struct omap_hwmod *oh)
  2032. {
  2033. int i;
  2034. for (i = 0; i < oh->rst_lines_cnt; i++) {
  2035. omap_hwmod_assert_hardreset(oh, oh->rst_lines[i].name);
  2036. omap_hwmod_deassert_hardreset(oh, oh->rst_lines[i].name);
  2037. }
  2038. return 0;
  2039. }
  2040. static struct omap_hwmod_class dra7xx_pciess_hwmod_class = {
  2041. .name = "pcie",
  2042. .reset = dra7xx_pciess_reset,
  2043. };
  2044. /* pcie1 */
  2045. static struct omap_hwmod_rst_info dra7xx_pciess1_resets[] = {
  2046. { .name = "pcie", .rst_shift = 0 },
  2047. };
  2048. static struct omap_hwmod dra7xx_pciess1_hwmod = {
  2049. .name = "pcie1",
  2050. .class = &dra7xx_pciess_hwmod_class,
  2051. .clkdm_name = "pcie_clkdm",
  2052. .rst_lines = dra7xx_pciess1_resets,
  2053. .rst_lines_cnt = ARRAY_SIZE(dra7xx_pciess1_resets),
  2054. .main_clk = "l4_root_clk_div",
  2055. .prcm = {
  2056. .omap4 = {
  2057. .clkctrl_offs = DRA7XX_CM_L3INIT_PCIESS1_CLKCTRL_OFFSET,
  2058. .rstctrl_offs = DRA7XX_RM_L3INIT_PCIESS_RSTCTRL_OFFSET,
  2059. .context_offs = DRA7XX_RM_L3INIT_PCIESS1_CONTEXT_OFFSET,
  2060. .modulemode = MODULEMODE_SWCTRL,
  2061. },
  2062. },
  2063. };
  2064. /* pcie2 */
  2065. static struct omap_hwmod_rst_info dra7xx_pciess2_resets[] = {
  2066. { .name = "pcie", .rst_shift = 1 },
  2067. };
  2068. /* pcie2 */
  2069. static struct omap_hwmod dra7xx_pciess2_hwmod = {
  2070. .name = "pcie2",
  2071. .class = &dra7xx_pciess_hwmod_class,
  2072. .clkdm_name = "pcie_clkdm",
  2073. .rst_lines = dra7xx_pciess2_resets,
  2074. .rst_lines_cnt = ARRAY_SIZE(dra7xx_pciess2_resets),
  2075. .main_clk = "l4_root_clk_div",
  2076. .prcm = {
  2077. .omap4 = {
  2078. .clkctrl_offs = DRA7XX_CM_L3INIT_PCIESS2_CLKCTRL_OFFSET,
  2079. .rstctrl_offs = DRA7XX_RM_L3INIT_PCIESS_RSTCTRL_OFFSET,
  2080. .context_offs = DRA7XX_RM_L3INIT_PCIESS2_CONTEXT_OFFSET,
  2081. .modulemode = MODULEMODE_SWCTRL,
  2082. },
  2083. },
  2084. };
  2085. /*
  2086. * 'pru-icss' class
  2087. * Programmable Real-Time Unit and Industrial Communication Subsystem
  2088. */
  2089. static struct omap_hwmod_class dra7xx_pruss_hwmod_class = {
  2090. .name = "pruss",
  2091. };
  2092. /* pru-icss1 */
  2093. static struct omap_hwmod dra7xx_pruss1_hwmod = {
  2094. .name = "pruss1",
  2095. .class = &dra7xx_pruss_hwmod_class,
  2096. .clkdm_name = "l4per2_clkdm",
  2097. .prcm = {
  2098. .omap4 = {
  2099. .clkctrl_offs = DRA7XX_CM_L4PER2_PRUSS1_CLKCTRL_OFFSET,
  2100. .context_offs = DRA7XX_RM_L4PER2_PRUSS1_CONTEXT_OFFSET,
  2101. .modulemode = MODULEMODE_SWCTRL,
  2102. },
  2103. },
  2104. };
  2105. /* pru-icss2 */
  2106. static struct omap_hwmod dra7xx_pruss2_hwmod = {
  2107. .name = "pruss2",
  2108. .class = &dra7xx_pruss_hwmod_class,
  2109. .clkdm_name = "l4per2_clkdm",
  2110. .prcm = {
  2111. .omap4 = {
  2112. .clkctrl_offs = DRA7XX_CM_L4PER2_PRUSS2_CLKCTRL_OFFSET,
  2113. .context_offs = DRA7XX_RM_L4PER2_PRUSS2_CONTEXT_OFFSET,
  2114. .modulemode = MODULEMODE_SWCTRL,
  2115. },
  2116. },
  2117. };
  2118. /*
  2119. * 'qspi' class
  2120. *
  2121. */
  2122. static struct omap_hwmod_class_sysconfig dra7xx_qspi_sysc = {
  2123. .rev_offs = 0,
  2124. .sysc_offs = 0x0010,
  2125. .sysc_flags = SYSC_HAS_SIDLEMODE,
  2126. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2127. SIDLE_SMART_WKUP),
  2128. .sysc_fields = &omap_hwmod_sysc_type2,
  2129. };
  2130. static struct omap_hwmod_class dra7xx_qspi_hwmod_class = {
  2131. .name = "qspi",
  2132. .sysc = &dra7xx_qspi_sysc,
  2133. };
  2134. /* qspi */
  2135. static struct omap_hwmod dra7xx_qspi_hwmod = {
  2136. .name = "qspi",
  2137. .class = &dra7xx_qspi_hwmod_class,
  2138. .clkdm_name = "l4per2_clkdm",
  2139. .main_clk = "qspi_gfclk_div",
  2140. .prcm = {
  2141. .omap4 = {
  2142. .clkctrl_offs = DRA7XX_CM_L4PER2_QSPI_CLKCTRL_OFFSET,
  2143. .context_offs = DRA7XX_RM_L4PER2_QSPI_CONTEXT_OFFSET,
  2144. .modulemode = MODULEMODE_SWCTRL,
  2145. },
  2146. },
  2147. };
  2148. /*
  2149. * 'rtcss' class
  2150. *
  2151. */
  2152. static struct omap_hwmod_class_sysconfig dra7xx_rtcss_sysc = {
  2153. .rev_offs = 0x0074,
  2154. .sysc_offs = 0x0078,
  2155. .sysc_flags = SYSC_HAS_SIDLEMODE,
  2156. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2157. SIDLE_SMART_WKUP),
  2158. .sysc_fields = &omap_hwmod_sysc_type3,
  2159. };
  2160. static struct omap_hwmod_class dra7xx_rtcss_hwmod_class = {
  2161. .name = "rtcss",
  2162. .sysc = &dra7xx_rtcss_sysc,
  2163. .unlock = &omap_hwmod_rtc_unlock,
  2164. .lock = &omap_hwmod_rtc_lock,
  2165. };
  2166. /* rtcss */
  2167. static struct omap_hwmod dra7xx_rtcss_hwmod = {
  2168. .name = "rtcss",
  2169. .class = &dra7xx_rtcss_hwmod_class,
  2170. .clkdm_name = "rtc_clkdm",
  2171. .main_clk = "sys_32k_ck",
  2172. .prcm = {
  2173. .omap4 = {
  2174. .clkctrl_offs = DRA7XX_CM_RTC_RTCSS_CLKCTRL_OFFSET,
  2175. .context_offs = DRA7XX_RM_RTC_RTCSS_CONTEXT_OFFSET,
  2176. .modulemode = MODULEMODE_SWCTRL,
  2177. },
  2178. },
  2179. };
  2180. /*
  2181. * 'sata' class
  2182. *
  2183. */
  2184. static struct omap_hwmod_class_sysconfig dra7xx_sata_sysc = {
  2185. .rev_offs = 0x00fc,
  2186. .sysc_offs = 0x0000,
  2187. .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
  2188. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2189. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  2190. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  2191. .sysc_fields = &omap_hwmod_sysc_type2,
  2192. };
  2193. static struct omap_hwmod_class dra7xx_sata_hwmod_class = {
  2194. .name = "sata",
  2195. .sysc = &dra7xx_sata_sysc,
  2196. };
  2197. /* sata */
  2198. static struct omap_hwmod dra7xx_sata_hwmod = {
  2199. .name = "sata",
  2200. .class = &dra7xx_sata_hwmod_class,
  2201. .clkdm_name = "l3init_clkdm",
  2202. .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  2203. .main_clk = "func_48m_fclk",
  2204. .mpu_rt_idx = 1,
  2205. .prcm = {
  2206. .omap4 = {
  2207. .clkctrl_offs = DRA7XX_CM_L3INIT_SATA_CLKCTRL_OFFSET,
  2208. .context_offs = DRA7XX_RM_L3INIT_SATA_CONTEXT_OFFSET,
  2209. .modulemode = MODULEMODE_SWCTRL,
  2210. },
  2211. },
  2212. };
  2213. /*
  2214. * 'smartreflex' class
  2215. *
  2216. */
  2217. /* The IP is not compliant to type1 / type2 scheme */
  2218. static struct omap_hwmod_class_sysconfig dra7xx_smartreflex_sysc = {
  2219. .rev_offs = -ENODEV,
  2220. .sysc_offs = 0x0038,
  2221. .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE),
  2222. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2223. SIDLE_SMART_WKUP),
  2224. .sysc_fields = &omap36xx_sr_sysc_fields,
  2225. };
  2226. static struct omap_hwmod_class dra7xx_smartreflex_hwmod_class = {
  2227. .name = "smartreflex",
  2228. .sysc = &dra7xx_smartreflex_sysc,
  2229. .rev = 2,
  2230. };
  2231. /* smartreflex_core */
  2232. /* smartreflex_core dev_attr */
  2233. static struct omap_smartreflex_dev_attr smartreflex_core_dev_attr = {
  2234. .sensor_voltdm_name = "core",
  2235. };
  2236. static struct omap_hwmod dra7xx_smartreflex_core_hwmod = {
  2237. .name = "smartreflex_core",
  2238. .class = &dra7xx_smartreflex_hwmod_class,
  2239. .clkdm_name = "coreaon_clkdm",
  2240. .main_clk = "wkupaon_iclk_mux",
  2241. .prcm = {
  2242. .omap4 = {
  2243. .clkctrl_offs = DRA7XX_CM_COREAON_SMARTREFLEX_CORE_CLKCTRL_OFFSET,
  2244. .context_offs = DRA7XX_RM_COREAON_SMARTREFLEX_CORE_CONTEXT_OFFSET,
  2245. .modulemode = MODULEMODE_SWCTRL,
  2246. },
  2247. },
  2248. .dev_attr = &smartreflex_core_dev_attr,
  2249. };
  2250. /* smartreflex_mpu */
  2251. /* smartreflex_mpu dev_attr */
  2252. static struct omap_smartreflex_dev_attr smartreflex_mpu_dev_attr = {
  2253. .sensor_voltdm_name = "mpu",
  2254. };
  2255. static struct omap_hwmod dra7xx_smartreflex_mpu_hwmod = {
  2256. .name = "smartreflex_mpu",
  2257. .class = &dra7xx_smartreflex_hwmod_class,
  2258. .clkdm_name = "coreaon_clkdm",
  2259. .main_clk = "wkupaon_iclk_mux",
  2260. .prcm = {
  2261. .omap4 = {
  2262. .clkctrl_offs = DRA7XX_CM_COREAON_SMARTREFLEX_MPU_CLKCTRL_OFFSET,
  2263. .context_offs = DRA7XX_RM_COREAON_SMARTREFLEX_MPU_CONTEXT_OFFSET,
  2264. .modulemode = MODULEMODE_SWCTRL,
  2265. },
  2266. },
  2267. .dev_attr = &smartreflex_mpu_dev_attr,
  2268. };
  2269. /*
  2270. * 'spinlock' class
  2271. *
  2272. */
  2273. static struct omap_hwmod_class_sysconfig dra7xx_spinlock_sysc = {
  2274. .rev_offs = 0x0000,
  2275. .sysc_offs = 0x0010,
  2276. .syss_offs = 0x0014,
  2277. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  2278. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  2279. SYSS_HAS_RESET_STATUS),
  2280. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
  2281. .sysc_fields = &omap_hwmod_sysc_type1,
  2282. };
  2283. static struct omap_hwmod_class dra7xx_spinlock_hwmod_class = {
  2284. .name = "spinlock",
  2285. .sysc = &dra7xx_spinlock_sysc,
  2286. };
  2287. /* spinlock */
  2288. static struct omap_hwmod dra7xx_spinlock_hwmod = {
  2289. .name = "spinlock",
  2290. .class = &dra7xx_spinlock_hwmod_class,
  2291. .clkdm_name = "l4cfg_clkdm",
  2292. .main_clk = "l3_iclk_div",
  2293. .prcm = {
  2294. .omap4 = {
  2295. .clkctrl_offs = DRA7XX_CM_L4CFG_SPINLOCK_CLKCTRL_OFFSET,
  2296. .context_offs = DRA7XX_RM_L4CFG_SPINLOCK_CONTEXT_OFFSET,
  2297. },
  2298. },
  2299. };
  2300. /*
  2301. * 'timer' class
  2302. *
  2303. * This class contains several variants: ['timer_1ms', 'timer_secure',
  2304. * 'timer']
  2305. */
  2306. static struct omap_hwmod_class_sysconfig dra7xx_timer_1ms_sysc = {
  2307. .rev_offs = 0x0000,
  2308. .sysc_offs = 0x0010,
  2309. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  2310. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  2311. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2312. SIDLE_SMART_WKUP),
  2313. .sysc_fields = &omap_hwmod_sysc_type2,
  2314. };
  2315. static struct omap_hwmod_class dra7xx_timer_1ms_hwmod_class = {
  2316. .name = "timer",
  2317. .sysc = &dra7xx_timer_1ms_sysc,
  2318. };
  2319. static struct omap_hwmod_class_sysconfig dra7xx_timer_sysc = {
  2320. .rev_offs = 0x0000,
  2321. .sysc_offs = 0x0010,
  2322. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
  2323. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
  2324. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2325. SIDLE_SMART_WKUP),
  2326. .sysc_fields = &omap_hwmod_sysc_type2,
  2327. };
  2328. static struct omap_hwmod_class dra7xx_timer_hwmod_class = {
  2329. .name = "timer",
  2330. .sysc = &dra7xx_timer_sysc,
  2331. };
  2332. /* timer1 */
  2333. static struct omap_hwmod dra7xx_timer1_hwmod = {
  2334. .name = "timer1",
  2335. .class = &dra7xx_timer_1ms_hwmod_class,
  2336. .clkdm_name = "wkupaon_clkdm",
  2337. .main_clk = "timer1_gfclk_mux",
  2338. .prcm = {
  2339. .omap4 = {
  2340. .clkctrl_offs = DRA7XX_CM_WKUPAON_TIMER1_CLKCTRL_OFFSET,
  2341. .context_offs = DRA7XX_RM_WKUPAON_TIMER1_CONTEXT_OFFSET,
  2342. .modulemode = MODULEMODE_SWCTRL,
  2343. },
  2344. },
  2345. };
  2346. /* timer2 */
  2347. static struct omap_hwmod dra7xx_timer2_hwmod = {
  2348. .name = "timer2",
  2349. .class = &dra7xx_timer_1ms_hwmod_class,
  2350. .clkdm_name = "l4per_clkdm",
  2351. .main_clk = "timer2_gfclk_mux",
  2352. .prcm = {
  2353. .omap4 = {
  2354. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER2_CLKCTRL_OFFSET,
  2355. .context_offs = DRA7XX_RM_L4PER_TIMER2_CONTEXT_OFFSET,
  2356. .modulemode = MODULEMODE_SWCTRL,
  2357. },
  2358. },
  2359. };
  2360. /* timer3 */
  2361. static struct omap_hwmod dra7xx_timer3_hwmod = {
  2362. .name = "timer3",
  2363. .class = &dra7xx_timer_hwmod_class,
  2364. .clkdm_name = "l4per_clkdm",
  2365. .main_clk = "timer3_gfclk_mux",
  2366. .prcm = {
  2367. .omap4 = {
  2368. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER3_CLKCTRL_OFFSET,
  2369. .context_offs = DRA7XX_RM_L4PER_TIMER3_CONTEXT_OFFSET,
  2370. .modulemode = MODULEMODE_SWCTRL,
  2371. },
  2372. },
  2373. };
  2374. /* timer4 */
  2375. static struct omap_hwmod dra7xx_timer4_hwmod = {
  2376. .name = "timer4",
  2377. .class = &dra7xx_timer_hwmod_class,
  2378. .clkdm_name = "l4per_clkdm",
  2379. .main_clk = "timer4_gfclk_mux",
  2380. .prcm = {
  2381. .omap4 = {
  2382. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER4_CLKCTRL_OFFSET,
  2383. .context_offs = DRA7XX_RM_L4PER_TIMER4_CONTEXT_OFFSET,
  2384. .modulemode = MODULEMODE_SWCTRL,
  2385. },
  2386. },
  2387. };
  2388. /* timer5 */
  2389. static struct omap_hwmod dra7xx_timer5_hwmod = {
  2390. .name = "timer5",
  2391. .class = &dra7xx_timer_hwmod_class,
  2392. .clkdm_name = "ipu_clkdm",
  2393. .main_clk = "timer5_gfclk_mux",
  2394. .prcm = {
  2395. .omap4 = {
  2396. .clkctrl_offs = DRA7XX_CM_IPU_TIMER5_CLKCTRL_OFFSET,
  2397. .context_offs = DRA7XX_RM_IPU_TIMER5_CONTEXT_OFFSET,
  2398. .modulemode = MODULEMODE_SWCTRL,
  2399. },
  2400. },
  2401. };
  2402. /* timer6 */
  2403. static struct omap_hwmod dra7xx_timer6_hwmod = {
  2404. .name = "timer6",
  2405. .class = &dra7xx_timer_hwmod_class,
  2406. .clkdm_name = "ipu_clkdm",
  2407. .main_clk = "timer6_gfclk_mux",
  2408. .prcm = {
  2409. .omap4 = {
  2410. .clkctrl_offs = DRA7XX_CM_IPU_TIMER6_CLKCTRL_OFFSET,
  2411. .context_offs = DRA7XX_RM_IPU_TIMER6_CONTEXT_OFFSET,
  2412. .modulemode = MODULEMODE_SWCTRL,
  2413. },
  2414. },
  2415. };
  2416. /* timer7 */
  2417. static struct omap_hwmod dra7xx_timer7_hwmod = {
  2418. .name = "timer7",
  2419. .class = &dra7xx_timer_hwmod_class,
  2420. .clkdm_name = "ipu_clkdm",
  2421. .main_clk = "timer7_gfclk_mux",
  2422. .prcm = {
  2423. .omap4 = {
  2424. .clkctrl_offs = DRA7XX_CM_IPU_TIMER7_CLKCTRL_OFFSET,
  2425. .context_offs = DRA7XX_RM_IPU_TIMER7_CONTEXT_OFFSET,
  2426. .modulemode = MODULEMODE_SWCTRL,
  2427. },
  2428. },
  2429. };
  2430. /* timer8 */
  2431. static struct omap_hwmod dra7xx_timer8_hwmod = {
  2432. .name = "timer8",
  2433. .class = &dra7xx_timer_hwmod_class,
  2434. .clkdm_name = "ipu_clkdm",
  2435. .main_clk = "timer8_gfclk_mux",
  2436. .prcm = {
  2437. .omap4 = {
  2438. .clkctrl_offs = DRA7XX_CM_IPU_TIMER8_CLKCTRL_OFFSET,
  2439. .context_offs = DRA7XX_RM_IPU_TIMER8_CONTEXT_OFFSET,
  2440. .modulemode = MODULEMODE_SWCTRL,
  2441. },
  2442. },
  2443. };
  2444. /* timer9 */
  2445. static struct omap_hwmod dra7xx_timer9_hwmod = {
  2446. .name = "timer9",
  2447. .class = &dra7xx_timer_hwmod_class,
  2448. .clkdm_name = "l4per_clkdm",
  2449. .main_clk = "timer9_gfclk_mux",
  2450. .prcm = {
  2451. .omap4 = {
  2452. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER9_CLKCTRL_OFFSET,
  2453. .context_offs = DRA7XX_RM_L4PER_TIMER9_CONTEXT_OFFSET,
  2454. .modulemode = MODULEMODE_SWCTRL,
  2455. },
  2456. },
  2457. };
  2458. /* timer10 */
  2459. static struct omap_hwmod dra7xx_timer10_hwmod = {
  2460. .name = "timer10",
  2461. .class = &dra7xx_timer_1ms_hwmod_class,
  2462. .clkdm_name = "l4per_clkdm",
  2463. .main_clk = "timer10_gfclk_mux",
  2464. .prcm = {
  2465. .omap4 = {
  2466. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER10_CLKCTRL_OFFSET,
  2467. .context_offs = DRA7XX_RM_L4PER_TIMER10_CONTEXT_OFFSET,
  2468. .modulemode = MODULEMODE_SWCTRL,
  2469. },
  2470. },
  2471. };
  2472. /* timer11 */
  2473. static struct omap_hwmod dra7xx_timer11_hwmod = {
  2474. .name = "timer11",
  2475. .class = &dra7xx_timer_hwmod_class,
  2476. .clkdm_name = "l4per_clkdm",
  2477. .main_clk = "timer11_gfclk_mux",
  2478. .prcm = {
  2479. .omap4 = {
  2480. .clkctrl_offs = DRA7XX_CM_L4PER_TIMER11_CLKCTRL_OFFSET,
  2481. .context_offs = DRA7XX_RM_L4PER_TIMER11_CONTEXT_OFFSET,
  2482. .modulemode = MODULEMODE_SWCTRL,
  2483. },
  2484. },
  2485. };
  2486. /* timer12 */
  2487. static struct omap_hwmod dra7xx_timer12_hwmod = {
  2488. .name = "timer12",
  2489. .class = &dra7xx_timer_hwmod_class,
  2490. .clkdm_name = "wkupaon_clkdm",
  2491. .main_clk = "secure_32k_clk_src_ck",
  2492. .prcm = {
  2493. .omap4 = {
  2494. .clkctrl_offs = DRA7XX_CM_WKUPAON_TIMER12_CLKCTRL_OFFSET,
  2495. .context_offs = DRA7XX_RM_WKUPAON_TIMER12_CONTEXT_OFFSET,
  2496. },
  2497. },
  2498. };
  2499. /* timer13 */
  2500. static struct omap_hwmod dra7xx_timer13_hwmod = {
  2501. .name = "timer13",
  2502. .class = &dra7xx_timer_hwmod_class,
  2503. .clkdm_name = "l4per3_clkdm",
  2504. .main_clk = "timer13_gfclk_mux",
  2505. .prcm = {
  2506. .omap4 = {
  2507. .clkctrl_offs = DRA7XX_CM_L4PER3_TIMER13_CLKCTRL_OFFSET,
  2508. .context_offs = DRA7XX_RM_L4PER3_TIMER13_CONTEXT_OFFSET,
  2509. .modulemode = MODULEMODE_SWCTRL,
  2510. },
  2511. },
  2512. };
  2513. /* timer14 */
  2514. static struct omap_hwmod dra7xx_timer14_hwmod = {
  2515. .name = "timer14",
  2516. .class = &dra7xx_timer_hwmod_class,
  2517. .clkdm_name = "l4per3_clkdm",
  2518. .main_clk = "timer14_gfclk_mux",
  2519. .prcm = {
  2520. .omap4 = {
  2521. .clkctrl_offs = DRA7XX_CM_L4PER3_TIMER14_CLKCTRL_OFFSET,
  2522. .context_offs = DRA7XX_RM_L4PER3_TIMER14_CONTEXT_OFFSET,
  2523. .modulemode = MODULEMODE_SWCTRL,
  2524. },
  2525. },
  2526. };
  2527. /* timer15 */
  2528. static struct omap_hwmod dra7xx_timer15_hwmod = {
  2529. .name = "timer15",
  2530. .class = &dra7xx_timer_hwmod_class,
  2531. .clkdm_name = "l4per3_clkdm",
  2532. .main_clk = "timer15_gfclk_mux",
  2533. .prcm = {
  2534. .omap4 = {
  2535. .clkctrl_offs = DRA7XX_CM_L4PER3_TIMER15_CLKCTRL_OFFSET,
  2536. .context_offs = DRA7XX_RM_L4PER3_TIMER15_CONTEXT_OFFSET,
  2537. .modulemode = MODULEMODE_SWCTRL,
  2538. },
  2539. },
  2540. };
  2541. /* timer16 */
  2542. static struct omap_hwmod dra7xx_timer16_hwmod = {
  2543. .name = "timer16",
  2544. .class = &dra7xx_timer_hwmod_class,
  2545. .clkdm_name = "l4per3_clkdm",
  2546. .main_clk = "timer16_gfclk_mux",
  2547. .prcm = {
  2548. .omap4 = {
  2549. .clkctrl_offs = DRA7XX_CM_L4PER3_TIMER16_CLKCTRL_OFFSET,
  2550. .context_offs = DRA7XX_RM_L4PER3_TIMER16_CONTEXT_OFFSET,
  2551. .modulemode = MODULEMODE_SWCTRL,
  2552. },
  2553. },
  2554. };
  2555. /*
  2556. * 'uart' class
  2557. *
  2558. */
  2559. static struct omap_hwmod_class_sysconfig dra7xx_uart_sysc = {
  2560. .rev_offs = 0x0050,
  2561. .sysc_offs = 0x0054,
  2562. .syss_offs = 0x0058,
  2563. .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
  2564. SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
  2565. SYSS_HAS_RESET_STATUS),
  2566. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2567. SIDLE_SMART_WKUP),
  2568. .sysc_fields = &omap_hwmod_sysc_type1,
  2569. };
  2570. static struct omap_hwmod_class dra7xx_uart_hwmod_class = {
  2571. .name = "uart",
  2572. .sysc = &dra7xx_uart_sysc,
  2573. };
  2574. /* uart1 */
  2575. static struct omap_hwmod dra7xx_uart1_hwmod = {
  2576. .name = "uart1",
  2577. .class = &dra7xx_uart_hwmod_class,
  2578. .clkdm_name = "l4per_clkdm",
  2579. .main_clk = "uart1_gfclk_mux",
  2580. .flags = HWMOD_SWSUP_SIDLE_ACT | DEBUG_OMAP2UART1_FLAGS,
  2581. .prcm = {
  2582. .omap4 = {
  2583. .clkctrl_offs = DRA7XX_CM_L4PER_UART1_CLKCTRL_OFFSET,
  2584. .context_offs = DRA7XX_RM_L4PER_UART1_CONTEXT_OFFSET,
  2585. .modulemode = MODULEMODE_SWCTRL,
  2586. },
  2587. },
  2588. };
  2589. /* uart2 */
  2590. static struct omap_hwmod dra7xx_uart2_hwmod = {
  2591. .name = "uart2",
  2592. .class = &dra7xx_uart_hwmod_class,
  2593. .clkdm_name = "l4per_clkdm",
  2594. .main_clk = "uart2_gfclk_mux",
  2595. .flags = HWMOD_SWSUP_SIDLE_ACT,
  2596. .prcm = {
  2597. .omap4 = {
  2598. .clkctrl_offs = DRA7XX_CM_L4PER_UART2_CLKCTRL_OFFSET,
  2599. .context_offs = DRA7XX_RM_L4PER_UART2_CONTEXT_OFFSET,
  2600. .modulemode = MODULEMODE_SWCTRL,
  2601. },
  2602. },
  2603. };
  2604. /* uart3 */
  2605. static struct omap_hwmod dra7xx_uart3_hwmod = {
  2606. .name = "uart3",
  2607. .class = &dra7xx_uart_hwmod_class,
  2608. .clkdm_name = "l4per_clkdm",
  2609. .main_clk = "uart3_gfclk_mux",
  2610. .flags = HWMOD_SWSUP_SIDLE_ACT | DEBUG_OMAP4UART3_FLAGS,
  2611. .prcm = {
  2612. .omap4 = {
  2613. .clkctrl_offs = DRA7XX_CM_L4PER_UART3_CLKCTRL_OFFSET,
  2614. .context_offs = DRA7XX_RM_L4PER_UART3_CONTEXT_OFFSET,
  2615. .modulemode = MODULEMODE_SWCTRL,
  2616. },
  2617. },
  2618. };
  2619. /* uart4 */
  2620. static struct omap_hwmod dra7xx_uart4_hwmod = {
  2621. .name = "uart4",
  2622. .class = &dra7xx_uart_hwmod_class,
  2623. .clkdm_name = "l4per_clkdm",
  2624. .main_clk = "uart4_gfclk_mux",
  2625. .flags = HWMOD_SWSUP_SIDLE_ACT | DEBUG_OMAP4UART4_FLAGS,
  2626. .prcm = {
  2627. .omap4 = {
  2628. .clkctrl_offs = DRA7XX_CM_L4PER_UART4_CLKCTRL_OFFSET,
  2629. .context_offs = DRA7XX_RM_L4PER_UART4_CONTEXT_OFFSET,
  2630. .modulemode = MODULEMODE_SWCTRL,
  2631. },
  2632. },
  2633. };
  2634. /* uart5 */
  2635. static struct omap_hwmod dra7xx_uart5_hwmod = {
  2636. .name = "uart5",
  2637. .class = &dra7xx_uart_hwmod_class,
  2638. .clkdm_name = "l4per_clkdm",
  2639. .main_clk = "uart5_gfclk_mux",
  2640. .flags = HWMOD_SWSUP_SIDLE_ACT,
  2641. .prcm = {
  2642. .omap4 = {
  2643. .clkctrl_offs = DRA7XX_CM_L4PER_UART5_CLKCTRL_OFFSET,
  2644. .context_offs = DRA7XX_RM_L4PER_UART5_CONTEXT_OFFSET,
  2645. .modulemode = MODULEMODE_SWCTRL,
  2646. },
  2647. },
  2648. };
  2649. /* uart6 */
  2650. static struct omap_hwmod dra7xx_uart6_hwmod = {
  2651. .name = "uart6",
  2652. .class = &dra7xx_uart_hwmod_class,
  2653. .clkdm_name = "ipu_clkdm",
  2654. .main_clk = "uart6_gfclk_mux",
  2655. .flags = HWMOD_SWSUP_SIDLE_ACT,
  2656. .prcm = {
  2657. .omap4 = {
  2658. .clkctrl_offs = DRA7XX_CM_IPU_UART6_CLKCTRL_OFFSET,
  2659. .context_offs = DRA7XX_RM_IPU_UART6_CONTEXT_OFFSET,
  2660. .modulemode = MODULEMODE_SWCTRL,
  2661. },
  2662. },
  2663. };
  2664. /* uart7 */
  2665. static struct omap_hwmod dra7xx_uart7_hwmod = {
  2666. .name = "uart7",
  2667. .class = &dra7xx_uart_hwmod_class,
  2668. .clkdm_name = "l4per2_clkdm",
  2669. .main_clk = "uart7_gfclk_mux",
  2670. .flags = HWMOD_SWSUP_SIDLE_ACT,
  2671. .prcm = {
  2672. .omap4 = {
  2673. .clkctrl_offs = DRA7XX_CM_L4PER2_UART7_CLKCTRL_OFFSET,
  2674. .context_offs = DRA7XX_RM_L4PER2_UART7_CONTEXT_OFFSET,
  2675. .modulemode = MODULEMODE_SWCTRL,
  2676. },
  2677. },
  2678. };
  2679. /* uart8 */
  2680. static struct omap_hwmod dra7xx_uart8_hwmod = {
  2681. .name = "uart8",
  2682. .class = &dra7xx_uart_hwmod_class,
  2683. .clkdm_name = "l4per2_clkdm",
  2684. .main_clk = "uart8_gfclk_mux",
  2685. .flags = HWMOD_SWSUP_SIDLE_ACT,
  2686. .prcm = {
  2687. .omap4 = {
  2688. .clkctrl_offs = DRA7XX_CM_L4PER2_UART8_CLKCTRL_OFFSET,
  2689. .context_offs = DRA7XX_RM_L4PER2_UART8_CONTEXT_OFFSET,
  2690. .modulemode = MODULEMODE_SWCTRL,
  2691. },
  2692. },
  2693. };
  2694. /* uart9 */
  2695. static struct omap_hwmod dra7xx_uart9_hwmod = {
  2696. .name = "uart9",
  2697. .class = &dra7xx_uart_hwmod_class,
  2698. .clkdm_name = "l4per2_clkdm",
  2699. .main_clk = "uart9_gfclk_mux",
  2700. .flags = HWMOD_SWSUP_SIDLE_ACT,
  2701. .prcm = {
  2702. .omap4 = {
  2703. .clkctrl_offs = DRA7XX_CM_L4PER2_UART9_CLKCTRL_OFFSET,
  2704. .context_offs = DRA7XX_RM_L4PER2_UART9_CONTEXT_OFFSET,
  2705. .modulemode = MODULEMODE_SWCTRL,
  2706. },
  2707. },
  2708. };
  2709. /* uart10 */
  2710. static struct omap_hwmod dra7xx_uart10_hwmod = {
  2711. .name = "uart10",
  2712. .class = &dra7xx_uart_hwmod_class,
  2713. .clkdm_name = "wkupaon_clkdm",
  2714. .main_clk = "uart10_gfclk_mux",
  2715. .flags = HWMOD_SWSUP_SIDLE_ACT,
  2716. .prcm = {
  2717. .omap4 = {
  2718. .clkctrl_offs = DRA7XX_CM_WKUPAON_UART10_CLKCTRL_OFFSET,
  2719. .context_offs = DRA7XX_RM_WKUPAON_UART10_CONTEXT_OFFSET,
  2720. .modulemode = MODULEMODE_SWCTRL,
  2721. },
  2722. },
  2723. };
  2724. /* DES (the 'P' (public) device) */
  2725. static struct omap_hwmod_class_sysconfig dra7xx_des_sysc = {
  2726. .rev_offs = 0x0030,
  2727. .sysc_offs = 0x0034,
  2728. .syss_offs = 0x0038,
  2729. .sysc_flags = SYSS_HAS_RESET_STATUS,
  2730. };
  2731. static struct omap_hwmod_class dra7xx_des_hwmod_class = {
  2732. .name = "des",
  2733. .sysc = &dra7xx_des_sysc,
  2734. };
  2735. /* DES */
  2736. static struct omap_hwmod dra7xx_des_hwmod = {
  2737. .name = "des",
  2738. .class = &dra7xx_des_hwmod_class,
  2739. .clkdm_name = "l4sec_clkdm",
  2740. .main_clk = "l3_iclk_div",
  2741. .prcm = {
  2742. .omap4 = {
  2743. .clkctrl_offs = DRA7XX_CM_L4SEC_DES3DES_CLKCTRL_OFFSET,
  2744. .context_offs = DRA7XX_RM_L4SEC_DES3DES_CONTEXT_OFFSET,
  2745. .modulemode = MODULEMODE_HWCTRL,
  2746. },
  2747. },
  2748. };
  2749. /* rng */
  2750. static struct omap_hwmod_class_sysconfig dra7xx_rng_sysc = {
  2751. .rev_offs = 0x1fe0,
  2752. .sysc_offs = 0x1fe4,
  2753. .sysc_flags = SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE,
  2754. .idlemodes = SIDLE_FORCE | SIDLE_NO,
  2755. .sysc_fields = &omap_hwmod_sysc_type1,
  2756. };
  2757. static struct omap_hwmod_class dra7xx_rng_hwmod_class = {
  2758. .name = "rng",
  2759. .sysc = &dra7xx_rng_sysc,
  2760. };
  2761. static struct omap_hwmod dra7xx_rng_hwmod = {
  2762. .name = "rng",
  2763. .class = &dra7xx_rng_hwmod_class,
  2764. .flags = HWMOD_SWSUP_SIDLE,
  2765. .clkdm_name = "l4sec_clkdm",
  2766. .prcm = {
  2767. .omap4 = {
  2768. .clkctrl_offs = DRA7XX_CM_L4SEC_RNG_CLKCTRL_OFFSET,
  2769. .context_offs = DRA7XX_RM_L4SEC_RNG_CONTEXT_OFFSET,
  2770. .modulemode = MODULEMODE_HWCTRL,
  2771. },
  2772. },
  2773. };
  2774. /*
  2775. * 'usb_otg_ss' class
  2776. *
  2777. */
  2778. static struct omap_hwmod_class_sysconfig dra7xx_usb_otg_ss_sysc = {
  2779. .rev_offs = 0x0000,
  2780. .sysc_offs = 0x0010,
  2781. .sysc_flags = (SYSC_HAS_DMADISABLE | SYSC_HAS_MIDLEMODE |
  2782. SYSC_HAS_SIDLEMODE),
  2783. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2784. SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
  2785. MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
  2786. .sysc_fields = &omap_hwmod_sysc_type2,
  2787. };
  2788. static struct omap_hwmod_class dra7xx_usb_otg_ss_hwmod_class = {
  2789. .name = "usb_otg_ss",
  2790. .sysc = &dra7xx_usb_otg_ss_sysc,
  2791. };
  2792. /* usb_otg_ss1 */
  2793. static struct omap_hwmod_opt_clk usb_otg_ss1_opt_clks[] = {
  2794. { .role = "refclk960m", .clk = "usb_otg_ss1_refclk960m" },
  2795. };
  2796. static struct omap_hwmod dra7xx_usb_otg_ss1_hwmod = {
  2797. .name = "usb_otg_ss1",
  2798. .class = &dra7xx_usb_otg_ss_hwmod_class,
  2799. .clkdm_name = "l3init_clkdm",
  2800. .main_clk = "dpll_core_h13x2_ck",
  2801. .flags = HWMOD_CLKDM_NOAUTO,
  2802. .prcm = {
  2803. .omap4 = {
  2804. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS1_CLKCTRL_OFFSET,
  2805. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS1_CONTEXT_OFFSET,
  2806. .modulemode = MODULEMODE_HWCTRL,
  2807. },
  2808. },
  2809. .opt_clks = usb_otg_ss1_opt_clks,
  2810. .opt_clks_cnt = ARRAY_SIZE(usb_otg_ss1_opt_clks),
  2811. };
  2812. /* usb_otg_ss2 */
  2813. static struct omap_hwmod_opt_clk usb_otg_ss2_opt_clks[] = {
  2814. { .role = "refclk960m", .clk = "usb_otg_ss2_refclk960m" },
  2815. };
  2816. static struct omap_hwmod dra7xx_usb_otg_ss2_hwmod = {
  2817. .name = "usb_otg_ss2",
  2818. .class = &dra7xx_usb_otg_ss_hwmod_class,
  2819. .clkdm_name = "l3init_clkdm",
  2820. .main_clk = "dpll_core_h13x2_ck",
  2821. .flags = HWMOD_CLKDM_NOAUTO,
  2822. .prcm = {
  2823. .omap4 = {
  2824. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS2_CLKCTRL_OFFSET,
  2825. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS2_CONTEXT_OFFSET,
  2826. .modulemode = MODULEMODE_HWCTRL,
  2827. },
  2828. },
  2829. .opt_clks = usb_otg_ss2_opt_clks,
  2830. .opt_clks_cnt = ARRAY_SIZE(usb_otg_ss2_opt_clks),
  2831. };
  2832. /* usb_otg_ss3 */
  2833. static struct omap_hwmod dra7xx_usb_otg_ss3_hwmod = {
  2834. .name = "usb_otg_ss3",
  2835. .class = &dra7xx_usb_otg_ss_hwmod_class,
  2836. .clkdm_name = "l3init_clkdm",
  2837. .main_clk = "dpll_core_h13x2_ck",
  2838. .prcm = {
  2839. .omap4 = {
  2840. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS3_CLKCTRL_OFFSET,
  2841. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS3_CONTEXT_OFFSET,
  2842. .modulemode = MODULEMODE_HWCTRL,
  2843. },
  2844. },
  2845. };
  2846. /* usb_otg_ss4 */
  2847. static struct omap_hwmod dra7xx_usb_otg_ss4_hwmod = {
  2848. .name = "usb_otg_ss4",
  2849. .class = &dra7xx_usb_otg_ss_hwmod_class,
  2850. .clkdm_name = "l3init_clkdm",
  2851. .main_clk = "dpll_core_h13x2_ck",
  2852. .prcm = {
  2853. .omap4 = {
  2854. .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS4_CLKCTRL_OFFSET,
  2855. .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS4_CONTEXT_OFFSET,
  2856. .modulemode = MODULEMODE_HWCTRL,
  2857. },
  2858. },
  2859. };
  2860. /*
  2861. * 'vcp' class
  2862. *
  2863. */
  2864. static struct omap_hwmod_class dra7xx_vcp_hwmod_class = {
  2865. .name = "vcp",
  2866. };
  2867. /* vcp1 */
  2868. static struct omap_hwmod dra7xx_vcp1_hwmod = {
  2869. .name = "vcp1",
  2870. .class = &dra7xx_vcp_hwmod_class,
  2871. .clkdm_name = "l3main1_clkdm",
  2872. .main_clk = "l3_iclk_div",
  2873. .prcm = {
  2874. .omap4 = {
  2875. .clkctrl_offs = DRA7XX_CM_L3MAIN1_VCP1_CLKCTRL_OFFSET,
  2876. .context_offs = DRA7XX_RM_L3MAIN1_VCP1_CONTEXT_OFFSET,
  2877. },
  2878. },
  2879. };
  2880. /* vcp2 */
  2881. static struct omap_hwmod dra7xx_vcp2_hwmod = {
  2882. .name = "vcp2",
  2883. .class = &dra7xx_vcp_hwmod_class,
  2884. .clkdm_name = "l3main1_clkdm",
  2885. .main_clk = "l3_iclk_div",
  2886. .prcm = {
  2887. .omap4 = {
  2888. .clkctrl_offs = DRA7XX_CM_L3MAIN1_VCP2_CLKCTRL_OFFSET,
  2889. .context_offs = DRA7XX_RM_L3MAIN1_VCP2_CONTEXT_OFFSET,
  2890. },
  2891. },
  2892. };
  2893. /*
  2894. * 'wd_timer' class
  2895. *
  2896. */
  2897. static struct omap_hwmod_class_sysconfig dra7xx_wd_timer_sysc = {
  2898. .rev_offs = 0x0000,
  2899. .sysc_offs = 0x0010,
  2900. .syss_offs = 0x0014,
  2901. .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_SIDLEMODE |
  2902. SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
  2903. .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
  2904. SIDLE_SMART_WKUP),
  2905. .sysc_fields = &omap_hwmod_sysc_type1,
  2906. };
  2907. static struct omap_hwmod_class dra7xx_wd_timer_hwmod_class = {
  2908. .name = "wd_timer",
  2909. .sysc = &dra7xx_wd_timer_sysc,
  2910. .pre_shutdown = &omap2_wd_timer_disable,
  2911. .reset = &omap2_wd_timer_reset,
  2912. };
  2913. /* wd_timer2 */
  2914. static struct omap_hwmod dra7xx_wd_timer2_hwmod = {
  2915. .name = "wd_timer2",
  2916. .class = &dra7xx_wd_timer_hwmod_class,
  2917. .clkdm_name = "wkupaon_clkdm",
  2918. .main_clk = "sys_32k_ck",
  2919. .prcm = {
  2920. .omap4 = {
  2921. .clkctrl_offs = DRA7XX_CM_WKUPAON_WD_TIMER2_CLKCTRL_OFFSET,
  2922. .context_offs = DRA7XX_RM_WKUPAON_WD_TIMER2_CONTEXT_OFFSET,
  2923. .modulemode = MODULEMODE_SWCTRL,
  2924. },
  2925. },
  2926. };
  2927. /*
  2928. * Interfaces
  2929. */
  2930. /* l3_main_1 -> dmm */
  2931. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__dmm = {
  2932. .master = &dra7xx_l3_main_1_hwmod,
  2933. .slave = &dra7xx_dmm_hwmod,
  2934. .clk = "l3_iclk_div",
  2935. .user = OCP_USER_SDMA,
  2936. };
  2937. /* l3_main_2 -> l3_instr */
  2938. static struct omap_hwmod_ocp_if dra7xx_l3_main_2__l3_instr = {
  2939. .master = &dra7xx_l3_main_2_hwmod,
  2940. .slave = &dra7xx_l3_instr_hwmod,
  2941. .clk = "l3_iclk_div",
  2942. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2943. };
  2944. /* l4_cfg -> l3_main_1 */
  2945. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__l3_main_1 = {
  2946. .master = &dra7xx_l4_cfg_hwmod,
  2947. .slave = &dra7xx_l3_main_1_hwmod,
  2948. .clk = "l3_iclk_div",
  2949. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2950. };
  2951. /* mpu -> l3_main_1 */
  2952. static struct omap_hwmod_ocp_if dra7xx_mpu__l3_main_1 = {
  2953. .master = &dra7xx_mpu_hwmod,
  2954. .slave = &dra7xx_l3_main_1_hwmod,
  2955. .clk = "l3_iclk_div",
  2956. .user = OCP_USER_MPU,
  2957. };
  2958. /* l3_main_1 -> l3_main_2 */
  2959. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l3_main_2 = {
  2960. .master = &dra7xx_l3_main_1_hwmod,
  2961. .slave = &dra7xx_l3_main_2_hwmod,
  2962. .clk = "l3_iclk_div",
  2963. .user = OCP_USER_MPU,
  2964. };
  2965. /* l4_cfg -> l3_main_2 */
  2966. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__l3_main_2 = {
  2967. .master = &dra7xx_l4_cfg_hwmod,
  2968. .slave = &dra7xx_l3_main_2_hwmod,
  2969. .clk = "l3_iclk_div",
  2970. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2971. };
  2972. /* l3_main_1 -> l4_cfg */
  2973. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_cfg = {
  2974. .master = &dra7xx_l3_main_1_hwmod,
  2975. .slave = &dra7xx_l4_cfg_hwmod,
  2976. .clk = "l3_iclk_div",
  2977. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2978. };
  2979. /* l3_main_1 -> mmu0_dsp1 */
  2980. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mmu0_dsp1 = {
  2981. .master = &dra7xx_l3_main_1_hwmod,
  2982. .slave = &dra7xx_mmu0_dsp1_hwmod,
  2983. .clk = "l3_iclk_div",
  2984. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2985. };
  2986. /* l3_main_1 -> mmu1_dsp1 */
  2987. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mmu1_dsp1 = {
  2988. .master = &dra7xx_l3_main_1_hwmod,
  2989. .slave = &dra7xx_mmu1_dsp1_hwmod,
  2990. .clk = "l3_iclk_div",
  2991. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2992. };
  2993. /* l3_main_1 -> mmu0_dsp2 */
  2994. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mmu0_dsp2 = {
  2995. .master = &dra7xx_l3_main_1_hwmod,
  2996. .slave = &dra7xx_mmu0_dsp2_hwmod,
  2997. .clk = "l3_iclk_div",
  2998. .user = OCP_USER_MPU | OCP_USER_SDMA,
  2999. };
  3000. /* l3_main_1 -> mmu1_dsp2 */
  3001. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mmu1_dsp2 = {
  3002. .master = &dra7xx_l3_main_1_hwmod,
  3003. .slave = &dra7xx_mmu1_dsp2_hwmod,
  3004. .clk = "l3_iclk_div",
  3005. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3006. };
  3007. /* l3_main_1 -> mmu_ipu1 */
  3008. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mmu_ipu1 = {
  3009. .master = &dra7xx_l3_main_1_hwmod,
  3010. .slave = &dra7xx_mmu_ipu1_hwmod,
  3011. .clk = "l3_iclk_div",
  3012. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3013. };
  3014. /* l3_main_1 -> mmu_ipu2 */
  3015. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mmu_ipu2 = {
  3016. .master = &dra7xx_l3_main_1_hwmod,
  3017. .slave = &dra7xx_mmu_ipu2_hwmod,
  3018. .clk = "l3_iclk_div",
  3019. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3020. };
  3021. /* l3_main_1 -> l4_per1 */
  3022. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per1 = {
  3023. .master = &dra7xx_l3_main_1_hwmod,
  3024. .slave = &dra7xx_l4_per1_hwmod,
  3025. .clk = "l3_iclk_div",
  3026. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3027. };
  3028. /* l3_main_1 -> l4_per2 */
  3029. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per2 = {
  3030. .master = &dra7xx_l3_main_1_hwmod,
  3031. .slave = &dra7xx_l4_per2_hwmod,
  3032. .clk = "l3_iclk_div",
  3033. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3034. };
  3035. /* l3_main_1 -> l4_per3 */
  3036. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_per3 = {
  3037. .master = &dra7xx_l3_main_1_hwmod,
  3038. .slave = &dra7xx_l4_per3_hwmod,
  3039. .clk = "l3_iclk_div",
  3040. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3041. };
  3042. /* l3_main_1 -> l4_wkup */
  3043. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__l4_wkup = {
  3044. .master = &dra7xx_l3_main_1_hwmod,
  3045. .slave = &dra7xx_l4_wkup_hwmod,
  3046. .clk = "wkupaon_iclk_mux",
  3047. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3048. };
  3049. /* l4_per2 -> atl */
  3050. static struct omap_hwmod_ocp_if dra7xx_l4_per2__atl = {
  3051. .master = &dra7xx_l4_per2_hwmod,
  3052. .slave = &dra7xx_atl_hwmod,
  3053. .clk = "l3_iclk_div",
  3054. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3055. };
  3056. /* l3_main_1 -> bb2d */
  3057. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__bb2d = {
  3058. .master = &dra7xx_l3_main_1_hwmod,
  3059. .slave = &dra7xx_bb2d_hwmod,
  3060. .clk = "l3_iclk_div",
  3061. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3062. };
  3063. /* l4_wkup -> counter_32k */
  3064. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__counter_32k = {
  3065. .master = &dra7xx_l4_wkup_hwmod,
  3066. .slave = &dra7xx_counter_32k_hwmod,
  3067. .clk = "wkupaon_iclk_mux",
  3068. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3069. };
  3070. /* l4_wkup -> ctrl_module_wkup */
  3071. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__ctrl_module_wkup = {
  3072. .master = &dra7xx_l4_wkup_hwmod,
  3073. .slave = &dra7xx_ctrl_module_wkup_hwmod,
  3074. .clk = "wkupaon_iclk_mux",
  3075. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3076. };
  3077. static struct omap_hwmod_ocp_if dra7xx_l4_per2__cpgmac0 = {
  3078. .master = &dra7xx_l4_per2_hwmod,
  3079. .slave = &dra7xx_gmac_hwmod,
  3080. .clk = "dpll_gmac_ck",
  3081. .user = OCP_USER_MPU,
  3082. };
  3083. static struct omap_hwmod_ocp_if dra7xx_gmac__mdio = {
  3084. .master = &dra7xx_gmac_hwmod,
  3085. .slave = &dra7xx_mdio_hwmod,
  3086. .user = OCP_USER_MPU,
  3087. };
  3088. /* l4_wkup -> dcan1 */
  3089. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__dcan1 = {
  3090. .master = &dra7xx_l4_wkup_hwmod,
  3091. .slave = &dra7xx_dcan1_hwmod,
  3092. .clk = "wkupaon_iclk_mux",
  3093. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3094. };
  3095. /* l4_per2 -> dcan2 */
  3096. static struct omap_hwmod_ocp_if dra7xx_l4_per2__dcan2 = {
  3097. .master = &dra7xx_l4_per2_hwmod,
  3098. .slave = &dra7xx_dcan2_hwmod,
  3099. .clk = "l3_iclk_div",
  3100. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3101. };
  3102. /* l4_cfg -> dma_system */
  3103. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__dma_system = {
  3104. .master = &dra7xx_l4_cfg_hwmod,
  3105. .slave = &dra7xx_dma_system_hwmod,
  3106. .clk = "l3_iclk_div",
  3107. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3108. };
  3109. /* l3_main_1 -> tpcc */
  3110. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__tpcc = {
  3111. .master = &dra7xx_l3_main_1_hwmod,
  3112. .slave = &dra7xx_tpcc_hwmod,
  3113. .clk = "l3_iclk_div",
  3114. .user = OCP_USER_MPU,
  3115. };
  3116. /* l3_main_1 -> tptc0 */
  3117. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__tptc0 = {
  3118. .master = &dra7xx_l3_main_1_hwmod,
  3119. .slave = &dra7xx_tptc0_hwmod,
  3120. .clk = "l3_iclk_div",
  3121. .user = OCP_USER_MPU,
  3122. };
  3123. /* l3_main_1 -> tptc1 */
  3124. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__tptc1 = {
  3125. .master = &dra7xx_l3_main_1_hwmod,
  3126. .slave = &dra7xx_tptc1_hwmod,
  3127. .clk = "l3_iclk_div",
  3128. .user = OCP_USER_MPU,
  3129. };
  3130. /* dsp1 -> l3_main_1 */
  3131. static struct omap_hwmod_ocp_if dra7xx_dsp1__l3_main_1 = {
  3132. .master = &dra7xx_dsp1_hwmod,
  3133. .slave = &dra7xx_l3_main_1_hwmod,
  3134. .clk = "l3_iclk_div",
  3135. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3136. };
  3137. /* dsp2 -> l3_main_1 */
  3138. static struct omap_hwmod_ocp_if dra7xx_dsp2__l3_main_1 = {
  3139. .master = &dra7xx_dsp2_hwmod,
  3140. .slave = &dra7xx_l3_main_1_hwmod,
  3141. .clk = "l3_iclk_div",
  3142. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3143. };
  3144. /* l3_main_1 -> dss */
  3145. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__dss = {
  3146. .master = &dra7xx_l3_main_1_hwmod,
  3147. .slave = &dra7xx_dss_hwmod,
  3148. .clk = "l3_iclk_div",
  3149. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3150. };
  3151. /* l3_main_1 -> dispc */
  3152. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__dispc = {
  3153. .master = &dra7xx_l3_main_1_hwmod,
  3154. .slave = &dra7xx_dss_dispc_hwmod,
  3155. .clk = "l3_iclk_div",
  3156. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3157. };
  3158. /* l3_main_1 -> dispc */
  3159. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__hdmi = {
  3160. .master = &dra7xx_l3_main_1_hwmod,
  3161. .slave = &dra7xx_dss_hdmi_hwmod,
  3162. .clk = "l3_iclk_div",
  3163. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3164. };
  3165. /* l3_main_1 -> aes1 */
  3166. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__aes1 = {
  3167. .master = &dra7xx_l3_main_1_hwmod,
  3168. .slave = &dra7xx_aes1_hwmod,
  3169. .clk = "l3_iclk_div",
  3170. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3171. };
  3172. /* l3_main_1 -> aes2 */
  3173. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__aes2 = {
  3174. .master = &dra7xx_l3_main_1_hwmod,
  3175. .slave = &dra7xx_aes2_hwmod,
  3176. .clk = "l3_iclk_div",
  3177. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3178. };
  3179. /* l3_main_1 -> sha0 */
  3180. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__sha0 = {
  3181. .master = &dra7xx_l3_main_1_hwmod,
  3182. .slave = &dra7xx_sha0_hwmod,
  3183. .clk = "l3_iclk_div",
  3184. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3185. };
  3186. /* l4_per2 -> mcasp1 */
  3187. static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp1 = {
  3188. .master = &dra7xx_l4_per2_hwmod,
  3189. .slave = &dra7xx_mcasp1_hwmod,
  3190. .clk = "l4_root_clk_div",
  3191. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3192. };
  3193. /* l3_main_1 -> mcasp1 */
  3194. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mcasp1 = {
  3195. .master = &dra7xx_l3_main_1_hwmod,
  3196. .slave = &dra7xx_mcasp1_hwmod,
  3197. .clk = "l3_iclk_div",
  3198. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3199. };
  3200. /* l4_per2 -> mcasp2 */
  3201. static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp2 = {
  3202. .master = &dra7xx_l4_per2_hwmod,
  3203. .slave = &dra7xx_mcasp2_hwmod,
  3204. .clk = "l4_root_clk_div",
  3205. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3206. };
  3207. /* l3_main_1 -> mcasp2 */
  3208. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mcasp2 = {
  3209. .master = &dra7xx_l3_main_1_hwmod,
  3210. .slave = &dra7xx_mcasp2_hwmod,
  3211. .clk = "l3_iclk_div",
  3212. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3213. };
  3214. /* l4_per2 -> mcasp3 */
  3215. static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp3 = {
  3216. .master = &dra7xx_l4_per2_hwmod,
  3217. .slave = &dra7xx_mcasp3_hwmod,
  3218. .clk = "l4_root_clk_div",
  3219. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3220. };
  3221. /* l3_main_1 -> mcasp3 */
  3222. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__mcasp3 = {
  3223. .master = &dra7xx_l3_main_1_hwmod,
  3224. .slave = &dra7xx_mcasp3_hwmod,
  3225. .clk = "l3_iclk_div",
  3226. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3227. };
  3228. /* l4_per2 -> mcasp4 */
  3229. static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp4 = {
  3230. .master = &dra7xx_l4_per2_hwmod,
  3231. .slave = &dra7xx_mcasp4_hwmod,
  3232. .clk = "l4_root_clk_div",
  3233. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3234. };
  3235. /* l4_per2 -> mcasp5 */
  3236. static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp5 = {
  3237. .master = &dra7xx_l4_per2_hwmod,
  3238. .slave = &dra7xx_mcasp5_hwmod,
  3239. .clk = "l4_root_clk_div",
  3240. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3241. };
  3242. /* l4_per2 -> mcasp6 */
  3243. static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp6 = {
  3244. .master = &dra7xx_l4_per2_hwmod,
  3245. .slave = &dra7xx_mcasp6_hwmod,
  3246. .clk = "l4_root_clk_div",
  3247. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3248. };
  3249. /* l4_per2 -> mcasp7 */
  3250. static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp7 = {
  3251. .master = &dra7xx_l4_per2_hwmod,
  3252. .slave = &dra7xx_mcasp7_hwmod,
  3253. .clk = "l4_root_clk_div",
  3254. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3255. };
  3256. /* l4_per2 -> mcasp8 */
  3257. static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp8 = {
  3258. .master = &dra7xx_l4_per2_hwmod,
  3259. .slave = &dra7xx_mcasp8_hwmod,
  3260. .clk = "l4_root_clk_div",
  3261. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3262. };
  3263. /* l4_per1 -> elm */
  3264. static struct omap_hwmod_ocp_if dra7xx_l4_per1__elm = {
  3265. .master = &dra7xx_l4_per1_hwmod,
  3266. .slave = &dra7xx_elm_hwmod,
  3267. .clk = "l3_iclk_div",
  3268. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3269. };
  3270. /* l4_wkup -> gpio1 */
  3271. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__gpio1 = {
  3272. .master = &dra7xx_l4_wkup_hwmod,
  3273. .slave = &dra7xx_gpio1_hwmod,
  3274. .clk = "wkupaon_iclk_mux",
  3275. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3276. };
  3277. /* l4_per1 -> gpio2 */
  3278. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio2 = {
  3279. .master = &dra7xx_l4_per1_hwmod,
  3280. .slave = &dra7xx_gpio2_hwmod,
  3281. .clk = "l3_iclk_div",
  3282. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3283. };
  3284. /* l4_per1 -> gpio3 */
  3285. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio3 = {
  3286. .master = &dra7xx_l4_per1_hwmod,
  3287. .slave = &dra7xx_gpio3_hwmod,
  3288. .clk = "l3_iclk_div",
  3289. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3290. };
  3291. /* l4_per1 -> gpio4 */
  3292. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio4 = {
  3293. .master = &dra7xx_l4_per1_hwmod,
  3294. .slave = &dra7xx_gpio4_hwmod,
  3295. .clk = "l3_iclk_div",
  3296. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3297. };
  3298. /* l4_per1 -> gpio5 */
  3299. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio5 = {
  3300. .master = &dra7xx_l4_per1_hwmod,
  3301. .slave = &dra7xx_gpio5_hwmod,
  3302. .clk = "l3_iclk_div",
  3303. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3304. };
  3305. /* l4_per1 -> gpio6 */
  3306. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio6 = {
  3307. .master = &dra7xx_l4_per1_hwmod,
  3308. .slave = &dra7xx_gpio6_hwmod,
  3309. .clk = "l3_iclk_div",
  3310. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3311. };
  3312. /* l4_per1 -> gpio7 */
  3313. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio7 = {
  3314. .master = &dra7xx_l4_per1_hwmod,
  3315. .slave = &dra7xx_gpio7_hwmod,
  3316. .clk = "l3_iclk_div",
  3317. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3318. };
  3319. /* l4_per1 -> gpio8 */
  3320. static struct omap_hwmod_ocp_if dra7xx_l4_per1__gpio8 = {
  3321. .master = &dra7xx_l4_per1_hwmod,
  3322. .slave = &dra7xx_gpio8_hwmod,
  3323. .clk = "l3_iclk_div",
  3324. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3325. };
  3326. /* l3_main_1 -> gpmc */
  3327. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__gpmc = {
  3328. .master = &dra7xx_l3_main_1_hwmod,
  3329. .slave = &dra7xx_gpmc_hwmod,
  3330. .clk = "l3_iclk_div",
  3331. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3332. };
  3333. /* l3_main_1 -> gpu */
  3334. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__gpu = {
  3335. .master = &dra7xx_l3_main_1_hwmod,
  3336. .slave = &dra7xx_gpu_hwmod,
  3337. .clk = "l3_iclk_div",
  3338. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3339. };
  3340. /* l4_per1 -> hdq1w */
  3341. static struct omap_hwmod_ocp_if dra7xx_l4_per1__hdq1w = {
  3342. .master = &dra7xx_l4_per1_hwmod,
  3343. .slave = &dra7xx_hdq1w_hwmod,
  3344. .clk = "l3_iclk_div",
  3345. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3346. };
  3347. /* l4_per1 -> i2c1 */
  3348. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c1 = {
  3349. .master = &dra7xx_l4_per1_hwmod,
  3350. .slave = &dra7xx_i2c1_hwmod,
  3351. .clk = "l3_iclk_div",
  3352. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3353. };
  3354. /* l4_per1 -> i2c2 */
  3355. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c2 = {
  3356. .master = &dra7xx_l4_per1_hwmod,
  3357. .slave = &dra7xx_i2c2_hwmod,
  3358. .clk = "l3_iclk_div",
  3359. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3360. };
  3361. /* l4_per1 -> i2c3 */
  3362. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c3 = {
  3363. .master = &dra7xx_l4_per1_hwmod,
  3364. .slave = &dra7xx_i2c3_hwmod,
  3365. .clk = "l3_iclk_div",
  3366. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3367. };
  3368. /* l4_per1 -> i2c4 */
  3369. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c4 = {
  3370. .master = &dra7xx_l4_per1_hwmod,
  3371. .slave = &dra7xx_i2c4_hwmod,
  3372. .clk = "l3_iclk_div",
  3373. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3374. };
  3375. /* l4_per1 -> i2c5 */
  3376. static struct omap_hwmod_ocp_if dra7xx_l4_per1__i2c5 = {
  3377. .master = &dra7xx_l4_per1_hwmod,
  3378. .slave = &dra7xx_i2c5_hwmod,
  3379. .clk = "l3_iclk_div",
  3380. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3381. };
  3382. /* ipu1 -> l3_main_1 */
  3383. static struct omap_hwmod_ocp_if dra7xx_ipu1__l3_main_1 = {
  3384. .master = &dra7xx_ipu1_hwmod,
  3385. .slave = &dra7xx_l3_main_1_hwmod,
  3386. .clk = "l3_iclk_div",
  3387. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3388. };
  3389. /* ipu2 -> l3_main_1 */
  3390. static struct omap_hwmod_ocp_if dra7xx_ipu2__l3_main_1 = {
  3391. .master = &dra7xx_ipu2_hwmod,
  3392. .slave = &dra7xx_l3_main_1_hwmod,
  3393. .clk = "l3_iclk_div",
  3394. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3395. };
  3396. /* l4_cfg -> mailbox1 */
  3397. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__mailbox1 = {
  3398. .master = &dra7xx_l4_cfg_hwmod,
  3399. .slave = &dra7xx_mailbox1_hwmod,
  3400. .clk = "l3_iclk_div",
  3401. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3402. };
  3403. /* l4_per3 -> mailbox2 */
  3404. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox2 = {
  3405. .master = &dra7xx_l4_per3_hwmod,
  3406. .slave = &dra7xx_mailbox2_hwmod,
  3407. .clk = "l3_iclk_div",
  3408. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3409. };
  3410. /* l4_per3 -> mailbox3 */
  3411. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox3 = {
  3412. .master = &dra7xx_l4_per3_hwmod,
  3413. .slave = &dra7xx_mailbox3_hwmod,
  3414. .clk = "l3_iclk_div",
  3415. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3416. };
  3417. /* l4_per3 -> mailbox4 */
  3418. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox4 = {
  3419. .master = &dra7xx_l4_per3_hwmod,
  3420. .slave = &dra7xx_mailbox4_hwmod,
  3421. .clk = "l3_iclk_div",
  3422. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3423. };
  3424. /* l4_per3 -> mailbox5 */
  3425. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox5 = {
  3426. .master = &dra7xx_l4_per3_hwmod,
  3427. .slave = &dra7xx_mailbox5_hwmod,
  3428. .clk = "l3_iclk_div",
  3429. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3430. };
  3431. /* l4_per3 -> mailbox6 */
  3432. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox6 = {
  3433. .master = &dra7xx_l4_per3_hwmod,
  3434. .slave = &dra7xx_mailbox6_hwmod,
  3435. .clk = "l3_iclk_div",
  3436. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3437. };
  3438. /* l4_per3 -> mailbox7 */
  3439. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox7 = {
  3440. .master = &dra7xx_l4_per3_hwmod,
  3441. .slave = &dra7xx_mailbox7_hwmod,
  3442. .clk = "l3_iclk_div",
  3443. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3444. };
  3445. /* l4_per3 -> mailbox8 */
  3446. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox8 = {
  3447. .master = &dra7xx_l4_per3_hwmod,
  3448. .slave = &dra7xx_mailbox8_hwmod,
  3449. .clk = "l3_iclk_div",
  3450. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3451. };
  3452. /* l4_per3 -> mailbox9 */
  3453. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox9 = {
  3454. .master = &dra7xx_l4_per3_hwmod,
  3455. .slave = &dra7xx_mailbox9_hwmod,
  3456. .clk = "l3_iclk_div",
  3457. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3458. };
  3459. /* l4_per3 -> mailbox10 */
  3460. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox10 = {
  3461. .master = &dra7xx_l4_per3_hwmod,
  3462. .slave = &dra7xx_mailbox10_hwmod,
  3463. .clk = "l3_iclk_div",
  3464. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3465. };
  3466. /* l4_per3 -> mailbox11 */
  3467. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox11 = {
  3468. .master = &dra7xx_l4_per3_hwmod,
  3469. .slave = &dra7xx_mailbox11_hwmod,
  3470. .clk = "l3_iclk_div",
  3471. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3472. };
  3473. /* l4_per3 -> mailbox12 */
  3474. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox12 = {
  3475. .master = &dra7xx_l4_per3_hwmod,
  3476. .slave = &dra7xx_mailbox12_hwmod,
  3477. .clk = "l3_iclk_div",
  3478. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3479. };
  3480. /* l4_per3 -> mailbox13 */
  3481. static struct omap_hwmod_ocp_if dra7xx_l4_per3__mailbox13 = {
  3482. .master = &dra7xx_l4_per3_hwmod,
  3483. .slave = &dra7xx_mailbox13_hwmod,
  3484. .clk = "l3_iclk_div",
  3485. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3486. };
  3487. /* l4_per1 -> mcspi1 */
  3488. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi1 = {
  3489. .master = &dra7xx_l4_per1_hwmod,
  3490. .slave = &dra7xx_mcspi1_hwmod,
  3491. .clk = "l3_iclk_div",
  3492. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3493. };
  3494. /* l4_per1 -> mcspi2 */
  3495. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi2 = {
  3496. .master = &dra7xx_l4_per1_hwmod,
  3497. .slave = &dra7xx_mcspi2_hwmod,
  3498. .clk = "l3_iclk_div",
  3499. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3500. };
  3501. /* l4_per1 -> mcspi3 */
  3502. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi3 = {
  3503. .master = &dra7xx_l4_per1_hwmod,
  3504. .slave = &dra7xx_mcspi3_hwmod,
  3505. .clk = "l3_iclk_div",
  3506. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3507. };
  3508. /* l4_per1 -> mcspi4 */
  3509. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mcspi4 = {
  3510. .master = &dra7xx_l4_per1_hwmod,
  3511. .slave = &dra7xx_mcspi4_hwmod,
  3512. .clk = "l3_iclk_div",
  3513. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3514. };
  3515. /* l4_per1 -> mmc1 */
  3516. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc1 = {
  3517. .master = &dra7xx_l4_per1_hwmod,
  3518. .slave = &dra7xx_mmc1_hwmod,
  3519. .clk = "l3_iclk_div",
  3520. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3521. };
  3522. /* l4_per1 -> mmc2 */
  3523. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc2 = {
  3524. .master = &dra7xx_l4_per1_hwmod,
  3525. .slave = &dra7xx_mmc2_hwmod,
  3526. .clk = "l3_iclk_div",
  3527. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3528. };
  3529. /* l4_per1 -> mmc3 */
  3530. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc3 = {
  3531. .master = &dra7xx_l4_per1_hwmod,
  3532. .slave = &dra7xx_mmc3_hwmod,
  3533. .clk = "l3_iclk_div",
  3534. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3535. };
  3536. /* l4_per1 -> mmc4 */
  3537. static struct omap_hwmod_ocp_if dra7xx_l4_per1__mmc4 = {
  3538. .master = &dra7xx_l4_per1_hwmod,
  3539. .slave = &dra7xx_mmc4_hwmod,
  3540. .clk = "l3_iclk_div",
  3541. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3542. };
  3543. /* l4_cfg -> mpu */
  3544. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__mpu = {
  3545. .master = &dra7xx_l4_cfg_hwmod,
  3546. .slave = &dra7xx_mpu_hwmod,
  3547. .clk = "l3_iclk_div",
  3548. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3549. };
  3550. /* l4_cfg -> ocp2scp1 */
  3551. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__ocp2scp1 = {
  3552. .master = &dra7xx_l4_cfg_hwmod,
  3553. .slave = &dra7xx_ocp2scp1_hwmod,
  3554. .clk = "l4_root_clk_div",
  3555. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3556. };
  3557. /* l4_cfg -> ocp2scp3 */
  3558. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__ocp2scp3 = {
  3559. .master = &dra7xx_l4_cfg_hwmod,
  3560. .slave = &dra7xx_ocp2scp3_hwmod,
  3561. .clk = "l4_root_clk_div",
  3562. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3563. };
  3564. /* l3_main_1 -> pciess1 */
  3565. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__pciess1 = {
  3566. .master = &dra7xx_l3_main_1_hwmod,
  3567. .slave = &dra7xx_pciess1_hwmod,
  3568. .clk = "l3_iclk_div",
  3569. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3570. };
  3571. /* l4_cfg -> pciess1 */
  3572. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__pciess1 = {
  3573. .master = &dra7xx_l4_cfg_hwmod,
  3574. .slave = &dra7xx_pciess1_hwmod,
  3575. .clk = "l4_root_clk_div",
  3576. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3577. };
  3578. /* l3_main_1 -> pciess2 */
  3579. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__pciess2 = {
  3580. .master = &dra7xx_l3_main_1_hwmod,
  3581. .slave = &dra7xx_pciess2_hwmod,
  3582. .clk = "l3_iclk_div",
  3583. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3584. };
  3585. /* l4_cfg -> pciess2 */
  3586. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__pciess2 = {
  3587. .master = &dra7xx_l4_cfg_hwmod,
  3588. .slave = &dra7xx_pciess2_hwmod,
  3589. .clk = "l4_root_clk_div",
  3590. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3591. };
  3592. /* l4_cfg -> pruss1 */
  3593. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__pruss1 = {
  3594. .master = &dra7xx_l4_cfg_hwmod,
  3595. .slave = &dra7xx_pruss1_hwmod,
  3596. .clk = "dpll_gmac_h13x2_ck",
  3597. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3598. };
  3599. /* l4_cfg -> pruss2 */
  3600. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__pruss2 = {
  3601. .master = &dra7xx_l4_cfg_hwmod,
  3602. .slave = &dra7xx_pruss2_hwmod,
  3603. .clk = "dpll_gmac_h13x2_ck",
  3604. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3605. };
  3606. /* l3_main_1 -> qspi */
  3607. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__qspi = {
  3608. .master = &dra7xx_l3_main_1_hwmod,
  3609. .slave = &dra7xx_qspi_hwmod,
  3610. .clk = "l3_iclk_div",
  3611. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3612. };
  3613. /* l4_per3 -> rtcss */
  3614. static struct omap_hwmod_ocp_if dra7xx_l4_per3__rtcss = {
  3615. .master = &dra7xx_l4_per3_hwmod,
  3616. .slave = &dra7xx_rtcss_hwmod,
  3617. .clk = "l4_root_clk_div",
  3618. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3619. };
  3620. /* l4_cfg -> sata */
  3621. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__sata = {
  3622. .master = &dra7xx_l4_cfg_hwmod,
  3623. .slave = &dra7xx_sata_hwmod,
  3624. .clk = "l3_iclk_div",
  3625. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3626. };
  3627. /* l4_cfg -> smartreflex_core */
  3628. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__smartreflex_core = {
  3629. .master = &dra7xx_l4_cfg_hwmod,
  3630. .slave = &dra7xx_smartreflex_core_hwmod,
  3631. .clk = "l4_root_clk_div",
  3632. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3633. };
  3634. /* l4_cfg -> smartreflex_mpu */
  3635. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__smartreflex_mpu = {
  3636. .master = &dra7xx_l4_cfg_hwmod,
  3637. .slave = &dra7xx_smartreflex_mpu_hwmod,
  3638. .clk = "l4_root_clk_div",
  3639. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3640. };
  3641. /* l4_cfg -> spinlock */
  3642. static struct omap_hwmod_ocp_if dra7xx_l4_cfg__spinlock = {
  3643. .master = &dra7xx_l4_cfg_hwmod,
  3644. .slave = &dra7xx_spinlock_hwmod,
  3645. .clk = "l3_iclk_div",
  3646. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3647. };
  3648. /* l4_wkup -> timer1 */
  3649. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__timer1 = {
  3650. .master = &dra7xx_l4_wkup_hwmod,
  3651. .slave = &dra7xx_timer1_hwmod,
  3652. .clk = "wkupaon_iclk_mux",
  3653. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3654. };
  3655. /* l4_per1 -> timer2 */
  3656. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer2 = {
  3657. .master = &dra7xx_l4_per1_hwmod,
  3658. .slave = &dra7xx_timer2_hwmod,
  3659. .clk = "l3_iclk_div",
  3660. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3661. };
  3662. /* l4_per1 -> timer3 */
  3663. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer3 = {
  3664. .master = &dra7xx_l4_per1_hwmod,
  3665. .slave = &dra7xx_timer3_hwmod,
  3666. .clk = "l3_iclk_div",
  3667. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3668. };
  3669. /* l4_per1 -> timer4 */
  3670. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer4 = {
  3671. .master = &dra7xx_l4_per1_hwmod,
  3672. .slave = &dra7xx_timer4_hwmod,
  3673. .clk = "l3_iclk_div",
  3674. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3675. };
  3676. /* l4_per3 -> timer5 */
  3677. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer5 = {
  3678. .master = &dra7xx_l4_per3_hwmod,
  3679. .slave = &dra7xx_timer5_hwmod,
  3680. .clk = "l3_iclk_div",
  3681. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3682. };
  3683. /* l4_per3 -> timer6 */
  3684. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer6 = {
  3685. .master = &dra7xx_l4_per3_hwmod,
  3686. .slave = &dra7xx_timer6_hwmod,
  3687. .clk = "l3_iclk_div",
  3688. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3689. };
  3690. /* l4_per3 -> timer7 */
  3691. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer7 = {
  3692. .master = &dra7xx_l4_per3_hwmod,
  3693. .slave = &dra7xx_timer7_hwmod,
  3694. .clk = "l3_iclk_div",
  3695. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3696. };
  3697. /* l4_per3 -> timer8 */
  3698. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer8 = {
  3699. .master = &dra7xx_l4_per3_hwmod,
  3700. .slave = &dra7xx_timer8_hwmod,
  3701. .clk = "l3_iclk_div",
  3702. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3703. };
  3704. /* l4_per1 -> timer9 */
  3705. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer9 = {
  3706. .master = &dra7xx_l4_per1_hwmod,
  3707. .slave = &dra7xx_timer9_hwmod,
  3708. .clk = "l3_iclk_div",
  3709. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3710. };
  3711. /* l4_per1 -> timer10 */
  3712. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer10 = {
  3713. .master = &dra7xx_l4_per1_hwmod,
  3714. .slave = &dra7xx_timer10_hwmod,
  3715. .clk = "l3_iclk_div",
  3716. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3717. };
  3718. /* l4_per1 -> timer11 */
  3719. static struct omap_hwmod_ocp_if dra7xx_l4_per1__timer11 = {
  3720. .master = &dra7xx_l4_per1_hwmod,
  3721. .slave = &dra7xx_timer11_hwmod,
  3722. .clk = "l3_iclk_div",
  3723. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3724. };
  3725. /* l4_wkup -> timer12 */
  3726. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__timer12 = {
  3727. .master = &dra7xx_l4_wkup_hwmod,
  3728. .slave = &dra7xx_timer12_hwmod,
  3729. .clk = "wkupaon_iclk_mux",
  3730. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3731. };
  3732. /* l4_per3 -> timer13 */
  3733. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer13 = {
  3734. .master = &dra7xx_l4_per3_hwmod,
  3735. .slave = &dra7xx_timer13_hwmod,
  3736. .clk = "l3_iclk_div",
  3737. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3738. };
  3739. /* l4_per3 -> timer14 */
  3740. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer14 = {
  3741. .master = &dra7xx_l4_per3_hwmod,
  3742. .slave = &dra7xx_timer14_hwmod,
  3743. .clk = "l3_iclk_div",
  3744. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3745. };
  3746. /* l4_per3 -> timer15 */
  3747. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer15 = {
  3748. .master = &dra7xx_l4_per3_hwmod,
  3749. .slave = &dra7xx_timer15_hwmod,
  3750. .clk = "l3_iclk_div",
  3751. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3752. };
  3753. /* l4_per3 -> timer16 */
  3754. static struct omap_hwmod_ocp_if dra7xx_l4_per3__timer16 = {
  3755. .master = &dra7xx_l4_per3_hwmod,
  3756. .slave = &dra7xx_timer16_hwmod,
  3757. .clk = "l3_iclk_div",
  3758. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3759. };
  3760. /* l4_per1 -> uart1 */
  3761. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart1 = {
  3762. .master = &dra7xx_l4_per1_hwmod,
  3763. .slave = &dra7xx_uart1_hwmod,
  3764. .clk = "l3_iclk_div",
  3765. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3766. };
  3767. /* l4_per1 -> uart2 */
  3768. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart2 = {
  3769. .master = &dra7xx_l4_per1_hwmod,
  3770. .slave = &dra7xx_uart2_hwmod,
  3771. .clk = "l3_iclk_div",
  3772. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3773. };
  3774. /* l4_per1 -> uart3 */
  3775. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart3 = {
  3776. .master = &dra7xx_l4_per1_hwmod,
  3777. .slave = &dra7xx_uart3_hwmod,
  3778. .clk = "l3_iclk_div",
  3779. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3780. };
  3781. /* l4_per1 -> uart4 */
  3782. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart4 = {
  3783. .master = &dra7xx_l4_per1_hwmod,
  3784. .slave = &dra7xx_uart4_hwmod,
  3785. .clk = "l3_iclk_div",
  3786. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3787. };
  3788. /* l4_per1 -> uart5 */
  3789. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart5 = {
  3790. .master = &dra7xx_l4_per1_hwmod,
  3791. .slave = &dra7xx_uart5_hwmod,
  3792. .clk = "l3_iclk_div",
  3793. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3794. };
  3795. /* l4_per1 -> uart6 */
  3796. static struct omap_hwmod_ocp_if dra7xx_l4_per1__uart6 = {
  3797. .master = &dra7xx_l4_per1_hwmod,
  3798. .slave = &dra7xx_uart6_hwmod,
  3799. .clk = "l3_iclk_div",
  3800. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3801. };
  3802. /* l4_per2 -> uart7 */
  3803. static struct omap_hwmod_ocp_if dra7xx_l4_per2__uart7 = {
  3804. .master = &dra7xx_l4_per2_hwmod,
  3805. .slave = &dra7xx_uart7_hwmod,
  3806. .clk = "l3_iclk_div",
  3807. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3808. };
  3809. /* l4_per1 -> des */
  3810. static struct omap_hwmod_ocp_if dra7xx_l4_per1__des = {
  3811. .master = &dra7xx_l4_per1_hwmod,
  3812. .slave = &dra7xx_des_hwmod,
  3813. .clk = "l3_iclk_div",
  3814. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3815. };
  3816. /* l4_per2 -> uart8 */
  3817. static struct omap_hwmod_ocp_if dra7xx_l4_per2__uart8 = {
  3818. .master = &dra7xx_l4_per2_hwmod,
  3819. .slave = &dra7xx_uart8_hwmod,
  3820. .clk = "l3_iclk_div",
  3821. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3822. };
  3823. /* l4_per2 -> uart9 */
  3824. static struct omap_hwmod_ocp_if dra7xx_l4_per2__uart9 = {
  3825. .master = &dra7xx_l4_per2_hwmod,
  3826. .slave = &dra7xx_uart9_hwmod,
  3827. .clk = "l3_iclk_div",
  3828. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3829. };
  3830. /* l4_wkup -> uart10 */
  3831. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__uart10 = {
  3832. .master = &dra7xx_l4_wkup_hwmod,
  3833. .slave = &dra7xx_uart10_hwmod,
  3834. .clk = "wkupaon_iclk_mux",
  3835. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3836. };
  3837. /* l4_per1 -> rng */
  3838. static struct omap_hwmod_ocp_if dra7xx_l4_per1__rng = {
  3839. .master = &dra7xx_l4_per1_hwmod,
  3840. .slave = &dra7xx_rng_hwmod,
  3841. .user = OCP_USER_MPU,
  3842. };
  3843. /* l4_per3 -> usb_otg_ss1 */
  3844. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss1 = {
  3845. .master = &dra7xx_l4_per3_hwmod,
  3846. .slave = &dra7xx_usb_otg_ss1_hwmod,
  3847. .clk = "dpll_core_h13x2_ck",
  3848. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3849. };
  3850. /* l4_per3 -> usb_otg_ss2 */
  3851. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss2 = {
  3852. .master = &dra7xx_l4_per3_hwmod,
  3853. .slave = &dra7xx_usb_otg_ss2_hwmod,
  3854. .clk = "dpll_core_h13x2_ck",
  3855. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3856. };
  3857. /* l4_per3 -> usb_otg_ss3 */
  3858. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss3 = {
  3859. .master = &dra7xx_l4_per3_hwmod,
  3860. .slave = &dra7xx_usb_otg_ss3_hwmod,
  3861. .clk = "dpll_core_h13x2_ck",
  3862. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3863. };
  3864. /* l4_per3 -> usb_otg_ss4 */
  3865. static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss4 = {
  3866. .master = &dra7xx_l4_per3_hwmod,
  3867. .slave = &dra7xx_usb_otg_ss4_hwmod,
  3868. .clk = "dpll_core_h13x2_ck",
  3869. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3870. };
  3871. /* l3_main_1 -> vcp1 */
  3872. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__vcp1 = {
  3873. .master = &dra7xx_l3_main_1_hwmod,
  3874. .slave = &dra7xx_vcp1_hwmod,
  3875. .clk = "l3_iclk_div",
  3876. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3877. };
  3878. /* l4_per2 -> vcp1 */
  3879. static struct omap_hwmod_ocp_if dra7xx_l4_per2__vcp1 = {
  3880. .master = &dra7xx_l4_per2_hwmod,
  3881. .slave = &dra7xx_vcp1_hwmod,
  3882. .clk = "l3_iclk_div",
  3883. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3884. };
  3885. /* l3_main_1 -> vcp2 */
  3886. static struct omap_hwmod_ocp_if dra7xx_l3_main_1__vcp2 = {
  3887. .master = &dra7xx_l3_main_1_hwmod,
  3888. .slave = &dra7xx_vcp2_hwmod,
  3889. .clk = "l3_iclk_div",
  3890. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3891. };
  3892. /* l4_per2 -> vcp2 */
  3893. static struct omap_hwmod_ocp_if dra7xx_l4_per2__vcp2 = {
  3894. .master = &dra7xx_l4_per2_hwmod,
  3895. .slave = &dra7xx_vcp2_hwmod,
  3896. .clk = "l3_iclk_div",
  3897. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3898. };
  3899. /* l4_per3 -> vpe */
  3900. static struct omap_hwmod_ocp_if dra7xx_l4_per3__vpe = {
  3901. .master = &dra7xx_l4_per3_hwmod,
  3902. .slave = &dra7xx_vpe_hwmod,
  3903. .clk = "l3_iclk_div",
  3904. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3905. };
  3906. /* l4_per3 -> vip1 */
  3907. static struct omap_hwmod_ocp_if dra7xx_l4_per3__vip1 = {
  3908. .master = &dra7xx_l4_per3_hwmod,
  3909. .slave = &dra7xx_vip1_hwmod,
  3910. .clk = "l3_iclk_div",
  3911. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3912. };
  3913. /* l4_per3 -> vip2 */
  3914. static struct omap_hwmod_ocp_if dra7xx_l4_per3__vip2 = {
  3915. .master = &dra7xx_l4_per3_hwmod,
  3916. .slave = &dra7xx_vip2_hwmod,
  3917. .clk = "l3_iclk_div",
  3918. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3919. };
  3920. /* l4_per3 -> vip3 */
  3921. static struct omap_hwmod_ocp_if dra7xx_l4_per3__vip3 = {
  3922. .master = &dra7xx_l4_per3_hwmod,
  3923. .slave = &dra7xx_vip3_hwmod,
  3924. .clk = "l3_iclk_div",
  3925. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3926. };
  3927. /* l4_per2 -> cal */
  3928. static struct omap_hwmod_ocp_if dra7xx_l4_per2__cal = {
  3929. .master = &dra7xx_l4_per2_hwmod,
  3930. .slave = &dra7xx_cal_hwmod,
  3931. .clk = "l3_iclk_div",
  3932. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3933. };
  3934. /* l4_per3 -> dra76x_cal */
  3935. static struct omap_hwmod_ocp_if dra76x_l4_per3__cal = {
  3936. .master = &dra7xx_l4_per3_hwmod,
  3937. .slave = &dra76x_cal_hwmod,
  3938. .clk = "l3_iclk_div",
  3939. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3940. };
  3941. /* l4_wkup -> wd_timer2 */
  3942. static struct omap_hwmod_ocp_if dra7xx_l4_wkup__wd_timer2 = {
  3943. .master = &dra7xx_l4_wkup_hwmod,
  3944. .slave = &dra7xx_wd_timer2_hwmod,
  3945. .clk = "wkupaon_iclk_mux",
  3946. .user = OCP_USER_MPU | OCP_USER_SDMA,
  3947. };
  3948. /* l4_per2 -> epwmss0 */
  3949. static struct omap_hwmod_ocp_if dra7xx_l4_per2__epwmss0 = {
  3950. .master = &dra7xx_l4_per2_hwmod,
  3951. .slave = &dra7xx_epwmss0_hwmod,
  3952. .clk = "l4_root_clk_div",
  3953. .user = OCP_USER_MPU,
  3954. };
  3955. /* l4_per2 -> epwmss1 */
  3956. static struct omap_hwmod_ocp_if dra7xx_l4_per2__epwmss1 = {
  3957. .master = &dra7xx_l4_per2_hwmod,
  3958. .slave = &dra7xx_epwmss1_hwmod,
  3959. .clk = "l4_root_clk_div",
  3960. .user = OCP_USER_MPU,
  3961. };
  3962. /* l4_per2 -> epwmss2 */
  3963. static struct omap_hwmod_ocp_if dra7xx_l4_per2__epwmss2 = {
  3964. .master = &dra7xx_l4_per2_hwmod,
  3965. .slave = &dra7xx_epwmss2_hwmod,
  3966. .clk = "l4_root_clk_div",
  3967. .user = OCP_USER_MPU,
  3968. };
  3969. static struct omap_hwmod_ocp_if *dra7xx_hwmod_ocp_ifs[] __initdata = {
  3970. &dra7xx_l3_main_1__dmm,
  3971. &dra7xx_l3_main_2__l3_instr,
  3972. &dra7xx_l4_cfg__l3_main_1,
  3973. &dra7xx_mpu__l3_main_1,
  3974. &dra7xx_l3_main_1__l3_main_2,
  3975. &dra7xx_l4_cfg__l3_main_2,
  3976. &dra7xx_l3_main_1__l4_cfg,
  3977. &dra7xx_l3_main_1__l4_per1,
  3978. &dra7xx_l3_main_1__l4_per2,
  3979. &dra7xx_l3_main_1__l4_per3,
  3980. &dra7xx_l3_main_1__l4_wkup,
  3981. &dra7xx_l4_per2__atl,
  3982. &dra7xx_l3_main_1__bb2d,
  3983. &dra7xx_l4_wkup__counter_32k,
  3984. &dra7xx_l4_wkup__ctrl_module_wkup,
  3985. &dra7xx_l4_wkup__dcan1,
  3986. &dra7xx_l4_per2__dcan2,
  3987. &dra7xx_l4_per2__cpgmac0,
  3988. &dra7xx_l4_per2__mcasp1,
  3989. &dra7xx_l3_main_1__mcasp1,
  3990. &dra7xx_l4_per2__mcasp2,
  3991. &dra7xx_l3_main_1__mcasp2,
  3992. &dra7xx_l4_per2__mcasp3,
  3993. &dra7xx_l3_main_1__mcasp3,
  3994. &dra7xx_l4_per2__mcasp4,
  3995. &dra7xx_l4_per2__mcasp5,
  3996. &dra7xx_l4_per2__mcasp6,
  3997. &dra7xx_l4_per2__mcasp7,
  3998. &dra7xx_l4_per2__mcasp8,
  3999. &dra7xx_gmac__mdio,
  4000. &dra7xx_l4_cfg__dma_system,
  4001. &dra7xx_l3_main_1__tpcc,
  4002. &dra7xx_l3_main_1__tptc0,
  4003. &dra7xx_l3_main_1__tptc1,
  4004. &dra7xx_l3_main_1__dss,
  4005. &dra7xx_l3_main_1__dispc,
  4006. &dra7xx_dsp1__l3_main_1,
  4007. &dra7xx_l3_main_1__hdmi,
  4008. &dra7xx_l3_main_1__aes1,
  4009. &dra7xx_l3_main_1__aes2,
  4010. &dra7xx_l3_main_1__sha0,
  4011. &dra7xx_l4_per1__elm,
  4012. &dra7xx_l4_wkup__gpio1,
  4013. &dra7xx_l4_per1__gpio2,
  4014. &dra7xx_l4_per1__gpio3,
  4015. &dra7xx_l4_per1__gpio4,
  4016. &dra7xx_l4_per1__gpio5,
  4017. &dra7xx_l4_per1__gpio6,
  4018. &dra7xx_l4_per1__gpio7,
  4019. &dra7xx_l4_per1__gpio8,
  4020. &dra7xx_l3_main_1__gpmc,
  4021. &dra7xx_l3_main_1__gpu,
  4022. &dra7xx_l4_per1__hdq1w,
  4023. &dra7xx_l4_per1__i2c1,
  4024. &dra7xx_l4_per1__i2c2,
  4025. &dra7xx_l4_per1__i2c3,
  4026. &dra7xx_l4_per1__i2c4,
  4027. &dra7xx_l4_per1__i2c5,
  4028. &dra7xx_ipu1__l3_main_1,
  4029. &dra7xx_ipu2__l3_main_1,
  4030. &dra7xx_l4_cfg__mailbox1,
  4031. &dra7xx_l4_per3__mailbox2,
  4032. &dra7xx_l4_per3__mailbox3,
  4033. &dra7xx_l4_per3__mailbox4,
  4034. &dra7xx_l4_per3__mailbox5,
  4035. &dra7xx_l4_per3__mailbox6,
  4036. &dra7xx_l4_per3__mailbox7,
  4037. &dra7xx_l4_per3__mailbox8,
  4038. &dra7xx_l4_per3__mailbox9,
  4039. &dra7xx_l4_per3__mailbox10,
  4040. &dra7xx_l4_per3__mailbox11,
  4041. &dra7xx_l4_per3__mailbox12,
  4042. &dra7xx_l4_per3__mailbox13,
  4043. &dra7xx_l4_per1__mcspi1,
  4044. &dra7xx_l4_per1__mcspi2,
  4045. &dra7xx_l4_per1__mcspi3,
  4046. &dra7xx_l4_per1__mcspi4,
  4047. &dra7xx_l4_per1__mmc1,
  4048. &dra7xx_l4_per1__mmc2,
  4049. &dra7xx_l4_per1__mmc3,
  4050. &dra7xx_l4_per1__mmc4,
  4051. &dra7xx_l3_main_1__mmu0_dsp1,
  4052. &dra7xx_l3_main_1__mmu1_dsp1,
  4053. &dra7xx_l3_main_1__mmu_ipu1,
  4054. &dra7xx_l3_main_1__mmu_ipu2,
  4055. &dra7xx_l4_cfg__mpu,
  4056. &dra7xx_l4_cfg__ocp2scp1,
  4057. &dra7xx_l4_cfg__ocp2scp3,
  4058. &dra7xx_l3_main_1__pciess1,
  4059. &dra7xx_l4_cfg__pciess1,
  4060. &dra7xx_l3_main_1__pciess2,
  4061. &dra7xx_l4_cfg__pciess2,
  4062. &dra7xx_l4_cfg__pruss1,
  4063. &dra7xx_l4_cfg__pruss2,
  4064. &dra7xx_l3_main_1__qspi,
  4065. &dra7xx_l4_cfg__sata,
  4066. &dra7xx_l4_cfg__smartreflex_core,
  4067. &dra7xx_l4_cfg__smartreflex_mpu,
  4068. &dra7xx_l4_cfg__spinlock,
  4069. &dra7xx_l4_wkup__timer1,
  4070. &dra7xx_l4_per1__timer2,
  4071. &dra7xx_l4_per1__timer3,
  4072. &dra7xx_l4_per1__timer4,
  4073. &dra7xx_l4_per3__timer5,
  4074. &dra7xx_l4_per3__timer6,
  4075. &dra7xx_l4_per3__timer7,
  4076. &dra7xx_l4_per3__timer8,
  4077. &dra7xx_l4_per1__timer9,
  4078. &dra7xx_l4_per1__timer10,
  4079. &dra7xx_l4_per1__timer11,
  4080. &dra7xx_l4_per3__timer13,
  4081. &dra7xx_l4_per3__timer14,
  4082. &dra7xx_l4_per3__timer15,
  4083. &dra7xx_l4_per3__timer16,
  4084. &dra7xx_l4_per1__uart1,
  4085. &dra7xx_l4_per1__uart2,
  4086. &dra7xx_l4_per1__uart3,
  4087. &dra7xx_l4_per1__uart4,
  4088. &dra7xx_l4_per1__uart5,
  4089. &dra7xx_l4_per1__uart6,
  4090. &dra7xx_l4_per2__uart7,
  4091. &dra7xx_l4_per2__uart8,
  4092. &dra7xx_l4_per2__uart9,
  4093. &dra7xx_l4_wkup__uart10,
  4094. &dra7xx_l4_per1__des,
  4095. &dra7xx_l4_per3__usb_otg_ss1,
  4096. &dra7xx_l4_per3__usb_otg_ss2,
  4097. &dra7xx_l4_per3__usb_otg_ss3,
  4098. &dra7xx_l3_main_1__vcp1,
  4099. &dra7xx_l4_per2__vcp1,
  4100. &dra7xx_l3_main_1__vcp2,
  4101. &dra7xx_l4_per2__vcp2,
  4102. &dra7xx_l4_per3__vpe,
  4103. &dra7xx_l4_per3__vip1,
  4104. &dra7xx_l4_wkup__wd_timer2,
  4105. &dra7xx_l4_per2__epwmss0,
  4106. &dra7xx_l4_per2__epwmss1,
  4107. &dra7xx_l4_per2__epwmss2,
  4108. NULL,
  4109. };
  4110. /* GP-only hwmod links */
  4111. static struct omap_hwmod_ocp_if *dra7xx_gp_hwmod_ocp_ifs[] __initdata = {
  4112. &dra7xx_l4_wkup__timer12,
  4113. &dra7xx_l4_per1__rng,
  4114. NULL,
  4115. };
  4116. /* SoC variant specific hwmod links */
  4117. static struct omap_hwmod_ocp_if *dra76x_hwmod_ocp_ifs[] __initdata = {
  4118. &dra7xx_dsp2__l3_main_1,
  4119. &dra7xx_l3_main_1__mmu0_dsp2,
  4120. &dra7xx_l3_main_1__mmu1_dsp2,
  4121. &dra7xx_l4_per3__usb_otg_ss4,
  4122. &dra7xx_l4_per3__vip2,
  4123. NULL,
  4124. };
  4125. static struct omap_hwmod_ocp_if *acd_76x_hwmod_ocp_ifs[] __initdata = {
  4126. &dra76x_l4_per3__cal,
  4127. NULL,
  4128. };
  4129. static struct omap_hwmod_ocp_if *dra74x_hwmod_ocp_ifs[] __initdata = {
  4130. &dra7xx_dsp2__l3_main_1,
  4131. &dra7xx_l3_main_1__mmu0_dsp2,
  4132. &dra7xx_l3_main_1__mmu1_dsp2,
  4133. &dra7xx_l4_per3__usb_otg_ss4,
  4134. &dra7xx_l4_per3__vip2,
  4135. &dra7xx_l4_per3__vip3,
  4136. NULL,
  4137. };
  4138. static struct omap_hwmod_ocp_if *dra72x_hwmod_ocp_ifs[] __initdata = {
  4139. &dra7xx_l4_per2__cal,
  4140. NULL,
  4141. };
  4142. static struct omap_hwmod_ocp_if *rtc_hwmod_ocp_ifs[] __initdata = {
  4143. &dra7xx_l4_per3__rtcss,
  4144. NULL,
  4145. };
  4146. int __init dra7xx_hwmod_init(void)
  4147. {
  4148. int ret;
  4149. omap_hwmod_init();
  4150. ret = omap_hwmod_register_links(dra7xx_hwmod_ocp_ifs);
  4151. if (!ret && soc_is_dra74x()) {
  4152. ret = omap_hwmod_register_links(dra74x_hwmod_ocp_ifs);
  4153. if (!ret)
  4154. ret = omap_hwmod_register_links(rtc_hwmod_ocp_ifs);
  4155. } else if (!ret && soc_is_dra72x()) {
  4156. ret = omap_hwmod_register_links(dra72x_hwmod_ocp_ifs);
  4157. if (!ret && !of_machine_is_compatible("ti,dra718"))
  4158. ret = omap_hwmod_register_links(rtc_hwmod_ocp_ifs);
  4159. } else if (!ret && soc_is_dra76x()) {
  4160. ret = omap_hwmod_register_links(dra76x_hwmod_ocp_ifs);
  4161. if (!ret && soc_is_dra76x_acd()) {
  4162. ret = omap_hwmod_register_links(acd_76x_hwmod_ocp_ifs);
  4163. } else if (!ret && soc_is_dra76x_abz()) {
  4164. ret = omap_hwmod_register_links(rtc_hwmod_ocp_ifs);
  4165. }
  4166. }
  4167. if (!ret && omap_type() == OMAP2_DEVICE_TYPE_GP)
  4168. ret = omap_hwmod_register_links(dra7xx_gp_hwmod_ocp_ifs);
  4169. return ret;
  4170. }