Module Name: src Committed By: martin Date: Sat Sep 14 20:52:43 UTC 2013
Modified Files: src/sys/kern: kern_tc.c Log Message: ifdef a variable like its use To generate a diff of this commit: cvs rdiff -u -r1.45 -r1.46 src/sys/kern/kern_tc.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/kern/kern_tc.c diff -u src/sys/kern/kern_tc.c:1.45 src/sys/kern/kern_tc.c:1.46 --- src/sys/kern/kern_tc.c:1.45 Sun May 26 18:07:42 2013 +++ src/sys/kern/kern_tc.c Sat Sep 14 20:52:43 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_tc.c,v 1.45 2013/05/26 18:07:42 kardel Exp $ */ +/* $NetBSD: kern_tc.c,v 1.46 2013/09/14 20:52:43 martin Exp $ */ /*- * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc. @@ -40,7 +40,7 @@ #include <sys/cdefs.h> /* __FBSDID("$FreeBSD: src/sys/kern/kern_tc.c,v 1.166 2005/09/19 22:16:31 andre Exp $"); */ -__KERNEL_RCSID(0, "$NetBSD: kern_tc.c,v 1.45 2013/05/26 18:07:42 kardel Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_tc.c,v 1.46 2013/09/14 20:52:43 martin Exp $"); #ifdef _KERNEL_OPT #include "opt_ntp.h" @@ -992,7 +992,10 @@ pps_ref_event(struct pps_state *pps, struct timespec ts, *tsp, *osp; struct timehands *th; u_int64_t tcount, acount, dcount, *pcount; - int foff, fhard, gen; + int foff, gen; +#ifdef PPS_SYNC + int fhard; +#endif pps_seq_t *pseq; KASSERT(mutex_owned(&timecounter_lock)); @@ -1049,14 +1052,18 @@ pps_ref_event(struct pps_state *pps, tsp = &pps->ppsinfo.assert_timestamp; osp = &pps->ppsparam.assert_offset; foff = pps->ppsparam.mode & PPS_OFFSETASSERT; +#ifdef PPS_SYNC fhard = pps->kcmode & PPS_CAPTUREASSERT; +#endif pcount = &pps->ppscount[0]; pseq = &pps->ppsinfo.assert_sequence; } else { tsp = &pps->ppsinfo.clear_timestamp; osp = &pps->ppsparam.clear_offset; foff = pps->ppsparam.mode & PPS_OFFSETCLEAR; +#ifdef PPS_SYNC fhard = pps->kcmode & PPS_CAPTURECLEAR; +#endif pcount = &pps->ppscount[1]; pseq = &pps->ppsinfo.clear_sequence; }