From owner-svn-src-head@freebsd.org Fri Nov 13 00:48:35 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 A5F94A2C660; Fri, 13 Nov 2015 00:48:35 +0000 (UTC) (envelope-from ricera10@gmail.com) Received: from mail-qk0-f178.google.com (mail-qk0-f178.google.com [209.85.220.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 665331A4E; Fri, 13 Nov 2015 00:48:35 +0000 (UTC) (envelope-from ricera10@gmail.com) Received: by qkao63 with SMTP id o63so33015869qka.2; Thu, 12 Nov 2015 16:48:34 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :content-type; bh=5/GyjqYe++CQHzbPgWl5vPG2ACrABeOwQXSoAQc8hmQ=; b=T5bJgbf+L+4+UgzelArbM+rm4mosTV6Z7tg0/KdKoQAKE8jdpLKAUilzYKeVi58ieS FZYax4pPueQad7Mu19pSz+olErp4T6M1h7epV4mW6bv8opUR5QtNv7PpS//PeNmeveur G/2QqMZMnqGJ7D7Y4tCc2jM/qGQXxAjoCNUDCwyEmLv3sby9czASheT0VPQP6IMiJ9C2 +LDHD06zPodEGYHlobKUZPcQRB6LXbGmT+HVRYAagEaTmOBGF9aR6e6Mm7UWMbfkyq4v iTD/n1+C9VrdJkuRvvX0/QGgxggYzftGj0ypPXhKBbFPUsry/b6FD5+O1NJvVJ3OQ/UA DE9g== X-Received: by 10.140.82.213 with SMTP id h79mr19521119qgd.26.1447375356944; Thu, 12 Nov 2015 16:42:36 -0800 (PST) Received: from mail-qk0-f173.google.com (mail-qk0-f173.google.com. [209.85.220.173]) by smtp.gmail.com with ESMTPSA id w18sm4722117qgw.1.2015.11.12.16.42.36 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 12 Nov 2015 16:42:36 -0800 (PST) Received: by qkfo3 with SMTP id o3so32876284qkf.1; Thu, 12 Nov 2015 16:42:36 -0800 (PST) X-Received: by 10.55.77.71 with SMTP id a68mr19173952qkb.106.1447375356436; Thu, 12 Nov 2015 16:42:36 -0800 (PST) MIME-Version: 1.0 References: <201511120945.tAC9jZZk067057@repo.freebsd.org> In-Reply-To: <201511120945.tAC9jZZk067057@repo.freebsd.org> From: Eric Joyner Date: Fri, 13 Nov 2015 00:42:26 +0000 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r290708 - head/sys/dev/ixl To: Steven Hartland , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 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: Fri, 13 Nov 2015 00:48:35 -0000 I guess r280043 got overwritten at some point? - Eric On Thu, Nov 12, 2015 at 1:45 AM Steven Hartland wrote: > Author: smh > Date: Thu Nov 12 09:45:35 2015 > New Revision: 290708 > URL: https://svnweb.freebsd.org/changeset/base/290708 > > Log: > Fix ixl debug sysctls panic > > Remove the use of sbuf_data on drained sbufs from the debug sysctls: > * ixl_sysctl_hw_res_alloc > * ixl_sysctl_switch_config > > This prevents a kernel panic when accessing these values under a kernel > compiled with INVARIANTS. > > Sponsored by: Multiplay > > Modified: > head/sys/dev/ixl/if_ixl.c > > Modified: head/sys/dev/ixl/if_ixl.c > > ============================================================================== > --- head/sys/dev/ixl/if_ixl.c Thu Nov 12 09:20:10 2015 (r290707) > +++ head/sys/dev/ixl/if_ixl.c Thu Nov 12 09:45:35 2015 (r290708) > @@ -5119,17 +5119,9 @@ ixl_sysctl_hw_res_alloc(SYSCTL_HANDLER_A > } > > error = sbuf_finish(buf); > - if (error) { > - device_printf(dev, "Error finishing sbuf: %d\n", error); > - sbuf_delete(buf); > - return error; > - } > - > - error = sysctl_handle_string(oidp, sbuf_data(buf), sbuf_len(buf), > req); > - if (error) > - device_printf(dev, "sysctl error: %d\n", error); > sbuf_delete(buf); > - return error; > + > + return (error); > } > > /* > @@ -5236,15 +5228,6 @@ ixl_sysctl_switch_config(SYSCTL_HANDLER_ > sbuf_delete(nmbuf); > > error = sbuf_finish(buf); > - if (error) { > - device_printf(dev, "Error finishing sbuf: %d\n", error); > - sbuf_delete(buf); > - return error; > - } > - > - error = sysctl_handle_string(oidp, sbuf_data(buf), sbuf_len(buf), > req); > - if (error) > - device_printf(dev, "sysctl error: %d\n", error); > sbuf_delete(buf); > > return (error); > >