diff options
Diffstat (limited to 'drivers/clocksource/dw_apb_timer.c')
-rw-r--r-- | drivers/clocksource/dw_apb_timer.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/drivers/clocksource/dw_apb_timer.c b/drivers/clocksource/dw_apb_timer.c index 82ad6bccbc..3826c7490d 100644 --- a/drivers/clocksource/dw_apb_timer.c +++ b/drivers/clocksource/dw_apb_timer.c @@ -1,16 +1,12 @@ +// SPDX-License-Identifier: GPL-2.0-only /* * (C) Copyright 2009 Intel Corporation * Author: Jacob Pan (jacob.jun.pan@intel.com) * * Shared with ARM platforms, Jamie Iles, Picochip 2011 * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. - * * Support for the Synopsys DesignWare APB Timers. * - * * Taken from linux-4.9 kernel and adapted to barebox. */ #include <common.h> @@ -98,11 +94,12 @@ static struct clocksource dw_apb_clksrc = { .read = dw_apb_clocksource_read, .mask = CLOCKSOURCE_MASK(32), .shift = 0, + .priority = 50, }; -static int dw_apb_timer_probe(struct device_d *dev) +static int dw_apb_timer_probe(struct device *dev) { - struct device_node *np = dev->device_node; + struct device_node *np = dev->of_node; struct resource *iores; struct clk *clk; uint32_t clk_freq; @@ -138,8 +135,9 @@ static struct of_device_id dw_apb_timer_dt_ids[] = { { .compatible = "snps,dw-apb-timer", }, { } }; +MODULE_DEVICE_TABLE(of, dw_apb_timer_dt_ids); -static struct driver_d dw_apb_timer_driver = { +static struct driver dw_apb_timer_driver = { .name = "dw-apb-timer", .probe = dw_apb_timer_probe, .of_compatible = DRV_OF_COMPAT(dw_apb_timer_dt_ids), |