File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change 62
62
#define MPMU_UART_PLL 0x14
63
63
#define MPMU_PLL2_CR 0x34
64
64
65
+ enum mmp2_clk_model {
66
+ CLK_MODEL_MMP2 ,
67
+ CLK_MODEL_MMP3 ,
68
+ };
69
+
65
70
struct mmp2_clk_unit {
66
71
struct mmp_clk_unit unit ;
72
+ enum mmp2_clk_model model ;
67
73
void __iomem * mpmu_base ;
68
74
void __iomem * apmu_base ;
69
75
void __iomem * apbc_base ;
@@ -326,6 +332,11 @@ static void __init mmp2_clk_init(struct device_node *np)
326
332
if (!pxa_unit )
327
333
return ;
328
334
335
+ if (of_device_is_compatible (np , "marvell,mmp3-clock" ))
336
+ pxa_unit -> model = CLK_MODEL_MMP3 ;
337
+ else
338
+ pxa_unit -> model = CLK_MODEL_MMP2 ;
339
+
329
340
pxa_unit -> mpmu_base = of_iomap (np , 0 );
330
341
if (!pxa_unit -> mpmu_base ) {
331
342
pr_err ("failed to map mpmu registers\n" );
@@ -365,3 +376,4 @@ static void __init mmp2_clk_init(struct device_node *np)
365
376
}
366
377
367
378
CLK_OF_DECLARE (mmp2_clk , "marvell,mmp2-clock" , mmp2_clk_init );
379
+ CLK_OF_DECLARE (mmp3_clk , "marvell,mmp3-clock" , mmp2_clk_init );
You can’t perform that action at this time.
0 commit comments