From owner-svn-src-all@FreeBSD.ORG Fri Mar 30 22:52:09 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8D449106570F; Fri, 30 Mar 2012 22:52:09 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7805D8FC08; Fri, 30 Mar 2012 22:52:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q2UMq9Gj061354; Fri, 30 Mar 2012 22:52:09 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q2UMq9ut061352; Fri, 30 Mar 2012 22:52:09 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201203302252.q2UMq9ut061352@svn.freebsd.org> From: Dimitry Andric Date: Fri, 30 Mar 2012 22:52:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r233710 - head/sys/dev/isci X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 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: Fri, 30 Mar 2012 22:52:09 -0000 Author: dim Date: Fri Mar 30 22:52:08 2012 New Revision: 233710 URL: http://svn.freebsd.org/changeset/base/233710 Log: Fix the following compilation warning with clang trunk in isci(4): sys/dev/isci/isci_task_request.c:198:7: error: case value not in enumerated type 'SCI_TASK_STATUS' (aka 'enum _SCI_TASK_STATUS') [-Werror,-Wswitch] case SCI_FAILURE_TIMEOUT: ^ This is because the switch is done on a SCI_TASK_STATUS enum type, but the SCI_FAILURE_TIMEOUT value belongs to SCI_STATUS instead. Because the list of SCI_TASK_STATUS values cannot be modified at this time, use the simplest way to get rid of this warning, which is to cast the switch argument to int. No functional change. Reviewed by: jimharris MFC after: 3 days Modified: head/sys/dev/isci/isci_task_request.c Modified: head/sys/dev/isci/isci_task_request.c ============================================================================== --- head/sys/dev/isci/isci_task_request.c Fri Mar 30 20:17:39 2012 (r233709) +++ head/sys/dev/isci/isci_task_request.c Fri Mar 30 22:52:08 2012 (r233710) @@ -188,7 +188,7 @@ isci_task_request_complete(SCI_CONTROLLE isci_remote_device->is_resetting = FALSE; - switch (completion_status) { + switch ((int)completion_status) { case SCI_TASK_SUCCESS: case SCI_TASK_FAILURE_RESPONSE_VALID: break;