From owner-freebsd-net@freebsd.org Mon Apr 4 15:32:08 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 A3908B011B9 for ; Mon, 4 Apr 2016 15:32:08 +0000 (UTC) (envelope-from matt.joras@gmail.com) Received: from mail-ob0-x22d.google.com (mail-ob0-x22d.google.com [IPv6:2607:f8b0:4003:c01::22d]) (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 6E29D1074 for ; Mon, 4 Apr 2016 15:32:08 +0000 (UTC) (envelope-from matt.joras@gmail.com) Received: by mail-ob0-x22d.google.com with SMTP id bg3so36049695obb.1 for ; Mon, 04 Apr 2016 08:32:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to; bh=fq1GbRwVBWXB43f9Oxn91buiTiTLzWbdD8lQe5Wra88=; b=TnRvNIxDZ08h9Wo1JRsFjdQdbu8lOXiPFIMxdyc6Nh49bdkWvtMdj+tYSWAFBGYFfp Ao6pezwd4/UsfSGdjBa/3ljsaw7UZk4qmwUm0pydEkle2iagUKOqKU8UtJbA18mA2S// 6Xg9Fd64YfsSnOwEVidHtgjS/reAKkahMKFOErSEFxyFxkuhRT6dzKNu8f0IQOxz72nm 8sYHA+qymJ+IrDs9V2LWwwXFN3l/FLboTILS9ZMzT8TzsZ1Dur0zO8zJX42hWNNfloid qfE/1raGwbJk046H/oCfr5FocABj/ZlhgsrCxHmNPhlUnid88Dqq+ZUOn93wgEm7VKze nJCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to; bh=fq1GbRwVBWXB43f9Oxn91buiTiTLzWbdD8lQe5Wra88=; b=Bz8Mo8RjMebYe8+MmplnM4NezLFAy1WY0MZzvkd/aHKtvP033nA4exH719gqDHEQWT GNe05MwqS6FE8bSMNTAlYPq82z5WK9CWOnG6mKEefV9ep9s/iqEJV5jhjTAm8rU3tYA0 0K6TaCdwDZVkahiPOdMmlTwTEz6GfPuWH1/IRP/s9eUlJPFJ3IadcQg3vQ/1FGgqOLC9 q+4YGtuk/sfYg6duKaLP1YPL+eemAkHsU7pyJr87ggH6pvzApV+1lls4RAwqQ77oPGZQ TGi1yetL8UsiFY7ltlGroH0EOdtbu3/X/SqAuPzxubUIq1ZzhbwRbbbApkVdnbJfw0g9 yZPw== X-Gm-Message-State: AD7BkJI6vzgfCQSxtQVwcP8AfAJuiU35unZuIG4BwzvY17JpypIbaFnr1U5iPYg+ikchfQhI4H8PVb50yUOi1w== MIME-Version: 1.0 X-Received: by 10.60.101.132 with SMTP id fg4mr3708488oeb.21.1459783927734; Mon, 04 Apr 2016 08:32:07 -0700 (PDT) Received: by 10.202.170.20 with HTTP; Mon, 4 Apr 2016 08:32:07 -0700 (PDT) Date: Mon, 4 Apr 2016 08:32:07 -0700 Message-ID: Subject: if_vlan locking fixes From: Matt Joras To: freebsd-net@freebsd.org Content-Type: text/plain; charset=UTF-8 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, 04 Apr 2016 15:32:08 -0000 Hello, At Isilon we end up creating/destroying vlan interfaces a lot more than users typically do. Unfortunately this lead to a myriad of panics due to locking insufficiencies in if_vlan. I've fixed these internally and I've submitted a review of the changes. I would appreciate if anyone would like to review them. https://reviews.freebsd.org/D5825 The essence of the changes is to make the global vlan lock an rmlock(9) and expand its scope to synchronize reading/using ifvlans with destruction events as well as ensure exlusivity in certain configuration paths. Thanks, Matt Joras