From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 320BC29CA for ; Thu, 28 Nov 2024 00:31:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.133.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732753899; cv=none; b=DQSBIt3QF0pTyJMKTkWHG7A2VaFKt36+Hu9mGNIjHn/Nz6tQTSSWewOvSihNP+GRCiE1VG/ykIMk0xnmrUqYWUrMYSF56Tvp7ZKVbYIZFzyu+gMk/esuPBDy4CA1r5y4HmMB1MmoQnbWksNOQqYV37g9W0/XaeS0xgfmLd+pWFg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732753899; c=relaxed/simple; bh=AoDIcArxj8ATSkVwXz8Zpe7AfDUM3odoWu8H6UoSl5M=; h=From:Message-ID:Date:MIME-Version:Subject:To:Cc:References: In-Reply-To:Content-Type; b=jh39L0eiFfjsN4Za712GxZxR3dnaGnevdNZa1uzAmyRrwpkYHThKq/d+i9BhfSTyNH3d7ljMJrTdEikhUFdtqV7i2JwalQeXAQE+B9nbGE1edXnLlafvu5cbqW9h+tlO+LSZREmm/XmEmxyRTD4s/Iud55zKDOrERSMAeOrt2Mk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=LpBZKkVb; arc=none smtp.client-ip=170.10.133.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="LpBZKkVb" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1732753897; 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=3ibAv9WDOQTixkDjvaqVvQ7a/S55WmxPj/4iL3m5MBQ=; b=LpBZKkVbZmAub+dDlsY5PmQAoRbAi/FLLgHJ6/InoazhxVSGhU//xQlbkuuMExDdUQesaH AxVodtG72zE4PGVn2qSNq2kcdhm7vnsGnKDM4Ox7S8niW8ZBC8A6/yoIJl9z51mwJ+0Cqd 1CadN/BYLDUAuCdn9dcAh5B4G35xRgM= Received: from mail-qt1-f200.google.com (mail-qt1-f200.google.com [209.85.160.200]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-190-1cIZwvpaN0eY8CwA_EY9gw-1; Wed, 27 Nov 2024 19:31:35 -0500 X-MC-Unique: 1cIZwvpaN0eY8CwA_EY9gw-1 X-Mimecast-MFC-AGG-ID: 1cIZwvpaN0eY8CwA_EY9gw Received: by mail-qt1-f200.google.com with SMTP id d75a77b69052e-4669be6c87aso3601961cf.3 for ; Wed, 27 Nov 2024 16:31:35 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732753895; x=1733358695; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:user-agent:mime-version:date:message-id:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=3ibAv9WDOQTixkDjvaqVvQ7a/S55WmxPj/4iL3m5MBQ=; b=XGfIi2gZAzZs7suIaIin8JkU15eFItlBRwPN991fezT8z2qOm78qyZQCVhHnMrME29 SNHd+1P9fJPv928Rsek8qXDf9FzaR/1H/YNo7dlYjFmJNtkmfDZ3Ud1hoVeSEtxp4OWf 2Je/KpjxGZ+rGxANWmbJ3fhHQMyDtMh235xuiyLX8GVhHyyORqJu9avoJiG0lOEcpSk+ +jWc55QOOg0/lOjhM5mxQLD+v9NW6DzyjE5B2t6DgMJW9Zhjv45KabEhyYBPPA/N1oQX 4VPkqAiHPoYr+XJyoJxPau4c2k73mO4pR90qGN94E8uzQV3deUwcHM6HSBXqdxtLHZNO tinA== X-Forwarded-Encrypted: i=1; AJvYcCVX6AYQW0bwRIcq/h/oRFCLGEXfhZ46B3WosQOyUr+HO8BKcEbnoxKjgjtHHKoP1TpU5VuoS3veRQAovPw=@vger.kernel.org X-Gm-Message-State: AOJu0YxEF99bkANA4DGGgXOY/VdU2p7f/KOlq9Vu2VwQu3WqlEI5+2CK IhhOeFSKLzVuXlUftD8E9KXAh8viyv6Rhvncf81K0mDfgHDF4Tw62vIeuRn565IvmxGR6v4Szj0 e7LDr44xqxzm2xoZ4pcZ3pYjjY7j3lx+2u1+9iCt4GN0yRplleZDh7AymvNCSuA== X-Gm-Gg: ASbGncskcxg3MxSLoWY71Huq2EGEhvRLEW1yciamwcUENRzB6CTDg3DA+I6NFm0BHsr m+TXYwUWp1B5UHzFHn79+lignThP0sWvhXP7h8/LRlWSTDJArMxQsmyTZUF6QWyVEJBnpphFGZa K1tgZ0chxorOS86eoB+4fDjYOwfT8+xoXdGaUzLIk09m69waHB+FMXciYAlb/g9QrTSl8Sj6rKa q5syD8swfi9pDV7XiBtuJ984j9Drgza5ci6yET9M6RXQTghGSF1nZJm6FmCNb71z0Ul9nnhlYuq xsugn/HQhv82/+Xpyv4m X-Received: by 2002:a05:622a:4c6:b0:461:263e:6ab3 with SMTP id d75a77b69052e-466b352850amr62815781cf.30.1732753895431; Wed, 27 Nov 2024 16:31:35 -0800 (PST) X-Google-Smtp-Source: AGHT+IF/W+l9R6WzLCY1srU7yRdeSZ+03DxWX+0nFMWAkGHZPdrlg8bWU+gD1kjpnaQyMur/Z8EuAw== X-Received: by 2002:a05:622a:4c6:b0:461:263e:6ab3 with SMTP id d75a77b69052e-466b352850amr62815571cf.30.1732753895062; Wed, 27 Nov 2024 16:31:35 -0800 (PST) Received: from ?IPV6:2601:408:c180:2530:d041:4c25:86b8:e76a? ([2601:408:c180:2530:d041:4c25:86b8:e76a]) by smtp.gmail.com with ESMTPSA id d75a77b69052e-466c40663a8sm1095201cf.23.2024.11.27.16.31.32 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 27 Nov 2024 16:31:34 -0800 (PST) From: Waiman Long X-Google-Original-From: Waiman Long Message-ID: <6279e38a-9a3c-46ba-9161-5bc61f62d6d2@redhat.com> Date: Wed, 27 Nov 2024 19:31:31 -0500 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] sparc/pci: Make pci_poke_lock a raw_spinlock_t. To: Guenter Roeck , Waiman Long , Sebastian Andrzej Siewior Cc: Andreas Larsson , sparclinux@vger.kernel.org, linux-kernel@vger.kernel.org, Boqun Feng , Ingo Molnar , Peter Zijlstra , Thomas Gleixner , Will Deacon , "David S. Miller" References: <20241125181231.XpOsxxHx@linutronix.de> <72991b83-173e-492e-a4aa-5049304c1bd0@roeck-us.net> <5d269249-afd1-44f5-8faf-9ac11d9a3beb@redhat.com> <2a940822-b4d4-43ea-b4f7-4294043b76ea@roeck-us.net> <88f47cea-baba-4673-9bd7-7b7c3f421008@redhat.com> <20241126112000.UkTwR0Iv@linutronix.de> <48b9d642-9739-4333-b4b9-319df8a85e2d@redhat.com> <4eb7bb8e-c2aa-4ce5-9f15-3086fccf4e46@roeck-us.net> <20241127165356.hnkqmgcc@linutronix.de> <93c5b695-4c98-4b3d-99d7-592d949750be@roeck-us.net> Content-Language: en-US In-Reply-To: <93c5b695-4c98-4b3d-99d7-592d949750be@roeck-us.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 11/27/24 7:08 PM, Guenter Roeck wrote: > On 11/27/24 15:47, Waiman Long wrote: >> On 11/27/24 12:44 PM, Guenter Roeck wrote: >>> On 11/27/24 08:53, Sebastian Andrzej Siewior wrote: >>>> On 2024-11-27 08:02:50 [-0800], Guenter Roeck wrote: >>>>> On 11/27/24 07:39, Andreas Larsson wrote: >>>>>> Even though this is for sparc64, there is work being done looking >>>>>> into >>>>>> enabling RT for sparc32. If the amount of fixes needed to keep >>>>>> PROVE_RAW_LOCK_NESTING enabled is quite small at the moment I'd >>>>>> rather >>>>>> see it enabled for sparc rather than risking it becoming worse in >>>>>> the >>>>>> future. >>>> >>>> Okay. So you seem to be in favour of fixing the sparc64 splats Guenter >>>> reported? >>>> >>>>>> I don't know what the situation is for other architectures that >>>>>> does not >>>>>> support RT. >>>>>> >>>>> >>>>> For my part I still don't understand why PROVE_RAW_LOCK_NESTING is >>>>> no longer >>>>> a configurable option, or in other words why it is mandated even >>>>> for architectures >>>>> not supporting RT. To me this means that I'll either have to >>>>> disable PROVE_LOCKING >>>>> for sparc or live with endless warning backtraces. The latter >>>>> obscures real >>>>> problems, so it is a no-go. >>>> >>>> It is documented in Documentation/locking/locktypes.rst how the locks >>>> should nest. It is just nobody enabled it on sparc64 and tested. The >>>> option was meant temporary until the big read blocks are cleared. >>>> >>> >>> That doesn't explain why PROVE_RAW_LOCK_NESTING is now mandatory if >>> PROVE_LOCKING is enabled, even on architectures where is was not >>> tested. >>> I am all for testing, but that doesn't include making it mandatory >>> even where it is known to fail. Enabling it by default, sure, no >>> problem. >>> Dropping the option entirely after it is proven to no longer needed, >>> also no problem. But force-enabling it even where untested or, worse, >>> known to fail, is two steps too far. >> >> The main reason for enforcing PROVE_RAW_LOCK_NESTING with >> PROVE_LOCKING is due to the fact that PREEMPT_RT kernel is much less >> tested than the non-RT kernel. I do agree that we shouldn't force >> this on arches that don't support PREEMPT_RT. However, once an arch >> decides to support PREEMPT_RT, they have to fix all these >> raw_spinlock nesting problems. >> > > config PROVE_RAW_LOCK_NESTING > -       bool > +       bool "Enable raw_spinlock - spinlock nesting checks" if > ARCH_SUPPORTS_RT=n >         depends on PROVE_LOCKING > -       default y > +       default y if ARCH_SUPPORTS_RT > > would have accomplished that while at the same time making it optional > for non-RT architectures. I had actually thought about doing exactly that, but decide to keep the current mode for forcing  PROVE_RAW_LOCK_NESTING for arches that support PREEMPT_RT. I won't mind doing this alternative if others agree. Cheers, Longman