summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBin Meng <bmeng.cn@gmail.com>2015-11-13 00:11:16 -0800
committerSimon Glass <sjg@chromium.org>2015-12-01 06:23:51 -0700
commit9e360a5c9cac27c40547bc2e0b81bbadeffb3ca2 (patch)
tree276ff5fe62ae2554b18f5a9e7e9244c9b050ca60
parent579eb5a0cc61a529be5fb540fa32ed0404955db2 (diff)
downloadtalos-obmc-uboot-9e360a5c9cac27c40547bc2e0b81bbadeffb3ca2.tar.gz
talos-obmc-uboot-9e360a5c9cac27c40547bc2e0b81bbadeffb3ca2.zip
timer: altera: Remove the codes to get clock frequency
Since we have timer uclass to get clock frequency for us, remove the custom version in the altera timer driver. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Thomas Chou <thomas@wytron.com.tw> Acked-by: Simon Glass <sjg@chromium.org>
-rw-r--r--drivers/timer/altera_timer.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/timer/altera_timer.c b/drivers/timer/altera_timer.c
index 971ed38b6b..2364f1b00f 100644
--- a/drivers/timer/altera_timer.c
+++ b/drivers/timer/altera_timer.c
@@ -32,7 +32,6 @@ struct altera_timer_regs {
struct altera_timer_platdata {
struct altera_timer_regs *regs;
- unsigned long clock_rate;
};
static int altera_timer_get_count(struct udevice *dev, unsigned long *count)
@@ -54,12 +53,9 @@ static int altera_timer_get_count(struct udevice *dev, unsigned long *count)
static int altera_timer_probe(struct udevice *dev)
{
- struct timer_dev_priv *uc_priv = dev_get_uclass_priv(dev);
struct altera_timer_platdata *plat = dev->platdata;
struct altera_timer_regs *const regs = plat->regs;
- uc_priv->clock_rate = plat->clock_rate;
-
writel(0, &regs->status);
writel(0, &regs->control);
writel(ALTERA_TIMER_STOP, &regs->control);
@@ -78,8 +74,6 @@ static int altera_timer_ofdata_to_platdata(struct udevice *dev)
plat->regs = map_physmem(dev_get_addr(dev),
sizeof(struct altera_timer_regs),
MAP_NOCACHE);
- plat->clock_rate = fdtdec_get_int(gd->fdt_blob, dev->of_offset,
- "clock-frequency", 0);
return 0;
}
OpenPOWER on IntegriCloud