diff options
author | ian <ian@FreeBSD.org> | 2015-08-11 19:25:26 +0000 |
---|---|---|
committer | ian <ian@FreeBSD.org> | 2015-08-11 19:25:26 +0000 |
commit | db64dae30a2438c637c1ca9d87d17ada9c762b8b (patch) | |
tree | 1cc22b2601c2062506770e54b1ed46a38deffe13 | |
parent | aa6e077870dba233baad38898bc63b53d43968a4 (diff) | |
download | FreeBSD-src-db64dae30a2438c637c1ca9d87d17ada9c762b8b.zip FreeBSD-src-db64dae30a2438c637c1ca9d87d17ada9c762b8b.tar.gz |
Make this compile again when PPS_SYNC is defined. Also remove a couple
comment blocks and constants that no longer apply.
-rw-r--r-- | sys/arm/ti/am335x/am335x_dmtimer.c | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/sys/arm/ti/am335x/am335x_dmtimer.c b/sys/arm/ti/am335x/am335x_dmtimer.c index d93cc50..c4447fd 100644 --- a/sys/arm/ti/am335x/am335x_dmtimer.c +++ b/sys/arm/ti/am335x/am335x_dmtimer.c @@ -101,15 +101,6 @@ __FBSDID("$FreeBSD$"); #define DMT_TSICR_RESET (1 << 1) /* TSICR perform soft reset */ #define DMT_TCAR2 0x48 /* Capture Reg */ -/* - * Use timer 2 for the eventtimer. When PPS support is not compiled in, there's - * no need to use a timer that has an associated capture-input pin, so use timer - * 3 for timecounter. When PPS is compiled in we ignore the default and use - * whichever of timers 4-7 have the capture pin configured. - */ -#define DEFAULT_ET_TIMER 2 -#define DEFAULT_TC_TIMER 3 - #define DMTIMER_READ4(sc, reg) (bus_read_4((sc)->tmr_mem_res, (reg))) #define DMTIMER_WRITE4(sc, reg, val) (bus_write_4((sc)->tmr_mem_res, (reg), (val))) @@ -383,10 +374,10 @@ am335x_dmtimer_pps_init(device_t dev, struct am335x_dmtimer_softc *sc) TASK_INIT(&sc->pps_task, 0, am335x_dmtimer_process_pps_event, sc); /* Create the PPS cdev. */ + unit = device_get_unit(dev); sc->pps_cdev = make_dev(&am335x_dmtimer_pps_cdevsw, unit, UID_ROOT, GID_WHEEL, 0600, PPS_CDEV_NAME); sc->pps_cdev->si_drv1 = sc; - unit = device_get_unit(sc->pps_cdev); device_printf(dev, "Using DMTimer%d for PPS device /dev/%s%d\n", am335x_dmtimer_pps_module, PPS_CDEV_NAME, unit); @@ -597,12 +588,6 @@ am335x_dmtimer_attach(device_t dev) clk_ident_t timer_id; int enable; - /* - * Note that if this routine returns an error status rather than running - * to completion it makes no attempt to clean up allocated resources; - * the system is essentially dead anyway without functional timers. - */ - sc = device_get_softc(dev); sc->dev = dev; |