clk-3xxx-legacy.c 99 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656
  1. /*
  2. * OMAP3 Legacy clock data
  3. *
  4. * Copyright (C) 2014 Texas Instruments, Inc
  5. * Tero Kristo (t-kristo@ti.com)
  6. *
  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/kernel.h>
  17. #include <linux/clk.h>
  18. #include <linux/clk-provider.h>
  19. #include <linux/clk/ti.h>
  20. #include "clock.h"
  21. static struct ti_clk_fixed virt_12m_ck_data = {
  22. .frequency = 12000000,
  23. };
  24. static struct ti_clk virt_12m_ck = {
  25. .name = "virt_12m_ck",
  26. .type = TI_CLK_FIXED,
  27. .data = &virt_12m_ck_data,
  28. };
  29. static struct ti_clk_fixed virt_13m_ck_data = {
  30. .frequency = 13000000,
  31. };
  32. static struct ti_clk virt_13m_ck = {
  33. .name = "virt_13m_ck",
  34. .type = TI_CLK_FIXED,
  35. .data = &virt_13m_ck_data,
  36. };
  37. static struct ti_clk_fixed virt_19200000_ck_data = {
  38. .frequency = 19200000,
  39. };
  40. static struct ti_clk virt_19200000_ck = {
  41. .name = "virt_19200000_ck",
  42. .type = TI_CLK_FIXED,
  43. .data = &virt_19200000_ck_data,
  44. };
  45. static struct ti_clk_fixed virt_26000000_ck_data = {
  46. .frequency = 26000000,
  47. };
  48. static struct ti_clk virt_26000000_ck = {
  49. .name = "virt_26000000_ck",
  50. .type = TI_CLK_FIXED,
  51. .data = &virt_26000000_ck_data,
  52. };
  53. static struct ti_clk_fixed virt_38_4m_ck_data = {
  54. .frequency = 38400000,
  55. };
  56. static struct ti_clk virt_38_4m_ck = {
  57. .name = "virt_38_4m_ck",
  58. .type = TI_CLK_FIXED,
  59. .data = &virt_38_4m_ck_data,
  60. };
  61. static struct ti_clk_fixed virt_16_8m_ck_data = {
  62. .frequency = 16800000,
  63. };
  64. static struct ti_clk virt_16_8m_ck = {
  65. .name = "virt_16_8m_ck",
  66. .type = TI_CLK_FIXED,
  67. .data = &virt_16_8m_ck_data,
  68. };
  69. static const char *osc_sys_ck_parents[] = {
  70. "virt_12m_ck",
  71. "virt_13m_ck",
  72. "virt_19200000_ck",
  73. "virt_26000000_ck",
  74. "virt_38_4m_ck",
  75. "virt_16_8m_ck",
  76. };
  77. static struct ti_clk_mux osc_sys_ck_data = {
  78. .num_parents = ARRAY_SIZE(osc_sys_ck_parents),
  79. .reg = 0xd40,
  80. .module = TI_CLKM_PRM,
  81. .parents = osc_sys_ck_parents,
  82. };
  83. static struct ti_clk osc_sys_ck = {
  84. .name = "osc_sys_ck",
  85. .type = TI_CLK_MUX,
  86. .data = &osc_sys_ck_data,
  87. };
  88. static struct ti_clk_divider sys_ck_data = {
  89. .parent = "osc_sys_ck",
  90. .bit_shift = 6,
  91. .max_div = 3,
  92. .reg = 0x1270,
  93. .module = TI_CLKM_PRM,
  94. .flags = CLKF_INDEX_STARTS_AT_ONE,
  95. };
  96. static struct ti_clk sys_ck = {
  97. .name = "sys_ck",
  98. .type = TI_CLK_DIVIDER,
  99. .data = &sys_ck_data,
  100. };
  101. static const char *dpll3_ck_parents[] = {
  102. "sys_ck",
  103. "sys_ck",
  104. };
  105. static struct ti_clk_dpll dpll3_ck_data = {
  106. .num_parents = ARRAY_SIZE(dpll3_ck_parents),
  107. .control_reg = 0xd00,
  108. .idlest_reg = 0xd20,
  109. .mult_div1_reg = 0xd40,
  110. .autoidle_reg = 0xd30,
  111. .module = TI_CLKM_CM,
  112. .parents = dpll3_ck_parents,
  113. .flags = CLKF_CORE,
  114. .freqsel_mask = 0xf0,
  115. .div1_mask = 0x7f00,
  116. .idlest_mask = 0x1,
  117. .auto_recal_bit = 0x3,
  118. .max_divider = 0x80,
  119. .min_divider = 0x1,
  120. .recal_en_bit = 0x5,
  121. .max_multiplier = 0x7ff,
  122. .enable_mask = 0x7,
  123. .mult_mask = 0x7ff0000,
  124. .recal_st_bit = 0x5,
  125. .autoidle_mask = 0x7,
  126. };
  127. static struct ti_clk dpll3_ck = {
  128. .name = "dpll3_ck",
  129. .clkdm_name = "dpll3_clkdm",
  130. .type = TI_CLK_DPLL,
  131. .data = &dpll3_ck_data,
  132. };
  133. static struct ti_clk_divider dpll3_m2_ck_data = {
  134. .parent = "dpll3_ck",
  135. .bit_shift = 27,
  136. .max_div = 31,
  137. .reg = 0xd40,
  138. .module = TI_CLKM_CM,
  139. .flags = CLKF_INDEX_STARTS_AT_ONE,
  140. };
  141. static struct ti_clk dpll3_m2_ck = {
  142. .name = "dpll3_m2_ck",
  143. .type = TI_CLK_DIVIDER,
  144. .data = &dpll3_m2_ck_data,
  145. };
  146. static struct ti_clk_fixed_factor core_ck_data = {
  147. .parent = "dpll3_m2_ck",
  148. .div = 1,
  149. .mult = 1,
  150. };
  151. static struct ti_clk core_ck = {
  152. .name = "core_ck",
  153. .type = TI_CLK_FIXED_FACTOR,
  154. .data = &core_ck_data,
  155. };
  156. static struct ti_clk_divider l3_ick_data = {
  157. .parent = "core_ck",
  158. .max_div = 3,
  159. .reg = 0xa40,
  160. .module = TI_CLKM_CM,
  161. .flags = CLKF_INDEX_STARTS_AT_ONE,
  162. };
  163. static struct ti_clk l3_ick = {
  164. .name = "l3_ick",
  165. .type = TI_CLK_DIVIDER,
  166. .data = &l3_ick_data,
  167. };
  168. static struct ti_clk_fixed_factor security_l3_ick_data = {
  169. .parent = "l3_ick",
  170. .div = 1,
  171. .mult = 1,
  172. };
  173. static struct ti_clk security_l3_ick = {
  174. .name = "security_l3_ick",
  175. .type = TI_CLK_FIXED_FACTOR,
  176. .data = &security_l3_ick_data,
  177. };
  178. static struct ti_clk_fixed_factor wkup_l4_ick_data = {
  179. .parent = "sys_ck",
  180. .div = 1,
  181. .mult = 1,
  182. };
  183. static struct ti_clk wkup_l4_ick = {
  184. .name = "wkup_l4_ick",
  185. .type = TI_CLK_FIXED_FACTOR,
  186. .data = &wkup_l4_ick_data,
  187. };
  188. static struct ti_clk_gate usim_ick_data = {
  189. .parent = "wkup_l4_ick",
  190. .bit_shift = 9,
  191. .reg = 0xc10,
  192. .module = TI_CLKM_CM,
  193. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  194. };
  195. static struct ti_clk usim_ick = {
  196. .name = "usim_ick",
  197. .clkdm_name = "wkup_clkdm",
  198. .type = TI_CLK_GATE,
  199. .data = &usim_ick_data,
  200. };
  201. static struct ti_clk_gate dss2_alwon_fck_data = {
  202. .parent = "sys_ck",
  203. .bit_shift = 1,
  204. .reg = 0xe00,
  205. .module = TI_CLKM_CM,
  206. };
  207. static struct ti_clk dss2_alwon_fck = {
  208. .name = "dss2_alwon_fck",
  209. .clkdm_name = "dss_clkdm",
  210. .type = TI_CLK_GATE,
  211. .data = &dss2_alwon_fck_data,
  212. };
  213. static struct ti_clk_divider l4_ick_data = {
  214. .parent = "l3_ick",
  215. .bit_shift = 2,
  216. .max_div = 3,
  217. .reg = 0xa40,
  218. .module = TI_CLKM_CM,
  219. .flags = CLKF_INDEX_STARTS_AT_ONE,
  220. };
  221. static struct ti_clk l4_ick = {
  222. .name = "l4_ick",
  223. .type = TI_CLK_DIVIDER,
  224. .data = &l4_ick_data,
  225. };
  226. static struct ti_clk_fixed_factor core_l4_ick_data = {
  227. .parent = "l4_ick",
  228. .div = 1,
  229. .mult = 1,
  230. };
  231. static struct ti_clk core_l4_ick = {
  232. .name = "core_l4_ick",
  233. .type = TI_CLK_FIXED_FACTOR,
  234. .data = &core_l4_ick_data,
  235. };
  236. static struct ti_clk_gate mmchs2_ick_data = {
  237. .parent = "core_l4_ick",
  238. .bit_shift = 25,
  239. .reg = 0xa10,
  240. .module = TI_CLKM_CM,
  241. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  242. };
  243. static struct ti_clk mmchs2_ick = {
  244. .name = "mmchs2_ick",
  245. .clkdm_name = "core_l4_clkdm",
  246. .type = TI_CLK_GATE,
  247. .data = &mmchs2_ick_data,
  248. };
  249. static const char *dpll4_ck_parents[] = {
  250. "sys_ck",
  251. "sys_ck",
  252. };
  253. static struct ti_clk_dpll dpll4_ck_data = {
  254. .num_parents = ARRAY_SIZE(dpll4_ck_parents),
  255. .control_reg = 0xd00,
  256. .idlest_reg = 0xd20,
  257. .mult_div1_reg = 0xd44,
  258. .autoidle_reg = 0xd30,
  259. .module = TI_CLKM_CM,
  260. .parents = dpll4_ck_parents,
  261. .flags = CLKF_PER,
  262. .freqsel_mask = 0xf00000,
  263. .modes = 0x82,
  264. .div1_mask = 0x7f,
  265. .idlest_mask = 0x2,
  266. .auto_recal_bit = 0x13,
  267. .max_divider = 0x80,
  268. .min_divider = 0x1,
  269. .recal_en_bit = 0x6,
  270. .max_multiplier = 0x7ff,
  271. .enable_mask = 0x70000,
  272. .mult_mask = 0x7ff00,
  273. .recal_st_bit = 0x6,
  274. .autoidle_mask = 0x38,
  275. };
  276. static struct ti_clk dpll4_ck = {
  277. .name = "dpll4_ck",
  278. .clkdm_name = "dpll4_clkdm",
  279. .type = TI_CLK_DPLL,
  280. .data = &dpll4_ck_data,
  281. };
  282. static struct ti_clk_divider dpll4_m2_ck_data = {
  283. .parent = "dpll4_ck",
  284. .max_div = 63,
  285. .reg = 0xd48,
  286. .module = TI_CLKM_CM,
  287. .flags = CLKF_INDEX_STARTS_AT_ONE,
  288. };
  289. static struct ti_clk dpll4_m2_ck = {
  290. .name = "dpll4_m2_ck",
  291. .type = TI_CLK_DIVIDER,
  292. .data = &dpll4_m2_ck_data,
  293. };
  294. static struct ti_clk_fixed_factor dpll4_m2x2_mul_ck_data = {
  295. .parent = "dpll4_m2_ck",
  296. .div = 1,
  297. .mult = 2,
  298. };
  299. static struct ti_clk dpll4_m2x2_mul_ck = {
  300. .name = "dpll4_m2x2_mul_ck",
  301. .type = TI_CLK_FIXED_FACTOR,
  302. .data = &dpll4_m2x2_mul_ck_data,
  303. };
  304. static struct ti_clk_gate dpll4_m2x2_ck_data = {
  305. .parent = "dpll4_m2x2_mul_ck",
  306. .bit_shift = 0x1b,
  307. .reg = 0xd00,
  308. .module = TI_CLKM_CM,
  309. .flags = CLKF_SET_BIT_TO_DISABLE,
  310. };
  311. static struct ti_clk dpll4_m2x2_ck = {
  312. .name = "dpll4_m2x2_ck",
  313. .type = TI_CLK_GATE,
  314. .data = &dpll4_m2x2_ck_data,
  315. };
  316. static struct ti_clk_fixed_factor omap_96m_alwon_fck_data = {
  317. .parent = "dpll4_m2x2_ck",
  318. .div = 1,
  319. .mult = 1,
  320. };
  321. static struct ti_clk omap_96m_alwon_fck = {
  322. .name = "omap_96m_alwon_fck",
  323. .type = TI_CLK_FIXED_FACTOR,
  324. .data = &omap_96m_alwon_fck_data,
  325. };
  326. static struct ti_clk_fixed_factor cm_96m_fck_data = {
  327. .parent = "omap_96m_alwon_fck",
  328. .div = 1,
  329. .mult = 1,
  330. };
  331. static struct ti_clk cm_96m_fck = {
  332. .name = "cm_96m_fck",
  333. .type = TI_CLK_FIXED_FACTOR,
  334. .data = &cm_96m_fck_data,
  335. };
  336. static const char *omap_96m_fck_parents[] = {
  337. "cm_96m_fck",
  338. "sys_ck",
  339. };
  340. static struct ti_clk_mux omap_96m_fck_data = {
  341. .bit_shift = 6,
  342. .num_parents = ARRAY_SIZE(omap_96m_fck_parents),
  343. .reg = 0xd40,
  344. .module = TI_CLKM_CM,
  345. .parents = omap_96m_fck_parents,
  346. };
  347. static struct ti_clk omap_96m_fck = {
  348. .name = "omap_96m_fck",
  349. .type = TI_CLK_MUX,
  350. .data = &omap_96m_fck_data,
  351. };
  352. static struct ti_clk_fixed_factor core_96m_fck_data = {
  353. .parent = "omap_96m_fck",
  354. .div = 1,
  355. .mult = 1,
  356. };
  357. static struct ti_clk core_96m_fck = {
  358. .name = "core_96m_fck",
  359. .type = TI_CLK_FIXED_FACTOR,
  360. .data = &core_96m_fck_data,
  361. };
  362. static struct ti_clk_gate mspro_fck_data = {
  363. .parent = "core_96m_fck",
  364. .bit_shift = 23,
  365. .reg = 0xa00,
  366. .module = TI_CLKM_CM,
  367. .flags = CLKF_WAIT,
  368. };
  369. static struct ti_clk mspro_fck = {
  370. .name = "mspro_fck",
  371. .clkdm_name = "core_l4_clkdm",
  372. .type = TI_CLK_GATE,
  373. .data = &mspro_fck_data,
  374. };
  375. static struct ti_clk_gate dss_ick_3430es2_data = {
  376. .parent = "l4_ick",
  377. .bit_shift = 0,
  378. .reg = 0xe10,
  379. .module = TI_CLKM_CM,
  380. .flags = CLKF_DSS | CLKF_OMAP3 | CLKF_INTERFACE,
  381. };
  382. static struct ti_clk dss_ick_3430es2 = {
  383. .name = "dss_ick",
  384. .clkdm_name = "dss_clkdm",
  385. .type = TI_CLK_GATE,
  386. .data = &dss_ick_3430es2_data,
  387. };
  388. static struct ti_clk_gate uart4_ick_am35xx_data = {
  389. .parent = "core_l4_ick",
  390. .bit_shift = 23,
  391. .reg = 0xa10,
  392. .module = TI_CLKM_CM,
  393. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  394. };
  395. static struct ti_clk uart4_ick_am35xx = {
  396. .name = "uart4_ick_am35xx",
  397. .clkdm_name = "core_l4_clkdm",
  398. .type = TI_CLK_GATE,
  399. .data = &uart4_ick_am35xx_data,
  400. };
  401. static struct ti_clk_fixed_factor security_l4_ick2_data = {
  402. .parent = "l4_ick",
  403. .div = 1,
  404. .mult = 1,
  405. };
  406. static struct ti_clk security_l4_ick2 = {
  407. .name = "security_l4_ick2",
  408. .type = TI_CLK_FIXED_FACTOR,
  409. .data = &security_l4_ick2_data,
  410. };
  411. static struct ti_clk_gate aes1_ick_data = {
  412. .parent = "security_l4_ick2",
  413. .bit_shift = 3,
  414. .reg = 0xa14,
  415. .module = TI_CLKM_CM,
  416. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  417. };
  418. static struct ti_clk aes1_ick = {
  419. .name = "aes1_ick",
  420. .type = TI_CLK_GATE,
  421. .data = &aes1_ick_data,
  422. };
  423. static const char *dpll5_ck_parents[] = {
  424. "sys_ck",
  425. "sys_ck",
  426. };
  427. static struct ti_clk_dpll dpll5_ck_data = {
  428. .num_parents = ARRAY_SIZE(dpll5_ck_parents),
  429. .control_reg = 0xd04,
  430. .idlest_reg = 0xd24,
  431. .mult_div1_reg = 0xd4c,
  432. .autoidle_reg = 0xd34,
  433. .module = TI_CLKM_CM,
  434. .parents = dpll5_ck_parents,
  435. .freqsel_mask = 0xf0,
  436. .modes = 0x82,
  437. .div1_mask = 0x7f,
  438. .idlest_mask = 0x1,
  439. .auto_recal_bit = 0x3,
  440. .max_divider = 0x80,
  441. .min_divider = 0x1,
  442. .recal_en_bit = 0x19,
  443. .max_multiplier = 0x7ff,
  444. .enable_mask = 0x7,
  445. .mult_mask = 0x7ff00,
  446. .recal_st_bit = 0x19,
  447. .autoidle_mask = 0x7,
  448. };
  449. static struct ti_clk dpll5_ck = {
  450. .name = "dpll5_ck",
  451. .clkdm_name = "dpll5_clkdm",
  452. .type = TI_CLK_DPLL,
  453. .data = &dpll5_ck_data,
  454. };
  455. static struct ti_clk_divider dpll5_m2_ck_data = {
  456. .parent = "dpll5_ck",
  457. .max_div = 31,
  458. .reg = 0xd50,
  459. .module = TI_CLKM_CM,
  460. .flags = CLKF_INDEX_STARTS_AT_ONE,
  461. };
  462. static struct ti_clk dpll5_m2_ck = {
  463. .name = "dpll5_m2_ck",
  464. .type = TI_CLK_DIVIDER,
  465. .data = &dpll5_m2_ck_data,
  466. };
  467. static struct ti_clk_gate usbhost_120m_fck_data = {
  468. .parent = "dpll5_m2_ck",
  469. .bit_shift = 1,
  470. .reg = 0x1400,
  471. .module = TI_CLKM_CM,
  472. };
  473. static struct ti_clk usbhost_120m_fck = {
  474. .name = "usbhost_120m_fck",
  475. .clkdm_name = "usbhost_clkdm",
  476. .type = TI_CLK_GATE,
  477. .data = &usbhost_120m_fck_data,
  478. };
  479. static struct ti_clk_fixed_factor cm_96m_d2_fck_data = {
  480. .parent = "cm_96m_fck",
  481. .div = 2,
  482. .mult = 1,
  483. };
  484. static struct ti_clk cm_96m_d2_fck = {
  485. .name = "cm_96m_d2_fck",
  486. .type = TI_CLK_FIXED_FACTOR,
  487. .data = &cm_96m_d2_fck_data,
  488. };
  489. static struct ti_clk_fixed sys_altclk_data = {
  490. .frequency = 0x0,
  491. };
  492. static struct ti_clk sys_altclk = {
  493. .name = "sys_altclk",
  494. .type = TI_CLK_FIXED,
  495. .data = &sys_altclk_data,
  496. };
  497. static const char *omap_48m_fck_parents[] = {
  498. "cm_96m_d2_fck",
  499. "sys_altclk",
  500. };
  501. static struct ti_clk_mux omap_48m_fck_data = {
  502. .bit_shift = 3,
  503. .num_parents = ARRAY_SIZE(omap_48m_fck_parents),
  504. .reg = 0xd40,
  505. .module = TI_CLKM_CM,
  506. .parents = omap_48m_fck_parents,
  507. };
  508. static struct ti_clk omap_48m_fck = {
  509. .name = "omap_48m_fck",
  510. .type = TI_CLK_MUX,
  511. .data = &omap_48m_fck_data,
  512. };
  513. static struct ti_clk_fixed_factor core_48m_fck_data = {
  514. .parent = "omap_48m_fck",
  515. .div = 1,
  516. .mult = 1,
  517. };
  518. static struct ti_clk core_48m_fck = {
  519. .name = "core_48m_fck",
  520. .type = TI_CLK_FIXED_FACTOR,
  521. .data = &core_48m_fck_data,
  522. };
  523. static struct ti_clk_fixed mcbsp_clks_data = {
  524. .frequency = 0x0,
  525. };
  526. static struct ti_clk mcbsp_clks = {
  527. .name = "mcbsp_clks",
  528. .type = TI_CLK_FIXED,
  529. .data = &mcbsp_clks_data,
  530. };
  531. static struct ti_clk_gate mcbsp2_gate_fck_data = {
  532. .parent = "mcbsp_clks",
  533. .bit_shift = 0,
  534. .reg = 0x1000,
  535. .module = TI_CLKM_CM,
  536. };
  537. static struct ti_clk_fixed_factor per_96m_fck_data = {
  538. .parent = "omap_96m_alwon_fck",
  539. .div = 1,
  540. .mult = 1,
  541. };
  542. static struct ti_clk per_96m_fck = {
  543. .name = "per_96m_fck",
  544. .type = TI_CLK_FIXED_FACTOR,
  545. .data = &per_96m_fck_data,
  546. };
  547. static const char *mcbsp2_mux_fck_parents[] = {
  548. "per_96m_fck",
  549. "mcbsp_clks",
  550. };
  551. static struct ti_clk_mux mcbsp2_mux_fck_data = {
  552. .bit_shift = 6,
  553. .num_parents = ARRAY_SIZE(mcbsp2_mux_fck_parents),
  554. .reg = 0x274,
  555. .module = TI_CLKM_SCRM,
  556. .parents = mcbsp2_mux_fck_parents,
  557. };
  558. static struct ti_clk_composite mcbsp2_fck_data = {
  559. .mux = &mcbsp2_mux_fck_data,
  560. .gate = &mcbsp2_gate_fck_data,
  561. };
  562. static struct ti_clk mcbsp2_fck = {
  563. .name = "mcbsp2_fck",
  564. .type = TI_CLK_COMPOSITE,
  565. .data = &mcbsp2_fck_data,
  566. };
  567. static struct ti_clk_fixed_factor dpll3_m2x2_ck_data = {
  568. .parent = "dpll3_m2_ck",
  569. .div = 1,
  570. .mult = 2,
  571. };
  572. static struct ti_clk dpll3_m2x2_ck = {
  573. .name = "dpll3_m2x2_ck",
  574. .type = TI_CLK_FIXED_FACTOR,
  575. .data = &dpll3_m2x2_ck_data,
  576. };
  577. static struct ti_clk_fixed_factor corex2_fck_data = {
  578. .parent = "dpll3_m2x2_ck",
  579. .div = 1,
  580. .mult = 1,
  581. };
  582. static struct ti_clk corex2_fck = {
  583. .name = "corex2_fck",
  584. .type = TI_CLK_FIXED_FACTOR,
  585. .data = &corex2_fck_data,
  586. };
  587. static struct ti_clk_gate ssi_ssr_gate_fck_3430es1_data = {
  588. .parent = "corex2_fck",
  589. .bit_shift = 0,
  590. .reg = 0xa00,
  591. .module = TI_CLKM_CM,
  592. .flags = CLKF_NO_WAIT,
  593. };
  594. static int ssi_ssr_div_fck_3430es1_divs[] = {
  595. 0,
  596. 1,
  597. 2,
  598. 3,
  599. 4,
  600. 0,
  601. 6,
  602. 0,
  603. 8,
  604. };
  605. static struct ti_clk_divider ssi_ssr_div_fck_3430es1_data = {
  606. .num_dividers = ARRAY_SIZE(ssi_ssr_div_fck_3430es1_divs),
  607. .parent = "corex2_fck",
  608. .bit_shift = 8,
  609. .dividers = ssi_ssr_div_fck_3430es1_divs,
  610. .reg = 0xa40,
  611. .module = TI_CLKM_CM,
  612. };
  613. static struct ti_clk_composite ssi_ssr_fck_3430es1_data = {
  614. .gate = &ssi_ssr_gate_fck_3430es1_data,
  615. .divider = &ssi_ssr_div_fck_3430es1_data,
  616. };
  617. static struct ti_clk ssi_ssr_fck_3430es1 = {
  618. .name = "ssi_ssr_fck",
  619. .type = TI_CLK_COMPOSITE,
  620. .data = &ssi_ssr_fck_3430es1_data,
  621. };
  622. static struct ti_clk_fixed_factor ssi_sst_fck_3430es1_data = {
  623. .parent = "ssi_ssr_fck",
  624. .div = 2,
  625. .mult = 1,
  626. };
  627. static struct ti_clk ssi_sst_fck_3430es1 = {
  628. .name = "ssi_sst_fck",
  629. .type = TI_CLK_FIXED_FACTOR,
  630. .data = &ssi_sst_fck_3430es1_data,
  631. };
  632. static struct ti_clk_fixed omap_32k_fck_data = {
  633. .frequency = 32768,
  634. };
  635. static struct ti_clk omap_32k_fck = {
  636. .name = "omap_32k_fck",
  637. .type = TI_CLK_FIXED,
  638. .data = &omap_32k_fck_data,
  639. };
  640. static struct ti_clk_fixed_factor per_32k_alwon_fck_data = {
  641. .parent = "omap_32k_fck",
  642. .div = 1,
  643. .mult = 1,
  644. };
  645. static struct ti_clk per_32k_alwon_fck = {
  646. .name = "per_32k_alwon_fck",
  647. .type = TI_CLK_FIXED_FACTOR,
  648. .data = &per_32k_alwon_fck_data,
  649. };
  650. static struct ti_clk_gate gpio5_dbck_data = {
  651. .parent = "per_32k_alwon_fck",
  652. .bit_shift = 16,
  653. .reg = 0x1000,
  654. .module = TI_CLKM_CM,
  655. };
  656. static struct ti_clk gpio5_dbck = {
  657. .name = "gpio5_dbck",
  658. .clkdm_name = "per_clkdm",
  659. .type = TI_CLK_GATE,
  660. .data = &gpio5_dbck_data,
  661. };
  662. static struct ti_clk_gate gpt1_ick_data = {
  663. .parent = "wkup_l4_ick",
  664. .bit_shift = 0,
  665. .reg = 0xc10,
  666. .module = TI_CLKM_CM,
  667. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  668. };
  669. static struct ti_clk gpt1_ick = {
  670. .name = "gpt1_ick",
  671. .clkdm_name = "wkup_clkdm",
  672. .type = TI_CLK_GATE,
  673. .data = &gpt1_ick_data,
  674. };
  675. static struct ti_clk_gate mcspi3_fck_data = {
  676. .parent = "core_48m_fck",
  677. .bit_shift = 20,
  678. .reg = 0xa00,
  679. .module = TI_CLKM_CM,
  680. .flags = CLKF_WAIT,
  681. };
  682. static struct ti_clk mcspi3_fck = {
  683. .name = "mcspi3_fck",
  684. .clkdm_name = "core_l4_clkdm",
  685. .type = TI_CLK_GATE,
  686. .data = &mcspi3_fck_data,
  687. };
  688. static struct ti_clk_gate gpt2_gate_fck_data = {
  689. .parent = "sys_ck",
  690. .bit_shift = 3,
  691. .reg = 0x1000,
  692. .module = TI_CLKM_CM,
  693. };
  694. static const char *gpt2_mux_fck_parents[] = {
  695. "omap_32k_fck",
  696. "sys_ck",
  697. };
  698. static struct ti_clk_mux gpt2_mux_fck_data = {
  699. .num_parents = ARRAY_SIZE(gpt2_mux_fck_parents),
  700. .reg = 0x1040,
  701. .module = TI_CLKM_CM,
  702. .parents = gpt2_mux_fck_parents,
  703. };
  704. static struct ti_clk_composite gpt2_fck_data = {
  705. .mux = &gpt2_mux_fck_data,
  706. .gate = &gpt2_gate_fck_data,
  707. };
  708. static struct ti_clk gpt2_fck = {
  709. .name = "gpt2_fck",
  710. .type = TI_CLK_COMPOSITE,
  711. .data = &gpt2_fck_data,
  712. };
  713. static struct ti_clk_gate gpt10_ick_data = {
  714. .parent = "core_l4_ick",
  715. .bit_shift = 11,
  716. .reg = 0xa10,
  717. .module = TI_CLKM_CM,
  718. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  719. };
  720. static struct ti_clk gpt10_ick = {
  721. .name = "gpt10_ick",
  722. .clkdm_name = "core_l4_clkdm",
  723. .type = TI_CLK_GATE,
  724. .data = &gpt10_ick_data,
  725. };
  726. static struct ti_clk_gate uart2_fck_data = {
  727. .parent = "core_48m_fck",
  728. .bit_shift = 14,
  729. .reg = 0xa00,
  730. .module = TI_CLKM_CM,
  731. .flags = CLKF_WAIT,
  732. };
  733. static struct ti_clk uart2_fck = {
  734. .name = "uart2_fck",
  735. .clkdm_name = "core_l4_clkdm",
  736. .type = TI_CLK_GATE,
  737. .data = &uart2_fck_data,
  738. };
  739. static struct ti_clk_fixed_factor sr_l4_ick_data = {
  740. .parent = "l4_ick",
  741. .div = 1,
  742. .mult = 1,
  743. };
  744. static struct ti_clk sr_l4_ick = {
  745. .name = "sr_l4_ick",
  746. .type = TI_CLK_FIXED_FACTOR,
  747. .data = &sr_l4_ick_data,
  748. };
  749. static struct ti_clk_fixed_factor omap_96m_d8_fck_data = {
  750. .parent = "omap_96m_fck",
  751. .div = 8,
  752. .mult = 1,
  753. };
  754. static struct ti_clk omap_96m_d8_fck = {
  755. .name = "omap_96m_d8_fck",
  756. .type = TI_CLK_FIXED_FACTOR,
  757. .data = &omap_96m_d8_fck_data,
  758. };
  759. static struct ti_clk_divider dpll4_m5_ck_data = {
  760. .parent = "dpll4_ck",
  761. .max_div = 63,
  762. .reg = 0xf40,
  763. .module = TI_CLKM_CM,
  764. .flags = CLKF_INDEX_STARTS_AT_ONE,
  765. };
  766. static struct ti_clk dpll4_m5_ck = {
  767. .name = "dpll4_m5_ck",
  768. .type = TI_CLK_DIVIDER,
  769. .data = &dpll4_m5_ck_data,
  770. };
  771. static struct ti_clk_fixed_factor dpll4_m5x2_mul_ck_data = {
  772. .parent = "dpll4_m5_ck",
  773. .div = 1,
  774. .mult = 2,
  775. .flags = CLKF_SET_RATE_PARENT,
  776. };
  777. static struct ti_clk dpll4_m5x2_mul_ck = {
  778. .name = "dpll4_m5x2_mul_ck",
  779. .type = TI_CLK_FIXED_FACTOR,
  780. .data = &dpll4_m5x2_mul_ck_data,
  781. };
  782. static struct ti_clk_gate dpll4_m5x2_ck_data = {
  783. .parent = "dpll4_m5x2_mul_ck",
  784. .bit_shift = 0x1e,
  785. .reg = 0xd00,
  786. .module = TI_CLKM_CM,
  787. .flags = CLKF_SET_BIT_TO_DISABLE,
  788. };
  789. static struct ti_clk dpll4_m5x2_ck = {
  790. .name = "dpll4_m5x2_ck",
  791. .type = TI_CLK_GATE,
  792. .data = &dpll4_m5x2_ck_data,
  793. };
  794. static struct ti_clk_gate cam_mclk_data = {
  795. .parent = "dpll4_m5x2_ck",
  796. .bit_shift = 0,
  797. .reg = 0xf00,
  798. .module = TI_CLKM_CM,
  799. .flags = CLKF_SET_RATE_PARENT,
  800. };
  801. static struct ti_clk cam_mclk = {
  802. .name = "cam_mclk",
  803. .type = TI_CLK_GATE,
  804. .data = &cam_mclk_data,
  805. };
  806. static struct ti_clk_gate mcbsp3_gate_fck_data = {
  807. .parent = "mcbsp_clks",
  808. .bit_shift = 1,
  809. .reg = 0x1000,
  810. .module = TI_CLKM_CM,
  811. };
  812. static const char *mcbsp3_mux_fck_parents[] = {
  813. "per_96m_fck",
  814. "mcbsp_clks",
  815. };
  816. static struct ti_clk_mux mcbsp3_mux_fck_data = {
  817. .num_parents = ARRAY_SIZE(mcbsp3_mux_fck_parents),
  818. .reg = 0x2d8,
  819. .module = TI_CLKM_SCRM,
  820. .parents = mcbsp3_mux_fck_parents,
  821. };
  822. static struct ti_clk_composite mcbsp3_fck_data = {
  823. .mux = &mcbsp3_mux_fck_data,
  824. .gate = &mcbsp3_gate_fck_data,
  825. };
  826. static struct ti_clk mcbsp3_fck = {
  827. .name = "mcbsp3_fck",
  828. .type = TI_CLK_COMPOSITE,
  829. .data = &mcbsp3_fck_data,
  830. };
  831. static struct ti_clk_gate csi2_96m_fck_data = {
  832. .parent = "core_96m_fck",
  833. .bit_shift = 1,
  834. .reg = 0xf00,
  835. .module = TI_CLKM_CM,
  836. };
  837. static struct ti_clk csi2_96m_fck = {
  838. .name = "csi2_96m_fck",
  839. .clkdm_name = "cam_clkdm",
  840. .type = TI_CLK_GATE,
  841. .data = &csi2_96m_fck_data,
  842. };
  843. static struct ti_clk_gate gpt9_gate_fck_data = {
  844. .parent = "sys_ck",
  845. .bit_shift = 10,
  846. .reg = 0x1000,
  847. .module = TI_CLKM_CM,
  848. };
  849. static const char *gpt9_mux_fck_parents[] = {
  850. "omap_32k_fck",
  851. "sys_ck",
  852. };
  853. static struct ti_clk_mux gpt9_mux_fck_data = {
  854. .bit_shift = 7,
  855. .num_parents = ARRAY_SIZE(gpt9_mux_fck_parents),
  856. .reg = 0x1040,
  857. .module = TI_CLKM_CM,
  858. .parents = gpt9_mux_fck_parents,
  859. };
  860. static struct ti_clk_composite gpt9_fck_data = {
  861. .mux = &gpt9_mux_fck_data,
  862. .gate = &gpt9_gate_fck_data,
  863. };
  864. static struct ti_clk gpt9_fck = {
  865. .name = "gpt9_fck",
  866. .type = TI_CLK_COMPOSITE,
  867. .data = &gpt9_fck_data,
  868. };
  869. static struct ti_clk_divider dpll3_m3_ck_data = {
  870. .parent = "dpll3_ck",
  871. .bit_shift = 16,
  872. .max_div = 31,
  873. .reg = 0x1140,
  874. .module = TI_CLKM_CM,
  875. .flags = CLKF_INDEX_STARTS_AT_ONE,
  876. };
  877. static struct ti_clk dpll3_m3_ck = {
  878. .name = "dpll3_m3_ck",
  879. .type = TI_CLK_DIVIDER,
  880. .data = &dpll3_m3_ck_data,
  881. };
  882. static struct ti_clk_fixed_factor dpll3_m3x2_mul_ck_data = {
  883. .parent = "dpll3_m3_ck",
  884. .div = 1,
  885. .mult = 2,
  886. };
  887. static struct ti_clk dpll3_m3x2_mul_ck = {
  888. .name = "dpll3_m3x2_mul_ck",
  889. .type = TI_CLK_FIXED_FACTOR,
  890. .data = &dpll3_m3x2_mul_ck_data,
  891. };
  892. static struct ti_clk_gate sr2_fck_data = {
  893. .parent = "sys_ck",
  894. .bit_shift = 7,
  895. .reg = 0xc00,
  896. .module = TI_CLKM_CM,
  897. .flags = CLKF_WAIT,
  898. };
  899. static struct ti_clk sr2_fck = {
  900. .name = "sr2_fck",
  901. .clkdm_name = "wkup_clkdm",
  902. .type = TI_CLK_GATE,
  903. .data = &sr2_fck_data,
  904. };
  905. static struct ti_clk_fixed pclk_ck_data = {
  906. .frequency = 27000000,
  907. };
  908. static struct ti_clk pclk_ck = {
  909. .name = "pclk_ck",
  910. .type = TI_CLK_FIXED,
  911. .data = &pclk_ck_data,
  912. };
  913. static struct ti_clk_gate wdt2_ick_data = {
  914. .parent = "wkup_l4_ick",
  915. .bit_shift = 5,
  916. .reg = 0xc10,
  917. .module = TI_CLKM_CM,
  918. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  919. };
  920. static struct ti_clk wdt2_ick = {
  921. .name = "wdt2_ick",
  922. .clkdm_name = "wkup_clkdm",
  923. .type = TI_CLK_GATE,
  924. .data = &wdt2_ick_data,
  925. };
  926. static struct ti_clk_fixed_factor core_l3_ick_data = {
  927. .parent = "l3_ick",
  928. .div = 1,
  929. .mult = 1,
  930. };
  931. static struct ti_clk core_l3_ick = {
  932. .name = "core_l3_ick",
  933. .type = TI_CLK_FIXED_FACTOR,
  934. .data = &core_l3_ick_data,
  935. };
  936. static struct ti_clk_gate mcspi4_fck_data = {
  937. .parent = "core_48m_fck",
  938. .bit_shift = 21,
  939. .reg = 0xa00,
  940. .module = TI_CLKM_CM,
  941. .flags = CLKF_WAIT,
  942. };
  943. static struct ti_clk mcspi4_fck = {
  944. .name = "mcspi4_fck",
  945. .clkdm_name = "core_l4_clkdm",
  946. .type = TI_CLK_GATE,
  947. .data = &mcspi4_fck_data,
  948. };
  949. static struct ti_clk_fixed_factor per_48m_fck_data = {
  950. .parent = "omap_48m_fck",
  951. .div = 1,
  952. .mult = 1,
  953. };
  954. static struct ti_clk per_48m_fck = {
  955. .name = "per_48m_fck",
  956. .type = TI_CLK_FIXED_FACTOR,
  957. .data = &per_48m_fck_data,
  958. };
  959. static struct ti_clk_gate uart4_fck_data = {
  960. .parent = "per_48m_fck",
  961. .bit_shift = 18,
  962. .reg = 0x1000,
  963. .module = TI_CLKM_CM,
  964. .flags = CLKF_WAIT,
  965. };
  966. static struct ti_clk uart4_fck = {
  967. .name = "uart4_fck",
  968. .clkdm_name = "per_clkdm",
  969. .type = TI_CLK_GATE,
  970. .data = &uart4_fck_data,
  971. };
  972. static struct ti_clk_fixed_factor omap_96m_d10_fck_data = {
  973. .parent = "omap_96m_fck",
  974. .div = 10,
  975. .mult = 1,
  976. };
  977. static struct ti_clk omap_96m_d10_fck = {
  978. .name = "omap_96m_d10_fck",
  979. .type = TI_CLK_FIXED_FACTOR,
  980. .data = &omap_96m_d10_fck_data,
  981. };
  982. static struct ti_clk_gate usim_gate_fck_data = {
  983. .parent = "omap_96m_fck",
  984. .bit_shift = 9,
  985. .reg = 0xc00,
  986. .module = TI_CLKM_CM,
  987. };
  988. static struct ti_clk_fixed_factor per_l4_ick_data = {
  989. .parent = "l4_ick",
  990. .div = 1,
  991. .mult = 1,
  992. };
  993. static struct ti_clk per_l4_ick = {
  994. .name = "per_l4_ick",
  995. .type = TI_CLK_FIXED_FACTOR,
  996. .data = &per_l4_ick_data,
  997. };
  998. static struct ti_clk_gate gpt5_ick_data = {
  999. .parent = "per_l4_ick",
  1000. .bit_shift = 6,
  1001. .reg = 0x1010,
  1002. .module = TI_CLKM_CM,
  1003. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1004. };
  1005. static struct ti_clk gpt5_ick = {
  1006. .name = "gpt5_ick",
  1007. .clkdm_name = "per_clkdm",
  1008. .type = TI_CLK_GATE,
  1009. .data = &gpt5_ick_data,
  1010. };
  1011. static struct ti_clk_gate mcspi2_ick_data = {
  1012. .parent = "core_l4_ick",
  1013. .bit_shift = 19,
  1014. .reg = 0xa10,
  1015. .module = TI_CLKM_CM,
  1016. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1017. };
  1018. static struct ti_clk mcspi2_ick = {
  1019. .name = "mcspi2_ick",
  1020. .clkdm_name = "core_l4_clkdm",
  1021. .type = TI_CLK_GATE,
  1022. .data = &mcspi2_ick_data,
  1023. };
  1024. static struct ti_clk_fixed_factor ssi_l4_ick_data = {
  1025. .parent = "l4_ick",
  1026. .div = 1,
  1027. .mult = 1,
  1028. };
  1029. static struct ti_clk ssi_l4_ick = {
  1030. .name = "ssi_l4_ick",
  1031. .clkdm_name = "core_l4_clkdm",
  1032. .type = TI_CLK_FIXED_FACTOR,
  1033. .data = &ssi_l4_ick_data,
  1034. };
  1035. static struct ti_clk_gate ssi_ick_3430es1_data = {
  1036. .parent = "ssi_l4_ick",
  1037. .bit_shift = 0,
  1038. .reg = 0xa10,
  1039. .module = TI_CLKM_CM,
  1040. .flags = CLKF_OMAP3 | CLKF_NO_WAIT | CLKF_INTERFACE,
  1041. };
  1042. static struct ti_clk ssi_ick_3430es1 = {
  1043. .name = "ssi_ick",
  1044. .clkdm_name = "core_l4_clkdm",
  1045. .type = TI_CLK_GATE,
  1046. .data = &ssi_ick_3430es1_data,
  1047. };
  1048. static struct ti_clk_gate i2c2_fck_data = {
  1049. .parent = "core_96m_fck",
  1050. .bit_shift = 16,
  1051. .reg = 0xa00,
  1052. .module = TI_CLKM_CM,
  1053. .flags = CLKF_WAIT,
  1054. };
  1055. static struct ti_clk i2c2_fck = {
  1056. .name = "i2c2_fck",
  1057. .clkdm_name = "core_l4_clkdm",
  1058. .type = TI_CLK_GATE,
  1059. .data = &i2c2_fck_data,
  1060. };
  1061. static struct ti_clk_divider dpll1_fck_data = {
  1062. .parent = "core_ck",
  1063. .bit_shift = 19,
  1064. .max_div = 7,
  1065. .reg = 0x940,
  1066. .module = TI_CLKM_CM,
  1067. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1068. };
  1069. static struct ti_clk dpll1_fck = {
  1070. .name = "dpll1_fck",
  1071. .type = TI_CLK_DIVIDER,
  1072. .data = &dpll1_fck_data,
  1073. };
  1074. static const char *dpll1_ck_parents[] = {
  1075. "sys_ck",
  1076. "dpll1_fck",
  1077. };
  1078. static struct ti_clk_dpll dpll1_ck_data = {
  1079. .num_parents = ARRAY_SIZE(dpll1_ck_parents),
  1080. .control_reg = 0x904,
  1081. .idlest_reg = 0x924,
  1082. .mult_div1_reg = 0x940,
  1083. .autoidle_reg = 0x934,
  1084. .module = TI_CLKM_CM,
  1085. .parents = dpll1_ck_parents,
  1086. .freqsel_mask = 0xf0,
  1087. .modes = 0xa0,
  1088. .div1_mask = 0x7f,
  1089. .idlest_mask = 0x1,
  1090. .auto_recal_bit = 0x3,
  1091. .max_divider = 0x80,
  1092. .min_divider = 0x1,
  1093. .recal_en_bit = 0x7,
  1094. .max_multiplier = 0x7ff,
  1095. .enable_mask = 0x7,
  1096. .mult_mask = 0x7ff00,
  1097. .recal_st_bit = 0x7,
  1098. .autoidle_mask = 0x7,
  1099. };
  1100. static struct ti_clk dpll1_ck = {
  1101. .name = "dpll1_ck",
  1102. .clkdm_name = "dpll1_clkdm",
  1103. .type = TI_CLK_DPLL,
  1104. .data = &dpll1_ck_data,
  1105. };
  1106. static struct ti_clk_fixed secure_32k_fck_data = {
  1107. .frequency = 32768,
  1108. };
  1109. static struct ti_clk secure_32k_fck = {
  1110. .name = "secure_32k_fck",
  1111. .type = TI_CLK_FIXED,
  1112. .data = &secure_32k_fck_data,
  1113. };
  1114. static struct ti_clk_gate gpio5_ick_data = {
  1115. .parent = "per_l4_ick",
  1116. .bit_shift = 16,
  1117. .reg = 0x1010,
  1118. .module = TI_CLKM_CM,
  1119. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1120. };
  1121. static struct ti_clk gpio5_ick = {
  1122. .name = "gpio5_ick",
  1123. .clkdm_name = "per_clkdm",
  1124. .type = TI_CLK_GATE,
  1125. .data = &gpio5_ick_data,
  1126. };
  1127. static struct ti_clk_divider dpll4_m4_ck_data = {
  1128. .parent = "dpll4_ck",
  1129. .max_div = 32,
  1130. .reg = 0xe40,
  1131. .module = TI_CLKM_CM,
  1132. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1133. };
  1134. static struct ti_clk dpll4_m4_ck = {
  1135. .name = "dpll4_m4_ck",
  1136. .type = TI_CLK_DIVIDER,
  1137. .data = &dpll4_m4_ck_data,
  1138. };
  1139. static struct ti_clk_fixed_factor dpll4_m4x2_mul_ck_data = {
  1140. .parent = "dpll4_m4_ck",
  1141. .div = 1,
  1142. .mult = 2,
  1143. .flags = CLKF_SET_RATE_PARENT,
  1144. };
  1145. static struct ti_clk dpll4_m4x2_mul_ck = {
  1146. .name = "dpll4_m4x2_mul_ck",
  1147. .type = TI_CLK_FIXED_FACTOR,
  1148. .data = &dpll4_m4x2_mul_ck_data,
  1149. };
  1150. static struct ti_clk_gate dpll4_m4x2_ck_data = {
  1151. .parent = "dpll4_m4x2_mul_ck",
  1152. .bit_shift = 0x1d,
  1153. .reg = 0xd00,
  1154. .module = TI_CLKM_CM,
  1155. .flags = CLKF_SET_RATE_PARENT | CLKF_SET_BIT_TO_DISABLE,
  1156. };
  1157. static struct ti_clk dpll4_m4x2_ck = {
  1158. .name = "dpll4_m4x2_ck",
  1159. .type = TI_CLK_GATE,
  1160. .data = &dpll4_m4x2_ck_data,
  1161. };
  1162. static struct ti_clk_gate dss1_alwon_fck_3430es2_data = {
  1163. .parent = "dpll4_m4x2_ck",
  1164. .bit_shift = 0,
  1165. .reg = 0xe00,
  1166. .module = TI_CLKM_CM,
  1167. .flags = CLKF_DSS | CLKF_SET_RATE_PARENT,
  1168. };
  1169. static struct ti_clk dss1_alwon_fck_3430es2 = {
  1170. .name = "dss1_alwon_fck",
  1171. .clkdm_name = "dss_clkdm",
  1172. .type = TI_CLK_GATE,
  1173. .data = &dss1_alwon_fck_3430es2_data,
  1174. };
  1175. static struct ti_clk_gate uart3_ick_data = {
  1176. .parent = "per_l4_ick",
  1177. .bit_shift = 11,
  1178. .reg = 0x1010,
  1179. .module = TI_CLKM_CM,
  1180. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1181. };
  1182. static struct ti_clk uart3_ick = {
  1183. .name = "uart3_ick",
  1184. .clkdm_name = "per_clkdm",
  1185. .type = TI_CLK_GATE,
  1186. .data = &uart3_ick_data,
  1187. };
  1188. static struct ti_clk_divider dpll4_m3_ck_data = {
  1189. .parent = "dpll4_ck",
  1190. .bit_shift = 8,
  1191. .max_div = 32,
  1192. .reg = 0xe40,
  1193. .module = TI_CLKM_CM,
  1194. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1195. };
  1196. static struct ti_clk dpll4_m3_ck = {
  1197. .name = "dpll4_m3_ck",
  1198. .type = TI_CLK_DIVIDER,
  1199. .data = &dpll4_m3_ck_data,
  1200. };
  1201. static struct ti_clk_gate mcbsp3_ick_data = {
  1202. .parent = "per_l4_ick",
  1203. .bit_shift = 1,
  1204. .reg = 0x1010,
  1205. .module = TI_CLKM_CM,
  1206. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1207. };
  1208. static struct ti_clk mcbsp3_ick = {
  1209. .name = "mcbsp3_ick",
  1210. .clkdm_name = "per_clkdm",
  1211. .type = TI_CLK_GATE,
  1212. .data = &mcbsp3_ick_data,
  1213. };
  1214. static struct ti_clk_gate gpio3_dbck_data = {
  1215. .parent = "per_32k_alwon_fck",
  1216. .bit_shift = 14,
  1217. .reg = 0x1000,
  1218. .module = TI_CLKM_CM,
  1219. };
  1220. static struct ti_clk gpio3_dbck = {
  1221. .name = "gpio3_dbck",
  1222. .clkdm_name = "per_clkdm",
  1223. .type = TI_CLK_GATE,
  1224. .data = &gpio3_dbck_data,
  1225. };
  1226. static struct ti_clk_gate fac_ick_data = {
  1227. .parent = "core_l4_ick",
  1228. .bit_shift = 8,
  1229. .reg = 0xa10,
  1230. .module = TI_CLKM_CM,
  1231. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1232. };
  1233. static struct ti_clk fac_ick = {
  1234. .name = "fac_ick",
  1235. .clkdm_name = "core_l4_clkdm",
  1236. .type = TI_CLK_GATE,
  1237. .data = &fac_ick_data,
  1238. };
  1239. static struct ti_clk_gate clkout2_src_gate_ck_data = {
  1240. .parent = "core_ck",
  1241. .bit_shift = 7,
  1242. .reg = 0xd70,
  1243. .module = TI_CLKM_CM,
  1244. .flags = CLKF_NO_WAIT,
  1245. };
  1246. static struct ti_clk_fixed_factor dpll4_m3x2_mul_ck_data = {
  1247. .parent = "dpll4_m3_ck",
  1248. .div = 1,
  1249. .mult = 2,
  1250. };
  1251. static struct ti_clk dpll4_m3x2_mul_ck = {
  1252. .name = "dpll4_m3x2_mul_ck",
  1253. .type = TI_CLK_FIXED_FACTOR,
  1254. .data = &dpll4_m3x2_mul_ck_data,
  1255. };
  1256. static struct ti_clk_gate dpll4_m3x2_ck_data = {
  1257. .parent = "dpll4_m3x2_mul_ck",
  1258. .bit_shift = 0x1c,
  1259. .reg = 0xd00,
  1260. .module = TI_CLKM_CM,
  1261. .flags = CLKF_SET_BIT_TO_DISABLE,
  1262. };
  1263. static struct ti_clk dpll4_m3x2_ck = {
  1264. .name = "dpll4_m3x2_ck",
  1265. .type = TI_CLK_GATE,
  1266. .data = &dpll4_m3x2_ck_data,
  1267. };
  1268. static const char *omap_54m_fck_parents[] = {
  1269. "dpll4_m3x2_ck",
  1270. "sys_altclk",
  1271. };
  1272. static struct ti_clk_mux omap_54m_fck_data = {
  1273. .bit_shift = 5,
  1274. .num_parents = ARRAY_SIZE(omap_54m_fck_parents),
  1275. .reg = 0xd40,
  1276. .module = TI_CLKM_CM,
  1277. .parents = omap_54m_fck_parents,
  1278. };
  1279. static struct ti_clk omap_54m_fck = {
  1280. .name = "omap_54m_fck",
  1281. .type = TI_CLK_MUX,
  1282. .data = &omap_54m_fck_data,
  1283. };
  1284. static const char *clkout2_src_mux_ck_parents[] = {
  1285. "core_ck",
  1286. "sys_ck",
  1287. "cm_96m_fck",
  1288. "omap_54m_fck",
  1289. };
  1290. static struct ti_clk_mux clkout2_src_mux_ck_data = {
  1291. .num_parents = ARRAY_SIZE(clkout2_src_mux_ck_parents),
  1292. .reg = 0xd70,
  1293. .module = TI_CLKM_CM,
  1294. .parents = clkout2_src_mux_ck_parents,
  1295. };
  1296. static struct ti_clk_composite clkout2_src_ck_data = {
  1297. .mux = &clkout2_src_mux_ck_data,
  1298. .gate = &clkout2_src_gate_ck_data,
  1299. };
  1300. static struct ti_clk clkout2_src_ck = {
  1301. .name = "clkout2_src_ck",
  1302. .type = TI_CLK_COMPOSITE,
  1303. .data = &clkout2_src_ck_data,
  1304. };
  1305. static struct ti_clk_gate i2c1_fck_data = {
  1306. .parent = "core_96m_fck",
  1307. .bit_shift = 15,
  1308. .reg = 0xa00,
  1309. .module = TI_CLKM_CM,
  1310. .flags = CLKF_WAIT,
  1311. };
  1312. static struct ti_clk i2c1_fck = {
  1313. .name = "i2c1_fck",
  1314. .clkdm_name = "core_l4_clkdm",
  1315. .type = TI_CLK_GATE,
  1316. .data = &i2c1_fck_data,
  1317. };
  1318. static struct ti_clk_gate wdt3_fck_data = {
  1319. .parent = "per_32k_alwon_fck",
  1320. .bit_shift = 12,
  1321. .reg = 0x1000,
  1322. .module = TI_CLKM_CM,
  1323. .flags = CLKF_WAIT,
  1324. };
  1325. static struct ti_clk wdt3_fck = {
  1326. .name = "wdt3_fck",
  1327. .clkdm_name = "per_clkdm",
  1328. .type = TI_CLK_GATE,
  1329. .data = &wdt3_fck_data,
  1330. };
  1331. static struct ti_clk_gate gpt7_gate_fck_data = {
  1332. .parent = "sys_ck",
  1333. .bit_shift = 8,
  1334. .reg = 0x1000,
  1335. .module = TI_CLKM_CM,
  1336. };
  1337. static const char *gpt7_mux_fck_parents[] = {
  1338. "omap_32k_fck",
  1339. "sys_ck",
  1340. };
  1341. static struct ti_clk_mux gpt7_mux_fck_data = {
  1342. .bit_shift = 5,
  1343. .num_parents = ARRAY_SIZE(gpt7_mux_fck_parents),
  1344. .reg = 0x1040,
  1345. .module = TI_CLKM_CM,
  1346. .parents = gpt7_mux_fck_parents,
  1347. };
  1348. static struct ti_clk_composite gpt7_fck_data = {
  1349. .mux = &gpt7_mux_fck_data,
  1350. .gate = &gpt7_gate_fck_data,
  1351. };
  1352. static struct ti_clk gpt7_fck = {
  1353. .name = "gpt7_fck",
  1354. .type = TI_CLK_COMPOSITE,
  1355. .data = &gpt7_fck_data,
  1356. };
  1357. static struct ti_clk_gate usb_l4_gate_ick_data = {
  1358. .parent = "l4_ick",
  1359. .bit_shift = 5,
  1360. .reg = 0xa10,
  1361. .module = TI_CLKM_CM,
  1362. .flags = CLKF_INTERFACE,
  1363. };
  1364. static struct ti_clk_divider usb_l4_div_ick_data = {
  1365. .parent = "l4_ick",
  1366. .bit_shift = 4,
  1367. .max_div = 1,
  1368. .reg = 0xa40,
  1369. .module = TI_CLKM_CM,
  1370. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1371. };
  1372. static struct ti_clk_composite usb_l4_ick_data = {
  1373. .gate = &usb_l4_gate_ick_data,
  1374. .divider = &usb_l4_div_ick_data,
  1375. };
  1376. static struct ti_clk usb_l4_ick = {
  1377. .name = "usb_l4_ick",
  1378. .type = TI_CLK_COMPOSITE,
  1379. .data = &usb_l4_ick_data,
  1380. };
  1381. static struct ti_clk_gate uart4_ick_data = {
  1382. .parent = "per_l4_ick",
  1383. .bit_shift = 18,
  1384. .reg = 0x1010,
  1385. .module = TI_CLKM_CM,
  1386. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1387. };
  1388. static struct ti_clk uart4_ick = {
  1389. .name = "uart4_ick",
  1390. .clkdm_name = "per_clkdm",
  1391. .type = TI_CLK_GATE,
  1392. .data = &uart4_ick_data,
  1393. };
  1394. static struct ti_clk_fixed dummy_ck_data = {
  1395. .frequency = 0,
  1396. };
  1397. static struct ti_clk dummy_ck = {
  1398. .name = "dummy_ck",
  1399. .type = TI_CLK_FIXED,
  1400. .data = &dummy_ck_data,
  1401. };
  1402. static const char *gpt3_mux_fck_parents[] = {
  1403. "omap_32k_fck",
  1404. "sys_ck",
  1405. };
  1406. static struct ti_clk_mux gpt3_mux_fck_data = {
  1407. .bit_shift = 1,
  1408. .num_parents = ARRAY_SIZE(gpt3_mux_fck_parents),
  1409. .reg = 0x1040,
  1410. .module = TI_CLKM_CM,
  1411. .parents = gpt3_mux_fck_parents,
  1412. };
  1413. static struct ti_clk_gate gpt9_ick_data = {
  1414. .parent = "per_l4_ick",
  1415. .bit_shift = 10,
  1416. .reg = 0x1010,
  1417. .module = TI_CLKM_CM,
  1418. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1419. };
  1420. static struct ti_clk gpt9_ick = {
  1421. .name = "gpt9_ick",
  1422. .clkdm_name = "per_clkdm",
  1423. .type = TI_CLK_GATE,
  1424. .data = &gpt9_ick_data,
  1425. };
  1426. static struct ti_clk_gate gpt10_gate_fck_data = {
  1427. .parent = "sys_ck",
  1428. .bit_shift = 11,
  1429. .reg = 0xa00,
  1430. .module = TI_CLKM_CM,
  1431. };
  1432. static struct ti_clk_gate dss_ick_3430es1_data = {
  1433. .parent = "l4_ick",
  1434. .bit_shift = 0,
  1435. .reg = 0xe10,
  1436. .module = TI_CLKM_CM,
  1437. .flags = CLKF_OMAP3 | CLKF_NO_WAIT | CLKF_INTERFACE,
  1438. };
  1439. static struct ti_clk dss_ick_3430es1 = {
  1440. .name = "dss_ick",
  1441. .clkdm_name = "dss_clkdm",
  1442. .type = TI_CLK_GATE,
  1443. .data = &dss_ick_3430es1_data,
  1444. };
  1445. static struct ti_clk_gate gpt11_ick_data = {
  1446. .parent = "core_l4_ick",
  1447. .bit_shift = 12,
  1448. .reg = 0xa10,
  1449. .module = TI_CLKM_CM,
  1450. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1451. };
  1452. static struct ti_clk gpt11_ick = {
  1453. .name = "gpt11_ick",
  1454. .clkdm_name = "core_l4_clkdm",
  1455. .type = TI_CLK_GATE,
  1456. .data = &gpt11_ick_data,
  1457. };
  1458. static struct ti_clk_divider dpll2_fck_data = {
  1459. .parent = "core_ck",
  1460. .bit_shift = 19,
  1461. .max_div = 7,
  1462. .reg = 0x40,
  1463. .module = TI_CLKM_CM,
  1464. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1465. };
  1466. static struct ti_clk dpll2_fck = {
  1467. .name = "dpll2_fck",
  1468. .type = TI_CLK_DIVIDER,
  1469. .data = &dpll2_fck_data,
  1470. };
  1471. static struct ti_clk_gate uart1_fck_data = {
  1472. .parent = "core_48m_fck",
  1473. .bit_shift = 13,
  1474. .reg = 0xa00,
  1475. .module = TI_CLKM_CM,
  1476. .flags = CLKF_WAIT,
  1477. };
  1478. static struct ti_clk uart1_fck = {
  1479. .name = "uart1_fck",
  1480. .clkdm_name = "core_l4_clkdm",
  1481. .type = TI_CLK_GATE,
  1482. .data = &uart1_fck_data,
  1483. };
  1484. static struct ti_clk_gate hsotgusb_ick_3430es1_data = {
  1485. .parent = "core_l3_ick",
  1486. .bit_shift = 4,
  1487. .reg = 0xa10,
  1488. .module = TI_CLKM_CM,
  1489. .flags = CLKF_OMAP3 | CLKF_NO_WAIT | CLKF_INTERFACE,
  1490. };
  1491. static struct ti_clk hsotgusb_ick_3430es1 = {
  1492. .name = "hsotgusb_ick_3430es1",
  1493. .clkdm_name = "core_l3_clkdm",
  1494. .type = TI_CLK_GATE,
  1495. .data = &hsotgusb_ick_3430es1_data,
  1496. };
  1497. static struct ti_clk_gate gpio2_ick_data = {
  1498. .parent = "per_l4_ick",
  1499. .bit_shift = 13,
  1500. .reg = 0x1010,
  1501. .module = TI_CLKM_CM,
  1502. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1503. };
  1504. static struct ti_clk gpio2_ick = {
  1505. .name = "gpio2_ick",
  1506. .clkdm_name = "per_clkdm",
  1507. .type = TI_CLK_GATE,
  1508. .data = &gpio2_ick_data,
  1509. };
  1510. static struct ti_clk_gate mmchs1_ick_data = {
  1511. .parent = "core_l4_ick",
  1512. .bit_shift = 24,
  1513. .reg = 0xa10,
  1514. .module = TI_CLKM_CM,
  1515. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1516. };
  1517. static struct ti_clk mmchs1_ick = {
  1518. .name = "mmchs1_ick",
  1519. .clkdm_name = "core_l4_clkdm",
  1520. .type = TI_CLK_GATE,
  1521. .data = &mmchs1_ick_data,
  1522. };
  1523. static struct ti_clk_gate modem_fck_data = {
  1524. .parent = "sys_ck",
  1525. .bit_shift = 31,
  1526. .reg = 0xa00,
  1527. .module = TI_CLKM_CM,
  1528. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1529. };
  1530. static struct ti_clk modem_fck = {
  1531. .name = "modem_fck",
  1532. .clkdm_name = "d2d_clkdm",
  1533. .type = TI_CLK_GATE,
  1534. .data = &modem_fck_data,
  1535. };
  1536. static struct ti_clk_gate mcbsp4_ick_data = {
  1537. .parent = "per_l4_ick",
  1538. .bit_shift = 2,
  1539. .reg = 0x1010,
  1540. .module = TI_CLKM_CM,
  1541. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1542. };
  1543. static struct ti_clk mcbsp4_ick = {
  1544. .name = "mcbsp4_ick",
  1545. .clkdm_name = "per_clkdm",
  1546. .type = TI_CLK_GATE,
  1547. .data = &mcbsp4_ick_data,
  1548. };
  1549. static struct ti_clk_gate gpio1_ick_data = {
  1550. .parent = "wkup_l4_ick",
  1551. .bit_shift = 3,
  1552. .reg = 0xc10,
  1553. .module = TI_CLKM_CM,
  1554. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1555. };
  1556. static struct ti_clk gpio1_ick = {
  1557. .name = "gpio1_ick",
  1558. .clkdm_name = "wkup_clkdm",
  1559. .type = TI_CLK_GATE,
  1560. .data = &gpio1_ick_data,
  1561. };
  1562. static const char *gpt6_mux_fck_parents[] = {
  1563. "omap_32k_fck",
  1564. "sys_ck",
  1565. };
  1566. static struct ti_clk_mux gpt6_mux_fck_data = {
  1567. .bit_shift = 4,
  1568. .num_parents = ARRAY_SIZE(gpt6_mux_fck_parents),
  1569. .reg = 0x1040,
  1570. .module = TI_CLKM_CM,
  1571. .parents = gpt6_mux_fck_parents,
  1572. };
  1573. static struct ti_clk_fixed_factor dpll1_x2_ck_data = {
  1574. .parent = "dpll1_ck",
  1575. .div = 1,
  1576. .mult = 2,
  1577. };
  1578. static struct ti_clk dpll1_x2_ck = {
  1579. .name = "dpll1_x2_ck",
  1580. .type = TI_CLK_FIXED_FACTOR,
  1581. .data = &dpll1_x2_ck_data,
  1582. };
  1583. static struct ti_clk_divider dpll1_x2m2_ck_data = {
  1584. .parent = "dpll1_x2_ck",
  1585. .max_div = 31,
  1586. .reg = 0x944,
  1587. .module = TI_CLKM_CM,
  1588. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1589. };
  1590. static struct ti_clk dpll1_x2m2_ck = {
  1591. .name = "dpll1_x2m2_ck",
  1592. .type = TI_CLK_DIVIDER,
  1593. .data = &dpll1_x2m2_ck_data,
  1594. };
  1595. static struct ti_clk_fixed_factor mpu_ck_data = {
  1596. .parent = "dpll1_x2m2_ck",
  1597. .div = 1,
  1598. .mult = 1,
  1599. };
  1600. static struct ti_clk mpu_ck = {
  1601. .name = "mpu_ck",
  1602. .type = TI_CLK_FIXED_FACTOR,
  1603. .data = &mpu_ck_data,
  1604. };
  1605. static struct ti_clk_divider arm_fck_data = {
  1606. .parent = "mpu_ck",
  1607. .max_div = 2,
  1608. .reg = 0x924,
  1609. .module = TI_CLKM_CM,
  1610. };
  1611. static struct ti_clk arm_fck = {
  1612. .name = "arm_fck",
  1613. .type = TI_CLK_DIVIDER,
  1614. .data = &arm_fck_data,
  1615. };
  1616. static struct ti_clk_fixed_factor core_d3_ck_data = {
  1617. .parent = "core_ck",
  1618. .div = 3,
  1619. .mult = 1,
  1620. };
  1621. static struct ti_clk core_d3_ck = {
  1622. .name = "core_d3_ck",
  1623. .type = TI_CLK_FIXED_FACTOR,
  1624. .data = &core_d3_ck_data,
  1625. };
  1626. static struct ti_clk_gate gpt11_gate_fck_data = {
  1627. .parent = "sys_ck",
  1628. .bit_shift = 12,
  1629. .reg = 0xa00,
  1630. .module = TI_CLKM_CM,
  1631. };
  1632. static const char *gpt11_mux_fck_parents[] = {
  1633. "omap_32k_fck",
  1634. "sys_ck",
  1635. };
  1636. static struct ti_clk_mux gpt11_mux_fck_data = {
  1637. .bit_shift = 7,
  1638. .num_parents = ARRAY_SIZE(gpt11_mux_fck_parents),
  1639. .reg = 0xa40,
  1640. .module = TI_CLKM_CM,
  1641. .parents = gpt11_mux_fck_parents,
  1642. };
  1643. static struct ti_clk_composite gpt11_fck_data = {
  1644. .mux = &gpt11_mux_fck_data,
  1645. .gate = &gpt11_gate_fck_data,
  1646. };
  1647. static struct ti_clk gpt11_fck = {
  1648. .name = "gpt11_fck",
  1649. .type = TI_CLK_COMPOSITE,
  1650. .data = &gpt11_fck_data,
  1651. };
  1652. static struct ti_clk_fixed_factor core_d6_ck_data = {
  1653. .parent = "core_ck",
  1654. .div = 6,
  1655. .mult = 1,
  1656. };
  1657. static struct ti_clk core_d6_ck = {
  1658. .name = "core_d6_ck",
  1659. .type = TI_CLK_FIXED_FACTOR,
  1660. .data = &core_d6_ck_data,
  1661. };
  1662. static struct ti_clk_gate uart4_fck_am35xx_data = {
  1663. .parent = "core_48m_fck",
  1664. .bit_shift = 23,
  1665. .reg = 0xa00,
  1666. .module = TI_CLKM_CM,
  1667. .flags = CLKF_WAIT,
  1668. };
  1669. static struct ti_clk uart4_fck_am35xx = {
  1670. .name = "uart4_fck_am35xx",
  1671. .clkdm_name = "core_l4_clkdm",
  1672. .type = TI_CLK_GATE,
  1673. .data = &uart4_fck_am35xx_data,
  1674. };
  1675. static struct ti_clk_gate dpll3_m3x2_ck_data = {
  1676. .parent = "dpll3_m3x2_mul_ck",
  1677. .bit_shift = 0xc,
  1678. .reg = 0xd00,
  1679. .module = TI_CLKM_CM,
  1680. .flags = CLKF_SET_BIT_TO_DISABLE,
  1681. };
  1682. static struct ti_clk dpll3_m3x2_ck = {
  1683. .name = "dpll3_m3x2_ck",
  1684. .type = TI_CLK_GATE,
  1685. .data = &dpll3_m3x2_ck_data,
  1686. };
  1687. static struct ti_clk_fixed_factor emu_core_alwon_ck_data = {
  1688. .parent = "dpll3_m3x2_ck",
  1689. .div = 1,
  1690. .mult = 1,
  1691. };
  1692. static struct ti_clk emu_core_alwon_ck = {
  1693. .name = "emu_core_alwon_ck",
  1694. .type = TI_CLK_FIXED_FACTOR,
  1695. .data = &emu_core_alwon_ck_data,
  1696. };
  1697. static struct ti_clk_divider dpll4_m6_ck_data = {
  1698. .parent = "dpll4_ck",
  1699. .bit_shift = 24,
  1700. .max_div = 63,
  1701. .reg = 0x1140,
  1702. .module = TI_CLKM_CM,
  1703. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1704. };
  1705. static struct ti_clk dpll4_m6_ck = {
  1706. .name = "dpll4_m6_ck",
  1707. .type = TI_CLK_DIVIDER,
  1708. .data = &dpll4_m6_ck_data,
  1709. };
  1710. static struct ti_clk_fixed_factor dpll4_m6x2_mul_ck_data = {
  1711. .parent = "dpll4_m6_ck",
  1712. .div = 1,
  1713. .mult = 2,
  1714. };
  1715. static struct ti_clk dpll4_m6x2_mul_ck = {
  1716. .name = "dpll4_m6x2_mul_ck",
  1717. .type = TI_CLK_FIXED_FACTOR,
  1718. .data = &dpll4_m6x2_mul_ck_data,
  1719. };
  1720. static struct ti_clk_gate dpll4_m6x2_ck_data = {
  1721. .parent = "dpll4_m6x2_mul_ck",
  1722. .bit_shift = 0x1f,
  1723. .reg = 0xd00,
  1724. .module = TI_CLKM_CM,
  1725. .flags = CLKF_SET_BIT_TO_DISABLE,
  1726. };
  1727. static struct ti_clk dpll4_m6x2_ck = {
  1728. .name = "dpll4_m6x2_ck",
  1729. .type = TI_CLK_GATE,
  1730. .data = &dpll4_m6x2_ck_data,
  1731. };
  1732. static struct ti_clk_fixed_factor emu_per_alwon_ck_data = {
  1733. .parent = "dpll4_m6x2_ck",
  1734. .div = 1,
  1735. .mult = 1,
  1736. };
  1737. static struct ti_clk emu_per_alwon_ck = {
  1738. .name = "emu_per_alwon_ck",
  1739. .type = TI_CLK_FIXED_FACTOR,
  1740. .data = &emu_per_alwon_ck_data,
  1741. };
  1742. static struct ti_clk_fixed_factor emu_mpu_alwon_ck_data = {
  1743. .parent = "mpu_ck",
  1744. .div = 1,
  1745. .mult = 1,
  1746. };
  1747. static struct ti_clk emu_mpu_alwon_ck = {
  1748. .name = "emu_mpu_alwon_ck",
  1749. .type = TI_CLK_FIXED_FACTOR,
  1750. .data = &emu_mpu_alwon_ck_data,
  1751. };
  1752. static const char *emu_src_mux_ck_parents[] = {
  1753. "sys_ck",
  1754. "emu_core_alwon_ck",
  1755. "emu_per_alwon_ck",
  1756. "emu_mpu_alwon_ck",
  1757. };
  1758. static struct ti_clk_mux emu_src_mux_ck_data = {
  1759. .num_parents = ARRAY_SIZE(emu_src_mux_ck_parents),
  1760. .reg = 0x1140,
  1761. .module = TI_CLKM_CM,
  1762. .parents = emu_src_mux_ck_parents,
  1763. };
  1764. static struct ti_clk emu_src_mux_ck = {
  1765. .name = "emu_src_mux_ck",
  1766. .type = TI_CLK_MUX,
  1767. .data = &emu_src_mux_ck_data,
  1768. };
  1769. static struct ti_clk_gate emu_src_ck_data = {
  1770. .parent = "emu_src_mux_ck",
  1771. .flags = CLKF_CLKDM,
  1772. };
  1773. static struct ti_clk emu_src_ck = {
  1774. .name = "emu_src_ck",
  1775. .clkdm_name = "emu_clkdm",
  1776. .type = TI_CLK_GATE,
  1777. .data = &emu_src_ck_data,
  1778. };
  1779. static struct ti_clk_divider atclk_fck_data = {
  1780. .parent = "emu_src_ck",
  1781. .bit_shift = 4,
  1782. .max_div = 3,
  1783. .reg = 0x1140,
  1784. .module = TI_CLKM_CM,
  1785. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1786. };
  1787. static struct ti_clk atclk_fck = {
  1788. .name = "atclk_fck",
  1789. .type = TI_CLK_DIVIDER,
  1790. .data = &atclk_fck_data,
  1791. };
  1792. static struct ti_clk_gate ipss_ick_data = {
  1793. .parent = "core_l3_ick",
  1794. .bit_shift = 4,
  1795. .reg = 0xa10,
  1796. .module = TI_CLKM_CM,
  1797. .flags = CLKF_AM35XX | CLKF_INTERFACE,
  1798. };
  1799. static struct ti_clk ipss_ick = {
  1800. .name = "ipss_ick",
  1801. .clkdm_name = "core_l3_clkdm",
  1802. .type = TI_CLK_GATE,
  1803. .data = &ipss_ick_data,
  1804. };
  1805. static struct ti_clk_gate emac_ick_data = {
  1806. .parent = "ipss_ick",
  1807. .bit_shift = 1,
  1808. .reg = 0x59c,
  1809. .module = TI_CLKM_SCRM,
  1810. .flags = CLKF_AM35XX,
  1811. };
  1812. static struct ti_clk emac_ick = {
  1813. .name = "emac_ick",
  1814. .clkdm_name = "core_l3_clkdm",
  1815. .type = TI_CLK_GATE,
  1816. .data = &emac_ick_data,
  1817. };
  1818. static struct ti_clk_gate vpfe_ick_data = {
  1819. .parent = "ipss_ick",
  1820. .bit_shift = 2,
  1821. .reg = 0x59c,
  1822. .module = TI_CLKM_SCRM,
  1823. .flags = CLKF_AM35XX,
  1824. };
  1825. static struct ti_clk vpfe_ick = {
  1826. .name = "vpfe_ick",
  1827. .clkdm_name = "core_l3_clkdm",
  1828. .type = TI_CLK_GATE,
  1829. .data = &vpfe_ick_data,
  1830. };
  1831. static const char *dpll2_ck_parents[] = {
  1832. "sys_ck",
  1833. "dpll2_fck",
  1834. };
  1835. static struct ti_clk_dpll dpll2_ck_data = {
  1836. .num_parents = ARRAY_SIZE(dpll2_ck_parents),
  1837. .control_reg = 0x4,
  1838. .idlest_reg = 0x24,
  1839. .mult_div1_reg = 0x40,
  1840. .autoidle_reg = 0x34,
  1841. .module = TI_CLKM_CM,
  1842. .parents = dpll2_ck_parents,
  1843. .freqsel_mask = 0xf0,
  1844. .modes = 0xa2,
  1845. .div1_mask = 0x7f,
  1846. .idlest_mask = 0x1,
  1847. .auto_recal_bit = 0x3,
  1848. .max_divider = 0x80,
  1849. .min_divider = 0x1,
  1850. .recal_en_bit = 0x8,
  1851. .max_multiplier = 0x7ff,
  1852. .enable_mask = 0x7,
  1853. .mult_mask = 0x7ff00,
  1854. .recal_st_bit = 0x8,
  1855. .autoidle_mask = 0x7,
  1856. };
  1857. static struct ti_clk dpll2_ck = {
  1858. .name = "dpll2_ck",
  1859. .clkdm_name = "dpll2_clkdm",
  1860. .type = TI_CLK_DPLL,
  1861. .data = &dpll2_ck_data,
  1862. };
  1863. static struct ti_clk_divider dpll2_m2_ck_data = {
  1864. .parent = "dpll2_ck",
  1865. .max_div = 31,
  1866. .reg = 0x44,
  1867. .module = TI_CLKM_CM,
  1868. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1869. };
  1870. static struct ti_clk dpll2_m2_ck = {
  1871. .name = "dpll2_m2_ck",
  1872. .type = TI_CLK_DIVIDER,
  1873. .data = &dpll2_m2_ck_data,
  1874. };
  1875. static const char *mcbsp4_mux_fck_parents[] = {
  1876. "per_96m_fck",
  1877. "mcbsp_clks",
  1878. };
  1879. static struct ti_clk_mux mcbsp4_mux_fck_data = {
  1880. .bit_shift = 2,
  1881. .num_parents = ARRAY_SIZE(mcbsp4_mux_fck_parents),
  1882. .reg = 0x2d8,
  1883. .module = TI_CLKM_SCRM,
  1884. .parents = mcbsp4_mux_fck_parents,
  1885. };
  1886. static const char *mcbsp1_mux_fck_parents[] = {
  1887. "core_96m_fck",
  1888. "mcbsp_clks",
  1889. };
  1890. static struct ti_clk_mux mcbsp1_mux_fck_data = {
  1891. .bit_shift = 2,
  1892. .num_parents = ARRAY_SIZE(mcbsp1_mux_fck_parents),
  1893. .reg = 0x274,
  1894. .module = TI_CLKM_SCRM,
  1895. .parents = mcbsp1_mux_fck_parents,
  1896. };
  1897. static struct ti_clk_gate gpt8_gate_fck_data = {
  1898. .parent = "sys_ck",
  1899. .bit_shift = 9,
  1900. .reg = 0x1000,
  1901. .module = TI_CLKM_CM,
  1902. };
  1903. static struct ti_clk_gate gpt8_ick_data = {
  1904. .parent = "per_l4_ick",
  1905. .bit_shift = 9,
  1906. .reg = 0x1010,
  1907. .module = TI_CLKM_CM,
  1908. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1909. };
  1910. static struct ti_clk gpt8_ick = {
  1911. .name = "gpt8_ick",
  1912. .clkdm_name = "per_clkdm",
  1913. .type = TI_CLK_GATE,
  1914. .data = &gpt8_ick_data,
  1915. };
  1916. static const char *gpt10_mux_fck_parents[] = {
  1917. "omap_32k_fck",
  1918. "sys_ck",
  1919. };
  1920. static struct ti_clk_mux gpt10_mux_fck_data = {
  1921. .bit_shift = 6,
  1922. .num_parents = ARRAY_SIZE(gpt10_mux_fck_parents),
  1923. .reg = 0xa40,
  1924. .module = TI_CLKM_CM,
  1925. .parents = gpt10_mux_fck_parents,
  1926. };
  1927. static struct ti_clk_gate mmchs3_ick_data = {
  1928. .parent = "core_l4_ick",
  1929. .bit_shift = 30,
  1930. .reg = 0xa10,
  1931. .module = TI_CLKM_CM,
  1932. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1933. };
  1934. static struct ti_clk mmchs3_ick = {
  1935. .name = "mmchs3_ick",
  1936. .clkdm_name = "core_l4_clkdm",
  1937. .type = TI_CLK_GATE,
  1938. .data = &mmchs3_ick_data,
  1939. };
  1940. static struct ti_clk_gate gpio3_ick_data = {
  1941. .parent = "per_l4_ick",
  1942. .bit_shift = 14,
  1943. .reg = 0x1010,
  1944. .module = TI_CLKM_CM,
  1945. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1946. };
  1947. static struct ti_clk gpio3_ick = {
  1948. .name = "gpio3_ick",
  1949. .clkdm_name = "per_clkdm",
  1950. .type = TI_CLK_GATE,
  1951. .data = &gpio3_ick_data,
  1952. };
  1953. static const char *traceclk_src_fck_parents[] = {
  1954. "sys_ck",
  1955. "emu_core_alwon_ck",
  1956. "emu_per_alwon_ck",
  1957. "emu_mpu_alwon_ck",
  1958. };
  1959. static struct ti_clk_mux traceclk_src_fck_data = {
  1960. .bit_shift = 2,
  1961. .num_parents = ARRAY_SIZE(traceclk_src_fck_parents),
  1962. .reg = 0x1140,
  1963. .module = TI_CLKM_CM,
  1964. .parents = traceclk_src_fck_parents,
  1965. };
  1966. static struct ti_clk traceclk_src_fck = {
  1967. .name = "traceclk_src_fck",
  1968. .type = TI_CLK_MUX,
  1969. .data = &traceclk_src_fck_data,
  1970. };
  1971. static struct ti_clk_divider traceclk_fck_data = {
  1972. .parent = "traceclk_src_fck",
  1973. .bit_shift = 11,
  1974. .max_div = 7,
  1975. .reg = 0x1140,
  1976. .module = TI_CLKM_CM,
  1977. .flags = CLKF_INDEX_STARTS_AT_ONE,
  1978. };
  1979. static struct ti_clk traceclk_fck = {
  1980. .name = "traceclk_fck",
  1981. .type = TI_CLK_DIVIDER,
  1982. .data = &traceclk_fck_data,
  1983. };
  1984. static struct ti_clk_gate mcbsp5_gate_fck_data = {
  1985. .parent = "mcbsp_clks",
  1986. .bit_shift = 10,
  1987. .reg = 0xa00,
  1988. .module = TI_CLKM_CM,
  1989. };
  1990. static struct ti_clk_gate sad2d_ick_data = {
  1991. .parent = "l3_ick",
  1992. .bit_shift = 3,
  1993. .reg = 0xa10,
  1994. .module = TI_CLKM_CM,
  1995. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  1996. };
  1997. static struct ti_clk sad2d_ick = {
  1998. .name = "sad2d_ick",
  1999. .clkdm_name = "d2d_clkdm",
  2000. .type = TI_CLK_GATE,
  2001. .data = &sad2d_ick_data,
  2002. };
  2003. static const char *gpt1_mux_fck_parents[] = {
  2004. "omap_32k_fck",
  2005. "sys_ck",
  2006. };
  2007. static struct ti_clk_mux gpt1_mux_fck_data = {
  2008. .num_parents = ARRAY_SIZE(gpt1_mux_fck_parents),
  2009. .reg = 0xc40,
  2010. .module = TI_CLKM_CM,
  2011. .parents = gpt1_mux_fck_parents,
  2012. };
  2013. static struct ti_clk_gate hecc_ck_data = {
  2014. .parent = "sys_ck",
  2015. .bit_shift = 3,
  2016. .reg = 0x59c,
  2017. .module = TI_CLKM_SCRM,
  2018. .flags = CLKF_AM35XX,
  2019. };
  2020. static struct ti_clk hecc_ck = {
  2021. .name = "hecc_ck",
  2022. .clkdm_name = "core_l3_clkdm",
  2023. .type = TI_CLK_GATE,
  2024. .data = &hecc_ck_data,
  2025. };
  2026. static struct ti_clk_gate gpt1_gate_fck_data = {
  2027. .parent = "sys_ck",
  2028. .bit_shift = 0,
  2029. .reg = 0xc00,
  2030. .module = TI_CLKM_CM,
  2031. };
  2032. static struct ti_clk_composite gpt1_fck_data = {
  2033. .mux = &gpt1_mux_fck_data,
  2034. .gate = &gpt1_gate_fck_data,
  2035. };
  2036. static struct ti_clk gpt1_fck = {
  2037. .name = "gpt1_fck",
  2038. .type = TI_CLK_COMPOSITE,
  2039. .data = &gpt1_fck_data,
  2040. };
  2041. static struct ti_clk_gate dpll4_m2x2_ck_omap36xx_data = {
  2042. .parent = "dpll4_m2x2_mul_ck",
  2043. .bit_shift = 0x1b,
  2044. .reg = 0xd00,
  2045. .module = TI_CLKM_CM,
  2046. .flags = CLKF_HSDIV | CLKF_SET_BIT_TO_DISABLE,
  2047. };
  2048. static struct ti_clk dpll4_m2x2_ck_omap36xx = {
  2049. .name = "dpll4_m2x2_ck",
  2050. .type = TI_CLK_GATE,
  2051. .data = &dpll4_m2x2_ck_omap36xx_data,
  2052. .patch = &dpll4_m2x2_ck,
  2053. };
  2054. static struct ti_clk_divider gfx_l3_fck_data = {
  2055. .parent = "l3_ick",
  2056. .max_div = 7,
  2057. .reg = 0xb40,
  2058. .module = TI_CLKM_CM,
  2059. .flags = CLKF_INDEX_STARTS_AT_ONE,
  2060. };
  2061. static struct ti_clk gfx_l3_fck = {
  2062. .name = "gfx_l3_fck",
  2063. .type = TI_CLK_DIVIDER,
  2064. .data = &gfx_l3_fck_data,
  2065. };
  2066. static struct ti_clk_gate gfx_cg1_ck_data = {
  2067. .parent = "gfx_l3_fck",
  2068. .bit_shift = 1,
  2069. .reg = 0xb00,
  2070. .module = TI_CLKM_CM,
  2071. .flags = CLKF_WAIT,
  2072. };
  2073. static struct ti_clk gfx_cg1_ck = {
  2074. .name = "gfx_cg1_ck",
  2075. .clkdm_name = "gfx_3430es1_clkdm",
  2076. .type = TI_CLK_GATE,
  2077. .data = &gfx_cg1_ck_data,
  2078. };
  2079. static struct ti_clk_gate mailboxes_ick_data = {
  2080. .parent = "core_l4_ick",
  2081. .bit_shift = 7,
  2082. .reg = 0xa10,
  2083. .module = TI_CLKM_CM,
  2084. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2085. };
  2086. static struct ti_clk mailboxes_ick = {
  2087. .name = "mailboxes_ick",
  2088. .clkdm_name = "core_l4_clkdm",
  2089. .type = TI_CLK_GATE,
  2090. .data = &mailboxes_ick_data,
  2091. };
  2092. static struct ti_clk_gate sha11_ick_data = {
  2093. .parent = "security_l4_ick2",
  2094. .bit_shift = 1,
  2095. .reg = 0xa14,
  2096. .module = TI_CLKM_CM,
  2097. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2098. };
  2099. static struct ti_clk sha11_ick = {
  2100. .name = "sha11_ick",
  2101. .type = TI_CLK_GATE,
  2102. .data = &sha11_ick_data,
  2103. };
  2104. static struct ti_clk_gate hsotgusb_ick_am35xx_data = {
  2105. .parent = "ipss_ick",
  2106. .bit_shift = 0,
  2107. .reg = 0x59c,
  2108. .module = TI_CLKM_SCRM,
  2109. .flags = CLKF_AM35XX,
  2110. };
  2111. static struct ti_clk hsotgusb_ick_am35xx = {
  2112. .name = "hsotgusb_ick_am35xx",
  2113. .clkdm_name = "core_l3_clkdm",
  2114. .type = TI_CLK_GATE,
  2115. .data = &hsotgusb_ick_am35xx_data,
  2116. };
  2117. static struct ti_clk_gate mmchs3_fck_data = {
  2118. .parent = "core_96m_fck",
  2119. .bit_shift = 30,
  2120. .reg = 0xa00,
  2121. .module = TI_CLKM_CM,
  2122. .flags = CLKF_WAIT,
  2123. };
  2124. static struct ti_clk mmchs3_fck = {
  2125. .name = "mmchs3_fck",
  2126. .clkdm_name = "core_l4_clkdm",
  2127. .type = TI_CLK_GATE,
  2128. .data = &mmchs3_fck_data,
  2129. };
  2130. static struct ti_clk_divider pclk_fck_data = {
  2131. .parent = "emu_src_ck",
  2132. .bit_shift = 8,
  2133. .max_div = 7,
  2134. .reg = 0x1140,
  2135. .module = TI_CLKM_CM,
  2136. .flags = CLKF_INDEX_STARTS_AT_ONE,
  2137. };
  2138. static struct ti_clk pclk_fck = {
  2139. .name = "pclk_fck",
  2140. .type = TI_CLK_DIVIDER,
  2141. .data = &pclk_fck_data,
  2142. };
  2143. static const char *dpll4_ck_omap36xx_parents[] = {
  2144. "sys_ck",
  2145. "sys_ck",
  2146. };
  2147. static struct ti_clk_dpll dpll4_ck_omap36xx_data = {
  2148. .num_parents = ARRAY_SIZE(dpll4_ck_omap36xx_parents),
  2149. .control_reg = 0xd00,
  2150. .idlest_reg = 0xd20,
  2151. .mult_div1_reg = 0xd44,
  2152. .autoidle_reg = 0xd30,
  2153. .module = TI_CLKM_CM,
  2154. .parents = dpll4_ck_omap36xx_parents,
  2155. .modes = 0x82,
  2156. .div1_mask = 0x7f,
  2157. .idlest_mask = 0x2,
  2158. .auto_recal_bit = 0x13,
  2159. .max_divider = 0x80,
  2160. .min_divider = 0x1,
  2161. .recal_en_bit = 0x6,
  2162. .max_multiplier = 0xfff,
  2163. .enable_mask = 0x70000,
  2164. .mult_mask = 0xfff00,
  2165. .recal_st_bit = 0x6,
  2166. .autoidle_mask = 0x38,
  2167. .sddiv_mask = 0xff000000,
  2168. .dco_mask = 0xe00000,
  2169. .flags = CLKF_PER | CLKF_J_TYPE,
  2170. };
  2171. static struct ti_clk dpll4_ck_omap36xx = {
  2172. .name = "dpll4_ck",
  2173. .type = TI_CLK_DPLL,
  2174. .data = &dpll4_ck_omap36xx_data,
  2175. .patch = &dpll4_ck,
  2176. };
  2177. static struct ti_clk_gate uart3_fck_data = {
  2178. .parent = "per_48m_fck",
  2179. .bit_shift = 11,
  2180. .reg = 0x1000,
  2181. .module = TI_CLKM_CM,
  2182. .flags = CLKF_WAIT,
  2183. };
  2184. static struct ti_clk uart3_fck = {
  2185. .name = "uart3_fck",
  2186. .clkdm_name = "per_clkdm",
  2187. .type = TI_CLK_GATE,
  2188. .data = &uart3_fck_data,
  2189. };
  2190. static struct ti_clk_fixed_factor wkup_32k_fck_data = {
  2191. .parent = "omap_32k_fck",
  2192. .div = 1,
  2193. .mult = 1,
  2194. };
  2195. static struct ti_clk wkup_32k_fck = {
  2196. .name = "wkup_32k_fck",
  2197. .type = TI_CLK_FIXED_FACTOR,
  2198. .data = &wkup_32k_fck_data,
  2199. };
  2200. static struct ti_clk_gate sys_clkout1_data = {
  2201. .parent = "osc_sys_ck",
  2202. .bit_shift = 7,
  2203. .reg = 0xd70,
  2204. .module = TI_CLKM_PRM,
  2205. };
  2206. static struct ti_clk sys_clkout1 = {
  2207. .name = "sys_clkout1",
  2208. .type = TI_CLK_GATE,
  2209. .data = &sys_clkout1_data,
  2210. };
  2211. static struct ti_clk_fixed_factor gpmc_fck_data = {
  2212. .parent = "core_l3_ick",
  2213. .div = 1,
  2214. .mult = 1,
  2215. };
  2216. static struct ti_clk gpmc_fck = {
  2217. .name = "gpmc_fck",
  2218. .type = TI_CLK_FIXED_FACTOR,
  2219. .data = &gpmc_fck_data,
  2220. };
  2221. static struct ti_clk_fixed_factor dpll5_m2_d20_ck_data = {
  2222. .parent = "dpll5_m2_ck",
  2223. .div = 20,
  2224. .mult = 1,
  2225. };
  2226. static struct ti_clk dpll5_m2_d20_ck = {
  2227. .name = "dpll5_m2_d20_ck",
  2228. .type = TI_CLK_FIXED_FACTOR,
  2229. .data = &dpll5_m2_d20_ck_data,
  2230. };
  2231. static struct ti_clk_gate dpll4_m5x2_ck_omap36xx_data = {
  2232. .parent = "dpll4_m5x2_mul_ck",
  2233. .bit_shift = 0x1e,
  2234. .reg = 0xd00,
  2235. .module = TI_CLKM_CM,
  2236. .flags = CLKF_HSDIV | CLKF_SET_RATE_PARENT | CLKF_SET_BIT_TO_DISABLE,
  2237. };
  2238. static struct ti_clk dpll4_m5x2_ck_omap36xx = {
  2239. .name = "dpll4_m5x2_ck",
  2240. .type = TI_CLK_GATE,
  2241. .data = &dpll4_m5x2_ck_omap36xx_data,
  2242. .patch = &dpll4_m5x2_ck,
  2243. };
  2244. static struct ti_clk_gate ssi_ssr_gate_fck_3430es2_data = {
  2245. .parent = "corex2_fck",
  2246. .bit_shift = 0,
  2247. .reg = 0xa00,
  2248. .module = TI_CLKM_CM,
  2249. .flags = CLKF_NO_WAIT,
  2250. };
  2251. static struct ti_clk_gate uart1_ick_data = {
  2252. .parent = "core_l4_ick",
  2253. .bit_shift = 13,
  2254. .reg = 0xa10,
  2255. .module = TI_CLKM_CM,
  2256. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2257. };
  2258. static struct ti_clk uart1_ick = {
  2259. .name = "uart1_ick",
  2260. .clkdm_name = "core_l4_clkdm",
  2261. .type = TI_CLK_GATE,
  2262. .data = &uart1_ick_data,
  2263. };
  2264. static struct ti_clk_gate iva2_ck_data = {
  2265. .parent = "dpll2_m2_ck",
  2266. .bit_shift = 0,
  2267. .reg = 0x0,
  2268. .module = TI_CLKM_CM,
  2269. .flags = CLKF_WAIT,
  2270. };
  2271. static struct ti_clk iva2_ck = {
  2272. .name = "iva2_ck",
  2273. .clkdm_name = "iva2_clkdm",
  2274. .type = TI_CLK_GATE,
  2275. .data = &iva2_ck_data,
  2276. };
  2277. static struct ti_clk_gate pka_ick_data = {
  2278. .parent = "security_l3_ick",
  2279. .bit_shift = 4,
  2280. .reg = 0xa14,
  2281. .module = TI_CLKM_CM,
  2282. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2283. };
  2284. static struct ti_clk pka_ick = {
  2285. .name = "pka_ick",
  2286. .type = TI_CLK_GATE,
  2287. .data = &pka_ick_data,
  2288. };
  2289. static struct ti_clk_gate gpt12_ick_data = {
  2290. .parent = "wkup_l4_ick",
  2291. .bit_shift = 1,
  2292. .reg = 0xc10,
  2293. .module = TI_CLKM_CM,
  2294. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2295. };
  2296. static struct ti_clk gpt12_ick = {
  2297. .name = "gpt12_ick",
  2298. .clkdm_name = "wkup_clkdm",
  2299. .type = TI_CLK_GATE,
  2300. .data = &gpt12_ick_data,
  2301. };
  2302. static const char *mcbsp5_mux_fck_parents[] = {
  2303. "core_96m_fck",
  2304. "mcbsp_clks",
  2305. };
  2306. static struct ti_clk_mux mcbsp5_mux_fck_data = {
  2307. .bit_shift = 4,
  2308. .num_parents = ARRAY_SIZE(mcbsp5_mux_fck_parents),
  2309. .reg = 0x2d8,
  2310. .module = TI_CLKM_SCRM,
  2311. .parents = mcbsp5_mux_fck_parents,
  2312. };
  2313. static struct ti_clk_composite mcbsp5_fck_data = {
  2314. .mux = &mcbsp5_mux_fck_data,
  2315. .gate = &mcbsp5_gate_fck_data,
  2316. };
  2317. static struct ti_clk mcbsp5_fck = {
  2318. .name = "mcbsp5_fck",
  2319. .type = TI_CLK_COMPOSITE,
  2320. .data = &mcbsp5_fck_data,
  2321. };
  2322. static struct ti_clk_gate usbhost_48m_fck_data = {
  2323. .parent = "omap_48m_fck",
  2324. .bit_shift = 0,
  2325. .reg = 0x1400,
  2326. .module = TI_CLKM_CM,
  2327. .flags = CLKF_DSS,
  2328. };
  2329. static struct ti_clk usbhost_48m_fck = {
  2330. .name = "usbhost_48m_fck",
  2331. .clkdm_name = "usbhost_clkdm",
  2332. .type = TI_CLK_GATE,
  2333. .data = &usbhost_48m_fck_data,
  2334. };
  2335. static struct ti_clk_gate des1_ick_data = {
  2336. .parent = "security_l4_ick2",
  2337. .bit_shift = 0,
  2338. .reg = 0xa14,
  2339. .module = TI_CLKM_CM,
  2340. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2341. };
  2342. static struct ti_clk des1_ick = {
  2343. .name = "des1_ick",
  2344. .type = TI_CLK_GATE,
  2345. .data = &des1_ick_data,
  2346. };
  2347. static struct ti_clk_gate sgx_gate_fck_data = {
  2348. .parent = "core_ck",
  2349. .bit_shift = 1,
  2350. .reg = 0xb00,
  2351. .module = TI_CLKM_CM,
  2352. };
  2353. static struct ti_clk_fixed_factor core_d4_ck_data = {
  2354. .parent = "core_ck",
  2355. .div = 4,
  2356. .mult = 1,
  2357. };
  2358. static struct ti_clk core_d4_ck = {
  2359. .name = "core_d4_ck",
  2360. .type = TI_CLK_FIXED_FACTOR,
  2361. .data = &core_d4_ck_data,
  2362. };
  2363. static struct ti_clk_fixed_factor omap_192m_alwon_fck_data = {
  2364. .parent = "dpll4_m2x2_ck",
  2365. .div = 1,
  2366. .mult = 1,
  2367. };
  2368. static struct ti_clk omap_192m_alwon_fck = {
  2369. .name = "omap_192m_alwon_fck",
  2370. .type = TI_CLK_FIXED_FACTOR,
  2371. .data = &omap_192m_alwon_fck_data,
  2372. };
  2373. static struct ti_clk_fixed_factor core_d2_ck_data = {
  2374. .parent = "core_ck",
  2375. .div = 2,
  2376. .mult = 1,
  2377. };
  2378. static struct ti_clk core_d2_ck = {
  2379. .name = "core_d2_ck",
  2380. .type = TI_CLK_FIXED_FACTOR,
  2381. .data = &core_d2_ck_data,
  2382. };
  2383. static struct ti_clk_fixed_factor corex2_d3_fck_data = {
  2384. .parent = "corex2_fck",
  2385. .div = 3,
  2386. .mult = 1,
  2387. };
  2388. static struct ti_clk corex2_d3_fck = {
  2389. .name = "corex2_d3_fck",
  2390. .type = TI_CLK_FIXED_FACTOR,
  2391. .data = &corex2_d3_fck_data,
  2392. };
  2393. static struct ti_clk_fixed_factor corex2_d5_fck_data = {
  2394. .parent = "corex2_fck",
  2395. .div = 5,
  2396. .mult = 1,
  2397. };
  2398. static struct ti_clk corex2_d5_fck = {
  2399. .name = "corex2_d5_fck",
  2400. .type = TI_CLK_FIXED_FACTOR,
  2401. .data = &corex2_d5_fck_data,
  2402. };
  2403. static const char *sgx_mux_fck_parents[] = {
  2404. "core_d3_ck",
  2405. "core_d4_ck",
  2406. "core_d6_ck",
  2407. "cm_96m_fck",
  2408. "omap_192m_alwon_fck",
  2409. "core_d2_ck",
  2410. "corex2_d3_fck",
  2411. "corex2_d5_fck",
  2412. };
  2413. static struct ti_clk_mux sgx_mux_fck_data = {
  2414. .num_parents = ARRAY_SIZE(sgx_mux_fck_parents),
  2415. .reg = 0xb40,
  2416. .module = TI_CLKM_CM,
  2417. .parents = sgx_mux_fck_parents,
  2418. };
  2419. static struct ti_clk_composite sgx_fck_data = {
  2420. .mux = &sgx_mux_fck_data,
  2421. .gate = &sgx_gate_fck_data,
  2422. };
  2423. static struct ti_clk sgx_fck = {
  2424. .name = "sgx_fck",
  2425. .type = TI_CLK_COMPOSITE,
  2426. .data = &sgx_fck_data,
  2427. };
  2428. static struct ti_clk_gate mcspi1_fck_data = {
  2429. .parent = "core_48m_fck",
  2430. .bit_shift = 18,
  2431. .reg = 0xa00,
  2432. .module = TI_CLKM_CM,
  2433. .flags = CLKF_WAIT,
  2434. };
  2435. static struct ti_clk mcspi1_fck = {
  2436. .name = "mcspi1_fck",
  2437. .clkdm_name = "core_l4_clkdm",
  2438. .type = TI_CLK_GATE,
  2439. .data = &mcspi1_fck_data,
  2440. };
  2441. static struct ti_clk_gate mmchs2_fck_data = {
  2442. .parent = "core_96m_fck",
  2443. .bit_shift = 25,
  2444. .reg = 0xa00,
  2445. .module = TI_CLKM_CM,
  2446. .flags = CLKF_WAIT,
  2447. };
  2448. static struct ti_clk mmchs2_fck = {
  2449. .name = "mmchs2_fck",
  2450. .clkdm_name = "core_l4_clkdm",
  2451. .type = TI_CLK_GATE,
  2452. .data = &mmchs2_fck_data,
  2453. };
  2454. static struct ti_clk_gate mcspi2_fck_data = {
  2455. .parent = "core_48m_fck",
  2456. .bit_shift = 19,
  2457. .reg = 0xa00,
  2458. .module = TI_CLKM_CM,
  2459. .flags = CLKF_WAIT,
  2460. };
  2461. static struct ti_clk mcspi2_fck = {
  2462. .name = "mcspi2_fck",
  2463. .clkdm_name = "core_l4_clkdm",
  2464. .type = TI_CLK_GATE,
  2465. .data = &mcspi2_fck_data,
  2466. };
  2467. static struct ti_clk_gate vpfe_fck_data = {
  2468. .parent = "pclk_ck",
  2469. .bit_shift = 10,
  2470. .reg = 0x59c,
  2471. .module = TI_CLKM_SCRM,
  2472. };
  2473. static struct ti_clk vpfe_fck = {
  2474. .name = "vpfe_fck",
  2475. .type = TI_CLK_GATE,
  2476. .data = &vpfe_fck_data,
  2477. };
  2478. static struct ti_clk_gate gpt4_gate_fck_data = {
  2479. .parent = "sys_ck",
  2480. .bit_shift = 5,
  2481. .reg = 0x1000,
  2482. .module = TI_CLKM_CM,
  2483. };
  2484. static struct ti_clk_gate mcbsp1_gate_fck_data = {
  2485. .parent = "mcbsp_clks",
  2486. .bit_shift = 9,
  2487. .reg = 0xa00,
  2488. .module = TI_CLKM_CM,
  2489. };
  2490. static struct ti_clk_gate gpt5_gate_fck_data = {
  2491. .parent = "sys_ck",
  2492. .bit_shift = 6,
  2493. .reg = 0x1000,
  2494. .module = TI_CLKM_CM,
  2495. };
  2496. static const char *gpt5_mux_fck_parents[] = {
  2497. "omap_32k_fck",
  2498. "sys_ck",
  2499. };
  2500. static struct ti_clk_mux gpt5_mux_fck_data = {
  2501. .bit_shift = 3,
  2502. .num_parents = ARRAY_SIZE(gpt5_mux_fck_parents),
  2503. .reg = 0x1040,
  2504. .module = TI_CLKM_CM,
  2505. .parents = gpt5_mux_fck_parents,
  2506. };
  2507. static struct ti_clk_composite gpt5_fck_data = {
  2508. .mux = &gpt5_mux_fck_data,
  2509. .gate = &gpt5_gate_fck_data,
  2510. };
  2511. static struct ti_clk gpt5_fck = {
  2512. .name = "gpt5_fck",
  2513. .type = TI_CLK_COMPOSITE,
  2514. .data = &gpt5_fck_data,
  2515. };
  2516. static struct ti_clk_gate ts_fck_data = {
  2517. .parent = "omap_32k_fck",
  2518. .bit_shift = 1,
  2519. .reg = 0xa08,
  2520. .module = TI_CLKM_CM,
  2521. };
  2522. static struct ti_clk ts_fck = {
  2523. .name = "ts_fck",
  2524. .clkdm_name = "core_l4_clkdm",
  2525. .type = TI_CLK_GATE,
  2526. .data = &ts_fck_data,
  2527. };
  2528. static struct ti_clk_fixed_factor wdt1_fck_data = {
  2529. .parent = "secure_32k_fck",
  2530. .div = 1,
  2531. .mult = 1,
  2532. };
  2533. static struct ti_clk wdt1_fck = {
  2534. .name = "wdt1_fck",
  2535. .type = TI_CLK_FIXED_FACTOR,
  2536. .data = &wdt1_fck_data,
  2537. };
  2538. static struct ti_clk_gate dpll4_m6x2_ck_omap36xx_data = {
  2539. .parent = "dpll4_m6x2_mul_ck",
  2540. .bit_shift = 0x1f,
  2541. .reg = 0xd00,
  2542. .module = TI_CLKM_CM,
  2543. .flags = CLKF_HSDIV | CLKF_SET_BIT_TO_DISABLE,
  2544. };
  2545. static struct ti_clk dpll4_m6x2_ck_omap36xx = {
  2546. .name = "dpll4_m6x2_ck",
  2547. .type = TI_CLK_GATE,
  2548. .data = &dpll4_m6x2_ck_omap36xx_data,
  2549. .patch = &dpll4_m6x2_ck,
  2550. };
  2551. static const char *gpt4_mux_fck_parents[] = {
  2552. "omap_32k_fck",
  2553. "sys_ck",
  2554. };
  2555. static struct ti_clk_mux gpt4_mux_fck_data = {
  2556. .bit_shift = 2,
  2557. .num_parents = ARRAY_SIZE(gpt4_mux_fck_parents),
  2558. .reg = 0x1040,
  2559. .module = TI_CLKM_CM,
  2560. .parents = gpt4_mux_fck_parents,
  2561. };
  2562. static struct ti_clk_gate usbhost_ick_data = {
  2563. .parent = "l4_ick",
  2564. .bit_shift = 0,
  2565. .reg = 0x1410,
  2566. .module = TI_CLKM_CM,
  2567. .flags = CLKF_DSS | CLKF_OMAP3 | CLKF_INTERFACE,
  2568. };
  2569. static struct ti_clk usbhost_ick = {
  2570. .name = "usbhost_ick",
  2571. .clkdm_name = "usbhost_clkdm",
  2572. .type = TI_CLK_GATE,
  2573. .data = &usbhost_ick_data,
  2574. };
  2575. static struct ti_clk_gate mcbsp2_ick_data = {
  2576. .parent = "per_l4_ick",
  2577. .bit_shift = 0,
  2578. .reg = 0x1010,
  2579. .module = TI_CLKM_CM,
  2580. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2581. };
  2582. static struct ti_clk mcbsp2_ick = {
  2583. .name = "mcbsp2_ick",
  2584. .clkdm_name = "per_clkdm",
  2585. .type = TI_CLK_GATE,
  2586. .data = &mcbsp2_ick_data,
  2587. };
  2588. static struct ti_clk_gate omapctrl_ick_data = {
  2589. .parent = "core_l4_ick",
  2590. .bit_shift = 6,
  2591. .reg = 0xa10,
  2592. .module = TI_CLKM_CM,
  2593. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2594. };
  2595. static struct ti_clk omapctrl_ick = {
  2596. .name = "omapctrl_ick",
  2597. .clkdm_name = "core_l4_clkdm",
  2598. .type = TI_CLK_GATE,
  2599. .data = &omapctrl_ick_data,
  2600. };
  2601. static struct ti_clk_fixed_factor omap_96m_d4_fck_data = {
  2602. .parent = "omap_96m_fck",
  2603. .div = 4,
  2604. .mult = 1,
  2605. };
  2606. static struct ti_clk omap_96m_d4_fck = {
  2607. .name = "omap_96m_d4_fck",
  2608. .type = TI_CLK_FIXED_FACTOR,
  2609. .data = &omap_96m_d4_fck_data,
  2610. };
  2611. static struct ti_clk_gate gpt6_ick_data = {
  2612. .parent = "per_l4_ick",
  2613. .bit_shift = 7,
  2614. .reg = 0x1010,
  2615. .module = TI_CLKM_CM,
  2616. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2617. };
  2618. static struct ti_clk gpt6_ick = {
  2619. .name = "gpt6_ick",
  2620. .clkdm_name = "per_clkdm",
  2621. .type = TI_CLK_GATE,
  2622. .data = &gpt6_ick_data,
  2623. };
  2624. static struct ti_clk_gate dpll3_m3x2_ck_omap36xx_data = {
  2625. .parent = "dpll3_m3x2_mul_ck",
  2626. .bit_shift = 0xc,
  2627. .reg = 0xd00,
  2628. .module = TI_CLKM_CM,
  2629. .flags = CLKF_HSDIV | CLKF_SET_BIT_TO_DISABLE,
  2630. };
  2631. static struct ti_clk dpll3_m3x2_ck_omap36xx = {
  2632. .name = "dpll3_m3x2_ck",
  2633. .type = TI_CLK_GATE,
  2634. .data = &dpll3_m3x2_ck_omap36xx_data,
  2635. .patch = &dpll3_m3x2_ck,
  2636. };
  2637. static struct ti_clk_gate i2c3_ick_data = {
  2638. .parent = "core_l4_ick",
  2639. .bit_shift = 17,
  2640. .reg = 0xa10,
  2641. .module = TI_CLKM_CM,
  2642. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2643. };
  2644. static struct ti_clk i2c3_ick = {
  2645. .name = "i2c3_ick",
  2646. .clkdm_name = "core_l4_clkdm",
  2647. .type = TI_CLK_GATE,
  2648. .data = &i2c3_ick_data,
  2649. };
  2650. static struct ti_clk_gate gpio6_ick_data = {
  2651. .parent = "per_l4_ick",
  2652. .bit_shift = 17,
  2653. .reg = 0x1010,
  2654. .module = TI_CLKM_CM,
  2655. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2656. };
  2657. static struct ti_clk gpio6_ick = {
  2658. .name = "gpio6_ick",
  2659. .clkdm_name = "per_clkdm",
  2660. .type = TI_CLK_GATE,
  2661. .data = &gpio6_ick_data,
  2662. };
  2663. static struct ti_clk_gate mspro_ick_data = {
  2664. .parent = "core_l4_ick",
  2665. .bit_shift = 23,
  2666. .reg = 0xa10,
  2667. .module = TI_CLKM_CM,
  2668. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2669. };
  2670. static struct ti_clk mspro_ick = {
  2671. .name = "mspro_ick",
  2672. .clkdm_name = "core_l4_clkdm",
  2673. .type = TI_CLK_GATE,
  2674. .data = &mspro_ick_data,
  2675. };
  2676. static struct ti_clk_composite mcbsp1_fck_data = {
  2677. .mux = &mcbsp1_mux_fck_data,
  2678. .gate = &mcbsp1_gate_fck_data,
  2679. };
  2680. static struct ti_clk mcbsp1_fck = {
  2681. .name = "mcbsp1_fck",
  2682. .type = TI_CLK_COMPOSITE,
  2683. .data = &mcbsp1_fck_data,
  2684. };
  2685. static struct ti_clk_gate gpt3_gate_fck_data = {
  2686. .parent = "sys_ck",
  2687. .bit_shift = 4,
  2688. .reg = 0x1000,
  2689. .module = TI_CLKM_CM,
  2690. };
  2691. static struct ti_clk_fixed rmii_ck_data = {
  2692. .frequency = 50000000,
  2693. };
  2694. static struct ti_clk rmii_ck = {
  2695. .name = "rmii_ck",
  2696. .type = TI_CLK_FIXED,
  2697. .data = &rmii_ck_data,
  2698. };
  2699. static struct ti_clk_gate gpt6_gate_fck_data = {
  2700. .parent = "sys_ck",
  2701. .bit_shift = 7,
  2702. .reg = 0x1000,
  2703. .module = TI_CLKM_CM,
  2704. };
  2705. static struct ti_clk_composite gpt6_fck_data = {
  2706. .mux = &gpt6_mux_fck_data,
  2707. .gate = &gpt6_gate_fck_data,
  2708. };
  2709. static struct ti_clk gpt6_fck = {
  2710. .name = "gpt6_fck",
  2711. .type = TI_CLK_COMPOSITE,
  2712. .data = &gpt6_fck_data,
  2713. };
  2714. static struct ti_clk_fixed_factor dpll5_m2_d4_ck_data = {
  2715. .parent = "dpll5_m2_ck",
  2716. .div = 4,
  2717. .mult = 1,
  2718. };
  2719. static struct ti_clk dpll5_m2_d4_ck = {
  2720. .name = "dpll5_m2_d4_ck",
  2721. .type = TI_CLK_FIXED_FACTOR,
  2722. .data = &dpll5_m2_d4_ck_data,
  2723. };
  2724. static struct ti_clk_fixed_factor sys_d2_ck_data = {
  2725. .parent = "sys_ck",
  2726. .div = 2,
  2727. .mult = 1,
  2728. };
  2729. static struct ti_clk sys_d2_ck = {
  2730. .name = "sys_d2_ck",
  2731. .type = TI_CLK_FIXED_FACTOR,
  2732. .data = &sys_d2_ck_data,
  2733. };
  2734. static struct ti_clk_fixed_factor omap_96m_d2_fck_data = {
  2735. .parent = "omap_96m_fck",
  2736. .div = 2,
  2737. .mult = 1,
  2738. };
  2739. static struct ti_clk omap_96m_d2_fck = {
  2740. .name = "omap_96m_d2_fck",
  2741. .type = TI_CLK_FIXED_FACTOR,
  2742. .data = &omap_96m_d2_fck_data,
  2743. };
  2744. static struct ti_clk_fixed_factor dpll5_m2_d8_ck_data = {
  2745. .parent = "dpll5_m2_ck",
  2746. .div = 8,
  2747. .mult = 1,
  2748. };
  2749. static struct ti_clk dpll5_m2_d8_ck = {
  2750. .name = "dpll5_m2_d8_ck",
  2751. .type = TI_CLK_FIXED_FACTOR,
  2752. .data = &dpll5_m2_d8_ck_data,
  2753. };
  2754. static struct ti_clk_fixed_factor dpll5_m2_d16_ck_data = {
  2755. .parent = "dpll5_m2_ck",
  2756. .div = 16,
  2757. .mult = 1,
  2758. };
  2759. static struct ti_clk dpll5_m2_d16_ck = {
  2760. .name = "dpll5_m2_d16_ck",
  2761. .type = TI_CLK_FIXED_FACTOR,
  2762. .data = &dpll5_m2_d16_ck_data,
  2763. };
  2764. static const char *usim_mux_fck_parents[] = {
  2765. "sys_ck",
  2766. "sys_d2_ck",
  2767. "omap_96m_d2_fck",
  2768. "omap_96m_d4_fck",
  2769. "omap_96m_d8_fck",
  2770. "omap_96m_d10_fck",
  2771. "dpll5_m2_d4_ck",
  2772. "dpll5_m2_d8_ck",
  2773. "dpll5_m2_d16_ck",
  2774. "dpll5_m2_d20_ck",
  2775. };
  2776. static struct ti_clk_mux usim_mux_fck_data = {
  2777. .bit_shift = 3,
  2778. .num_parents = ARRAY_SIZE(usim_mux_fck_parents),
  2779. .reg = 0xc40,
  2780. .module = TI_CLKM_CM,
  2781. .parents = usim_mux_fck_parents,
  2782. .flags = CLKF_INDEX_STARTS_AT_ONE,
  2783. };
  2784. static struct ti_clk_composite usim_fck_data = {
  2785. .mux = &usim_mux_fck_data,
  2786. .gate = &usim_gate_fck_data,
  2787. };
  2788. static struct ti_clk usim_fck = {
  2789. .name = "usim_fck",
  2790. .type = TI_CLK_COMPOSITE,
  2791. .data = &usim_fck_data,
  2792. };
  2793. static int ssi_ssr_div_fck_3430es2_divs[] = {
  2794. 0,
  2795. 1,
  2796. 2,
  2797. 3,
  2798. 4,
  2799. 0,
  2800. 6,
  2801. 0,
  2802. 8,
  2803. };
  2804. static struct ti_clk_divider ssi_ssr_div_fck_3430es2_data = {
  2805. .num_dividers = ARRAY_SIZE(ssi_ssr_div_fck_3430es2_divs),
  2806. .parent = "corex2_fck",
  2807. .bit_shift = 8,
  2808. .dividers = ssi_ssr_div_fck_3430es2_divs,
  2809. .reg = 0xa40,
  2810. .module = TI_CLKM_CM,
  2811. };
  2812. static struct ti_clk_composite ssi_ssr_fck_3430es2_data = {
  2813. .gate = &ssi_ssr_gate_fck_3430es2_data,
  2814. .divider = &ssi_ssr_div_fck_3430es2_data,
  2815. };
  2816. static struct ti_clk ssi_ssr_fck_3430es2 = {
  2817. .name = "ssi_ssr_fck",
  2818. .type = TI_CLK_COMPOSITE,
  2819. .data = &ssi_ssr_fck_3430es2_data,
  2820. };
  2821. static struct ti_clk_gate dss1_alwon_fck_3430es1_data = {
  2822. .parent = "dpll4_m4x2_ck",
  2823. .bit_shift = 0,
  2824. .reg = 0xe00,
  2825. .module = TI_CLKM_CM,
  2826. .flags = CLKF_SET_RATE_PARENT,
  2827. };
  2828. static struct ti_clk dss1_alwon_fck_3430es1 = {
  2829. .name = "dss1_alwon_fck",
  2830. .clkdm_name = "dss_clkdm",
  2831. .type = TI_CLK_GATE,
  2832. .data = &dss1_alwon_fck_3430es1_data,
  2833. };
  2834. static struct ti_clk_gate gpt3_ick_data = {
  2835. .parent = "per_l4_ick",
  2836. .bit_shift = 4,
  2837. .reg = 0x1010,
  2838. .module = TI_CLKM_CM,
  2839. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2840. };
  2841. static struct ti_clk gpt3_ick = {
  2842. .name = "gpt3_ick",
  2843. .clkdm_name = "per_clkdm",
  2844. .type = TI_CLK_GATE,
  2845. .data = &gpt3_ick_data,
  2846. };
  2847. static struct ti_clk_fixed_factor omap_12m_fck_data = {
  2848. .parent = "omap_48m_fck",
  2849. .div = 4,
  2850. .mult = 1,
  2851. };
  2852. static struct ti_clk omap_12m_fck = {
  2853. .name = "omap_12m_fck",
  2854. .type = TI_CLK_FIXED_FACTOR,
  2855. .data = &omap_12m_fck_data,
  2856. };
  2857. static struct ti_clk_fixed_factor core_12m_fck_data = {
  2858. .parent = "omap_12m_fck",
  2859. .div = 1,
  2860. .mult = 1,
  2861. };
  2862. static struct ti_clk core_12m_fck = {
  2863. .name = "core_12m_fck",
  2864. .type = TI_CLK_FIXED_FACTOR,
  2865. .data = &core_12m_fck_data,
  2866. };
  2867. static struct ti_clk_gate hdq_fck_data = {
  2868. .parent = "core_12m_fck",
  2869. .bit_shift = 22,
  2870. .reg = 0xa00,
  2871. .module = TI_CLKM_CM,
  2872. .flags = CLKF_WAIT,
  2873. };
  2874. static struct ti_clk hdq_fck = {
  2875. .name = "hdq_fck",
  2876. .clkdm_name = "core_l4_clkdm",
  2877. .type = TI_CLK_GATE,
  2878. .data = &hdq_fck_data,
  2879. };
  2880. static struct ti_clk_gate usbtll_fck_data = {
  2881. .parent = "dpll5_m2_ck",
  2882. .bit_shift = 2,
  2883. .reg = 0xa08,
  2884. .module = TI_CLKM_CM,
  2885. .flags = CLKF_WAIT,
  2886. };
  2887. static struct ti_clk usbtll_fck = {
  2888. .name = "usbtll_fck",
  2889. .clkdm_name = "core_l4_clkdm",
  2890. .type = TI_CLK_GATE,
  2891. .data = &usbtll_fck_data,
  2892. };
  2893. static struct ti_clk_gate hsotgusb_fck_am35xx_data = {
  2894. .parent = "sys_ck",
  2895. .bit_shift = 8,
  2896. .reg = 0x59c,
  2897. .module = TI_CLKM_SCRM,
  2898. };
  2899. static struct ti_clk hsotgusb_fck_am35xx = {
  2900. .name = "hsotgusb_fck_am35xx",
  2901. .clkdm_name = "core_l3_clkdm",
  2902. .type = TI_CLK_GATE,
  2903. .data = &hsotgusb_fck_am35xx_data,
  2904. };
  2905. static struct ti_clk_gate hsotgusb_ick_3430es2_data = {
  2906. .parent = "core_l3_ick",
  2907. .bit_shift = 4,
  2908. .reg = 0xa10,
  2909. .module = TI_CLKM_CM,
  2910. .flags = CLKF_HSOTGUSB | CLKF_OMAP3 | CLKF_INTERFACE,
  2911. };
  2912. static struct ti_clk hsotgusb_ick_3430es2 = {
  2913. .name = "hsotgusb_ick_3430es2",
  2914. .clkdm_name = "core_l3_clkdm",
  2915. .type = TI_CLK_GATE,
  2916. .data = &hsotgusb_ick_3430es2_data,
  2917. };
  2918. static struct ti_clk_gate gfx_l3_ck_data = {
  2919. .parent = "l3_ick",
  2920. .bit_shift = 0,
  2921. .reg = 0xb10,
  2922. .module = TI_CLKM_CM,
  2923. .flags = CLKF_WAIT,
  2924. };
  2925. static struct ti_clk gfx_l3_ck = {
  2926. .name = "gfx_l3_ck",
  2927. .clkdm_name = "gfx_3430es1_clkdm",
  2928. .type = TI_CLK_GATE,
  2929. .data = &gfx_l3_ck_data,
  2930. };
  2931. static struct ti_clk_fixed_factor gfx_l3_ick_data = {
  2932. .parent = "gfx_l3_ck",
  2933. .div = 1,
  2934. .mult = 1,
  2935. };
  2936. static struct ti_clk gfx_l3_ick = {
  2937. .name = "gfx_l3_ick",
  2938. .type = TI_CLK_FIXED_FACTOR,
  2939. .data = &gfx_l3_ick_data,
  2940. };
  2941. static struct ti_clk_gate mcbsp1_ick_data = {
  2942. .parent = "core_l4_ick",
  2943. .bit_shift = 9,
  2944. .reg = 0xa10,
  2945. .module = TI_CLKM_CM,
  2946. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2947. };
  2948. static struct ti_clk mcbsp1_ick = {
  2949. .name = "mcbsp1_ick",
  2950. .clkdm_name = "core_l4_clkdm",
  2951. .type = TI_CLK_GATE,
  2952. .data = &mcbsp1_ick_data,
  2953. };
  2954. static struct ti_clk_fixed_factor gpt12_fck_data = {
  2955. .parent = "secure_32k_fck",
  2956. .div = 1,
  2957. .mult = 1,
  2958. };
  2959. static struct ti_clk gpt12_fck = {
  2960. .name = "gpt12_fck",
  2961. .type = TI_CLK_FIXED_FACTOR,
  2962. .data = &gpt12_fck_data,
  2963. };
  2964. static struct ti_clk_gate gfx_cg2_ck_data = {
  2965. .parent = "gfx_l3_fck",
  2966. .bit_shift = 2,
  2967. .reg = 0xb00,
  2968. .module = TI_CLKM_CM,
  2969. .flags = CLKF_WAIT,
  2970. };
  2971. static struct ti_clk gfx_cg2_ck = {
  2972. .name = "gfx_cg2_ck",
  2973. .clkdm_name = "gfx_3430es1_clkdm",
  2974. .type = TI_CLK_GATE,
  2975. .data = &gfx_cg2_ck_data,
  2976. };
  2977. static struct ti_clk_gate i2c2_ick_data = {
  2978. .parent = "core_l4_ick",
  2979. .bit_shift = 16,
  2980. .reg = 0xa10,
  2981. .module = TI_CLKM_CM,
  2982. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  2983. };
  2984. static struct ti_clk i2c2_ick = {
  2985. .name = "i2c2_ick",
  2986. .clkdm_name = "core_l4_clkdm",
  2987. .type = TI_CLK_GATE,
  2988. .data = &i2c2_ick_data,
  2989. };
  2990. static struct ti_clk_gate gpio4_dbck_data = {
  2991. .parent = "per_32k_alwon_fck",
  2992. .bit_shift = 15,
  2993. .reg = 0x1000,
  2994. .module = TI_CLKM_CM,
  2995. };
  2996. static struct ti_clk gpio4_dbck = {
  2997. .name = "gpio4_dbck",
  2998. .clkdm_name = "per_clkdm",
  2999. .type = TI_CLK_GATE,
  3000. .data = &gpio4_dbck_data,
  3001. };
  3002. static struct ti_clk_gate i2c3_fck_data = {
  3003. .parent = "core_96m_fck",
  3004. .bit_shift = 17,
  3005. .reg = 0xa00,
  3006. .module = TI_CLKM_CM,
  3007. .flags = CLKF_WAIT,
  3008. };
  3009. static struct ti_clk i2c3_fck = {
  3010. .name = "i2c3_fck",
  3011. .clkdm_name = "core_l4_clkdm",
  3012. .type = TI_CLK_GATE,
  3013. .data = &i2c3_fck_data,
  3014. };
  3015. static struct ti_clk_composite gpt3_fck_data = {
  3016. .mux = &gpt3_mux_fck_data,
  3017. .gate = &gpt3_gate_fck_data,
  3018. };
  3019. static struct ti_clk gpt3_fck = {
  3020. .name = "gpt3_fck",
  3021. .type = TI_CLK_COMPOSITE,
  3022. .data = &gpt3_fck_data,
  3023. };
  3024. static struct ti_clk_gate i2c1_ick_data = {
  3025. .parent = "core_l4_ick",
  3026. .bit_shift = 15,
  3027. .reg = 0xa10,
  3028. .module = TI_CLKM_CM,
  3029. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3030. };
  3031. static struct ti_clk i2c1_ick = {
  3032. .name = "i2c1_ick",
  3033. .clkdm_name = "core_l4_clkdm",
  3034. .type = TI_CLK_GATE,
  3035. .data = &i2c1_ick_data,
  3036. };
  3037. static struct ti_clk_gate omap_32ksync_ick_data = {
  3038. .parent = "wkup_l4_ick",
  3039. .bit_shift = 2,
  3040. .reg = 0xc10,
  3041. .module = TI_CLKM_CM,
  3042. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3043. };
  3044. static struct ti_clk omap_32ksync_ick = {
  3045. .name = "omap_32ksync_ick",
  3046. .clkdm_name = "wkup_clkdm",
  3047. .type = TI_CLK_GATE,
  3048. .data = &omap_32ksync_ick_data,
  3049. };
  3050. static struct ti_clk_gate aes2_ick_data = {
  3051. .parent = "core_l4_ick",
  3052. .bit_shift = 28,
  3053. .reg = 0xa10,
  3054. .module = TI_CLKM_CM,
  3055. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3056. };
  3057. static struct ti_clk aes2_ick = {
  3058. .name = "aes2_ick",
  3059. .clkdm_name = "core_l4_clkdm",
  3060. .type = TI_CLK_GATE,
  3061. .data = &aes2_ick_data,
  3062. };
  3063. static const char *gpt8_mux_fck_parents[] = {
  3064. "omap_32k_fck",
  3065. "sys_ck",
  3066. };
  3067. static struct ti_clk_mux gpt8_mux_fck_data = {
  3068. .bit_shift = 6,
  3069. .num_parents = ARRAY_SIZE(gpt8_mux_fck_parents),
  3070. .reg = 0x1040,
  3071. .module = TI_CLKM_CM,
  3072. .parents = gpt8_mux_fck_parents,
  3073. };
  3074. static struct ti_clk_composite gpt8_fck_data = {
  3075. .mux = &gpt8_mux_fck_data,
  3076. .gate = &gpt8_gate_fck_data,
  3077. };
  3078. static struct ti_clk gpt8_fck = {
  3079. .name = "gpt8_fck",
  3080. .type = TI_CLK_COMPOSITE,
  3081. .data = &gpt8_fck_data,
  3082. };
  3083. static struct ti_clk_gate mcbsp4_gate_fck_data = {
  3084. .parent = "mcbsp_clks",
  3085. .bit_shift = 2,
  3086. .reg = 0x1000,
  3087. .module = TI_CLKM_CM,
  3088. };
  3089. static struct ti_clk_composite mcbsp4_fck_data = {
  3090. .mux = &mcbsp4_mux_fck_data,
  3091. .gate = &mcbsp4_gate_fck_data,
  3092. };
  3093. static struct ti_clk mcbsp4_fck = {
  3094. .name = "mcbsp4_fck",
  3095. .type = TI_CLK_COMPOSITE,
  3096. .data = &mcbsp4_fck_data,
  3097. };
  3098. static struct ti_clk_gate gpio2_dbck_data = {
  3099. .parent = "per_32k_alwon_fck",
  3100. .bit_shift = 13,
  3101. .reg = 0x1000,
  3102. .module = TI_CLKM_CM,
  3103. };
  3104. static struct ti_clk gpio2_dbck = {
  3105. .name = "gpio2_dbck",
  3106. .clkdm_name = "per_clkdm",
  3107. .type = TI_CLK_GATE,
  3108. .data = &gpio2_dbck_data,
  3109. };
  3110. static struct ti_clk_gate usbtll_ick_data = {
  3111. .parent = "core_l4_ick",
  3112. .bit_shift = 2,
  3113. .reg = 0xa18,
  3114. .module = TI_CLKM_CM,
  3115. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3116. };
  3117. static struct ti_clk usbtll_ick = {
  3118. .name = "usbtll_ick",
  3119. .clkdm_name = "core_l4_clkdm",
  3120. .type = TI_CLK_GATE,
  3121. .data = &usbtll_ick_data,
  3122. };
  3123. static struct ti_clk_gate mcspi4_ick_data = {
  3124. .parent = "core_l4_ick",
  3125. .bit_shift = 21,
  3126. .reg = 0xa10,
  3127. .module = TI_CLKM_CM,
  3128. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3129. };
  3130. static struct ti_clk mcspi4_ick = {
  3131. .name = "mcspi4_ick",
  3132. .clkdm_name = "core_l4_clkdm",
  3133. .type = TI_CLK_GATE,
  3134. .data = &mcspi4_ick_data,
  3135. };
  3136. static struct ti_clk_gate dss_96m_fck_data = {
  3137. .parent = "omap_96m_fck",
  3138. .bit_shift = 2,
  3139. .reg = 0xe00,
  3140. .module = TI_CLKM_CM,
  3141. };
  3142. static struct ti_clk dss_96m_fck = {
  3143. .name = "dss_96m_fck",
  3144. .clkdm_name = "dss_clkdm",
  3145. .type = TI_CLK_GATE,
  3146. .data = &dss_96m_fck_data,
  3147. };
  3148. static struct ti_clk_divider rm_ick_data = {
  3149. .parent = "l4_ick",
  3150. .bit_shift = 1,
  3151. .max_div = 3,
  3152. .reg = 0xc40,
  3153. .module = TI_CLKM_CM,
  3154. .flags = CLKF_INDEX_STARTS_AT_ONE,
  3155. };
  3156. static struct ti_clk rm_ick = {
  3157. .name = "rm_ick",
  3158. .type = TI_CLK_DIVIDER,
  3159. .data = &rm_ick_data,
  3160. };
  3161. static struct ti_clk_gate hdq_ick_data = {
  3162. .parent = "core_l4_ick",
  3163. .bit_shift = 22,
  3164. .reg = 0xa10,
  3165. .module = TI_CLKM_CM,
  3166. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3167. };
  3168. static struct ti_clk hdq_ick = {
  3169. .name = "hdq_ick",
  3170. .clkdm_name = "core_l4_clkdm",
  3171. .type = TI_CLK_GATE,
  3172. .data = &hdq_ick_data,
  3173. };
  3174. static struct ti_clk_fixed_factor dpll3_x2_ck_data = {
  3175. .parent = "dpll3_ck",
  3176. .div = 1,
  3177. .mult = 2,
  3178. };
  3179. static struct ti_clk dpll3_x2_ck = {
  3180. .name = "dpll3_x2_ck",
  3181. .type = TI_CLK_FIXED_FACTOR,
  3182. .data = &dpll3_x2_ck_data,
  3183. };
  3184. static struct ti_clk_gate mad2d_ick_data = {
  3185. .parent = "l3_ick",
  3186. .bit_shift = 3,
  3187. .reg = 0xa18,
  3188. .module = TI_CLKM_CM,
  3189. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3190. };
  3191. static struct ti_clk mad2d_ick = {
  3192. .name = "mad2d_ick",
  3193. .clkdm_name = "d2d_clkdm",
  3194. .type = TI_CLK_GATE,
  3195. .data = &mad2d_ick_data,
  3196. };
  3197. static struct ti_clk_gate fshostusb_fck_data = {
  3198. .parent = "core_48m_fck",
  3199. .bit_shift = 5,
  3200. .reg = 0xa00,
  3201. .module = TI_CLKM_CM,
  3202. .flags = CLKF_WAIT,
  3203. };
  3204. static struct ti_clk fshostusb_fck = {
  3205. .name = "fshostusb_fck",
  3206. .clkdm_name = "core_l4_clkdm",
  3207. .type = TI_CLK_GATE,
  3208. .data = &fshostusb_fck_data,
  3209. };
  3210. static struct ti_clk_gate sr1_fck_data = {
  3211. .parent = "sys_ck",
  3212. .bit_shift = 6,
  3213. .reg = 0xc00,
  3214. .module = TI_CLKM_CM,
  3215. .flags = CLKF_WAIT,
  3216. };
  3217. static struct ti_clk sr1_fck = {
  3218. .name = "sr1_fck",
  3219. .clkdm_name = "wkup_clkdm",
  3220. .type = TI_CLK_GATE,
  3221. .data = &sr1_fck_data,
  3222. };
  3223. static struct ti_clk_gate des2_ick_data = {
  3224. .parent = "core_l4_ick",
  3225. .bit_shift = 26,
  3226. .reg = 0xa10,
  3227. .module = TI_CLKM_CM,
  3228. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3229. };
  3230. static struct ti_clk des2_ick = {
  3231. .name = "des2_ick",
  3232. .clkdm_name = "core_l4_clkdm",
  3233. .type = TI_CLK_GATE,
  3234. .data = &des2_ick_data,
  3235. };
  3236. static struct ti_clk_gate sdrc_ick_data = {
  3237. .parent = "core_l3_ick",
  3238. .bit_shift = 1,
  3239. .reg = 0xa10,
  3240. .module = TI_CLKM_CM,
  3241. .flags = CLKF_WAIT,
  3242. };
  3243. static struct ti_clk sdrc_ick = {
  3244. .name = "sdrc_ick",
  3245. .clkdm_name = "core_l3_clkdm",
  3246. .type = TI_CLK_GATE,
  3247. .data = &sdrc_ick_data,
  3248. };
  3249. static struct ti_clk_composite gpt4_fck_data = {
  3250. .mux = &gpt4_mux_fck_data,
  3251. .gate = &gpt4_gate_fck_data,
  3252. };
  3253. static struct ti_clk gpt4_fck = {
  3254. .name = "gpt4_fck",
  3255. .type = TI_CLK_COMPOSITE,
  3256. .data = &gpt4_fck_data,
  3257. };
  3258. static struct ti_clk_gate dpll4_m3x2_ck_omap36xx_data = {
  3259. .parent = "dpll4_m3x2_mul_ck",
  3260. .bit_shift = 0x1c,
  3261. .reg = 0xd00,
  3262. .module = TI_CLKM_CM,
  3263. .flags = CLKF_HSDIV | CLKF_SET_BIT_TO_DISABLE,
  3264. };
  3265. static struct ti_clk dpll4_m3x2_ck_omap36xx = {
  3266. .name = "dpll4_m3x2_ck",
  3267. .type = TI_CLK_GATE,
  3268. .data = &dpll4_m3x2_ck_omap36xx_data,
  3269. .patch = &dpll4_m3x2_ck,
  3270. };
  3271. static struct ti_clk_gate cpefuse_fck_data = {
  3272. .parent = "sys_ck",
  3273. .bit_shift = 0,
  3274. .reg = 0xa08,
  3275. .module = TI_CLKM_CM,
  3276. };
  3277. static struct ti_clk cpefuse_fck = {
  3278. .name = "cpefuse_fck",
  3279. .clkdm_name = "core_l4_clkdm",
  3280. .type = TI_CLK_GATE,
  3281. .data = &cpefuse_fck_data,
  3282. };
  3283. static struct ti_clk_gate mcspi3_ick_data = {
  3284. .parent = "core_l4_ick",
  3285. .bit_shift = 20,
  3286. .reg = 0xa10,
  3287. .module = TI_CLKM_CM,
  3288. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3289. };
  3290. static struct ti_clk mcspi3_ick = {
  3291. .name = "mcspi3_ick",
  3292. .clkdm_name = "core_l4_clkdm",
  3293. .type = TI_CLK_GATE,
  3294. .data = &mcspi3_ick_data,
  3295. };
  3296. static struct ti_clk_fixed_factor ssi_sst_fck_3430es2_data = {
  3297. .parent = "ssi_ssr_fck",
  3298. .div = 2,
  3299. .mult = 1,
  3300. };
  3301. static struct ti_clk ssi_sst_fck_3430es2 = {
  3302. .name = "ssi_sst_fck",
  3303. .type = TI_CLK_FIXED_FACTOR,
  3304. .data = &ssi_sst_fck_3430es2_data,
  3305. };
  3306. static struct ti_clk_gate gpio1_dbck_data = {
  3307. .parent = "wkup_32k_fck",
  3308. .bit_shift = 3,
  3309. .reg = 0xc00,
  3310. .module = TI_CLKM_CM,
  3311. };
  3312. static struct ti_clk gpio1_dbck = {
  3313. .name = "gpio1_dbck",
  3314. .clkdm_name = "wkup_clkdm",
  3315. .type = TI_CLK_GATE,
  3316. .data = &gpio1_dbck_data,
  3317. };
  3318. static struct ti_clk_gate gpt4_ick_data = {
  3319. .parent = "per_l4_ick",
  3320. .bit_shift = 5,
  3321. .reg = 0x1010,
  3322. .module = TI_CLKM_CM,
  3323. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3324. };
  3325. static struct ti_clk gpt4_ick = {
  3326. .name = "gpt4_ick",
  3327. .clkdm_name = "per_clkdm",
  3328. .type = TI_CLK_GATE,
  3329. .data = &gpt4_ick_data,
  3330. };
  3331. static struct ti_clk_gate gpt2_ick_data = {
  3332. .parent = "per_l4_ick",
  3333. .bit_shift = 3,
  3334. .reg = 0x1010,
  3335. .module = TI_CLKM_CM,
  3336. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3337. };
  3338. static struct ti_clk gpt2_ick = {
  3339. .name = "gpt2_ick",
  3340. .clkdm_name = "per_clkdm",
  3341. .type = TI_CLK_GATE,
  3342. .data = &gpt2_ick_data,
  3343. };
  3344. static struct ti_clk_gate mmchs1_fck_data = {
  3345. .parent = "core_96m_fck",
  3346. .bit_shift = 24,
  3347. .reg = 0xa00,
  3348. .module = TI_CLKM_CM,
  3349. .flags = CLKF_WAIT,
  3350. };
  3351. static struct ti_clk mmchs1_fck = {
  3352. .name = "mmchs1_fck",
  3353. .clkdm_name = "core_l4_clkdm",
  3354. .type = TI_CLK_GATE,
  3355. .data = &mmchs1_fck_data,
  3356. };
  3357. static struct ti_clk_fixed dummy_apb_pclk_data = {
  3358. .frequency = 0x0,
  3359. };
  3360. static struct ti_clk dummy_apb_pclk = {
  3361. .name = "dummy_apb_pclk",
  3362. .type = TI_CLK_FIXED,
  3363. .data = &dummy_apb_pclk_data,
  3364. };
  3365. static struct ti_clk_gate gpio6_dbck_data = {
  3366. .parent = "per_32k_alwon_fck",
  3367. .bit_shift = 17,
  3368. .reg = 0x1000,
  3369. .module = TI_CLKM_CM,
  3370. };
  3371. static struct ti_clk gpio6_dbck = {
  3372. .name = "gpio6_dbck",
  3373. .clkdm_name = "per_clkdm",
  3374. .type = TI_CLK_GATE,
  3375. .data = &gpio6_dbck_data,
  3376. };
  3377. static struct ti_clk_gate uart2_ick_data = {
  3378. .parent = "core_l4_ick",
  3379. .bit_shift = 14,
  3380. .reg = 0xa10,
  3381. .module = TI_CLKM_CM,
  3382. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3383. };
  3384. static struct ti_clk uart2_ick = {
  3385. .name = "uart2_ick",
  3386. .clkdm_name = "core_l4_clkdm",
  3387. .type = TI_CLK_GATE,
  3388. .data = &uart2_ick_data,
  3389. };
  3390. static struct ti_clk_fixed_factor dpll4_x2_ck_data = {
  3391. .parent = "dpll4_ck",
  3392. .div = 1,
  3393. .mult = 2,
  3394. };
  3395. static struct ti_clk dpll4_x2_ck = {
  3396. .name = "dpll4_x2_ck",
  3397. .type = TI_CLK_FIXED_FACTOR,
  3398. .data = &dpll4_x2_ck_data,
  3399. };
  3400. static struct ti_clk_gate gpt7_ick_data = {
  3401. .parent = "per_l4_ick",
  3402. .bit_shift = 8,
  3403. .reg = 0x1010,
  3404. .module = TI_CLKM_CM,
  3405. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3406. };
  3407. static struct ti_clk gpt7_ick = {
  3408. .name = "gpt7_ick",
  3409. .clkdm_name = "per_clkdm",
  3410. .type = TI_CLK_GATE,
  3411. .data = &gpt7_ick_data,
  3412. };
  3413. static struct ti_clk_gate dss_tv_fck_data = {
  3414. .parent = "omap_54m_fck",
  3415. .bit_shift = 2,
  3416. .reg = 0xe00,
  3417. .module = TI_CLKM_CM,
  3418. };
  3419. static struct ti_clk dss_tv_fck = {
  3420. .name = "dss_tv_fck",
  3421. .clkdm_name = "dss_clkdm",
  3422. .type = TI_CLK_GATE,
  3423. .data = &dss_tv_fck_data,
  3424. };
  3425. static struct ti_clk_gate mcbsp5_ick_data = {
  3426. .parent = "core_l4_ick",
  3427. .bit_shift = 10,
  3428. .reg = 0xa10,
  3429. .module = TI_CLKM_CM,
  3430. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3431. };
  3432. static struct ti_clk mcbsp5_ick = {
  3433. .name = "mcbsp5_ick",
  3434. .clkdm_name = "core_l4_clkdm",
  3435. .type = TI_CLK_GATE,
  3436. .data = &mcbsp5_ick_data,
  3437. };
  3438. static struct ti_clk_gate mcspi1_ick_data = {
  3439. .parent = "core_l4_ick",
  3440. .bit_shift = 18,
  3441. .reg = 0xa10,
  3442. .module = TI_CLKM_CM,
  3443. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3444. };
  3445. static struct ti_clk mcspi1_ick = {
  3446. .name = "mcspi1_ick",
  3447. .clkdm_name = "core_l4_clkdm",
  3448. .type = TI_CLK_GATE,
  3449. .data = &mcspi1_ick_data,
  3450. };
  3451. static struct ti_clk_gate d2d_26m_fck_data = {
  3452. .parent = "sys_ck",
  3453. .bit_shift = 3,
  3454. .reg = 0xa00,
  3455. .module = TI_CLKM_CM,
  3456. .flags = CLKF_WAIT,
  3457. };
  3458. static struct ti_clk d2d_26m_fck = {
  3459. .name = "d2d_26m_fck",
  3460. .clkdm_name = "d2d_clkdm",
  3461. .type = TI_CLK_GATE,
  3462. .data = &d2d_26m_fck_data,
  3463. };
  3464. static struct ti_clk_gate wdt3_ick_data = {
  3465. .parent = "per_l4_ick",
  3466. .bit_shift = 12,
  3467. .reg = 0x1010,
  3468. .module = TI_CLKM_CM,
  3469. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3470. };
  3471. static struct ti_clk wdt3_ick = {
  3472. .name = "wdt3_ick",
  3473. .clkdm_name = "per_clkdm",
  3474. .type = TI_CLK_GATE,
  3475. .data = &wdt3_ick_data,
  3476. };
  3477. static struct ti_clk_divider pclkx2_fck_data = {
  3478. .parent = "emu_src_ck",
  3479. .bit_shift = 6,
  3480. .max_div = 3,
  3481. .reg = 0x1140,
  3482. .module = TI_CLKM_CM,
  3483. .flags = CLKF_INDEX_STARTS_AT_ONE,
  3484. };
  3485. static struct ti_clk pclkx2_fck = {
  3486. .name = "pclkx2_fck",
  3487. .type = TI_CLK_DIVIDER,
  3488. .data = &pclkx2_fck_data,
  3489. };
  3490. static struct ti_clk_gate sha12_ick_data = {
  3491. .parent = "core_l4_ick",
  3492. .bit_shift = 27,
  3493. .reg = 0xa10,
  3494. .module = TI_CLKM_CM,
  3495. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3496. };
  3497. static struct ti_clk sha12_ick = {
  3498. .name = "sha12_ick",
  3499. .clkdm_name = "core_l4_clkdm",
  3500. .type = TI_CLK_GATE,
  3501. .data = &sha12_ick_data,
  3502. };
  3503. static struct ti_clk_gate emac_fck_data = {
  3504. .parent = "rmii_ck",
  3505. .bit_shift = 9,
  3506. .reg = 0x59c,
  3507. .module = TI_CLKM_SCRM,
  3508. };
  3509. static struct ti_clk emac_fck = {
  3510. .name = "emac_fck",
  3511. .type = TI_CLK_GATE,
  3512. .data = &emac_fck_data,
  3513. };
  3514. static struct ti_clk_composite gpt10_fck_data = {
  3515. .mux = &gpt10_mux_fck_data,
  3516. .gate = &gpt10_gate_fck_data,
  3517. };
  3518. static struct ti_clk gpt10_fck = {
  3519. .name = "gpt10_fck",
  3520. .type = TI_CLK_COMPOSITE,
  3521. .data = &gpt10_fck_data,
  3522. };
  3523. static struct ti_clk_gate wdt2_fck_data = {
  3524. .parent = "wkup_32k_fck",
  3525. .bit_shift = 5,
  3526. .reg = 0xc00,
  3527. .module = TI_CLKM_CM,
  3528. .flags = CLKF_WAIT,
  3529. };
  3530. static struct ti_clk wdt2_fck = {
  3531. .name = "wdt2_fck",
  3532. .clkdm_name = "wkup_clkdm",
  3533. .type = TI_CLK_GATE,
  3534. .data = &wdt2_fck_data,
  3535. };
  3536. static struct ti_clk_gate cam_ick_data = {
  3537. .parent = "l4_ick",
  3538. .bit_shift = 0,
  3539. .reg = 0xf10,
  3540. .module = TI_CLKM_CM,
  3541. .flags = CLKF_OMAP3 | CLKF_NO_WAIT | CLKF_INTERFACE,
  3542. };
  3543. static struct ti_clk cam_ick = {
  3544. .name = "cam_ick",
  3545. .clkdm_name = "cam_clkdm",
  3546. .type = TI_CLK_GATE,
  3547. .data = &cam_ick_data,
  3548. };
  3549. static struct ti_clk_gate ssi_ick_3430es2_data = {
  3550. .parent = "ssi_l4_ick",
  3551. .bit_shift = 0,
  3552. .reg = 0xa10,
  3553. .module = TI_CLKM_CM,
  3554. .flags = CLKF_SSI | CLKF_OMAP3 | CLKF_INTERFACE,
  3555. };
  3556. static struct ti_clk ssi_ick_3430es2 = {
  3557. .name = "ssi_ick",
  3558. .clkdm_name = "core_l4_clkdm",
  3559. .type = TI_CLK_GATE,
  3560. .data = &ssi_ick_3430es2_data,
  3561. };
  3562. static struct ti_clk_gate gpio4_ick_data = {
  3563. .parent = "per_l4_ick",
  3564. .bit_shift = 15,
  3565. .reg = 0x1010,
  3566. .module = TI_CLKM_CM,
  3567. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3568. };
  3569. static struct ti_clk gpio4_ick = {
  3570. .name = "gpio4_ick",
  3571. .clkdm_name = "per_clkdm",
  3572. .type = TI_CLK_GATE,
  3573. .data = &gpio4_ick_data,
  3574. };
  3575. static struct ti_clk_gate wdt1_ick_data = {
  3576. .parent = "wkup_l4_ick",
  3577. .bit_shift = 4,
  3578. .reg = 0xc10,
  3579. .module = TI_CLKM_CM,
  3580. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3581. };
  3582. static struct ti_clk wdt1_ick = {
  3583. .name = "wdt1_ick",
  3584. .clkdm_name = "wkup_clkdm",
  3585. .type = TI_CLK_GATE,
  3586. .data = &wdt1_ick_data,
  3587. };
  3588. static struct ti_clk_gate rng_ick_data = {
  3589. .parent = "security_l4_ick2",
  3590. .bit_shift = 2,
  3591. .reg = 0xa14,
  3592. .module = TI_CLKM_CM,
  3593. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3594. };
  3595. static struct ti_clk rng_ick = {
  3596. .name = "rng_ick",
  3597. .type = TI_CLK_GATE,
  3598. .data = &rng_ick_data,
  3599. };
  3600. static struct ti_clk_gate icr_ick_data = {
  3601. .parent = "core_l4_ick",
  3602. .bit_shift = 29,
  3603. .reg = 0xa10,
  3604. .module = TI_CLKM_CM,
  3605. .flags = CLKF_OMAP3 | CLKF_INTERFACE,
  3606. };
  3607. static struct ti_clk icr_ick = {
  3608. .name = "icr_ick",
  3609. .clkdm_name = "core_l4_clkdm",
  3610. .type = TI_CLK_GATE,
  3611. .data = &icr_ick_data,
  3612. };
  3613. static struct ti_clk_gate sgx_ick_data = {
  3614. .parent = "l3_ick",
  3615. .bit_shift = 0,
  3616. .reg = 0xb10,
  3617. .module = TI_CLKM_CM,
  3618. .flags = CLKF_WAIT,
  3619. };
  3620. static struct ti_clk sgx_ick = {
  3621. .name = "sgx_ick",
  3622. .clkdm_name = "sgx_clkdm",
  3623. .type = TI_CLK_GATE,
  3624. .data = &sgx_ick_data,
  3625. };
  3626. static struct ti_clk_divider sys_clkout2_data = {
  3627. .parent = "clkout2_src_ck",
  3628. .bit_shift = 3,
  3629. .max_div = 64,
  3630. .reg = 0xd70,
  3631. .module = TI_CLKM_CM,
  3632. .flags = CLKF_INDEX_POWER_OF_TWO,
  3633. };
  3634. static struct ti_clk sys_clkout2 = {
  3635. .name = "sys_clkout2",
  3636. .type = TI_CLK_DIVIDER,
  3637. .data = &sys_clkout2_data,
  3638. };
  3639. static struct ti_clk_alias omap34xx_omap36xx_clks[] = {
  3640. CLK(NULL, "security_l4_ick2", &security_l4_ick2),
  3641. CLK(NULL, "aes1_ick", &aes1_ick),
  3642. CLK("omap_rng", "ick", &rng_ick),
  3643. CLK("omap3-rom-rng", "ick", &rng_ick),
  3644. CLK(NULL, "sha11_ick", &sha11_ick),
  3645. CLK(NULL, "des1_ick", &des1_ick),
  3646. CLK(NULL, "cam_mclk", &cam_mclk),
  3647. CLK(NULL, "cam_ick", &cam_ick),
  3648. CLK(NULL, "csi2_96m_fck", &csi2_96m_fck),
  3649. CLK(NULL, "security_l3_ick", &security_l3_ick),
  3650. CLK(NULL, "pka_ick", &pka_ick),
  3651. CLK(NULL, "icr_ick", &icr_ick),
  3652. CLK(NULL, "des2_ick", &des2_ick),
  3653. CLK(NULL, "mspro_ick", &mspro_ick),
  3654. CLK(NULL, "mailboxes_ick", &mailboxes_ick),
  3655. CLK(NULL, "ssi_l4_ick", &ssi_l4_ick),
  3656. CLK(NULL, "sr1_fck", &sr1_fck),
  3657. CLK(NULL, "sr2_fck", &sr2_fck),
  3658. CLK(NULL, "sr_l4_ick", &sr_l4_ick),
  3659. CLK(NULL, "dpll2_fck", &dpll2_fck),
  3660. CLK(NULL, "dpll2_ck", &dpll2_ck),
  3661. CLK(NULL, "dpll2_m2_ck", &dpll2_m2_ck),
  3662. CLK(NULL, "iva2_ck", &iva2_ck),
  3663. CLK(NULL, "modem_fck", &modem_fck),
  3664. CLK(NULL, "sad2d_ick", &sad2d_ick),
  3665. CLK(NULL, "mad2d_ick", &mad2d_ick),
  3666. CLK(NULL, "mspro_fck", &mspro_fck),
  3667. { NULL },
  3668. };
  3669. static struct ti_clk_alias omap36xx_omap3430es2plus_clks[] = {
  3670. CLK(NULL, "ssi_ssr_fck", &ssi_ssr_fck_3430es2),
  3671. CLK(NULL, "ssi_sst_fck", &ssi_sst_fck_3430es2),
  3672. CLK("musb-omap2430", "ick", &hsotgusb_ick_3430es2),
  3673. CLK(NULL, "hsotgusb_ick", &hsotgusb_ick_3430es2),
  3674. CLK(NULL, "ssi_ick", &ssi_ick_3430es2),
  3675. CLK(NULL, "sys_d2_ck", &sys_d2_ck),
  3676. CLK(NULL, "omap_96m_d2_fck", &omap_96m_d2_fck),
  3677. CLK(NULL, "omap_96m_d4_fck", &omap_96m_d4_fck),
  3678. CLK(NULL, "omap_96m_d8_fck", &omap_96m_d8_fck),
  3679. CLK(NULL, "omap_96m_d10_fck", &omap_96m_d10_fck),
  3680. CLK(NULL, "dpll5_m2_d4_ck", &dpll5_m2_d4_ck),
  3681. CLK(NULL, "dpll5_m2_d8_ck", &dpll5_m2_d8_ck),
  3682. CLK(NULL, "dpll5_m2_d16_ck", &dpll5_m2_d16_ck),
  3683. CLK(NULL, "dpll5_m2_d20_ck", &dpll5_m2_d20_ck),
  3684. CLK(NULL, "usim_fck", &usim_fck),
  3685. CLK(NULL, "usim_ick", &usim_ick),
  3686. { NULL },
  3687. };
  3688. static struct ti_clk_alias omap3xxx_clks[] = {
  3689. CLK(NULL, "apb_pclk", &dummy_apb_pclk),
  3690. CLK(NULL, "omap_32k_fck", &omap_32k_fck),
  3691. CLK(NULL, "virt_12m_ck", &virt_12m_ck),
  3692. CLK(NULL, "virt_13m_ck", &virt_13m_ck),
  3693. CLK(NULL, "virt_19200000_ck", &virt_19200000_ck),
  3694. CLK(NULL, "virt_26000000_ck", &virt_26000000_ck),
  3695. CLK(NULL, "virt_38_4m_ck", &virt_38_4m_ck),
  3696. CLK(NULL, "virt_16_8m_ck", &virt_16_8m_ck),
  3697. CLK(NULL, "osc_sys_ck", &osc_sys_ck),
  3698. CLK("twl", "fck", &osc_sys_ck),
  3699. CLK(NULL, "sys_ck", &sys_ck),
  3700. CLK(NULL, "timer_sys_ck", &sys_ck),
  3701. CLK(NULL, "dpll4_ck", &dpll4_ck),
  3702. CLK(NULL, "dpll4_m2_ck", &dpll4_m2_ck),
  3703. CLK(NULL, "dpll4_m2x2_mul_ck", &dpll4_m2x2_mul_ck),
  3704. CLK(NULL, "dpll4_m2x2_ck", &dpll4_m2x2_ck),
  3705. CLK(NULL, "omap_96m_alwon_fck", &omap_96m_alwon_fck),
  3706. CLK(NULL, "dpll3_ck", &dpll3_ck),
  3707. CLK(NULL, "dpll3_m3_ck", &dpll3_m3_ck),
  3708. CLK(NULL, "dpll3_m3x2_mul_ck", &dpll3_m3x2_mul_ck),
  3709. CLK(NULL, "dpll3_m3x2_ck", &dpll3_m3x2_ck),
  3710. CLK("etb", "emu_core_alwon_ck", &emu_core_alwon_ck),
  3711. CLK(NULL, "sys_altclk", &sys_altclk),
  3712. CLK(NULL, "sys_clkout1", &sys_clkout1),
  3713. CLK(NULL, "dpll3_m2_ck", &dpll3_m2_ck),
  3714. CLK(NULL, "core_ck", &core_ck),
  3715. CLK(NULL, "dpll1_fck", &dpll1_fck),
  3716. CLK(NULL, "dpll1_ck", &dpll1_ck),
  3717. CLK(NULL, "cpufreq_ck", &dpll1_ck),
  3718. CLK(NULL, "dpll1_x2_ck", &dpll1_x2_ck),
  3719. CLK(NULL, "dpll1_x2m2_ck", &dpll1_x2m2_ck),
  3720. CLK(NULL, "dpll3_x2_ck", &dpll3_x2_ck),
  3721. CLK(NULL, "dpll3_m2x2_ck", &dpll3_m2x2_ck),
  3722. CLK(NULL, "dpll4_x2_ck", &dpll4_x2_ck),
  3723. CLK(NULL, "cm_96m_fck", &cm_96m_fck),
  3724. CLK(NULL, "omap_96m_fck", &omap_96m_fck),
  3725. CLK(NULL, "dpll4_m3_ck", &dpll4_m3_ck),
  3726. CLK(NULL, "dpll4_m3x2_mul_ck", &dpll4_m3x2_mul_ck),
  3727. CLK(NULL, "dpll4_m3x2_ck", &dpll4_m3x2_ck),
  3728. CLK(NULL, "omap_54m_fck", &omap_54m_fck),
  3729. CLK(NULL, "cm_96m_d2_fck", &cm_96m_d2_fck),
  3730. CLK(NULL, "omap_48m_fck", &omap_48m_fck),
  3731. CLK(NULL, "omap_12m_fck", &omap_12m_fck),
  3732. CLK(NULL, "dpll4_m4_ck", &dpll4_m4_ck),
  3733. CLK(NULL, "dpll4_m4x2_mul_ck", &dpll4_m4x2_mul_ck),
  3734. CLK(NULL, "dpll4_m4x2_ck", &dpll4_m4x2_ck),
  3735. CLK(NULL, "dpll4_m5_ck", &dpll4_m5_ck),
  3736. CLK(NULL, "dpll4_m5x2_mul_ck", &dpll4_m5x2_mul_ck),
  3737. CLK(NULL, "dpll4_m5x2_ck", &dpll4_m5x2_ck),
  3738. CLK(NULL, "dpll4_m6_ck", &dpll4_m6_ck),
  3739. CLK(NULL, "dpll4_m6x2_mul_ck", &dpll4_m6x2_mul_ck),
  3740. CLK(NULL, "dpll4_m6x2_ck", &dpll4_m6x2_ck),
  3741. CLK("etb", "emu_per_alwon_ck", &emu_per_alwon_ck),
  3742. CLK(NULL, "clkout2_src_ck", &clkout2_src_ck),
  3743. CLK(NULL, "sys_clkout2", &sys_clkout2),
  3744. CLK(NULL, "corex2_fck", &corex2_fck),
  3745. CLK(NULL, "mpu_ck", &mpu_ck),
  3746. CLK(NULL, "arm_fck", &arm_fck),
  3747. CLK("etb", "emu_mpu_alwon_ck", &emu_mpu_alwon_ck),
  3748. CLK(NULL, "l3_ick", &l3_ick),
  3749. CLK(NULL, "l4_ick", &l4_ick),
  3750. CLK(NULL, "rm_ick", &rm_ick),
  3751. CLK(NULL, "timer_32k_ck", &omap_32k_fck),
  3752. CLK(NULL, "gpt10_fck", &gpt10_fck),
  3753. CLK(NULL, "gpt11_fck", &gpt11_fck),
  3754. CLK(NULL, "core_96m_fck", &core_96m_fck),
  3755. CLK(NULL, "mmchs2_fck", &mmchs2_fck),
  3756. CLK(NULL, "mmchs1_fck", &mmchs1_fck),
  3757. CLK(NULL, "i2c3_fck", &i2c3_fck),
  3758. CLK(NULL, "i2c2_fck", &i2c2_fck),
  3759. CLK(NULL, "i2c1_fck", &i2c1_fck),
  3760. CLK(NULL, "core_48m_fck", &core_48m_fck),
  3761. CLK(NULL, "mcspi4_fck", &mcspi4_fck),
  3762. CLK(NULL, "mcspi3_fck", &mcspi3_fck),
  3763. CLK(NULL, "mcspi2_fck", &mcspi2_fck),
  3764. CLK(NULL, "mcspi1_fck", &mcspi1_fck),
  3765. CLK(NULL, "uart2_fck", &uart2_fck),
  3766. CLK(NULL, "uart1_fck", &uart1_fck),
  3767. CLK(NULL, "core_12m_fck", &core_12m_fck),
  3768. CLK("omap_hdq.0", "fck", &hdq_fck),
  3769. CLK(NULL, "hdq_fck", &hdq_fck),
  3770. CLK(NULL, "core_l3_ick", &core_l3_ick),
  3771. CLK(NULL, "sdrc_ick", &sdrc_ick),
  3772. CLK(NULL, "gpmc_fck", &gpmc_fck),
  3773. CLK(NULL, "core_l4_ick", &core_l4_ick),
  3774. CLK("omap_hsmmc.1", "ick", &mmchs2_ick),
  3775. CLK("omap_hsmmc.0", "ick", &mmchs1_ick),
  3776. CLK(NULL, "mmchs2_ick", &mmchs2_ick),
  3777. CLK(NULL, "mmchs1_ick", &mmchs1_ick),
  3778. CLK("omap_hdq.0", "ick", &hdq_ick),
  3779. CLK(NULL, "hdq_ick", &hdq_ick),
  3780. CLK("omap2_mcspi.4", "ick", &mcspi4_ick),
  3781. CLK("omap2_mcspi.3", "ick", &mcspi3_ick),
  3782. CLK("omap2_mcspi.2", "ick", &mcspi2_ick),
  3783. CLK("omap2_mcspi.1", "ick", &mcspi1_ick),
  3784. CLK(NULL, "mcspi4_ick", &mcspi4_ick),
  3785. CLK(NULL, "mcspi3_ick", &mcspi3_ick),
  3786. CLK(NULL, "mcspi2_ick", &mcspi2_ick),
  3787. CLK(NULL, "mcspi1_ick", &mcspi1_ick),
  3788. CLK("omap_i2c.3", "ick", &i2c3_ick),
  3789. CLK("omap_i2c.2", "ick", &i2c2_ick),
  3790. CLK("omap_i2c.1", "ick", &i2c1_ick),
  3791. CLK(NULL, "i2c3_ick", &i2c3_ick),
  3792. CLK(NULL, "i2c2_ick", &i2c2_ick),
  3793. CLK(NULL, "i2c1_ick", &i2c1_ick),
  3794. CLK(NULL, "uart2_ick", &uart2_ick),
  3795. CLK(NULL, "uart1_ick", &uart1_ick),
  3796. CLK(NULL, "gpt11_ick", &gpt11_ick),
  3797. CLK(NULL, "gpt10_ick", &gpt10_ick),
  3798. CLK(NULL, "mcbsp5_ick", &mcbsp5_ick),
  3799. CLK(NULL, "mcbsp1_ick", &mcbsp1_ick),
  3800. CLK(NULL, "omapctrl_ick", &omapctrl_ick),
  3801. CLK(NULL, "dss_tv_fck", &dss_tv_fck),
  3802. CLK(NULL, "dss_96m_fck", &dss_96m_fck),
  3803. CLK(NULL, "dss2_alwon_fck", &dss2_alwon_fck),
  3804. CLK(NULL, "init_60m_fclk", &dummy_ck),
  3805. CLK(NULL, "gpt1_fck", &gpt1_fck),
  3806. CLK(NULL, "aes2_ick", &aes2_ick),
  3807. CLK(NULL, "wkup_32k_fck", &wkup_32k_fck),
  3808. CLK(NULL, "gpio1_dbck", &gpio1_dbck),
  3809. CLK(NULL, "sha12_ick", &sha12_ick),
  3810. CLK(NULL, "wdt2_fck", &wdt2_fck),
  3811. CLK(NULL, "wkup_l4_ick", &wkup_l4_ick),
  3812. CLK("omap_wdt", "ick", &wdt2_ick),
  3813. CLK(NULL, "wdt2_ick", &wdt2_ick),
  3814. CLK(NULL, "wdt1_ick", &wdt1_ick),
  3815. CLK(NULL, "gpio1_ick", &gpio1_ick),
  3816. CLK(NULL, "omap_32ksync_ick", &omap_32ksync_ick),
  3817. CLK(NULL, "gpt12_ick", &gpt12_ick),
  3818. CLK(NULL, "gpt1_ick", &gpt1_ick),
  3819. CLK(NULL, "per_96m_fck", &per_96m_fck),
  3820. CLK(NULL, "per_48m_fck", &per_48m_fck),
  3821. CLK(NULL, "uart3_fck", &uart3_fck),
  3822. CLK(NULL, "gpt2_fck", &gpt2_fck),
  3823. CLK(NULL, "gpt3_fck", &gpt3_fck),
  3824. CLK(NULL, "gpt4_fck", &gpt4_fck),
  3825. CLK(NULL, "gpt5_fck", &gpt5_fck),
  3826. CLK(NULL, "gpt6_fck", &gpt6_fck),
  3827. CLK(NULL, "gpt7_fck", &gpt7_fck),
  3828. CLK(NULL, "gpt8_fck", &gpt8_fck),
  3829. CLK(NULL, "gpt9_fck", &gpt9_fck),
  3830. CLK(NULL, "per_32k_alwon_fck", &per_32k_alwon_fck),
  3831. CLK(NULL, "gpio6_dbck", &gpio6_dbck),
  3832. CLK(NULL, "gpio5_dbck", &gpio5_dbck),
  3833. CLK(NULL, "gpio4_dbck", &gpio4_dbck),
  3834. CLK(NULL, "gpio3_dbck", &gpio3_dbck),
  3835. CLK(NULL, "gpio2_dbck", &gpio2_dbck),
  3836. CLK(NULL, "wdt3_fck", &wdt3_fck),
  3837. CLK(NULL, "per_l4_ick", &per_l4_ick),
  3838. CLK(NULL, "gpio6_ick", &gpio6_ick),
  3839. CLK(NULL, "gpio5_ick", &gpio5_ick),
  3840. CLK(NULL, "gpio4_ick", &gpio4_ick),
  3841. CLK(NULL, "gpio3_ick", &gpio3_ick),
  3842. CLK(NULL, "gpio2_ick", &gpio2_ick),
  3843. CLK(NULL, "wdt3_ick", &wdt3_ick),
  3844. CLK(NULL, "uart3_ick", &uart3_ick),
  3845. CLK(NULL, "uart4_ick", &uart4_ick),
  3846. CLK(NULL, "gpt9_ick", &gpt9_ick),
  3847. CLK(NULL, "gpt8_ick", &gpt8_ick),
  3848. CLK(NULL, "gpt7_ick", &gpt7_ick),
  3849. CLK(NULL, "gpt6_ick", &gpt6_ick),
  3850. CLK(NULL, "gpt5_ick", &gpt5_ick),
  3851. CLK(NULL, "gpt4_ick", &gpt4_ick),
  3852. CLK(NULL, "gpt3_ick", &gpt3_ick),
  3853. CLK(NULL, "gpt2_ick", &gpt2_ick),
  3854. CLK(NULL, "mcbsp_clks", &mcbsp_clks),
  3855. CLK("omap-mcbsp.1", "ick", &mcbsp1_ick),
  3856. CLK("omap-mcbsp.2", "ick", &mcbsp2_ick),
  3857. CLK("omap-mcbsp.3", "ick", &mcbsp3_ick),
  3858. CLK("omap-mcbsp.4", "ick", &mcbsp4_ick),
  3859. CLK("omap-mcbsp.5", "ick", &mcbsp5_ick),
  3860. CLK(NULL, "mcbsp1_ick", &mcbsp1_ick),
  3861. CLK(NULL, "mcbsp2_ick", &mcbsp2_ick),
  3862. CLK(NULL, "mcbsp3_ick", &mcbsp3_ick),
  3863. CLK(NULL, "mcbsp4_ick", &mcbsp4_ick),
  3864. CLK(NULL, "mcbsp5_ick", &mcbsp5_ick),
  3865. CLK(NULL, "mcbsp1_fck", &mcbsp1_fck),
  3866. CLK(NULL, "mcbsp2_fck", &mcbsp2_fck),
  3867. CLK(NULL, "mcbsp3_fck", &mcbsp3_fck),
  3868. CLK(NULL, "mcbsp4_fck", &mcbsp4_fck),
  3869. CLK(NULL, "mcbsp5_fck", &mcbsp5_fck),
  3870. CLK(NULL, "emu_src_mux_ck", &emu_src_mux_ck),
  3871. CLK("etb", "emu_src_ck", &emu_src_ck),
  3872. CLK(NULL, "emu_src_mux_ck", &emu_src_mux_ck),
  3873. CLK(NULL, "emu_src_ck", &emu_src_ck),
  3874. CLK(NULL, "pclk_fck", &pclk_fck),
  3875. CLK(NULL, "pclkx2_fck", &pclkx2_fck),
  3876. CLK(NULL, "atclk_fck", &atclk_fck),
  3877. CLK(NULL, "traceclk_src_fck", &traceclk_src_fck),
  3878. CLK(NULL, "traceclk_fck", &traceclk_fck),
  3879. CLK(NULL, "secure_32k_fck", &secure_32k_fck),
  3880. CLK(NULL, "gpt12_fck", &gpt12_fck),
  3881. CLK(NULL, "wdt1_fck", &wdt1_fck),
  3882. { NULL },
  3883. };
  3884. static struct ti_clk_alias omap36xx_am35xx_omap3430es2plus_clks[] = {
  3885. CLK(NULL, "dpll5_ck", &dpll5_ck),
  3886. CLK(NULL, "dpll5_m2_ck", &dpll5_m2_ck),
  3887. CLK(NULL, "core_d3_ck", &core_d3_ck),
  3888. CLK(NULL, "core_d4_ck", &core_d4_ck),
  3889. CLK(NULL, "core_d6_ck", &core_d6_ck),
  3890. CLK(NULL, "omap_192m_alwon_fck", &omap_192m_alwon_fck),
  3891. CLK(NULL, "core_d2_ck", &core_d2_ck),
  3892. CLK(NULL, "corex2_d3_fck", &corex2_d3_fck),
  3893. CLK(NULL, "corex2_d5_fck", &corex2_d5_fck),
  3894. CLK(NULL, "sgx_fck", &sgx_fck),
  3895. CLK(NULL, "sgx_ick", &sgx_ick),
  3896. CLK(NULL, "cpefuse_fck", &cpefuse_fck),
  3897. CLK(NULL, "ts_fck", &ts_fck),
  3898. CLK(NULL, "usbtll_fck", &usbtll_fck),
  3899. CLK(NULL, "usbtll_ick", &usbtll_ick),
  3900. CLK("omap_hsmmc.2", "ick", &mmchs3_ick),
  3901. CLK(NULL, "mmchs3_ick", &mmchs3_ick),
  3902. CLK(NULL, "mmchs3_fck", &mmchs3_fck),
  3903. CLK(NULL, "dss1_alwon_fck", &dss1_alwon_fck_3430es2),
  3904. CLK("omapdss_dss", "ick", &dss_ick_3430es2),
  3905. CLK(NULL, "dss_ick", &dss_ick_3430es2),
  3906. CLK(NULL, "usbhost_120m_fck", &usbhost_120m_fck),
  3907. CLK(NULL, "usbhost_48m_fck", &usbhost_48m_fck),
  3908. CLK(NULL, "usbhost_ick", &usbhost_ick),
  3909. { NULL },
  3910. };
  3911. static struct ti_clk_alias omap3430es1_clks[] = {
  3912. CLK(NULL, "gfx_l3_ck", &gfx_l3_ck),
  3913. CLK(NULL, "gfx_l3_fck", &gfx_l3_fck),
  3914. CLK(NULL, "gfx_l3_ick", &gfx_l3_ick),
  3915. CLK(NULL, "gfx_cg1_ck", &gfx_cg1_ck),
  3916. CLK(NULL, "gfx_cg2_ck", &gfx_cg2_ck),
  3917. CLK(NULL, "d2d_26m_fck", &d2d_26m_fck),
  3918. CLK(NULL, "fshostusb_fck", &fshostusb_fck),
  3919. CLK(NULL, "ssi_ssr_fck", &ssi_ssr_fck_3430es1),
  3920. CLK(NULL, "ssi_sst_fck", &ssi_sst_fck_3430es1),
  3921. CLK("musb-omap2430", "ick", &hsotgusb_ick_3430es1),
  3922. CLK(NULL, "hsotgusb_ick", &hsotgusb_ick_3430es1),
  3923. CLK(NULL, "fac_ick", &fac_ick),
  3924. CLK(NULL, "ssi_ick", &ssi_ick_3430es1),
  3925. CLK(NULL, "usb_l4_ick", &usb_l4_ick),
  3926. CLK(NULL, "dss1_alwon_fck", &dss1_alwon_fck_3430es1),
  3927. CLK("omapdss_dss", "ick", &dss_ick_3430es1),
  3928. CLK(NULL, "dss_ick", &dss_ick_3430es1),
  3929. { NULL },
  3930. };
  3931. static struct ti_clk_alias omap36xx_clks[] = {
  3932. CLK(NULL, "uart4_fck", &uart4_fck),
  3933. { NULL },
  3934. };
  3935. static struct ti_clk_alias am35xx_clks[] = {
  3936. CLK(NULL, "ipss_ick", &ipss_ick),
  3937. CLK(NULL, "rmii_ck", &rmii_ck),
  3938. CLK(NULL, "pclk_ck", &pclk_ck),
  3939. CLK(NULL, "emac_ick", &emac_ick),
  3940. CLK(NULL, "emac_fck", &emac_fck),
  3941. CLK("davinci_emac.0", NULL, &emac_ick),
  3942. CLK("davinci_mdio.0", NULL, &emac_fck),
  3943. CLK("vpfe-capture", "master", &vpfe_ick),
  3944. CLK("vpfe-capture", "slave", &vpfe_fck),
  3945. CLK(NULL, "hsotgusb_ick", &hsotgusb_ick_am35xx),
  3946. CLK(NULL, "hsotgusb_fck", &hsotgusb_fck_am35xx),
  3947. CLK(NULL, "hecc_ck", &hecc_ck),
  3948. CLK(NULL, "uart4_ick", &uart4_ick_am35xx),
  3949. CLK(NULL, "uart4_fck", &uart4_fck_am35xx),
  3950. { NULL },
  3951. };
  3952. static struct ti_clk *omap36xx_clk_patches[] = {
  3953. &dpll4_m3x2_ck_omap36xx,
  3954. &dpll3_m3x2_ck_omap36xx,
  3955. &dpll4_m6x2_ck_omap36xx,
  3956. &dpll4_m2x2_ck_omap36xx,
  3957. &dpll4_m5x2_ck_omap36xx,
  3958. &dpll4_ck_omap36xx,
  3959. NULL,
  3960. };
  3961. static const char *enable_init_clks[] = {
  3962. "sdrc_ick",
  3963. "gpmc_fck",
  3964. "omapctrl_ick",
  3965. };
  3966. static void __init omap3_clk_legacy_common_init(void)
  3967. {
  3968. omap2_clk_disable_autoidle_all();
  3969. omap2_clk_enable_init_clocks(enable_init_clks,
  3970. ARRAY_SIZE(enable_init_clks));
  3971. pr_info("Clocking rate (Crystal/Core/MPU): %ld.%01ld/%ld/%ld MHz\n",
  3972. (clk_get_rate(osc_sys_ck.clk) / 1000000),
  3973. (clk_get_rate(osc_sys_ck.clk) / 100000) % 10,
  3974. (clk_get_rate(core_ck.clk) / 1000000),
  3975. (clk_get_rate(arm_fck.clk) / 1000000));
  3976. }
  3977. int __init omap3430es1_clk_legacy_init(void)
  3978. {
  3979. int r;
  3980. r = ti_clk_register_legacy_clks(omap3430es1_clks);
  3981. r |= ti_clk_register_legacy_clks(omap34xx_omap36xx_clks);
  3982. r |= ti_clk_register_legacy_clks(omap3xxx_clks);
  3983. omap3_clk_legacy_common_init();
  3984. return r;
  3985. }
  3986. int __init omap3430_clk_legacy_init(void)
  3987. {
  3988. int r;
  3989. r = ti_clk_register_legacy_clks(omap34xx_omap36xx_clks);
  3990. r |= ti_clk_register_legacy_clks(omap36xx_omap3430es2plus_clks);
  3991. r |= ti_clk_register_legacy_clks(omap36xx_am35xx_omap3430es2plus_clks);
  3992. r |= ti_clk_register_legacy_clks(omap3xxx_clks);
  3993. omap3_clk_legacy_common_init();
  3994. omap3_clk_lock_dpll5();
  3995. return r;
  3996. }
  3997. int __init omap36xx_clk_legacy_init(void)
  3998. {
  3999. int r;
  4000. ti_clk_patch_legacy_clks(omap36xx_clk_patches);
  4001. r = ti_clk_register_legacy_clks(omap36xx_clks);
  4002. r |= ti_clk_register_legacy_clks(omap36xx_omap3430es2plus_clks);
  4003. r |= ti_clk_register_legacy_clks(omap34xx_omap36xx_clks);
  4004. r |= ti_clk_register_legacy_clks(omap36xx_am35xx_omap3430es2plus_clks);
  4005. r |= ti_clk_register_legacy_clks(omap3xxx_clks);
  4006. omap3_clk_legacy_common_init();
  4007. omap3_clk_lock_dpll5();
  4008. return r;
  4009. }
  4010. int __init am35xx_clk_legacy_init(void)
  4011. {
  4012. int r;
  4013. r = ti_clk_register_legacy_clks(am35xx_clks);
  4014. r |= ti_clk_register_legacy_clks(omap36xx_am35xx_omap3430es2plus_clks);
  4015. r |= ti_clk_register_legacy_clks(omap3xxx_clks);
  4016. omap3_clk_legacy_common_init();
  4017. omap3_clk_lock_dpll5();
  4018. return r;
  4019. }