Received: by 2002:ab2:60d1:0:b0:1f7:5705:b850 with SMTP id i17csp1011323lqm; Thu, 2 May 2024 02:32:50 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUvo3knDRqm/YjGXPMsjqJcoJPgXCxZ5T8dLYUVZ6ADnUkFz9+OmX0f+XyogLVCL0+EKDWSCpVHnrktM56kV3ewKaWBoxLuGuKRrPsbHQ== X-Google-Smtp-Source: AGHT+IFWLgfuE/Wvs0BNprPlQFtYhoK+ZzK9jLFsg2aSgCNqIVQlF7Wp+iy+e5cG7vSrbIjUTVvu X-Received: by 2002:a17:90a:b788:b0:2a7:455d:82db with SMTP id m8-20020a17090ab78800b002a7455d82dbmr5027167pjr.36.1714642370106; Thu, 02 May 2024 02:32:50 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714642370; cv=pass; d=google.com; s=arc-20160816; b=LIJVFFCus+6oyGog4mV8NHnrpREDYp1JILetzXozHleHlCz7zRk+pi+QV7m55jdInx 92gjdjT7+tdGBskU27zcyO51R+AaPumkqG+eumL5LndhcAgBbS15tReTZcIzLFfKwOYW 3X87bEcZuyhLQ3idbxL/olCoYQOyQr52oKADStyjl++Z/qce5pySBM6CQ19eoaHu1yUH PXBxH2K8i0q/Mvy56V9/bOifRo0O91nX+/Hqncwx4MUfMzpOYr6BeXiPpZNURZcsO02u HixoGy3wawU/+sbReUCU3oRJaTwZq9jyxy5GlXcIrp3lsVtStSTeIFm8hbuTMfO4fSgx aMYg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=v5c/xzuoMbwgLTcT01z9IraUvhuoSBUQKktz1b968Xw=; fh=5ub3fBCFG7G6N9Ag9PaE5HLrJEYtwO6DMeBSM2PGHlg=; b=uF+92RJhRnf6/qk/PUitRmzZlwaCezoWVWR5/jXHaEHSzVl/iq7jp3laTfU4R08Ttw 5DoCtTGGdH+N0YnyfDtwyvX24ZHnzLvt//P0yI6/mdry1iwO1Vh+1JlM6npgnZZqYc3l i4DKqea/ukis6yUyErPklnFXWLeL4YA3Cdx+HjvmyxyPUyWddPFJ8yK5dWpfgDEjuVh7 nvkV2/jcy/z/bcNWFTMLPoTPEWSRg0mUMvfMzoBn1rROg0vrW9530PghwIYopLMmE32R An95//pyU26qaoQGGA6pjwE73DNMwSI1EnCwE2hZYQoMbc/z17bsK0vZE63ZqN7nNkEE pyrA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=YIOO6VEH; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-kernel+bounces-166226-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-166226-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id p15-20020a17090a428f00b002b117520218si721423pjg.13.2024.05.02.02.32.49 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 May 2024 02:32:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-166226-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=YIOO6VEH; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-kernel+bounces-166226-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-166226-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com 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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 622F8286B89 for ; Thu, 2 May 2024 09:31:35 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9B1735645B; Thu, 2 May 2024 09:31:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="YIOO6VEH" Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (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 9915153373; Thu, 2 May 2024 09:31:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714642278; cv=none; b=OiQmRTrIaS6lrtrebV+8DC+caxvbhwildh6flScYkujCGriq84TD5LsGKuVEeGL1kyRKnex30kzkdWhJBb6mlwjgbhB/hk1H+Fsxr4xD/TfvlsVmhirtPZntA6UVAqMrHDXpWUbH7cjyJufhz4X/omS0X6p/YHX0mO9DcDPb/8c= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714642278; c=relaxed/simple; bh=S9nKncTosJNtyw2fp8qJOuPt58/MGn3btQW/Tmk2CNI=; h=Date:From:To:CC:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=omzBpLBBHYjRgxd6xJR7Ex6GUHcnSqQUaKJs94O/W+22l1lyurzTEe8N4NXj4NaQWBUpjsGGoPbo6sPGs3PLr+kLTUZ9k1xtOsEOklZypGQmzmZ5dKkh80/zC5W1L4T0xwwunoslm11g00h2WghgQ14OETrLzCjdg6tQmbo07Ro= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=YIOO6VEH; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Received: from pps.filterd (m0279863.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 4429Jhjo016657; Thu, 2 May 2024 09:31:07 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=qcppdkim1; bh=v5c/xzuoMbwgLTcT01z9I raUvhuoSBUQKktz1b968Xw=; b=YIOO6VEH6ekLYPiopTBdm3D7pDqfUWzV0MvSM hVEnz1X+Qin/RrMNRK8CHdWZEx8s0++v1Y1hQ0NE6XhQZAeekqIet5YzH3TXFNOZ OVYOABl3qMJaPWgIELxdWC8AsLXzkm/XLttAwOd70zR/brw9jVIJkpyCkq/lDxl7 gPDPgN5vv7KQ0od3sC24ZaG0ID1NppOhEOxVwAwZmSl215w4BV0gq50teK13vOGz 9ShQIK7rl1tclqkvuRMPcKdChO6rwrkSMRjw91fEPciU2ayTBN76FDtZB0WGBZh4 NuMTEz5xZPQtGkRqhuLWBA3E/xM8nCCrwS2EZWz0b5M79EgYQ== Received: from nasanppmta01.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3xv6q0r6c3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 02 May 2024 09:31:06 +0000 (GMT) Received: from nasanex01b.na.qualcomm.com (nasanex01b.na.qualcomm.com [10.46.141.250]) by NASANPPMTA01.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 4429V3vm024061 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 2 May 2024 09:31:03 GMT Received: from hu-varada-blr.qualcomm.com (10.80.80.8) by nasanex01b.na.qualcomm.com (10.46.141.250) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.9; Thu, 2 May 2024 02:30:58 -0700 Date: Thu, 2 May 2024 15:00:54 +0530 From: Varadarajan Narayanan To: Konrad Dybcio CC: , , , , , , , , , , , , , Subject: Re: [PATCH v9 6/6] arm64: dts: qcom: ipq9574: Add icc provider ability to gcc Message-ID: References: <20240418092305.2337429-1-quic_varada@quicinc.com> <20240418092305.2337429-7-quic_varada@quicinc.com> <27f4f3dd-9375-40cf-8c8f-1c4edf66e31b@linaro.org> 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="us-ascii" Content-Disposition: inline In-Reply-To: <27f4f3dd-9375-40cf-8c8f-1c4edf66e31b@linaro.org> X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nasanex01b.na.qualcomm.com (10.46.141.250) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: f32cUZJHVPOeDkNbmNDX5tkaGpQ2T_YX X-Proofpoint-GUID: f32cUZJHVPOeDkNbmNDX5tkaGpQ2T_YX X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1011,Hydra:6.0.650,FMLib:17.11.176.26 definitions=2024-05-01_16,2024-05-02_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 lowpriorityscore=0 bulkscore=0 priorityscore=1501 spamscore=0 mlxlogscore=999 malwarescore=0 phishscore=0 adultscore=0 clxscore=1015 mlxscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2404010003 definitions=main-2405020058 On Tue, Apr 30, 2024 at 12:05:29PM +0200, Konrad Dybcio wrote: > On 25.04.2024 12:26 PM, Varadarajan Narayanan wrote: > > On Tue, Apr 23, 2024 at 02:58:41PM +0200, Konrad Dybcio wrote: > >> > >> > >> On 4/18/24 11:23, Varadarajan Narayanan wrote: > >>> IPQ SoCs dont involve RPM in managing NoC related clocks and > >>> there is no NoC scaling. Linux itself handles these clocks. > >>> However, these should not be exposed as just clocks and align > >>> with other Qualcomm SoCs that handle these clocks from a > >>> interconnect provider. > >>> > >>> Hence include icc provider capability to the gcc node so that > >>> peripherals can use the interconnect facility to enable these > >>> clocks. > >>> > >>> Reviewed-by: Dmitry Baryshkov > >>> Signed-off-by: Varadarajan Narayanan > >>> --- > >> > >> If this is all you do to enable interconnect (which is not the case, > >> as this patch only satisfies the bindings checker, the meaningful > >> change happens in the previous patch) and nothing explodes, this is > >> an apparent sign of your driver doing nothing. > > > > It appears to do nothing because, we are just enabling the clock > > provider to also act as interconnect provider. Only when the > > consumers are enabled with interconnect usage, this will create > > paths and turn on the relevant NOC clocks. > > No, with sync_state it actually does "something" (sets the interconnect > path bandwidths to zero). And *this* patch does nothing functionally, > it only makes the dt checker happy. I understand. > > This interconnect will be used by the PCIe and NSS blocks. When > > those patches were posted earlier, they were put on hold until > > interconnect driver is available. > > > > Once this patch gets in, PCIe for example will make use of icc. > > Please refer to https://lore.kernel.org/linux-arm-msm/20230519090219.15925-5-quic_devipriy@quicinc.com/. > > > > The 'pcieX' nodes will include the following entries. > > > > interconnects = <&gcc MASTER_ANOC_PCIE0 &gcc SLAVE_ANOC_PCIE0>, > > <&gcc MASTER_SNOC_PCIE0 &gcc SLAVE_SNOC_PCIE0>; > > interconnect-names = "pcie-mem", "cpu-pcie"; > > Okay. What about USB that's already enabled? And BIMC/MEMNOC? For USB, the GCC_ANOC_USB_AXI_CLK is enabled as part of the iface clock. Hence, interconnect is not specified there. MEMNOC to System NOC interfaces seem to be enabled automatically. Software doesn't have to turn on or program specific clocks. > >> The expected reaction to "enabling interconnect" without defining the > >> required paths for your hardware would be a crash-on-sync_state, as all > >> unused (from Linux's POV) resources ought to be shut down. > >> > >> Because you lack sync_state, the interconnects silently retain the state > >> that they were left in (which is not deterministic), and that's precisely > >> what we want to avoid. > > > > I tried to set 'sync_state' to icc_sync_state to be invoked and > > didn't see any crash. > > Have you confirmed that the registers are actually written to, and with > correct values? I tried the following combinations:- 1. Top of tree linux-next + This patch set * icc_sync_state called * No crash or hang observed * From /sys/kernel/debug/clk/clk_summary can see the relevant clocks are set to the expected rates (compared with downstream kernel) 2. Top of tree linux-next + This patch set + PCIe enablement * icc_sync_state NOT called * No crash or hang observed * From /sys/kernel/debug/clk/clk_summary can see the relevant clocks are set to the expected rates (compared with downstream kernel) Does this answer your question? Please let me know if you were looking for some other information. Thanks Varada