Received: by 10.192.165.148 with SMTP id m20csp1009598imm; Sat, 5 May 2018 02:56:31 -0700 (PDT) X-Google-Smtp-Source: AB8JxZo5BTGwJRT4/kE0fiuAsUO7I/oL+wdV38SxxhbOAvRu6NUm1bXLAZp8Ha5DGRaK46ROfHqQ X-Received: by 2002:a17:902:2f43:: with SMTP id s61-v6mr30388624plb.99.1525514191128; Sat, 05 May 2018 02:56:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525514191; cv=none; d=google.com; s=arc-20160816; b=T+NJKDTv975PRAsIy1Bs0NRXrO0AkA2qnidk1sgjIjK0X5zdE/O0sWh2EVQWENUBhw VTKI20gZg/j5v1/m+6Uh7fjw3Rcx7YyyujBCY2rNnYN5UzgBF/G9yYkIJlwHV6k8J3/b jNTcDc72kwXXpFTR4F6MMImIVb8PijED8PRRVmjcIRek0JAqLWSt4AvSS4Eqw36sEwFe 0vNApDI6BeKRPLPN+xSCi5V7DSvF8nBfwBJHxsmOE8uQsj0qVZ8hrS1gBshI6IaPLyqM NWiyVtu0przc/ybc+h4kVHScg+wgxIA7CtjxJi0606qezIxSK2Z+qKlSNZXBz3u9mSCr FZuQ== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=wNEickg0KkBJF7XpaxH7HTnoQ1pYWUcWAl+dbked0fI=; b=EvCURKO1feOxfRQx/+7D2/g8hJynBqR7+TATunFwu2fq3UghHesuHNeZcohfes62uP 401R61qGZQAKN8/3Y8V4qjjfD+fugm1djN6u++liKEmqbZKiiG+DnTuD/MuE/Tuf8QXM ssT1f6tWwqd6P8g22u07lJ86cUFwMmrYWr5kIH3W9o6m8v9V5Omc/ruyXoXSe5O1SQ67 BomTAJ69/BLKPKwYb8ImZPk3AqznHpXB1QH+k2w2t4xqQD2MYvRwiye7Owp4JqTYlRE3 SysGFrqYOec7FNcJ6ewjiymDFNL1LNYeU+5LwTrEwFPTuwvOutvEpcdJ7c33VfJAJB81 GLRw== 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 e29-v6si17775055plj.518.2018.05.05.02.56.16; Sat, 05 May 2018 02:56:31 -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 S1751248AbeEEJ4E (ORCPT + 99 others); Sat, 5 May 2018 05:56:04 -0400 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:33866 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750821AbeEEJ4D (ORCPT ); Sat, 5 May 2018 05:56:03 -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 A3E1C80D; Sat, 5 May 2018 02:56:03 -0700 (PDT) Received: from [10.37.8.142] (unknown [10.37.8.142]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 5D9093F25D; Sat, 5 May 2018 02:56:01 -0700 (PDT) Subject: Re: [PATCH v2 03/27] coresight: Add helper device type To: Mathieu Poirier Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, mike.leach@linaro.org, robert.walker@arm.com, mark.rutland@arm.com, will.deacon@arm.com, robin.murphy@arm.com, sudeep.holla@arm.com, frowand.list@gmail.com, robh@kernel.org, john.horley@arm.com References: <1525165857-11096-1-git-send-email-suzuki.poulose@arm.com> <1525165857-11096-4-git-send-email-suzuki.poulose@arm.com> <20180503170040.GA11425@xps15> From: Suzuki K Poulose Message-ID: <86778b1b-cd08-629a-b56c-20549d9d7299@arm.com> Date: Sat, 5 May 2018 10:56:03 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <20180503170040.GA11425@xps15> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 05/03/2018 06:00 PM, Mathieu Poirier wrote: ... >> +/* >> + * coresight_release_device - Release this device and any of the helper >> + * devices connected to it for trace operation. >> + */ >> +static void coresight_release_device(struct coresight_device *csdev) >> +{ >> + int i; >> + >> + for (i = 0; i < csdev->nr_outport; i++) { >> + struct coresight_device *child = csdev->conns[i].child_dev; >> + >> + if (child && child->type == CORESIGHT_DEV_TYPE_HELPER) >> + pm_runtime_put(child->dev.parent); >> + } > > There is a newline here in coresight_prepare_device(). Either add one (or not) > in both function but please be consistent. > >> @@ -480,8 +517,7 @@ static int _coresight_build_path(struct coresight_device *csdev, >> >> node->csdev = csdev; >> list_add(&node->link, path); >> - pm_runtime_get_sync(csdev->dev.parent); >> - >> + coresight_prepare_device(csdev); > > There was a newline between pm_runtime_get_sync() and the return statement in > the original code. > >> @@ -775,6 +811,10 @@ static struct device_type coresight_dev_type[] = { >> .name = "source", >> .groups = coresight_source_groups, >> }, >> + { >> + .name = "helper", >> + }, >> + > > Extra newline. > >> }; >> +/** >> + * struct coresight_ops_helper - Operations for a helper device. >> + * >> + * All operations could pass in a device specific data, which could >> + * help the helper device to determine what to do. >> + * >> + * @enable : Turn the device ON. >> + * @disable : Turn the device OFF. > > There is a discrepancy between the comment and the operations, i.e enabling a > device is not synonymous of turning it on. Looking at patch 04/27 the ops is > called in tmc_etr_enable/disable_catu() so the comment propably needs to be > changed. Sure, will fix all of them. Cheers Suzuki