From owner-svn-src-all@freebsd.org Wed Jan 10 02:28:11 2018 Return-Path: Delivered-To: svn-src-all@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 7E3ACE5CECB; Wed, 10 Jan 2018 02:28:11 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5A1667D23E; Wed, 10 Jan 2018 02:28:11 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 97E611F862; Wed, 10 Jan 2018 02:28:10 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w0A2SAY9038026; Wed, 10 Jan 2018 02:28:10 GMT (envelope-from ian@FreeBSD.org) Received: (from ian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w0A2SA4k038025; Wed, 10 Jan 2018 02:28:10 GMT (envelope-from ian@FreeBSD.org) Message-Id: <201801100228.w0A2SA4k038025@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ian set sender to ian@FreeBSD.org using -f From: Ian Lepore Date: Wed, 10 Jan 2018 02:28:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r327756 - head/sys/dev/iicbus X-SVN-Group: head X-SVN-Commit-Author: ian X-SVN-Commit-Paths: head/sys/dev/iicbus X-SVN-Commit-Revision: 327756 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Jan 2018 02:28:11 -0000 Author: ian Date: Wed Jan 10 02:28:10 2018 New Revision: 327756 URL: https://svnweb.freebsd.org/changeset/base/327756 Log: Bugfix: on RTC chips with a 32-bit binary counter, after reading the time, return immediately rather than falling through to the logic that reads BCD-encoded time. Modified: head/sys/dev/iicbus/ds13rtc.c Modified: head/sys/dev/iicbus/ds13rtc.c ============================================================================== --- head/sys/dev/iicbus/ds13rtc.c Wed Jan 10 00:18:47 2018 (r327755) +++ head/sys/dev/iicbus/ds13rtc.c Wed Jan 10 02:28:10 2018 (r327756) @@ -364,9 +364,8 @@ ds13rtc_gettime(device_t dev, struct timespec *ts) /* If the chip counts time in binary, we just read and return it. */ if (sc->flags & SC_F_BINARY) { - if ((err = read_timeword(sc, &ts->tv_sec)) != 0) - return (err); ts->tv_nsec = 0; + return (read_timeword(sc, &ts->tv_sec)); } /*