Received: by 2002:a05:7208:3003:b0:81:def:69cd with SMTP id f3csp821827rba; Wed, 27 Mar 2024 12:51:17 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWmiasaZ4PRPrwiS1hqDbE9MhBTQQn7/Pbxi/p6YPm5q/Euw//YithiiNFU4RE4hSmWHBjD/bausfhmepkbguchfLpw+BboZ9qmxfGrwg== X-Google-Smtp-Source: AGHT+IE3GsxWhWM3t88tUpvJVmap6vVKiKsyS/42hqgYo7S/Jk7JZDWry3PV4hYPzHMb2EQqbSQN X-Received: by 2002:a17:902:d1cc:b0:1e0:b5d4:9f61 with SMTP id g12-20020a170902d1cc00b001e0b5d49f61mr637478plb.36.1711569077063; Wed, 27 Mar 2024 12:51:17 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711569077; cv=pass; d=google.com; s=arc-20160816; b=nC7EhTHglpKahZKp1kM0MPq/aSFT3WJkJWyd/+ismOTwZqDThry2g1II/ii5EKG0CD cmNiMoeu6OQ2UMZOxvcoPNuVx7Ac6yiQagQjl5Xc338PJuhrInrpRnynVY0uAzBAWkIo i2ZVQzRZExYSkHRdQadtxcSlqjm3K6/P/BG+bXOxK6y5gb7WqiQ1ZUFV+PkpJHWtQoTk C93S5dSqEUTXP8Rpzl/DzimgyfkDXcVx6dgtVwbdcd77rYq//Buqqn2xZJt4skq7gaCo dawrvQeFdISZCR9DlQrvPn+QbwRDxQUVOqmZkvBaJ31F324YcHoNDcYmZ8XK8gTco2/e ggug== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:autocrypt:from :content-language:references:cc:to:subject:user-agent:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:date:message-id :dkim-signature; bh=dzIicXHMZ050qTLYUr+hlMJXN5VMIm4RTBB+qAp88c4=; fh=D0XCdIpHZHAmvHTA6GBoBNmfMA8BykPG+55djRT5II0=; b=dMIy7+Pm7dYQxRszCyyHwsPRNQ47e7vgj0UyKVKSvcmZkuR7uT1VrfNjrJZDgkhtsB 1B7Zrr4yKVOGgYVjMsRAEliTm/NzBHROqmpOEwNtBava+B3JZJzY+7+x9S4W5o1b4VPc ODSEsY06XqN3unMdaDQuJvzr01vlHkqpFRuun4jlKMA5LV2HKKei4PZP5FMRbHBs7nmL ReqalUJ6sgyFsVolZjru6PmaPT7wJWc4FEZ58DDh13YZpqweLN9vfxEJziRbw/UDKsa6 PSPPVvGzUYCfQSoZeeRpvDiGgJAakUkY4u/9YbSdwUFkzxg8QgwMqtZkZsx7mDw1eEm3 xaPA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=QwS9S3ir; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-121915-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-121915-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id n10-20020a170902f60a00b001dfcea892bfsi9926812plg.526.2024.03.27.12.51.16 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Mar 2024 12:51:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-121915-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=QwS9S3ir; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-121915-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-121915-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.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 sy.mirrors.kernel.org (Postfix) with ESMTPS id E1280B26CD7 for ; Wed, 27 Mar 2024 19:37:59 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5538D1514C3; Wed, 27 Mar 2024 19:37:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="QwS9S3ir" Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B8F1B1E52C for ; Wed, 27 Mar 2024 19:37:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.51 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711568268; cv=none; b=BLs75fZ/4DvfpO9EWZJTe1+ROx0kU8ghcs7Jw1T3ZFV9Fp4zcMl8APk4OEyW8PY1W4SwcXD7ifS/Y4GC+3tnzZ4bKkLy5UI2EZofA+KTx9FmmGgiHMwcFq90NG4YIyxWkR+rz9YHMHEP0VHb/kvIZ9MNAl8cD07eh2b6QdysOcQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711568268; c=relaxed/simple; bh=2gqZ4R2kRz1uznHqor1WK2GlQpJzKrC2SE0LyqyvmYo=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=tq4Rx3xAELNf6+2mKEw1TACtlUfsu0wHXTK0W0GNz5BaKUe/EmIRVHtvAgQpmBzQUCZWRRLTxW5aezvnhOaitUkNZ+n+Vb/gb34QlIgXBQCiu5COpT9aELwcIdfZ+1OrJ3eHmgGWmspK+WmnQqudb45yJZBsDgpdxUBejPFJzaY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=QwS9S3ir; arc=none smtp.client-ip=209.85.167.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-512e4f4e463so178289e87.1 for ; Wed, 27 Mar 2024 12:37:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1711568265; x=1712173065; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:autocrypt:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:from:to:cc:subject:date:message-id:reply-to; bh=dzIicXHMZ050qTLYUr+hlMJXN5VMIm4RTBB+qAp88c4=; b=QwS9S3ir3Cf7b8aflI4zEEKy2c28C9K87cz5YrYzldHkjz2vV3X85d8DM5u7WV6xe5 kx9gxgC7yBRyL2fObiRku/ZBQ76FRKIBb3+YW0ehwW1h/Q/NFJTwpGER3N1sS73Y4j+3 PtlYFA8ZlR23HpSOZSOpjd2CvpXno3ssJq6DfsJZXaKf5XzDQOUx00gdI5ZLJOISjn2u zntNFhPx0MKAz1dCy+NOUjBRzK3QXLu9cSxZz/bxpYXB32FAg1Yn8naGxjGuuw6nC44U lY0mCYpSIYe4uC++NnfdtmIObsjCpghqN8GowootOwFut4kENtu7y/WJHWi4/cTuuR6h +yIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711568265; x=1712173065; h=content-transfer-encoding:in-reply-to:autocrypt:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=dzIicXHMZ050qTLYUr+hlMJXN5VMIm4RTBB+qAp88c4=; b=qPhIlZrXxyEBEO/20sBqERoSuEwBOP30YqBaaDFm5eQlZtuawPlouBe9hoHOVgLSAl 5rBsHdnNv7sho7Kz3O37PIW7OgV0FbRakk8KPw9KFUyHqAF9s/4azGWYpn9AShnZci4N K88GT7iJp1pbSOIpqntLhDHMKHbA+bGOCMpbtAiRrXLM/TZK+akugOpNx/sy9OIMk3JY 2/1RW76LYTNFPnw1N+eq510J5xmySTvqU1TC1eZidsjclnfF5USvnh6pHXqsQXz4X5gc RuvXn17WVrzK5u+pjkmucMi/dVkV2zN4Q2mmZoJxKs+bbDuTPvq/anxiVb/zqzNr7A/I GcWA== X-Forwarded-Encrypted: i=1; AJvYcCWWahWuAhX31Xf3+EFQ7nRMM65ocDlNk+ssIOrDkqdXe5ffpSrNs05SgFal6n3IRCqlwWy6S+LrJP4+MeWFhRFZ467N5bzXohfyivlU X-Gm-Message-State: AOJu0YwB7DI3yoyk55cm9+y4i7y7LDNKGj8462HRsqFyWApGczkrLooY AEA0/G1oTI6dJ/8JBMSmMd2AZ3GnnHcPMdiGb7QH5ZgbnR8+0FNxBzL87PZRsi7DEWKW8ime9k/ 9 X-Received: by 2002:a19:5e4b:0:b0:513:21a9:79a8 with SMTP id z11-20020a195e4b000000b0051321a979a8mr242105lfi.62.1711568264830; Wed, 27 Mar 2024 12:37:44 -0700 (PDT) Received: from [192.168.92.47] (078088045141.garwolin.vectranet.pl. [78.88.45.141]) by smtp.gmail.com with ESMTPSA id lm9-20020a170906980900b00a4761c94a5esm4327268ejb.107.2024.03.27.12.37.43 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 27 Mar 2024 12:37:44 -0700 (PDT) Message-ID: <11a193b1-7a3f-43ca-b885-cac8fdf2190b@linaro.org> Date: Wed, 27 Mar 2024 20:37:43 +0100 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 v2 2/3] PCI: qcom: Read back PARF_LTSSM register To: Johan Hovold Cc: Bjorn Helgaas , Bjorn Andersson , Manivannan Sadhasivam , Lorenzo Pieralisi , =?UTF-8?Q?Krzysztof_Wilczy=C5=84ski?= , Rob Herring , Bjorn Helgaas , Philipp Zabel , linux-arm-msm@vger.kernel.org, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold References: <20240215161114.GA1292081@bhelgaas> Content-Language: en-US From: Konrad Dybcio Autocrypt: addr=konrad.dybcio@linaro.org; keydata= xsFNBF9ALYUBEADWAhxdTBWrwAgDQQzc1O/bJ5O7b6cXYxwbBd9xKP7MICh5YA0DcCjJSOum BB/OmIWU6X+LZW6P88ZmHe+KeyABLMP5s1tJNK1j4ntT7mECcWZDzafPWF4F6m4WJOG27kTJ HGWdmtO+RvadOVi6CoUDqALsmfS3MUG5Pj2Ne9+0jRg4hEnB92AyF9rW2G3qisFcwPgvatt7 TXD5E38mLyOPOUyXNj9XpDbt1hNwKQfiidmPh5e7VNAWRnW1iCMMoKqzM1Anzq7e5Afyeifz zRcQPLaqrPjnKqZGL2BKQSZDh6NkI5ZLRhhHQf61fkWcUpTp1oDC6jWVfT7hwRVIQLrrNj9G MpPzrlN4YuAqKeIer1FMt8cq64ifgTzxHzXsMcUdclzq2LTk2RXaPl6Jg/IXWqUClJHbamSk t1bfif3SnmhA6TiNvEpDKPiT3IDs42THU6ygslrBxyROQPWLI9IL1y8S6RtEh8H+NZQWZNzm UQ3imZirlPjxZtvz1BtnnBWS06e7x/UEAguj7VHCuymVgpl2Za17d1jj81YN5Rp5L9GXxkV1 aUEwONM3eCI3qcYm5JNc5X+JthZO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kQR4cBcg5dfFju1Q//Xta1ShwL0MLSC1KL1lXGXeRM 8arzfyiB5wJ9tb9U/nZvhhdfilEDLe0jKJY0RJErbdRHsalwQCrtq/1ewQpMpsRxXzAjgfRN jc4tgxRWmI+aVTzSRpywNahzZBT695hMz81cVZJoZzaV0KaMTlSnBkrviPz1nIGHYCHJxF9r cIu0GSIyUjZ/7xslxdvjpLth16H27JCWDzDqIQMtg61063gNyEyWgt1qRSaK14JIH/DoYRfn jfFQSC8bffFjat7BQGFz4ZpRavkMUFuDirn5Tf28oc5ebe2cIHp4/kajTx/7JOxWZ80U70mA cBgEeYSrYYnX+UJsSxpzLc/0sT1eRJDEhI4XIQM4ClIzpsCIN5HnVF76UQXh3a9zpwh3dk8i bhN/URmCOTH+LHNJYN/MxY8wuukq877DWB7k86pBs5IDLAXmW8v3gIDWyIcgYqb2v8QO2Mqx YMqL7UZxVLul4/JbllsQB8F/fNI8AfttmAQL9cwo6C8yDTXKdho920W4WUR9k8NT/OBqWSyk bGqMHex48FVZhexNPYOd58EY9/7mL5u0sJmo+jTeb4JBgIbFPJCFyng4HwbniWgQJZ1WqaUC nas9J77uICis2WH7N8Bs9jy0wQYezNzqS+FxoNXmDQg2jetX8en4bO2Di7Pmx0jXA4TOb9TM izWDgYvmBE8= In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 15.03.2024 5:47 PM, Johan Hovold wrote: > On Fri, Mar 15, 2024 at 11:16:59AM +0100, Konrad Dybcio wrote: >> On 2/16/24 07:52, Johan Hovold wrote: > >>> This makes no sense. As Bjorn already said, you're just polling for the >>> link to come up (for a second). And unless you have something else that >>> depends on the write to have reached the device, there is no need to >>> read it back. It's not going to be cached indefinitely if that's what >>> you fear. >> >> The point is, if we know that the hardware is expected to return "done" >> within the polling timeout value of receiving the request to do so, we >> are actively taking away an unknown amount of time from that timeout. > > We're talking about microseconds, not milliseconds or seconds as you > seem to believe. > >> So, if the polling condition becomes true after 980ms, but due to write >> buffering the value reached the PCIe hardware after 21 ms, we're gonna >> hit a timeout. Or under truly extreme circumstances, the polling may >> time out before the write has even arrived at the PCIe hw. > > So the write latency is not an issue here. Right, I'm willing to believe the CPU will kick the can down the road for this long. I'll drop this. Konrad