From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.4 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A3FDBC33C9E for ; Tue, 14 Jan 2020 18:33:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7A5B124672 for ; Tue, 14 Jan 2020 18:33:47 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="UtHq2sW4" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728800AbgANSdq (ORCPT ); Tue, 14 Jan 2020 13:33:46 -0500 Received: from us-smtp-delivery-1.mimecast.com ([205.139.110.120]:46615 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726053AbgANSdo (ORCPT ); Tue, 14 Jan 2020 13:33:44 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1579026823; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=VU3iLjKmaQ0aNJQ9ZbgSwibwLQ11TCA8buR9ZQY0R+A=; b=UtHq2sW4cdTFh1NyvPX7PwJvumIv8lApltMFT3/dT3R0ezQE3xJnMYrJjIvhsV9Q0B6KaS cr+Ck+c/IpueQnm4Q9VpoPpaCG2LnjI7ev1/wyjaZZ7o4pz84xIxHIWNBYJWXAhwfjFhNr V+uZ6cmlcJxqAK0HDmyGjRdMMI24J7o= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-272-OMK7ZWSpPBGwRivqNqoE-g-1; Tue, 14 Jan 2020 13:33:40 -0500 X-MC-Unique: OMK7ZWSpPBGwRivqNqoE-g-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id AD03F801E78; Tue, 14 Jan 2020 18:33:38 +0000 (UTC) Received: from llong.remote.csb (ovpn-122-218.rdu2.redhat.com [10.10.122.218]) by smtp.corp.redhat.com (Postfix) with ESMTP id 8900F5C1D6; Tue, 14 Jan 2020 18:33:33 +0000 (UTC) Subject: Re: [PATCH 02/12] locking/rwsem: Exit early when held by an anonymous owner To: Christoph Hellwig Cc: linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, Peter Zijlstra , Thomas Gleixner , Ingo Molnar , Will Deacon , Andrew Morton , linux-ext4@vger.kernel.org, cluster-devel@redhat.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org References: <20200114161225.309792-1-hch@lst.de> <20200114161225.309792-3-hch@lst.de> <925d1343-670e-8f92-0e73-6e9cee0d3ffb@redhat.com> <20200114182514.GA9949@lst.de> From: Waiman Long Organization: Red Hat Message-ID: <478b3737-79e1-33a9-ac44-c6656e83adf5@redhat.com> Date: Tue, 14 Jan 2020 13:33:33 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 MIME-Version: 1.0 In-Reply-To: <20200114182514.GA9949@lst.de> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Content-Language: en-US X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On 1/14/20 1:25 PM, Christoph Hellwig wrote: > On Tue, Jan 14, 2020 at 01:17:45PM -0500, Waiman Long wrote: >> The owner field is just a pointer to the task structure with the lower 3 >> bits served as flag bits. Setting owner to RWSEM_OWNER_UNKNOWN (-2) will >> stop optimistic spinning. So under what condition did the crash happen? > When running xfstests with all patches in this series except for this > one, IIRC in generic/114. OK, I think I know where the bug is. I will send a patch to fix that. Thanks, Longman