Received: by 2002:a05:7412:e794:b0:fa:551:50a7 with SMTP id o20csp2154333rdd; Fri, 12 Jan 2024 00:29:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IHk1xeY2Wf7pA1i3hqlYsJJjszs/VwvrXM2alBCiQUa5JW9YUzwSkoCN1Kl6Dz5UUHl0FY4 X-Received: by 2002:aa7:cf04:0:b0:554:3ba8:f804 with SMTP id a4-20020aa7cf04000000b005543ba8f804mr411310edy.28.1705048186022; Fri, 12 Jan 2024 00:29:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1705048186; cv=none; d=google.com; s=arc-20160816; b=aA3wrtJuI+zeCDNVs7xs7CiRXtOI1E25KJq0ARVd/5cFPBkYV6pwntzriKP70mzMxS OlRDZdwcy1YmB39ujEm+FffmLfbkoihTWo+hS5OA/YwktUurHpLoPqYiweX50p4W9BTt KHr2yFVmYPvjM9/jx3uMTtWugMF/z8Ii/zWA8XZNeG0CdDCz8AWSsb/W2j/qr77wjZum +SnxdJuUB9Wi3wp6cZXr5kRIYDqMmeRmCk6TWvj2g8q85tuT2Jz1FRXmwoMP4hBzIEDr 4/Sy4miqBMb+MEB47/0F6Q7azdKZoZYrJZN/3WkY7If0MgdxKNDB6554BjopWPgogwBT P8vg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:date:message-id :dkim-signature; bh=rzSBMcH9OV38tGE26hwdykcph14F12FzWZt67w15gGA=; fh=MxCuWwE8nKcSuI9PVrblrJsvk0M56IvVjf/hp0Pypns=; b=mfR/qZ58OxKSC5fhF6Squev33j+w/bQOVjsXap2jVuytdttwILvPy0JDuR/6SmaXwq Qud6yX53Nlh/QTym1UG4vbuco8rvUg43051pPxkSyT35rm39Ftf8Dru55JllvXJyy6QQ C7bpF4OgscKguhyh3scPBTt9CZRlxs2jVJr+YrFNrE+vZ4VSe1aXzFvT2rAdKudIcvjf uU2QW/YYa2DDS43MQF3udOxP1j3Z5iTOJfdgZcdELM+ZqJB4m35Wp6fSs8T3TdSG2oYa 00CGjB8rZ8atYAb4MJ64+yy/OaFj0W+pHWoOp1Ikx5al2zLqDBtj1sevjNSBDRXHi2mb LFGQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=QIzYeLBF; spf=pass (google.com: domain of linux-kernel+bounces-24424-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-24424-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id fe3-20020a056402390300b00558b0a33a7esi856645edb.499.2024.01.12.00.29.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Jan 2024 00:29:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-24424-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=@linaro.org header.s=google header.b=QIzYeLBF; spf=pass (google.com: domain of linux-kernel+bounces-24424-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-24424-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 am.mirrors.kernel.org (Postfix) with ESMTPS id 98A521F260FF for ; Fri, 12 Jan 2024 08:29:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D38625D8FA; Fri, 12 Jan 2024 08:29:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="QIzYeLBF" Received: from mail-wm1-f42.google.com (mail-wm1-f42.google.com [209.85.128.42]) (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 EC5A85D8E7 for ; Fri, 12 Jan 2024 08:29:28 +0000 (UTC) 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-wm1-f42.google.com with SMTP id 5b1f17b1804b1-40b5155e154so79130785e9.3 for ; Fri, 12 Jan 2024 00:29:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1705048167; x=1705652967; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=rzSBMcH9OV38tGE26hwdykcph14F12FzWZt67w15gGA=; b=QIzYeLBFr1Z2YhvUAjOFcfs1vHuJC85UwMAyKvH92LeEjiUSP4vk4QE2+d83wN1p6f NrLfdg2ic/i1iJZqF1Cfn1ef+9ecmTe6oZJFJdfKzV2bXC58ZPzAEQ+7Gpkh+yikxUjW CGlH+CqSBClqGBA4NNfNpSecJlL0rh5VRr6YK7C+vMkhO0QLTCaUCERr8im6UN9Sb74C Ton0svIQyOQ5FCQvaoguP3c6djxE9zlubFoggcHbl/iHp2EGrhJ54UgnzeaTbEOe3Eh+ YdhzZf2QAkmT6Rm4EldX1+IewKB40ScazcaGk9uXIzhd05ZVjXhFJqjk7BOHJSiAhR7z O4XA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705048167; x=1705652967; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=rzSBMcH9OV38tGE26hwdykcph14F12FzWZt67w15gGA=; b=hfXi44M33j9AjydawQhU56vFZ9VAbJTO12HqEKhpe47iMaqO3NmRkaJ4roeXb8NaJP PYY1q+IBlblz14aSROjBrDfvv6TodKYFMVMzvakIMnWimaIEzxSJdlhgHm+s5RpGBH44 U8MvAEJ4z7sth0adNeN7PhG4JQ/vOONJlE/tnuYFR2+dYKtThROafTAEqSxuTpPArRHQ 7eW7U/qwB5z/I6dgrfwF7vDOlIl+tAWEuGOsWLGt5O5yN+qjKiD/UWnoU3zZRQ8JGttL 3BtlnPl4UcX0uwz7f2beNINTP1J+8r7fKrg4g1QSDmCCmRzDv4aEd1Jm+bHPmEZu+G3f 2MSA== X-Gm-Message-State: AOJu0Yy1PoV/EbguerreYVdP4CMghweEjyU2NitswE8RO2WoIoZtIOEb A70qYZd9pmN5A5rAJVI8rCGEn/CTpqEH1moFN7QCSympm5Q= X-Received: by 2002:a05:600c:1e17:b0:40d:5bbf:71f2 with SMTP id ay23-20020a05600c1e1700b0040d5bbf71f2mr583829wmb.5.1705048167162; Fri, 12 Jan 2024 00:29:27 -0800 (PST) Received: from [192.168.1.20] ([178.197.223.112]) by smtp.gmail.com with ESMTPSA id i8-20020a05600c354800b0040e555f12d8sm8765004wmq.8.2024.01.12.00.29.25 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 12 Jan 2024 00:29:26 -0800 (PST) Message-ID: Date: Fri, 12 Jan 2024 09:29:24 +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: Proposal for QCOM PCIe switch power and configuration driver Content-Language: en-US To: Krishna Chaitanya Chundru , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: Manivannan Sadhasivam , Veerabhadrarao Badiganti , quic_skananth@quicinc.com, bartosz.golaszewski@linaro.org, open list , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , "open list:PCIE ENDPOINT DRIVER FOR QUALCOMM" , p.zabel@pengutronix.de, Bjorn Helgaas , "open list:PCIE ENDPOINT DRIVER FOR QUALCOMM" References: <413d612f-0e31-6281-64e3-6484b85afe06@quicinc.com> <036823ce-9815-4884-aa3a-9c3831cea9bb@linaro.org> From: Krzysztof Kozlowski Autocrypt: addr=krzysztof.kozlowski@linaro.org; keydata= xsFNBFVDQq4BEAC6KeLOfFsAvFMBsrCrJ2bCalhPv5+KQF2PS2+iwZI8BpRZoV+Bd5kWvN79 cFgcqTTuNHjAvxtUG8pQgGTHAObYs6xeYJtjUH0ZX6ndJ33FJYf5V3yXqqjcZ30FgHzJCFUu JMp7PSyMPzpUXfU12yfcRYVEMQrmplNZssmYhiTeVicuOOypWugZKVLGNm0IweVCaZ/DJDIH gNbpvVwjcKYrx85m9cBVEBUGaQP6AT7qlVCkrf50v8bofSIyVa2xmubbAwwFA1oxoOusjPIE J3iadrwpFvsZjF5uHAKS+7wHLoW9hVzOnLbX6ajk5Hf8Pb1m+VH/E8bPBNNYKkfTtypTDUCj NYcd27tjnXfG+SDs/EXNUAIRefCyvaRG7oRYF3Ec+2RgQDRnmmjCjoQNbFrJvJkFHlPeHaeS BosGY+XWKydnmsfY7SSnjAzLUGAFhLd/XDVpb1Een2XucPpKvt9ORF+48gy12FA5GduRLhQU vK4tU7ojoem/G23PcowM1CwPurC8sAVsQb9KmwTGh7rVz3ks3w/zfGBy3+WmLg++C2Wct6nM Pd8/6CBVjEWqD06/RjI2AnjIq5fSEH/BIfXXfC68nMp9BZoy3So4ZsbOlBmtAPvMYX6U8VwD TNeBxJu5Ex0Izf1NV9CzC3nNaFUYOY8KfN01X5SExAo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p3jmGxZw4aTc5xoAZBLo0OV+Ezo71pg3AYvq0a3/oGRG KQ06ztUMRrj8eVtpImjsWCd0bDWRaaR4vqhCHvAG9iWXZu4qh3ipie2Y0oSJygcZT7H3UZxq fyYKiqEmRuqsvv6dcbblD8ZLkz1EVZL6djImH5zc5x8qpVxlA0A0i23v5QvN00m6G9NFF0Le D2GYIS41Kv4Isx2dEFh+/Q== In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 12/01/2024 05:16, Krishna Chaitanya Chundru wrote: > ++CC Philipp Zabel ( reset controller maintainer) & Bjorn & PCI list > from PCIe subsytem. > > On 1/11/2024 11:20 PM, Krzysztof Kozlowski wrote: >> On 11/01/2024 18:38, Krishna Chaitanya Chundru wrote: >>> Hi DT maintainers, >>> >>> We are trying to upstream the QCOM PCIe switch which has I2C interface >>> to configure the switch. >>> >>> In generic a PCIe switch is a device that allows expansion of PCI >>> Express hierarchy, which allows more devices(PCIe endpoints) to be >>> connected to a single PCIe port. >>> >>> We need to configure the QCOM switch like L0s, L1ss entry times, Tx >>> amplitudes etc.. through I2C interface before PCIe link is established >>> as these settings can affect link stability if we don't configure them. >>> >>> Once PCIe switch is configured, PCIe link between the PCIe switch and >>> PCIe port connected should be established by the QCOM PCIe controller >>> driver to enumerate the PCIe endpoints connected to the PCIe switch. >>> >>> We had a QCOM switch driver which powers on the switch and do the I2C >>> configurations. >>> >>> This is how the flow goes. >>> -->Power on the switch >>> -->Do Switch configuration (over i2c) with qcom switch driver >>> -->PCIe link training and enumeration. >> >> And where is the PCI controller in this? Why isn't this represented like >> I2C or GPIO expander? You need to describe what exactly the switch is doing. >> > The PCIe link training and enumeration is handled by PCIe controller driver. > Usually a single endpoint will be connected to PCIe port, using a switch > we can connect multiple endpoints like WLAN, NVME, PCIe to ethernet > bridge etc. So in single instance of PCIe multiple endpoints are > connected and enumerated. > Like I2C or GPIO expander we don't want to configure any endpoints, here > we are trying to solve the initialization part of the switch power to > the switch and configuration of the switch before PCIe controller starts > link training and enumeration. Post your datasheet or at least send some diagrams describing everything, so I won't have to keep guessing. > >> Also, how about using existing solutions? Aren't there any? I am not >> going to look for them for you... >> > As of I know we don't have any solutions exiting now, we are trying to > explore different ways for it. So did you look it up? How much? If I find one, in the drivers, what then? Can you look for it first? >> Anyway, you should ask (means Cc) reset controller maintainers if they >> are happy for such usage of reset framework for something not being a >> reset. For similar reasons you should Cc PCI maintainers. If you ask me, >> then no, PCI switch does not look like reset line so, you should not use >> reset lines. >> > I added both maintainers now. sorry for the miss. > We want to use reset line because I2c driver has to power on the device > and configure the switch only before PCIe controller driver probes. Let's don't repeat the style of discussion we have with Luo Jie, where I say this is not reset and you say "but we want" and use some ridiculous argument. > This is how reset controller operates(correct me if I was wrong). I talk about bindings. Otherwise why would you Cc me? Just because something has power it is a reset? No, it is not. You said about configuring lines: reset does not do this. I am really tired of such discussions after last time. Getting half-baked answers from you, incomplete pictures and something just to respond to my question without providing anything valuable, because you do not want to disclose too much. I got really disappointed last time and this will affect further submissions from you. That's how reputation works, sorry. Just because it controls power, among many other things, does not mean it is a reset. Maybe it is a phy? Or a mux? How do I know? Do you expect me to guess? Best regards, Krzysztof