Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp665723rdb; Mon, 29 Jan 2024 14:24:31 -0800 (PST) X-Google-Smtp-Source: AGHT+IG7FBPuTPso+T50emYOS8gzuazrerdE8cRM8vHY/wBvFQgR980mBoG21SP8DKvWF+EskgsV X-Received: by 2002:a17:906:cf8f:b0:a30:c104:3a9c with SMTP id um15-20020a170906cf8f00b00a30c1043a9cmr8582100ejb.13.1706567071611; Mon, 29 Jan 2024 14:24:31 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706567071; cv=pass; d=google.com; s=arc-20160816; b=OQ/N68wy23lrUXjSI0AQIXQQ9UaMqxlEeS0tPeJkvgCovesshn7lO7KV65q3KvcVwI 2hhQvPWsYQOE82zq8zp5od1UGV6Z8wf/TIObHpjrFqgQ6L1yag3/bF5eMnXNVegcDbiR Fc3nywSpJHQODA/4Ab0NaJoEl2aLUuwirwnAEjckVFhyUJF9Y+ShS7y1OCXUQVHcK431 Z6EF2KuSlz36nXsMnwRVEXPPDLw91aFt11njjXgZVYS9k/X22e/pwNkFNZF13j+Q6Ef3 ITnG0oMLpskfCGhBFvx8ve5j5PByfmY5GPzg2rgXcP8ytL5gDOfQPPJnIt5VQPMlMpTI 1kyQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :message-id:subject:cc:to:from:date:dkim-signature; bh=gIbOAaN6JrpFISmabguIJ7/Zk5OBj+4D3K/Pr7IV0LM=; fh=yitKyQkVbb3/Q2UBVh9TzgETEinm4DaTRKDNXnhgric=; b=yYZ5lwT96pVBzj7/6ACoApNfwsNaUN046K7Em+hHrl/uKug+5vD3h28yurQzQfkXHx lEbj+MkmHEaJawT5X8DqXhwd3Yk2byuSxpBoxjGmkEShUI7EvmvcXsz5HFFeDb6AzDa0 1jbg5M94toHr3zHBZcFAV7bRvyfWfMIOtpOpfKQtse0UywFLP0AsE+rNUCUGI7rVetx6 OgmC0P0sSTyOV6Yn7veo01xsKYlE6EYI8ql8qJW3ADFAknz3BdXSBQYPcDx9vkOKvJls JlVpuYrl+aWwx+ANuiIRZLUGeahFGvpReJ61bkYkk41/0jbuwufCmXTlLmp1ba9Nfdy7 kOpg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Ck2k0fZw; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-43568-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-43568-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id g18-20020a170906349200b00a2c29dde73dsi3820362ejb.542.2024.01.29.14.24.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Jan 2024 14:24:31 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-43568-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Ck2k0fZw; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-43568-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-43568-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 5FD091F252D0 for ; Mon, 29 Jan 2024 22:24:31 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 983EA15959B; Mon, 29 Jan 2024 22:24:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Ck2k0fZw" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 ACD21604C5; Mon, 29 Jan 2024 22:24:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706567059; cv=none; b=SfCuUhB17tOT1m7HkIvKvcDmwGHHWsOA2d/gHBi7/Mr6SmXqaYntHZRlNVxWr4ZjgA/W/57uJYaYXFnLWR57V/uUaxni6B/+B+iSIzTkOoXSXJV8LEtH8j4kSIWgI4v4bjuSFC3AiHAcMbZXwmgox0pDeXQvKK/OQtSkZS8IGik= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706567059; c=relaxed/simple; bh=ybFG/1Z4KxjabyhfsG3KnCV0yC0WVemE8bZH31BWBWs=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type: Content-Disposition:In-Reply-To; b=LKCkAd4RSdtnwguZOzkaRwvaEJdX4xNP7lq6EKac4pXwJmonhMuQ3eTX2GOCZ4An8PmO+OY3r75/9LsiffqmEDKXOPN9hacN+2aZsA+zjcccQPgEb+7eSZfiasq4/AyLAppj28rQv4LrLLQyMrAKjGPwrIoA4WbOiWtMoIb5/Tk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Ck2k0fZw; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 37A73C433C7; Mon, 29 Jan 2024 22:24:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1706567059; bh=ybFG/1Z4KxjabyhfsG3KnCV0yC0WVemE8bZH31BWBWs=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=Ck2k0fZwm/Pk8pIi0KJeREyhovqDDsGwMIZgTbTDEMIvOq+jcsS6gwzg6tSqm2yg/ Un7ZiJ28Dy5HREDsy3riYcb7eyEhabvcj1iKQ4sPAxSVHGGGB0HE/fsf2aBy4FAhMQ pEC7ux/ujiSzz8Y7i5g4gIQxwMxX5NHtu9xqWz+Qb4x2l05G7BsmL3oMOh4m6siavA TCiOXzOQdnUGZzjSpIyAukY0UNO5mkt2X8Sy5TzavFpMOQQLgruDl//y/D89GDN+T+ JkRoApJbNDyjseUhath0mAq9O1iHmGXNMri1QlN1mzR6hlIcdcMBI3yBc8XFxF9QZ+ VFCMG08qKy0mw== Date: Mon, 29 Jan 2024 16:24:17 -0600 From: Bjorn Helgaas To: Thomas Richard Cc: Linus Walleij , Bartosz Golaszewski , Andy Shevchenko , Tony Lindgren , Haojian Zhuang , Vignesh R , Aaro Koskinen , Janusz Krzysztofik , Andi Shyti , Peter Rosin , Vinod Koul , Kishon Vijay Abraham I , Philipp Zabel , Tom Joseph , Lorenzo Pieralisi , Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , Rob Herring , Bjorn Helgaas , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-omap@vger.kernel.org, linux-i2c@vger.kernel.org, linux-phy@lists.infradead.org, linux-pci@vger.kernel.org, gregory.clement@bootlin.com, theo.lebrun@bootlin.com, thomas.petazzoni@bootlin.com, u-kumar1@ti.com Subject: Re: [PATCH v2 13/15] PCI: cadence: add resume support to cdns_pcie_host_setup() Message-ID: <20240129222417.GA477936@bhelgaas> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20240129221647.GA477676@bhelgaas> On Mon, Jan 29, 2024 at 04:16:49PM -0600, Bjorn Helgaas wrote: > On Fri, Jan 26, 2024 at 03:43:39PM -0600, Bjorn Helgaas wrote: > > On Fri, Jan 26, 2024 at 03:36:55PM +0100, Thomas Richard wrote: > > > From: Théo Lebrun > > > > > > That function mixes probe structure init and hardware config. > > > The whole hardware config part must be done at resume after a suspend to > > > ram. > > > We therefore pass it a boolean flag determining if we are at probe or at > > > resume. > > ... > > It'd be super nice to have them the same. Passing in a "probe" flag > > works but seems a little harder to read in cdns_pcie_host_setup() and > > you have to keep track of what it means in the callers. > > Maybe a better way to say this is that this patch uses the "probe" > flag to select the behavior of cdns_pcie_host_setup(), and I think it > would be nicer to split those two behaviors into separate functions. Oops, sorry, Andy, I wrote this before I saw your similar response from last Friday. Didn't mean to repeat what you already said! Bjorn