Received: by 2002:a05:7412:f584:b0:e2:908c:2ebd with SMTP id eh4csp1929473rdb; Tue, 5 Sep 2023 09:05:22 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEYa0qfqeA3/Nt60aPklO34xVzri6fq2j1RZklFyIFsMYv4ASR8hj+yrE43XA/nWMIW7HG9 X-Received: by 2002:a17:907:2cc9:b0:994:577:f9dd with SMTP id hg9-20020a1709072cc900b009940577f9ddmr230641ejc.9.1693929922280; Tue, 05 Sep 2023 09:05:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1693929922; cv=none; d=google.com; s=arc-20160816; b=eXOYAs0/Pt5z5zenr9yaErMDi33x+eOXEuSSGx+628xYcMi03dH7N/aVobcrTiiu03 fmbcUqUqgU+IJOXjKSryVFg5bJX+YZNmIGZuzyDbVMjWEFZHbTxPuAhSKR3xW7vuvMwj y/C5hGQpYXriuk7tbVRjbCV5SL5TomxnUSHqMBedL+FrOloDK6vf0DqZazMntDgAzAyn 52ofcS0nJ9KECf+L+9yV8w4Kv7x8qV2GQfOP4V2G/88LgP8x0G6vksteJvHYMKUCWIQl E+13KTmmhmILMSgT2F+/5UepUjRAgGn0+ECHEw9NrWhE5mxgOWMaZiYUflpoSjmEomkx texg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=uA8feDnfGHOk6NcJ6jrXFKT175jb13DVc+EiyDbwTPA=; fh=QUdzzp73bfau0kTVlrwKumoXjWU2UTSARjqwGSyzhwU=; b=hhU+1PAtyIeeLVXdn3numOyMzp9WcBBiipc6FhHoirRM0mN5QsPWSUxHmiBzHU89Aj s8gKHVW8gPzyiEgYPhBy7lKYcpojbFXAT0rVRKUxZsyqUYVcs7UiWYMCGHv7r5OPfR+f slRsjZRcYdKVlI1A2bOXWBNUfH7ygMImRd7/uHgplbPOGl8xDdWp0cSqEz85pWcAr1wo IYptd3r4Y9aUCKoZHoCvXZ5vE2vFGgfmGjaPsNM2Nk+/rWd1MXyUokENuzfESgcUjBw8 hEgPs/UNt8gAQIlLkYpa4AB8R21wwwsXRNvQ0HR7fRrFI4MqEoPYqn1S2FuFQZDxb2Ku jHtQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=xuzUWMHs; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k14-20020a1709063e0e00b0099cc4c7e050si7796558eji.237.2023.09.05.09.05.13; Tue, 05 Sep 2023 09:05:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=xuzUWMHs; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1351163AbjIDPkc (ORCPT + 21 others); Mon, 4 Sep 2023 11:40:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55298 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229492AbjIDPkc (ORCPT ); Mon, 4 Sep 2023 11:40:32 -0400 Received: from pandora.armlinux.org.uk (unknown [IPv6:2001:4d48:ad52:32c8:5054:ff:fe00:142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C57E183; Mon, 4 Sep 2023 08:40:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To: Content-Transfer-Encoding:Content-Type:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=uA8feDnfGHOk6NcJ6jrXFKT175jb13DVc+EiyDbwTPA=; b=xuzUWMHsXGqAZRQ52Hk+bYd9vb 8qK4wqmRuiiU0q60skq3F8zPEhiOJ7czhr4HDQ2yRd9me0L4jZ6SARUmzhlGioPmzkS6lul7wUcNU k0zZofi0DMgZ0yoa60hSdW7e7Aree+n1vaDr+SAmi67V2oGrRFkn6FYFU+yu1yMalkdqqpZkzN2wl eqN+xTJ57FQ5N6C3VR+G8e0+CAqvLZdR+2oLdFZXaVdnJXC9SQc7h+VM/qTCRKqmbIkLwSazH3Cm4 v7cxYzxjH1pO0y6CaqahzWUDVKPjGRT+pbicU3B7pFg96uIIPVAGKPy6qC+/xisjPS+OcwLhXeF3C jmu48B2A==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:40242) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1qdBgT-00071H-35; Mon, 04 Sep 2023 16:40:14 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1qdBgR-0002fG-PD; Mon, 04 Sep 2023 16:40:11 +0100 Date: Mon, 4 Sep 2023 16:40:11 +0100 From: "Russell King (Oracle)" To: Waiman Long Cc: =?utf-8?B?UmFmYcWCIE1pxYJlY2tp?= , Peter Zijlstra , Ingo Molnar , Will Deacon , Boqun Feng , Daniel Lezcano , Thomas Gleixner , Florian Fainelli , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, openwrt-devel@lists.openwrt.org, bcm-kernel-feedback-list@broadcom.com Subject: Re: ARM BCM53573 SoC hangs/lockups caused by locks/clock/random changes Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Sender: Russell King (Oracle) X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED,RDNS_NONE, SPF_HELO_NONE,SPF_NONE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Sep 04, 2023 at 11:25:57AM -0400, Waiman Long wrote: > > On 9/4/23 04:33, Rafał Miłecki wrote: > > As those hangs/lockups are related to so many different changes it's > > really hard to debug them. > > > > This bug seems to be specific to the slow arch clock that affects > > stability only when kernel locking code and symbols layout trigger some > > very specific timing. > > > > Enabling CONFIG_PROVE_LOCKING seems to make issue go away but it affects > > so much code it's hard to tell why it actually matters. > > > > Same for disabling CONFIG_SMP. I noticed Broadcom's SDK keeps it > > disabled. I tried it and it improves stability (I had 3 devices with 6 > > days of uptime and counting) indeed. Again it affects a lot of kernel > > parts so it's hard to tell why it helps. > > > > Unless someone comes up with some magic solution I'll probably try > > building BCM53573 images without CONFIG_SMP for my personal needs. > > All the locking operations rely on the fact that the instruction to acquire > or release a lock is atomic. Is it possible that it may not be the case > under certain circumstances for this ARM BCM53573 SoC? Or maybe some Kconfig > options are not set correctly like missing some errata that are needed. > > I don't know enough about the 32-bit arm architecture to say whether this is > the case or not, but that is my best guess. So, BCM53573 is Cortex-A7, which is ARMv7, which has the exclusive load/store instructions. Whether the SoC has the necessary exclusive monitors to support these instructions is another matter, and I suspect someone with documentation would need to check that. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!