From owner-svn-src-head@freebsd.org Sat Feb 25 16:50:47 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 A8B79CED871; Sat, 25 Feb 2017 16:50:47 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citapm.icyb.net.ua (citapm.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 966656B4; Sat, 25 Feb 2017 16:50:45 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citapm.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id SAA08245; Sat, 25 Feb 2017 18:50:44 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1chfYS-0002VA-5L; Sat, 25 Feb 2017 18:50:44 +0200 Subject: Re: svn commit: r314273 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . sys To: src-committers@FreeBSD.org, svn-src-all@FreeBSD.org, svn-src-head@FreeBSD.org References: <201702251645.v1PGjrNP036632@repo.freebsd.org> From: Andriy Gapon Message-ID: <4ee5dd9d-a72e-f21b-ebac-b13dd8b45439@FreeBSD.org> Date: Sat, 25 Feb 2017 18:49:47 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <201702251645.v1PGjrNP036632@repo.freebsd.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit 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: Sat, 25 Feb 2017 16:50:47 -0000 On 25/02/2017 18:45, Andriy Gapon wrote: > Author: avg > Date: Sat Feb 25 16:45:53 2017 > New Revision: 314273 > URL: https://svnweb.freebsd.org/changeset/base/314273 > > Log: > zfs: call spa_deadman on a taskqueue thread > > callout(9) prohibits callout functions from sleeping. > illumos mutexes are emulated using sx(9). > spa_deadman() calls vdev_deadman() and the latter acquires vq_lock. > > As a result we can get a more confusing panic instead of a specific > panic or no panic: > sleepq_add: td 0xfffff80019669960 to sleep on wchan 0xfffff8001cff4d88 with sleeping prohibited > > This change adds another level of indirection where the deadman > callout schedules spa_deadman() to be executed on taskqueue_thread. > > While there, use callout_schedule(0 instead of callout_reset() > in spa_sync(). > > Discussed with: mav > MFC after: 1 week > Differential Revision: https://reviews.freebsd.org/D9762 Sponsored by: Panzura -- Andriy Gapon