diff options
author | Tom Rini <trini@konsulko.com> | 2021-01-11 13:55:03 -0500 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2021-01-11 13:55:03 -0500 |
commit | d71be1990218957b9f05dbf13a72859a2abe06d7 (patch) | |
tree | 99858dc9988f7f7b4c0ab1d8d45738e3abdf38c8 /drivers/timer/atcpit100_timer.c | |
parent | c4fddedc48f336eabc4ce3f74940e6aa372de18c (diff) | |
parent | bc0b99bd8b19599f670f42401de655fa9b44cd94 (diff) |
Merge branch 'next'
Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'drivers/timer/atcpit100_timer.c')
-rw-r--r-- | drivers/timer/atcpit100_timer.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/timer/atcpit100_timer.c b/drivers/timer/atcpit100_timer.c index fcb8a45358..fbc7fac1bb 100644 --- a/drivers/timer/atcpit100_timer.c +++ b/drivers/timer/atcpit100_timer.c @@ -64,13 +64,13 @@ struct atctmr_timer_regs { u32 int_mask; /* 0x38 */ }; -struct atcpit_timer_platdata { +struct atcpit_timer_plat { u32 *regs; }; static u64 atcpit_timer_get_count(struct udevice *dev) { - struct atcpit_timer_platdata *plat = dev_get_platdata(dev); + struct atcpit_timer_plat *plat = dev_get_plat(dev); u32 val; val = ~(REG32_TMR(CH_CNT(1))+0xffffffff); return timer_conv_64(val); @@ -78,16 +78,16 @@ static u64 atcpit_timer_get_count(struct udevice *dev) static int atcpit_timer_probe(struct udevice *dev) { - struct atcpit_timer_platdata *plat = dev_get_platdata(dev); + struct atcpit_timer_plat *plat = dev_get_plat(dev); REG32_TMR(CH_REL(1)) = 0xffffffff; REG32_TMR(CH_CTL(1)) = APB_CLK|TMR_32; REG32_TMR(CH_EN) |= CH_TMR_EN(1 , 0); return 0; } -static int atcpit_timer_ofdata_to_platdata(struct udevice *dev) +static int atcpit_timer_of_to_plat(struct udevice *dev) { - struct atcpit_timer_platdata *plat = dev_get_platdata(dev); + struct atcpit_timer_plat *plat = dev_get_plat(dev); plat->regs = map_physmem(dev_read_addr(dev), 0x100 , MAP_NOCACHE); return 0; } @@ -105,8 +105,8 @@ U_BOOT_DRIVER(atcpit100_timer) = { .name = "atcpit100_timer", .id = UCLASS_TIMER, .of_match = atcpit_timer_ids, - .ofdata_to_platdata = atcpit_timer_ofdata_to_platdata, - .platdata_auto_alloc_size = sizeof(struct atcpit_timer_platdata), + .of_to_plat = atcpit_timer_of_to_plat, + .plat_auto = sizeof(struct atcpit_timer_plat), .probe = atcpit_timer_probe, .ops = &atcpit_timer_ops, }; |