omap_hwmod_33xx_data.c 80 KB

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