From owner-svn-src-head@freebsd.org Thu Sep 28 19:33:38 2017 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 21B15E07477; Thu, 28 Sep 2017 19:33:38 +0000 (UTC) (envelope-from n_hibma@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 DFF5C6B36C; Thu, 28 Sep 2017 19:33:37 +0000 (UTC) (envelope-from n_hibma@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v8SJXblQ017504; Thu, 28 Sep 2017 19:33:37 GMT (envelope-from n_hibma@FreeBSD.org) Received: (from n_hibma@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v8SJXbUo017503; Thu, 28 Sep 2017 19:33:37 GMT (envelope-from n_hibma@FreeBSD.org) Message-Id: <201709281933.v8SJXbUo017503@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: n_hibma set sender to n_hibma@FreeBSD.org using -f From: Nick Hibma Date: Thu, 28 Sep 2017 19:33:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r324088 - head/sys/dev/smc X-SVN-Group: head X-SVN-Commit-Author: n_hibma X-SVN-Commit-Paths: head/sys/dev/smc X-SVN-Commit-Revision: 324088 X-SVN-Commit-Repository: base 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.23 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: Thu, 28 Sep 2017 19:33:38 -0000 Author: n_hibma Date: Thu Sep 28 19:33:36 2017 New Revision: 324088 URL: https://svnweb.freebsd.org/changeset/base/324088 Log: Make this compile with DEVICE_POLLING set. smc_poll had the wrong prototype. It returns 0 as it does not check anything but submits a taskqueue. Reviewed by: benno MFC after: 2 weeks Modified: head/sys/dev/smc/if_smc.c Modified: head/sys/dev/smc/if_smc.c ============================================================================== --- head/sys/dev/smc/if_smc.c Thu Sep 28 17:55:41 2017 (r324087) +++ head/sys/dev/smc/if_smc.c Thu Sep 28 19:33:36 2017 (r324088) @@ -782,7 +782,7 @@ smc_task_rx(void *context, int pending) } #ifdef DEVICE_POLLING -static void +static int smc_poll(struct ifnet *ifp, enum poll_cmd cmd, int count) { struct smc_softc *sc; @@ -792,12 +792,13 @@ smc_poll(struct ifnet *ifp, enum poll_cmd cmd, int cou SMC_LOCK(sc); if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { SMC_UNLOCK(sc); - return; + return (0); } SMC_UNLOCK(sc); if (cmd == POLL_AND_CHECK_STATUS) taskqueue_enqueue(sc->smc_tq, &sc->smc_intr); + return (0); } #endif