Received: by 2002:a25:86ce:0:0:0:0:0 with SMTP id y14csp312077ybm; Wed, 22 May 2019 03:41:04 -0700 (PDT) X-Google-Smtp-Source: APXvYqzrAnTOC+Qx5tmLMlL/lwFMIGqcqweqWlFlEoAiUHyRAo+HKHYZ/M6qMGKmQuAeJUwpsSAQ X-Received: by 2002:a17:902:29c8:: with SMTP id h66mr65196825plb.269.1558521664104; Wed, 22 May 2019 03:41:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558521664; cv=none; d=google.com; s=arc-20160816; b=HL/ZfuJ/1D7f1OexWVrG1e9aTVQoWN6HA8rRzzr52zXCHAXSqqfjPGZbCkfp3QT9cz wTGhKPJn20uguoFCDa9qcU/9+UbM/AkukANT64LwKQG/fTCailbYM6dLAjBFwgxtZ7M/ NqZUYF1IEQXqRmKfY1g+JuI7TVLw4nBldEvg2EmGf+Bzr0erLRhensjsFapycz0bVwNc E4h5kz+iItkLWoTAd+wMPo3vjOLZmOwLoKxamTG5ZQj5U3rcS4GqUgXg2XnHlBo93E4g HILOCzPWQfUEZUAsWsZySDePzWFKn4hJvLkLrnIzbZ5dZHdIe9JyNqp/g9v9kBtfyHRQ 5UDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=j2RCJ7yrNYeQbws/9vfx06izFXDUW+Uf0IRoS3lMcoE=; b=wnnozBYyJf51oUT96PaIEyrP8H/2hBVhlWeFOdfHycBi1pQRWFq+ontbNRzkYWkipH 40e/yf4zB+vaKE90KUaDvqWCwbq0ZRPoXq93oL8PZ17ovccbBZ23lKfQBieMxC8aOsjZ IRYfQSh/onCBVXBRKYrTB1AGwBtzhva1uPY7X5BHFTEzyqDCzarkYkzLXU+VC2kQAVoU Fqa+/a4t/XUqcXeAibx/bjOvE7A/kg+0bPDZLSGkDTj2muIgcYc+zs7olGll9Dr21u7B 9qL2MRdb0/frFh0oej0MWWAs8ovL6AMahSHKcb0jjyKWwkPJNOdrBIzQrhuE4Jyv46ex IjNA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z9si26553488pgi.341.2019.05.22.03.40.48; Wed, 22 May 2019 03:41:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729120AbfEVKfW (ORCPT + 99 others); Wed, 22 May 2019 06:35:22 -0400 Received: from foss.arm.com ([217.140.101.70]:46948 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729035AbfEVKfU (ORCPT ); Wed, 22 May 2019 06:35:20 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 755C215BF; Wed, 22 May 2019 03:35:20 -0700 (PDT) Received: from en101.cambridge.arm.com (en101.cambridge.arm.com [10.1.196.93]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 65BBE3F575; Wed, 22 May 2019 03:35:19 -0700 (PDT) From: Suzuki K Poulose To: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, mathieu.poirier@linaro.org, coresight@lists.linaro.org, Suzuki K Poulose Subject: [PATCH v4 02/30] coresight: replicator: Cleanup device tracking Date: Wed, 22 May 2019 11:34:35 +0100 Message-Id: <1558521304-27469-3-git-send-email-suzuki.poulose@arm.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1558521304-27469-1-git-send-email-suzuki.poulose@arm.com> References: <1558521304-27469-1-git-send-email-suzuki.poulose@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org In preparation to use a consistent device naming scheme, clean up the device link tracking in replicator driver. Use the "coresight" device instead of the "real" parent device for all internal purposes. All other requests (e.g, power management, DMA operations) must use the "real" device which is the parent device. Reviewed-by: Mathieu Poirier Signed-off-by: Suzuki K Poulose --- drivers/hwtracing/coresight/coresight-replicator.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/hwtracing/coresight/coresight-replicator.c b/drivers/hwtracing/coresight/coresight-replicator.c index 8c9ce74..ee6ad34 100644 --- a/drivers/hwtracing/coresight/coresight-replicator.c +++ b/drivers/hwtracing/coresight/coresight-replicator.c @@ -26,13 +26,11 @@ * struct replicator_drvdata - specifics associated to a replicator component * @base: memory mapped base address for this component. Also indicates * whether this one is programmable or not. - * @dev: the device entity associated with this component * @atclk: optional clock for the core parts of the replicator. * @csdev: component vitals needed by the framework */ struct replicator_drvdata { void __iomem *base; - struct device *dev; struct clk *atclk; struct coresight_device *csdev; }; @@ -100,7 +98,7 @@ static int replicator_enable(struct coresight_device *csdev, int inport, if (drvdata->base) rc = dynamic_replicator_enable(drvdata, inport, outport); if (!rc) - dev_dbg(drvdata->dev, "REPLICATOR enabled\n"); + dev_dbg(&csdev->dev, "REPLICATOR enabled\n"); return rc; } @@ -139,7 +137,7 @@ static void replicator_disable(struct coresight_device *csdev, int inport, if (drvdata->base) dynamic_replicator_disable(drvdata, inport, outport); - dev_dbg(drvdata->dev, "REPLICATOR disabled\n"); + dev_dbg(&csdev->dev, "REPLICATOR disabled\n"); } static const struct coresight_ops_link replicator_link_ops = { @@ -196,7 +194,6 @@ static int replicator_probe(struct device *dev, struct resource *res) if (!drvdata) return -ENOMEM; - drvdata->dev = dev; drvdata->atclk = devm_clk_get(dev, "atclk"); /* optional */ if (!IS_ERR(drvdata->atclk)) { ret = clk_prepare_enable(drvdata->atclk); -- 2.7.4