From owner-svn-src-projects@freebsd.org Fri Feb 3 07:29:03 2017 Return-Path: Delivered-To: svn-src-projects@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 85AF7CCEC24 for ; Fri, 3 Feb 2017 07:29:03 +0000 (UTC) (envelope-from hselasky@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 mx1.freebsd.org (Postfix) with ESMTPS id 52CF3364; Fri, 3 Feb 2017 07:29:03 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v137T2rg042506; Fri, 3 Feb 2017 07:29:02 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v137T2xh042505; Fri, 3 Feb 2017 07:29:02 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201702030729.v137T2xh042505@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Fri, 3 Feb 2017 07:29:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r313138 - projects/hps_head/sys/kern X-SVN-Group: projects MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-projects@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the src " projects" tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Feb 2017 07:29:03 -0000 Author: hselasky Date: Fri Feb 3 07:29:02 2017 New Revision: 313138 URL: https://svnweb.freebsd.org/changeset/base/313138 Log: Fix build with KTR enabled. Found by: markj @ Modified: projects/hps_head/sys/kern/kern_timeout.c Modified: projects/hps_head/sys/kern/kern_timeout.c ============================================================================== --- projects/hps_head/sys/kern/kern_timeout.c Fri Feb 3 06:04:06 2017 (r313137) +++ projects/hps_head/sys/kern/kern_timeout.c Fri Feb 3 07:29:02 2017 (r313138) @@ -1015,16 +1015,14 @@ callout_handle_init(struct callout_handl static const char * callout_retvalstring(callout_ret_t retval) { - switch (retval.value) { - case CALLOUT_RET_DRAINING: + if (retval.value == CALLOUT_RET_DRAINING) return ("callout cannot be stopped and needs drain"); - case CALLOUT_RET_CANCELLED: + else if (retval.value == CALLOUT_RET_CANCELLED) return ("callout was successfully stopped"); - case CALLOUT_RET_CANCELLED_AND_DRAINING: + else if (retval.value == CALLOUT_RET_CANCELLED_AND_DRAINING) return ("callout was successfully stopped while being serviced"); - default: + else return ("callout was already stopped"); - } } #endif