From owner-freebsd-net@freebsd.org Mon Apr 11 22:01:22 2016 Return-Path: Delivered-To: freebsd-net@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 52ABDB0C532 for ; Mon, 11 Apr 2016 22:01:22 +0000 (UTC) (envelope-from jfvogel@gmail.com) Received: from mail-vk0-x236.google.com (mail-vk0-x236.google.com [IPv6:2607:f8b0:400c:c05::236]) (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 156041F66; Mon, 11 Apr 2016 22:01:22 +0000 (UTC) (envelope-from jfvogel@gmail.com) Received: by mail-vk0-x236.google.com with SMTP id t129so146803913vkg.2; Mon, 11 Apr 2016 15:01:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=7Y4tnV9mfwVKzXTczu4vpl+AmnuiZeTmbBYo73jbMkc=; b=cKvnR7O5lP9TDn1n/j08OXp6ao5qDiYrzfpGv3VYq/sYMptpgqgQcw8hrCL209TkAy dhLJVD3aucvmsaYmJuAu2TolOXArt8NUNyQNk/J5qua1k1jtI3uzU+pj0/D8YwfrBZe0 yBPT+ErHibCvOr2Bt44AgsKkjZWLZfqEzAtjZf9kvoBmqXjj1JgG1/WnMuXkk+3EABRe 1+taruztXQ6qgRLFr30lb/HeLRgrFxtESIe4leFF+HDQBPmVHxyrtKOCrU9WlX0wbTkT 6NiylL1IcHtd55v20quHrRaRs+gYC14j70A/rLmWJWCq3+u6USKJwAcZAJItXl4MvZLO 7HOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=7Y4tnV9mfwVKzXTczu4vpl+AmnuiZeTmbBYo73jbMkc=; b=h1p7BOz4Q7GhSYry3KEzVG+aAniX61q/WJxXa8eI8DLNh9zFZzm5MEwtUjLAW6aO1+ 3yMmodBfbh8U7k0/6mh5JJG06arMWPD1i5v3HbVEMq8NN/7DcTENopaAKjJ5+yx+nU1b u1dhrMCCq72k58Tmh139lbHe0Ogooax/UrQBGA5n9DwOJ7qgx4xLJucG56enOaJt6Hpv nqz7Mkp7Leq4sLAr8d6cLMJy38v1ChpctntDE+x2qqcbkQLm221GJ77uyBmssbzbMjim 0W+Tn9N9WTqPwiT2LAoSz6FJYLuvQqC7QIuyTEUM/aGIM7ZpnvWzxcpWYAZJYcMuqCzG oD8g== X-Gm-Message-State: AD7BkJJw0klzA0m2JHfZMsYO49rpvp6VSygxQxckgk2qWQS/Rj7Y4vpXnbYbI/lLcA0udBV6GFXqL9W6djYgEQ== MIME-Version: 1.0 X-Received: by 10.31.52.147 with SMTP id b141mr12931947vka.82.1460412081099; Mon, 11 Apr 2016 15:01:21 -0700 (PDT) Received: by 10.31.171.206 with HTTP; Mon, 11 Apr 2016 15:01:21 -0700 (PDT) In-Reply-To: References: Date: Mon, 11 Apr 2016 15:01:21 -0700 Message-ID: Subject: Re: Question on sysctl tree handling From: Jack Vogel To: "K. Macy" Cc: FreeBSD Net Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.21 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Apr 2016 22:01:22 -0000 Why should init have to be rerun just because TSO or CSUM is turned off or on, its a flag that is checked in the TX routines? I am controlling some cases in the ioctl routine so it does the necessary things, but does not rerun all of init. If its a long running system that means its unlikely be go undergoing a config change, yes? BTW, the sysctl stuff is still giving me trouble. I create a new node, and add stats oids to that, if a reinit happens, they can be removed, but then I get a warning message when the driver goes thru detach complaining that an oid cannot be unregistered... It's proving to be frustrating :( I appreciate the comments Kip. Jack On Mon, Apr 11, 2016 at 2:03 PM, K. Macy wrote: > You do understand that init needs to be run every time interface > settings are changed (TSO / PROMISC / CSUM/ etc)? Reallocating queues > and interrupts every time is fragile (long running systems can run low > on contiguous memory) and, in the common case that you're not actually > changing the number, gratuitous. > > Cheers. > -M > > On Fri, Apr 8, 2016 at 2:56 PM, Jack Vogel wrote: > > LOL, why does it seem that as soon as I ask the answer hits me in the > nose > > :) > > > > I found the sysctl_ctx_free call, sorry for the noise.... > > > > Jack > > > > > > On Fri, Apr 8, 2016 at 2:51 PM, Jack Vogel wrote: > > > >> > >> I have a driver design where the queue/ring/irq layout is done in init > >> rather > >> than in attach, allowing easy reconfiguration. What I'm not sure about > is > >> how to handle the sysctl tree during a reinit, I don't see a procedure > to > >> free up things so I can restructure :( > >> > >> Am I missing something, any pointers or suggestions appreciated. > >> > >> Thanks, > >> > >> Jack > >> > >> > > _______________________________________________ > > freebsd-net@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/freebsd-net > > To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org" >