Received: by 10.192.165.148 with SMTP id m20csp4461747imm; Tue, 8 May 2018 08:49:30 -0700 (PDT) X-Google-Smtp-Source: AB8JxZomkHq5kZBwate42f30mu2h9lGdDJ49HfAGxPV/6tX0XOa5dC+xRi1vr9vX2Uu8SHBH6kc4 X-Received: by 2002:a63:7f59:: with SMTP id p25-v6mr33071346pgn.440.1525794570512; Tue, 08 May 2018 08:49:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525794570; cv=none; d=google.com; s=arc-20160816; b=jJk+2kehNU5CX0BoBRUfji4Y4zGarlPKIXYzVuXUdnKjcB/ZZ3cRof9s4yjtIuuZb+ 8LAvQcfocFNEU/SrPqEHU5Mh5L/C/CqKnXrV3/2T6iMSHLphJRN/esvzuHY+ZNYQbJkK VgO5erPk7gvTLAPk5RJPp6QurVOCv1zHtC09YgxqXwYdtKoWupeESdSRcBnj6/tM8Qd4 ftKMh177oEtK9rFIo0CD9wfahbf02DHtz7GUK5KG1VlZhoV70RxdmCVkNNC9dIrDyEqJ lufZSttOmoxbNjz+Gj8eG3olC874AFJX/IB0ybvpTw5f06onXlroKH4mlaMdzUA4shVe 9BHQ== 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=dC+h2Avnx1h2E9yDYm1r7U3Op5Ercaer5/SOGlwm2GU=; b=RSIOOXlQ7XyNKYLCRA/IEy9AH5pJ3/TtioOLimUsbcZq7cIbvB0jA+C8f4rGglUcRJ 9okbDx2VIfj6UraY2zWzeBNu8WWxgsVVNhu2uZpfAPDpghICtMZcn+w5huGfs+72WbZT yxktOdQjxuQUjt4xZgL8SsYB2ue2WVWeL9YrASSaWZcBCGAXWNO8GhQbFclTxLQf0aRN Q0JhtRl29CvdsG/aIpswGCR2xDQ6RHktytkF04MsO0XqaQlJZVpf/AmTuV6bhg58hc/o UBx0DMNcHg4i6M4fu4l0Q1WdZJ5Urc/Uq3TRADZcDaAb0NRMsfYsxkrmUGQO0rLk0P57 qUqg== 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 31-v6si16333930pli.404.2018.05.08.08.49.15; Tue, 08 May 2018 08:49:30 -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 S932344AbeEHPsl (ORCPT + 99 others); Tue, 8 May 2018 11:48:41 -0400 Received: from foss.arm.com ([217.140.101.70]:60258 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755041AbeEHPsk (ORCPT ); Tue, 8 May 2018 11:48:40 -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 3DAC680D; Tue, 8 May 2018 08:48:40 -0700 (PDT) Received: from [10.1.206.73] (en101.cambridge.arm.com [10.1.206.73]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id EE9863F58C; Tue, 8 May 2018 08:48:37 -0700 (PDT) Subject: Re: [PATCH v2 10/27] dts: bindings: Restrict coresight tmc-etr scatter-gather mode To: Rob Herring , Mathieu Poirier Cc: linux-arm-kernel , "linux-kernel@vger.kernel.org" , Mike Leach , Robert Walker , Mark Rutland , Will Deacon , Robin Murphy , Sudeep Holla , Frank Rowand , John Horley , Mathieu Poirier , devicetree@vger.kernel.org References: <1525165857-11096-1-git-send-email-suzuki.poulose@arm.com> <1525165857-11096-11-git-send-email-suzuki.poulose@arm.com> <20180501131300.GA31425@rob-hp-laptop> From: Suzuki K Poulose Message-ID: <514f69b1-2219-aa83-dfe8-09c26ed4f5b1@arm.com> Date: Tue, 8 May 2018 16:48:36 +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: Content-Type: text/plain; charset=us-ascii; 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 04/05/18 23:56, Rob Herring wrote: > On Thu, May 3, 2018 at 3:32 PM, Mathieu Poirier > wrote: >> On 1 May 2018 at 07:13, Rob Herring wrote: >>> On Tue, May 01, 2018 at 10:10:40AM +0100, Suzuki K Poulose wrote: >>>> We are about to add the support for ETR builtin scatter-gather mode >>>> for dealing with large amount of trace buffers. However, on some of >>>> the platforms, using the ETR SG mode can lock up the system due to >>>> the way the ETR is connected to the memory subsystem. >>>> >>>> In SG mode, the ETR performs READ from the scatter-gather table to >>>> fetch the next page and regular WRITE of trace data. If the READ >>>> operation doesn't complete(due to the memory subsystem issues, >>>> which we have seen on a couple of platforms) the trace WRITE >>>> cannot proceed leading to issues. So, we by default do not >>>> use the SG mode, unless it is known to be safe on the platform. >>>> We define a DT property for the TMC node to specify whether we >>>> have a proper SG mode. >>>> --- >>>> Documentation/devicetree/bindings/arm/coresight.txt | 3 +++ >>>> drivers/hwtracing/coresight/coresight-tmc.c | 8 +++++++- >>>> 2 files changed, 10 insertions(+), 1 deletion(-) >>>> >>>> diff --git a/Documentation/devicetree/bindings/arm/coresight.txt b/Documentation/devicetree/bindings/arm/coresight.txt >>>> index cdd84d0..7c0c8f0 100644 >>>> --- a/Documentation/devicetree/bindings/arm/coresight.txt >>>> +++ b/Documentation/devicetree/bindings/arm/coresight.txt >>>> @@ -88,6 +88,9 @@ its hardware characteristcs. >>>> * arm,buffer-size: size of contiguous buffer space for TMC ETR >>>> (embedded trace router) >>>> >>>> + * scatter-gather: boolean. Indicates that the TMC-ETR can safely >>>> + use the SG mode on this system. >>>> + >>> >>> Needs a vendor prefix. >>> >> >> Thinking further on this, do we need to make it device specific as >> well - something like "arm,etr-scatter-gather"? That way we don't >> have to redefine "scatter-gather" for other ARM devices if they happen >> to need the same property but for different reasons. > > No. If we had a bunch of cases, then we'd probably want to have just > 'scatter-gather'. Does it mean "arm,scatter-gather" ? If we ever wanted to add the device specific information, I would prefer to go with "arm,tmc-scatter-gather" and not "etr-scatter-gather". They both could mean different things. > > BTW, if SG had already been supported, then I'd say this is a quirk > and we should invert this property. Otherwise, you'd be disabling once > enabled SG and require working platforms to update their dtb. Of > course, I shouldn't really let the state of an OS driver influence the > DT binding. > The SG support is added with this series. So, the OS has never made use of the feature. Suzuki