Received: by 2002:a05:7412:f584:b0:e2:908c:2ebd with SMTP id eh4csp700214rdb; Sun, 3 Sep 2023 06:48:08 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHs4plkL+kPVGhR0/xhl8reBA9hCUcwXS3OTp+qmJUZJO2/GVkif6eTTUE5axukWYY4xAH0 X-Received: by 2002:a17:907:78c1:b0:9a1:c991:a51c with SMTP id kv1-20020a17090778c100b009a1c991a51cmr5434541ejc.2.1693748888114; Sun, 03 Sep 2023 06:48:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1693748888; cv=none; d=google.com; s=arc-20160816; b=g+EXMkePtOPT2v/g0FvZHInllZKCg5YVzSPuAVSTcFglrjS4M43QJQvtCNbcvdxbww Zxo13JhvtsEpoYBXGhzC+fsBfwawCQohdaI1ve0jR6tv9vs9YoAxD9+7KvYSsNsErQES 7oho7I5oYuviy+JQ6dT8dp0m4OQ7wcnAHbzfafwPsy7hSF0TasnelyoT35eVbM1bC+Xx uwFJ+ybX8UiYHE/botIhI4ZfQ4C1av3CeAmk6cUpsSDVtxcF2iCdfna23Sy5DebdjZAy 194crFZXfAqxe8X4T/0fRr78I0uIeUdgikKgt7qz2t1KAtuoeOxGBXpnXL913zuIdf2m UOBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:feedback-id:dkim-signature:dkim-signature; bh=3Bxg+078KgJz5tyNgD/JmbFy76+3swKXt6BGQD9tQ3o=; fh=L21UCsxh2rQSmqTGRz7oqcvzVmjwRc+LNYqIaa01lsg=; b=XrUmNGRWSXP1HXkZqoOMVBhgxaEf+8Yj/AAo2JtSTwXW61OfGmVxvm9jba6Q7X6NbI TJtYCMmIFI+GpD/ma5uvaADP9jtiQ4Y2WTdZAjAiuZEG5WT8sGbWD1WGdqnWheTsUVSV A04q/sFcBKtDRzjSaKQoFkBBotyN22TOHPAL3fhdsk1x7kpAPfsW3hJq799qLAthOB3S QiRvlHltxOQterWq/qR1CEAVSlnt9Rz0/1/5opPCGxzO4DJVRlUxuAurtZfG6hSK5d2L aEo/4xrKj0F3ASUjt1PtA5MzLuQBNuK0fOwDi9B13eZaFzDEWKbUik1sBmjUf6smQZ3t Hphw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (expired) header.i=@flygoat.com header.s=fm2 header.b="xQaKSO/s"; dkim=neutral (expired) header.i=@messagingengine.com header.s=fm1 header.b=iZqLyH1w; 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=flygoat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k9-20020a170906578900b00978884c2f47si4926992ejq.867.2023.09.03.06.48.01; Sun, 03 Sep 2023 06:48:08 -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=neutral (expired) header.i=@flygoat.com header.s=fm2 header.b="xQaKSO/s"; dkim=neutral (expired) header.i=@messagingengine.com header.s=fm1 header.b=iZqLyH1w; 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=flygoat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244519AbjHaKEw (ORCPT + 26 others); Thu, 31 Aug 2023 06:04:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48410 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229733AbjHaKEv (ORCPT ); Thu, 31 Aug 2023 06:04:51 -0400 Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 33A45CEE; Thu, 31 Aug 2023 03:04:48 -0700 (PDT) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id CC4595C0094; Thu, 31 Aug 2023 06:04:45 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Thu, 31 Aug 2023 06:04:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=flygoat.com; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to; s=fm2; t= 1693476285; x=1693562685; bh=3Bxg+078KgJz5tyNgD/JmbFy76+3swKXt6B GQD9tQ3o=; b=xQaKSO/slhT3iA6z7K5DoGuYaIFmdHmzjpEo0OmEiUFCe4VqLi1 xU6xeQdztTvQFeaH/AfVmqolCmgFZvEOTNITKudVAa956Q/5yA6eGWh41wiMOI8x gT5YyXsGBaGDCRgfSY2z5Y1LoiotjF5ZEroa5bW/lTJNwMKXey5sce2CQ+BGsk5c vulklhbn4WCP1/koVDm3jTQn9SeX2QG6kRNkfzCm0ixri46ljbKecFa4U3faxS7X I6MYBozS+vrqSgIgqruc58RES+kXRq0+heaBLB3gQ8bZ8m25KIzn5t6OlYvEMYVk wP8OwtVgbC4lfhTwDAzNdfwP9PJyui/efGw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1693476285; x=1693562685; bh=3Bxg+078KgJz5tyNgD/JmbFy76+3swKXt6B GQD9tQ3o=; b=iZqLyH1wWf1q38vMPMgm18pJKTKFDes4WE2z36cbp7XPNyN3mct GRyOX2+EibJYON8+OHzOfQ0apZwy2Uaf6mPPF+AQERGPw4grTA7Cizk8ElpHqipN F/Pb9CW11XMYHBRnMLIlctSYfR7JkiE1i4epHorM/+59Ff1uZR175D3+ufl+RGml r3ooSFRWDc93kxePIDZEWICdYBGsCZ3bJ11sesWxIDJULk0mwyKLufcCA5MTCPNv HzffujUf7yeB2lwlE1ZgsujxWUiUJf03Wm1Tb1wiVz8U2YpcJByPwwNouVdTq4wN G7kCrdApfeVAVUtbHtmZh9jz+uX3nlfuubQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedviedrudegtddgvdegucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepkfffgggfuffvvehfhfgjtgfgsehtkeertddtfeejnecuhfhrohhmpeflihgr gihunhcujggrnhhguceojhhirgiguhhnrdihrghnghesfhhlhihgohgrthdrtghomheqne cuggftrfgrthhtvghrnhepudfhkeevvddtueekfeefgfetlefgueegueeltddtieejgeei heevgfehgfdvfeegnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilh hfrhhomhepjhhirgiguhhnrdihrghnghesfhhlhihgohgrthdrtghomh X-ME-Proxy: Feedback-ID: ifd894703:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 31 Aug 2023 06:04:43 -0400 (EDT) Message-ID: Date: Thu, 31 Aug 2023 18:04:39 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.14.0 Subject: Re: [PATCH v2] pci: loongson: Workaround MIPS firmware MRRS settings Content-Language: en-GB To: Huacai Chen , bhelgaas@google.com Cc: linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, kw@linux.com, lpieralisi@kernel.org, stable@vger.kernel.org References: <20230725061008.1504292-1-jiaxun.yang@flygoat.com> <861a809d-3df1-327e-e033-87506f6d89e5@flygoat.com> <62a7b292-ea1e-fb88-79cb-e7968d350a5e@flygoat.com> From: Jiaxun Yang In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-6.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS autolearn=ham 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 在 2023/8/31 17:42, Huacai Chen 写道: > On Thu, Aug 31, 2023 at 4:58 PM Jiaxun Yang wrote: >> >> >> 在 2023/8/31 14:22, Huacai Chen 写道: >> >> [...] >>> But it is worth to try, and you can walk the children to set mrrs when >>> the quirk runs on bridges, I think. >> No, this will break hotplug, I had managed to get hotplug work on 2K1000. >> Also we have no guarantee on order of discovering devices. >>>> but the old quirk should run on every single device. >>> Your current patch has a drawback that both quirks will run for MIPS, >>> and their order is random (though it may cause nothing, but not >>> elegant). >> Actually loongson_mrrs_quirk is declared by DECLARE_PCI_FIXUP_EARLY but >> loongson_old_mrrs_quirk is declared by DECLARE_PCI_FIXUP_ENABLE, >> which means loongson_old_mrrs_quirk always runs after loongson_mrrs_quirk as >> expected. > Then I think it is better to put this quirk in arch/mips/loongson64/, > just as pci_fixup_radeon(). Hmm, spiting two quirks with similar functionality into two places doesn't sound like a good idea. PCI folks, what do you think? Thanks. - Jiaxun [...]