Received: by 2002:a05:7412:ba23:b0:fa:4c10:6cad with SMTP id jp35csp1512257rdb; Sat, 20 Jan 2024 02:02:48 -0800 (PST) X-Google-Smtp-Source: AGHT+IH+IsXsX582WLRBAJFIBCCL+2fPITdNCw8K7tUQ8BRNrHNCiLuK+gjGdx7WwunG6QNvVOVS X-Received: by 2002:a17:902:ed0c:b0:1d5:4de3:ac46 with SMTP id b12-20020a170902ed0c00b001d54de3ac46mr1488617pld.3.1705744968582; Sat, 20 Jan 2024 02:02:48 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705744968; cv=pass; d=google.com; s=arc-20160816; b=uNrE/ksqK86UEImKOIYkNYET1WnkanAnyTyjpsNhAyRZizjFXilCox6JukjoA42TPy m3LG8snzwi2dUR/crOSuTLHmWoNZ0cI6xmPpdUBUXC4Kq7vvmI71/E+yqn40kbj/Y7+v zVH4peORppHiWnFrrh/qUOn5OjkwXVdddIbbPeqi8DCPf+anCr9u/ZNN4l4OD/Bb5Hgu HEJ08Ht0J5t4wW9Y/akZiVuD8Vu4/Bojdq84T7Y9K2oMACotWChJCdb7dPTJTCDemxvb O9uRSoGaYTkWvmJlcmPGcDDSBPg5FvSPRbIL+se6Z/Q8u6mhvz2fUpgx7Vzst/FiwVqY IiLQ== 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 :references:message-id:subject:cc:to:from:date; bh=2F19as677Npl7MNzkQg2qapyI2vwkrNOz4PNCt9E1Kk=; fh=YaTZrVoCnUsNUvoMLPnvgLl3HtTjUQojd6dP7Utu1RM=; b=N69DtPiaVpl3YNpdkB+Zh0WX8CahFgllJHxBI+6zbPDGAr20b9pNwCbC6qf5QvaFnv 3+89nf43obUK6eqReRGInxPvUROqowLMfOltdDyZv2w3a1TVUDU5vYKicRlhKzyiG1U8 LLxcVr/0nmY9u/o6CM8emS2Wc9TysJvnQIohTv8i58sjwbLHjjfnlRBtu87SFK/dsQEJ TwNuUydClSzro8LOn3SsbfuVH10ohmGEWJWFanqSZx4ySU8YsCVDlw522Atijd3en2LA u/F4aZDmVhOUS3+2zPJJfkLfBN3eKGUpkisIZUmeDK9QxYTZGUONjp12kxo3MHnk/jw5 Q4Uw== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=arm.com dmarc=pass fromdomain=arm.com); spf=pass (google.com: domain of linux-kernel+bounces-31754-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-31754-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id m4-20020a170902bb8400b001d7303c7aaasi806528pls.80.2024.01.20.02.02.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 20 Jan 2024 02:02:48 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-31754-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; arc=pass (i=1 spf=pass spfdomain=arm.com dmarc=pass fromdomain=arm.com); spf=pass (google.com: domain of linux-kernel+bounces-31754-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-31754-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 8A3CCB22860 for ; Sat, 20 Jan 2024 10:02:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D11F5D26A; Sat, 20 Jan 2024 10:02:36 +0000 (UTC) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C41EE3222; Sat, 20 Jan 2024 10:02:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705744956; cv=none; b=pPB9MsQkTCg0HA4wnqDAXkGllLHv8/7Dm+U1wKGoVkyTiUZcQyYePF9QbeYiER0CwWi20EcZUaAVqtX4VAINoUAuQWoJ4jfIcrzqIh9B/h+2C0G9LsYVIVZ6mj3ir+lyttBKJrP9kERI/MduZ6jh7w8qzx/roTrULfhm5gNoSTs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705744956; c=relaxed/simple; bh=1mq/TzDDXHVp5Q39X59Xe+zvOA2DB6bcQQvkeWJI9TU=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=AfYSc18oqyXyY19othwQULuqlW3WUq8rRHhMCn4+7/yDW53haPJKU2kT4VZ28xtSG6aS6WPUeRBaBCiLOq5uJg3V6D/Ns6sZTfSqcdo3UfeQVveC3hk//KrbiCw/tbaF/RecMMikHReOcVGvDCwNT8hwlG/1IWEpyIoYR2gTHe0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id B8264DA7; Sat, 20 Jan 2024 02:03:18 -0800 (PST) Received: from pluto (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 35D873F73F; Sat, 20 Jan 2024 02:02:31 -0800 (PST) Date: Sat, 20 Jan 2024 10:02:28 +0000 From: Cristian Marussi To: Peng Fan Cc: sudeep.holla@arm.com, mturquette@baylibre.com, sboyd@kernel.org, linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, Peng Fan Subject: Re: [PATCH V3 2/2] clk: scmi: support state_ctrl_forbidden Message-ID: References: <20240115060203.813168-1-peng.fan@oss.nxp.com> <20240115060203.813168-2-peng.fan@oss.nxp.com> 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: On Sat, Jan 20, 2024 at 10:44:06AM +0800, Peng Fan wrote: > > > 在 1/19/2024 2:27 AM, Cristian Marussi 写道: > > On Mon, Jan 15, 2024 at 02:02:03PM +0800, Peng Fan (OSS) wrote: > > > From: Peng Fan > > > > > > Some clocks may exported to linux, while those clocks are not allowed > > > to configure by Linux. For example: > > > > > > SYS_CLK1----- > > > \ > > > --MUX--->MMC1_CLK > > > / > > > SYS_CLK2----- > > > > > > MMC1 needs set parent, so SYS_CLK1 and SYS_CLK2 are exported to Linux, > > > then the clk propagation will touch SYS_CLK1 or SYS_CLK2. > > > So we need bypass the failure for SYS_CLK1 or SYS_CLK2 when enable > > > the clock of MMC1. > > > > > > > Hi, > > > > so this looks good to me and apparently (as noted) the CLK framework is OK > > with a driver swallowing the -EACCESS when a clock is immutable, BUT at the > > end of the day do we even need to try this SCMI call and hide the failure in > > case of immutable clocks ? > > > > I mean, what if we just dont provide any callback for enable/disable...I can > > see plenty of drivers not providing those callbacks ? > > Maybe this is probably more of a question for Stephen... > > > > IOW what about doing something like below...does it make any difference > > in your setup ? works fine in my emulated env > > It should be fine to use your changes. Do you expect me to use your patch or > make it as a follow up patch? > It was just a suggestion, if you think is fine just include it in your series, I dont mind. > > > > (Note that last snippet in clk_gate_restore_context() is probably a fix > > that needs to be added anyway by looking at the code in clk.c) > > This API seems only used by TI gate driver, this change should be in a > standalone change go through clk tree. So I would your changes > as a standalone optimization follow up patch, while not included > in my patchset. Yes, indeed I have made a small patch of it to post it separately..and I forgot :D... sending it now. Thanks, Cristian