From owner-svn-src-head@freebsd.org Sat Jun 27 09:01:49 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 E3A9298D1EF; Sat, 27 Jun 2015 09:01:49 +0000 (UTC) (envelope-from nyan@FreeBSD.org) Received: from svn.freebsd.org (svn.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 D505314CD; Sat, 27 Jun 2015 09:01:49 +0000 (UTC) (envelope-from nyan@FreeBSD.org) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t5R91n1o033092; Sat, 27 Jun 2015 09:01:49 GMT (envelope-from nyan@FreeBSD.org) Received: (from nyan@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t5R91nen033091; Sat, 27 Jun 2015 09:01:49 GMT (envelope-from nyan@FreeBSD.org) Message-Id: <201506270901.t5R91nen033091@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: nyan set sender to nyan@FreeBSD.org using -f From: Takahashi Yoshihiro Date: Sat, 27 Jun 2015 09:01:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r284886 - head/sys/dev/fe 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: Sat, 27 Jun 2015 09:01:50 -0000 Author: nyan Date: Sat Jun 27 09:01:49 2015 New Revision: 284886 URL: https://svnweb.freebsd.org/changeset/base/284886 Log: MFi386: r278165 Silence a coverity warning about ignoring a return value. Modified: head/sys/dev/fe/if_fe_cbus.c Modified: head/sys/dev/fe/if_fe_cbus.c ============================================================================== --- head/sys/dev/fe/if_fe_cbus.c Sat Jun 27 08:49:41 2015 (r284885) +++ head/sys/dev/fe/if_fe_cbus.c Sat Jun 27 09:01:49 2015 (r284886) @@ -157,10 +157,21 @@ static int fe_isa_attach(device_t dev) { struct fe_softc *sc = device_get_softc(dev); + int error = 0; - if (sc->port_used) - fe98_alloc_port(dev, sc->type); - fe_alloc_irq(dev, 0); + /* + * Note: these routines aren't expected to fail since we also call + * them in the probe routine. But coverity complains, so we'll honor + * that complaint since the intention here was never to ignore them.. + */ + if (sc->port_used) { + error = fe98_alloc_port(dev, sc->type); + if (error != 0) + return (error); + } + error = fe_alloc_irq(dev, 0); + if (error != 0) + return (error); return fe_attach(dev); }