From owner-svn-src-head@freebsd.org Tue Aug 11 19:25:27 2015 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9D3E399FB52; Tue, 11 Aug 2015 19:25:27 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 75262952; Tue, 11 Aug 2015 19:25:27 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.70]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id t7BJPRjn095202; Tue, 11 Aug 2015 19:25:27 GMT (envelope-from ian@FreeBSD.org) Received: (from ian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id t7BJPRM6095201; Tue, 11 Aug 2015 19:25:27 GMT (envelope-from ian@FreeBSD.org) Message-Id: <201508111925.t7BJPRM6095201@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ian set sender to ian@FreeBSD.org using -f From: Ian Lepore Date: Tue, 11 Aug 2015 19:25:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r286648 - head/sys/arm/ti/am335x X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Aug 2015 19:25:27 -0000 Author: ian Date: Tue Aug 11 19:25:26 2015 New Revision: 286648 URL: https://svnweb.freebsd.org/changeset/base/286648 Log: Make this compile again when PPS_SYNC is defined. Also remove a couple comment blocks and constants that no longer apply. Modified: head/sys/arm/ti/am335x/am335x_dmtimer.c Modified: head/sys/arm/ti/am335x/am335x_dmtimer.c ============================================================================== --- head/sys/arm/ti/am335x/am335x_dmtimer.c Tue Aug 11 19:15:55 2015 (r286647) +++ head/sys/arm/ti/am335x/am335x_dmtimer.c Tue Aug 11 19:25:26 2015 (r286648) @@ -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, st 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;