Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp8241008ybi; Tue, 23 Jul 2019 05:17:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqztiw572PxfnXmaVTNYvoPXrmRISpE/Eac1mAJB5mNhQIVBxghDgBxTC+gbdDdyBLQtB+Eu X-Received: by 2002:a63:cc14:: with SMTP id x20mr29781078pgf.142.1563884278948; Tue, 23 Jul 2019 05:17:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563884278; cv=none; d=google.com; s=arc-20160816; b=devqlbJkSDba1vEvJfDUmu5/pw0OxihYi8kMEVViKSZOQkU1b9yIRF5ef9K/ZtRyTz Jmj9eGlEr/729UDg30jhhYehWNQfd1UPY/B7Lcmt9JYpwl+gI+8/ljL82PjenB9Yw1Gj TT/AzAwX1LFAM6JEcxMOad8wgy8Kh0Leh2nYJDXlvoEERg0+Zz07KCYDrY4AEBMwHWEn 0oLLDLJ7/xJR50r7PF4IdW623aeH4qMNOUAH614kKjsJSGVxHJWxebcj3HpoqQqe6TTH QStPKUAqV9pqA8d6R+a1ElqkUI/nP+fC6KHmbOxCg/bnA9ws4kceyUWK2ypdbHRNbkTC S+1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:organization:from:references:cc:to:subject; bh=Cx/6A4VOSCJ/YJdMlpKRqYm4oPMNC3XQhHhcGZ1JjxU=; b=wGD14DVs1IZoZMLSeliF8nvTjEBE4yXQr0YTFizxStrBbD2QIsv/dPmKmzbf8kGuG+ aFGiPdaDqKJ74g1EitVOf9Mbh/EBDa9Jz09QTyt8+uhWemb4IcigCNMlvcPUb9vQ2p8R AX+L7JcU2mRIoj+dA/jAW18rmf5lnC4+yol3ut1y6KiZvpHb2UOZ1mgLSNcfmZIvkE2p cVvqd0Os2ZD73lByXl2r0PkPSYUjVwy+s+a6lYtV5wu51NxheaHYktxe3oHPB+bJlUDj uUsDLl6f6c6ly6TKjqSjO9EcfeoZwVxUZ+EZAdGm3KJ0MSwurwmqcfN7zlCrbKuXtOTc EAQQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l62si11112721pgd.24.2019.07.23.05.17.42; Tue, 23 Jul 2019 05:17:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728694AbfGWC5I (ORCPT + 99 others); Mon, 22 Jul 2019 22:57:08 -0400 Received: from mx1.redhat.com ([209.132.183.28]:43120 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726610AbfGWC5I (ORCPT ); Mon, 22 Jul 2019 22:57:08 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id A6AAE5D674; Tue, 23 Jul 2019 02:57:07 +0000 (UTC) Received: from llong.remote.csb (ovpn-121-40.rdu2.redhat.com [10.10.121.40]) by smtp.corp.redhat.com (Postfix) with ESMTP id 65BAB60603; Tue, 23 Jul 2019 02:57:05 +0000 (UTC) Subject: Re: [PATCH v8 13/19] locking/rwsem: Make rwsem->owner an atomic_long_t To: Luis Henriques Cc: Linus Torvalds , Borislav Petkov , Will Deacon , huang ying , Peter Zijlstra , Jeff Layton , the arch/x86 maintainers , Thomas Gleixner , Tim Chen , Ingo Molnar , Davidlohr Bueso , Linux List Kernel Mailing , "H. Peter Anvin" References: <20190520205918.22251-1-longman@redhat.com> <20190520205918.22251-14-longman@redhat.com> <20190719184538.GA20324@hermes.olymp> <2ed44afa-4528-a785-f188-2daf24343f97@redhat.com> <87h87hksim.fsf@suse.com> <81e82d5b-5074-77e8-7204-28479bbe0df0@redhat.com> <87wogbjeoh.fsf@suse.com> From: Waiman Long Organization: Red Hat Message-ID: <82c9383c-487f-1e13-2bbd-4767ac634a79@redhat.com> Date: Mon, 22 Jul 2019 22:57:04 -0400 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: <87wogbjeoh.fsf@suse.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Tue, 23 Jul 2019 02:57:08 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 7/21/19 4:49 PM, Luis Henriques wrote: > Waiman Long writes: > >> On 7/20/19 4:41 AM, Luis Henriques wrote: >>> "Linus Torvalds" writes: >>> >>>> On Fri, Jul 19, 2019 at 12:32 PM Waiman Long wrote: >>>>> This patch shouldn't change the behavior of the rwsem code. The code >>>>> only access data within the rw_semaphore structures. I don't know why it >>>>> will cause a KASAN error. I will have to reproduce it and figure out >>>>> exactly which statement is doing the invalid access. >>>> The stack traces should show line numbers if you run them through >>>> scripts/decode_stacktrace.sh. >>>> >>>> You need to have debug info enabled for that, though. >>>> >>>> Luis? >>>> >>>> Linus >>> Yep, sure. And I should have done this in the initial report. It's a >>> different trace, I had to recompile the kernel. >>> >>> (I'm also adding Jeff to the CC list.) >>> >>> Cheers, >> Thanks for the information. I think I know where the problem is. Would >> you mind applying the attached patch to see if it can fix the KASAN error. > Yep, that seems to work -- I can't reproduce the error anymore (and > sorry for the delay). Thanks! And feel free to add my Tested-by. > > Cheers, Thanks for the testing. I will post the official patch tomorrow. Cheers, Longman