From owner-freebsd-stable@freebsd.org Thu Feb 4 18:47:35 2016 Return-Path: Delivered-To: freebsd-stable@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 578D2A9BA03 for ; Thu, 4 Feb 2016 18:47:35 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 35A57999 for ; Thu, 4 Feb 2016 18:47:35 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: by mailman.ysv.freebsd.org (Postfix) id 34DA1A9BA01; Thu, 4 Feb 2016 18:47:35 +0000 (UTC) Delivered-To: stable@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 34687A9BA00 for ; Thu, 4 Feb 2016 18:47:35 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-ig0-x231.google.com (mail-ig0-x231.google.com [IPv6:2607:f8b0:4001:c05::231]) (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 F07E1997 for ; Thu, 4 Feb 2016 18:47:34 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: by mail-ig0-x231.google.com with SMTP id 5so67240386igt.0 for ; Thu, 04 Feb 2016 10:47:34 -0800 (PST) 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:content-type:content-transfer-encoding; bh=5e3DrHPVfPwGxbigtV8ktAIVfXt8TKGekud/hAL+3AY=; b=lLAMdd2y28B0ISDCx0EPSuGNm85BaP7R2cHlVFo+WvJ4E4mGD0YlD2uaGyOkI8mGQo xO27cMtTDW9L771SDR0NyIKgRIyvEMYnba1/usCnr66mzwJoO4yHZZ3PQ9bw8jbuskez FmHicM4DqXGRY65JU8wJfaJH82YVkZgmPderG2x2rSKlCHb1GhLkq7a9pmM6xp0IngyX ao3rDuZNDxaeA2UGaeH9DLHQ/Jc3q160qbPK1eB/sbRP2k9Y0EaoGJxP3G06am1eEsSP opH8zdUJCrC7PVJGUTVvHWqni6TJ8YNWVH4QjqgLLKcP3SbtzAsAEY8WTBzeeqX7U4EP zy6Q== 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:content-type :content-transfer-encoding; bh=5e3DrHPVfPwGxbigtV8ktAIVfXt8TKGekud/hAL+3AY=; b=G8Brhs9CTUOgDjI7QlbD8a5mRQ9tkF3Qe8RgfQRRdays0ootJhvRXNNZxFtIKPsfbc o2sa+7KOd888m6h7v+PUxdK5MP8oME7r556XL1Bc4yLzRxbYuVw5hBILdTZKEH+c9Ll7 UgOi8UtS48njpC8sGGuAHI54vI5IKEqUqbbc5ldrwZWCxN6zAGG7jMgWmFx7LtDffaCF nMZpCn15YsOwCeTtxo6cu33lYX0x5QrfzQ1qLPB4VSlvJwX1TzgzHA7ElLj25Ws7c/Uq Js2FGhEDhKLGpzh+bgfs/Hr0VbLhnlHBwK0nYuci25ynX9w6pyyL99z+P6OWTm404Mfa AxXw== X-Gm-Message-State: AG10YOTfOawlv507dzyQc7WHVOgmV5cQo9d7sNv5BEwcRlVneIBZn6HWDz5wJLtfPh3eNsDIHb/cT6/vj0+8fA== MIME-Version: 1.0 X-Received: by 10.50.171.225 with SMTP id ax1mr5288334igc.61.1454611654448; Thu, 04 Feb 2016 10:47:34 -0800 (PST) Received: by 10.36.14.19 with HTTP; Thu, 4 Feb 2016 10:47:34 -0800 (PST) In-Reply-To: References: <20151018185639.GF42243@zxy.spb.ru> <20151018210049.GT6469@zxy.spb.ru> <20151022163519.GF6469@zxy.spb.ru> <20160202204446.GQ88527@zxy.spb.ru> <20160204130029.GC88527@zxy.spb.ru> Date: Thu, 4 Feb 2016 10:47:34 -0800 Message-ID: Subject: Re: 82576 + NETMAP + VLAN From: Adrian Chadd To: Slawa Olhovchenkov Cc: Luigi Rizzo , "stable@freebsd.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Feb 2016 18:47:35 -0000 .. but if it does, can you enable witness and see what it reports as lock order violations? -a On 4 February 2016 at 10:47, Adrian Chadd wrote: > I've no time to help with this, I'm sorry :( > > > -a > > > On 4 February 2016 at 05:00, Slawa Olhovchenkov wrote: >> On Tue, Feb 02, 2016 at 11:44:47PM +0300, Slawa Olhovchenkov wrote: >> >>> On Thu, Oct 22, 2015 at 11:24:53AM -0700, Luigi Rizzo wrote: >>> >>> > On Thu, Oct 22, 2015 at 11:12 AM, Adrian Chadd wrote: >>> > > On 22 October 2015 at 09:35, Slawa Olhovchenkov wr= ote: >>> > >> On Sun, Oct 18, 2015 at 07:45:52PM -0700, Adrian Chadd wrote: >>> > >> >>> > >>> Heh, file a bug with luigi; it should be defined better inside ne= tmap itself. >>> > >> >>> > >> I am CC: luigi. >>> > >> >>> > >> Next question: do kevent RX/TX sync? >>> > >> In my setup I am need to manual NIOCTXSYNC/NIOCRXSYNC. >>> > > >>> > > Hi, >>> > > >>> > > Nope. kqueue() doesn't do the implicit sync like poll() does; it's >>> > > just the notification path. >>> > >>> > actually not. When the file descriptor is registered there >>> > is an implicit sync, and there is another one when an event >>> > is posted for the file descriptor. >>> > >>> > unless there are bugs, of course. >>> >>> I found strange behaivor: >>> >>> 1. open netmap and register in main thread >>> 2. kevent register in different thread >>> 3. result: got event by kevent but no ring sinc (all head,tail,cur >>> still 0). >>> >>> Is this normal? Or is this bug? >>> >>> open and registering netmap in same thread as kevent resolve this. >> >> Also, kevent+netmap deadlocked for me: >> >> PID TID COMM TDNAME KSTACK >> 1095 100207 addos - mi_switch+0xe1 sleepq_cat= ch_signals+0xab sleepq_timedwait_sig+0x10 _sleep+0x238 kern_nanosleep+0x10e= sys_nanosleep+0x51 amd64_syscall+0x40f Xfast_syscall+0xfb >> 1095 100208 addos worker#0 mi_switch+0xe1 sleepq_cat= ch_signals+0xab sleepq_wait_sig+0xf _sleep+0x27d kern_kevent+0x401 sys_keve= nt+0x12a amd64_syscall+0x40f Xfast_syscall+0xfb >> 1095 100209 addos worker#1 mi_switch+0xe1 turnstile_= wait+0x42a __mtx_lock_sleep+0x26b knote+0x38 freebsd_selwakeup+0x8b netmap_= notify+0x55 netmap_pipe_txsync+0x156 netmap_poll+0x400 netmap_knrw+0x6e kqu= eue_register+0x799 kern_kevent+0x158 sys_kevent+0x12a amd64_syscall+0x40f X= fast_syscall+0xfb >> 1095 100210 addos worker#2 mi_switch+0xe1 sleepq_cat= ch_signals+0xab sleepq_wait_sig+0xf _sleep+0x27d kern_kevent+0x401 sys_keve= nt+0x12a amd64_syscall+0x40f Xfast_syscall+0xfb >> 1095 100211 addos worker#NOIP mi_switch+0xe1 sleepq_cat= ch_signals+0xab sleepq_wait_sig+0xf _sleep+0x27d kern_kevent+0x401 sys_keve= nt+0x12a amd64_syscall+0x40f Xfast_syscall+0xfb >> 1095 100212 addos balancer mi_switch+0xe1 turnstile_= wait+0x42a __mtx_lock_sleep+0x26b knote+0x38 freebsd_selwakeup+0x8b netmap_= notify+0x2a netmap_pipe_rxsync+0x54 netmap_poll+0x774 netmap_knrw+0x6e kern= _kevent+0x5cc sys_kevent+0x12a amd64_syscall+0x40f Xfast_syscall+0xfb