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/misc/sifive-otp.c | |
parent | c4fddedc48f336eabc4ce3f74940e6aa372de18c (diff) | |
parent | bc0b99bd8b19599f670f42401de655fa9b44cd94 (diff) |
Merge branch 'next'
Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'drivers/misc/sifive-otp.c')
-rw-r--r-- | drivers/misc/sifive-otp.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/misc/sifive-otp.c b/drivers/misc/sifive-otp.c index 92f08dde011..3e658b35662 100644 --- a/drivers/misc/sifive-otp.c +++ b/drivers/misc/sifive-otp.c @@ -89,7 +89,7 @@ struct sifive_otp_regs { u32 pwe; /* Write enable input (defines program cycle) */ }; -struct sifive_otp_platdata { +struct sifive_otp_plat { struct sifive_otp_regs __iomem *regs; u32 total_fuses; }; @@ -100,7 +100,7 @@ struct sifive_otp_platdata { static int sifive_otp_read(struct udevice *dev, int offset, void *buf, int size) { - struct sifive_otp_platdata *plat = dev_get_platdata(dev); + struct sifive_otp_plat *plat = dev_get_plat(dev); struct sifive_otp_regs *regs = (struct sifive_otp_regs *)plat->regs; /* Check if offset and size are multiple of BYTES_PER_FUSE */ @@ -162,7 +162,7 @@ static int sifive_otp_read(struct udevice *dev, int offset, static int sifive_otp_write(struct udevice *dev, int offset, const void *buf, int size) { - struct sifive_otp_platdata *plat = dev_get_platdata(dev); + struct sifive_otp_plat *plat = dev_get_plat(dev); struct sifive_otp_regs *regs = (struct sifive_otp_regs *)plat->regs; /* Check if offset and size are multiple of BYTES_PER_FUSE */ @@ -239,9 +239,9 @@ static int sifive_otp_write(struct udevice *dev, int offset, return size; } -static int sifive_otp_ofdata_to_platdata(struct udevice *dev) +static int sifive_otp_of_to_plat(struct udevice *dev) { - struct sifive_otp_platdata *plat = dev_get_platdata(dev); + struct sifive_otp_plat *plat = dev_get_plat(dev); int ret; plat->regs = dev_read_addr_ptr(dev); @@ -269,7 +269,7 @@ U_BOOT_DRIVER(sifive_otp) = { .name = "sifive_otp", .id = UCLASS_MISC, .of_match = sifive_otp_ids, - .ofdata_to_platdata = sifive_otp_ofdata_to_platdata, - .platdata_auto_alloc_size = sizeof(struct sifive_otp_platdata), + .of_to_plat = sifive_otp_of_to_plat, + .plat_auto = sizeof(struct sifive_otp_plat), .ops = &sifive_otp_ops, }; |