Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp415723ybh; Wed, 22 Jul 2020 04:03:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwdlEhi/9HLffnKn3wXVAkQoPLJevaKkb22St9zMNgFtAFORRbUFg3ZRtEk65f/vVXiHoG0 X-Received: by 2002:a05:6402:796:: with SMTP id d22mr31235208edy.78.1595415782396; Wed, 22 Jul 2020 04:03:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595415782; cv=none; d=google.com; s=arc-20160816; b=UZrV1daZTUbLSF6e76tAgHJM1o7kM2Jy4aGxCvDfc2GuWhOGcVQFcehsBgdInqO7Z8 gQNjgvrD3kdjYNuBurhoFqm2ZMQ8y5676u1MTxq6ALE62g1m0IijFUyP/iefrn/QbxMh nEa8XYyvPo2T1DgbOjSyqs7xs7uGLyCFIpDSZOrUjCdYBR4B/S+WtcxHMNaSd52TyZyG hWpcXAB1twlykISehtwmoOi2ducEuqOySju69TfYc2MhP7PMuDgPJE+QL5+WP4WRUv2o F47IdIDsHr8NCFtnaecQbAzZ0yI8Q6911Q0ym4o4O77uXMQfPszeeG7NPtf7aA4iQWPp GGHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=niAmRUGsg4kxR596xiqQAVaMYD9d+SGcGWnDYDntXxM=; b=qgCYunyLT872/cqKn3MRcmWC7i8rO6FjL4InlCADQB0+GgToIitLVXXylzIE5tDIgt YJ75Y7xeQ+bZSkC4N7rjRHvfFaEZpKODTs4brczqC5GKZ/Tf20tH3hevl0vh3mJGzk9L 1/ZQyf7te3X7jSSzznDaqKTuB9PIxi97iXEVblP7m4U7P6TBpt1qFwQTucjgQXk9e0C0 M8S5o6G8i+KrDIU9rLsB+YdDW1EcaxlLZQvXsix6YJJLQn9mptzhK00r43yR8wQ/MU30 BeRjDSUfPrMcHLxTdgwYVZLIxS45uP2+BPYvc0MVOr8n6aldFEamaZnMcWsv0Q9bZVyf 52tg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=r94Bx+p3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w20si14453747eds.305.2020.07.22.04.02.38; Wed, 22 Jul 2020 04:03:02 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=r94Bx+p3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730460AbgGVLBq (ORCPT + 99 others); Wed, 22 Jul 2020 07:01:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47708 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730054AbgGVLBo (ORCPT ); Wed, 22 Jul 2020 07:01:44 -0400 Received: from mail-wr1-x443.google.com (mail-wr1-x443.google.com [IPv6:2a00:1450:4864:20::443]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9B269C0619E1 for ; Wed, 22 Jul 2020 04:01:43 -0700 (PDT) Received: by mail-wr1-x443.google.com with SMTP id 88so1477638wrh.3 for ; Wed, 22 Jul 2020 04:01:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=niAmRUGsg4kxR596xiqQAVaMYD9d+SGcGWnDYDntXxM=; b=r94Bx+p3fcIDdAUsi8ATLuebYYefpEfjtAfalUhzc8pUWLe7DYZlGToUERmUT6175v ridcQ7TDaWP5Jou4y5JCHVow5LoJaJmJTCGsqXpB1OrI5UBftKfAYaVYfwzURR66u/H9 iHci+7rpt+mdko5bdHcESZMNj4ARx6gtgIhfZZ/o0auMSlQPxuV4B2FlB+9MMh7yl9Iv nBI5Anaw9Q7+OmR8XNlS06NTmtjbZTzwh5i4lOJra4g19ge0YzKw0ZZOzzm/YUG6QVwU 8Am9GunVPEw14N3o7HFV6CuCO0QWUc6s/ie+Uy5RY9m5EjGvqPB07L4KQv75NEShn5qI N7IA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=niAmRUGsg4kxR596xiqQAVaMYD9d+SGcGWnDYDntXxM=; b=ubRlqjO5XAM9XzkZHTy0FyJTabC0MzBG5egzRWC5/njAH1qSp2MKk45hl/ArmCJhcB MJnOlxHmNqa93PHsCUnCk99WaQjbnCobR3gQo1pLZ1cNLXuBH/lVdU5D1lA79pjcZJr1 em3PajzxngYvdvVOmR2C7wLqkxUBlLA20zxp+sDb7KN4XuHPrmDB8UCe3Sla+xZFuBl/ 7avTPTVTJju3DlU4RI+A2UO5d4NbIkN6NhIhahG71YEzfJ5IS52GhVDMrsFjiI1dpjcB mzB0FiycWyo7IvGylySp1DyKtbgPhXHObdZv870AWsYjue1/8c/z4JrN8Nfn8qbxwwip 3+pw== X-Gm-Message-State: AOAM5329nxg4KMj6zmvsP9M+AeOokcoxuGI24O0NNFMaiTFPU+2K548M QiWjMF6BaM2VzB2+SUxNHqV3qQ== X-Received: by 2002:a5d:4a0d:: with SMTP id m13mr13001479wrq.12.1595415702339; Wed, 22 Jul 2020 04:01:42 -0700 (PDT) Received: from localhost.localdomain ([212.45.67.2]) by smtp.googlemail.com with ESMTPSA id y6sm41256164wrr.74.2020.07.22.04.01.41 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 22 Jul 2020 04:01:41 -0700 (PDT) From: Georgi Djakov To: linux-pm@vger.kernel.org Cc: saravanak@google.com, mdtipton@codeaurora.org, okukatla@codeaurora.org, bjorn.andersson@linaro.org, vincent.guittot@linaro.org, georgi.djakov@linaro.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 2/2] interconnect: qcom: Use icc_sync_state in sdm845 and osm-3l drivers Date: Wed, 22 Jul 2020 14:01:39 +0300 Message-Id: <20200722110139.24778-3-georgi.djakov@linaro.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200722110139.24778-1-georgi.djakov@linaro.org> References: <20200722110139.24778-1-georgi.djakov@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Lowering the bandwidth on the bus might have negative consequences if it's done before all consumers had a chance to cast their vote. Let's return the maximum amount of bandwidth as initial value. This bandwidth level would be maintained until all consumers have probed. Signed-off-by: Georgi Djakov --- drivers/interconnect/qcom/osm-l3.c | 3 +++ drivers/interconnect/qcom/sdm845.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/drivers/interconnect/qcom/osm-l3.c b/drivers/interconnect/qcom/osm-l3.c index 96fb9ff5ff2e..54aff6273af1 100644 --- a/drivers/interconnect/qcom/osm-l3.c +++ b/drivers/interconnect/qcom/osm-l3.c @@ -236,6 +236,8 @@ static int qcom_osm_l3_probe(struct platform_device *pdev) node->name = qnodes[i]->name; node->data = qnodes[i]; + node->init_avg = INT_MAX; + node->init_peak = INT_MAX; icc_node_add(node, provider); for (j = 0; j < qnodes[i]->num_links; j++) @@ -268,6 +270,7 @@ static struct platform_driver osm_l3_driver = { .driver = { .name = "osm-l3", .of_match_table = osm_l3_of_match, + .sync_state = icc_sync_state, }, }; module_platform_driver(osm_l3_driver); diff --git a/drivers/interconnect/qcom/sdm845.c b/drivers/interconnect/qcom/sdm845.c index f6c7b969520d..c04775820f15 100644 --- a/drivers/interconnect/qcom/sdm845.c +++ b/drivers/interconnect/qcom/sdm845.c @@ -503,6 +503,8 @@ static int qnoc_probe(struct platform_device *pdev) node->name = qnodes[i]->name; node->data = qnodes[i]; + node->init_avg = INT_MAX; + node->init_peak = INT_MAX; icc_node_add(node, provider); for (j = 0; j < qnodes[i]->num_links; j++) @@ -559,6 +561,7 @@ static struct platform_driver qnoc_driver = { .driver = { .name = "qnoc-sdm845", .of_match_table = qnoc_of_match, + .sync_state = icc_sync_state, }, }; module_platform_driver(qnoc_driver);