From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A6AAA489872 for ; Thu, 30 Jul 2026 08:07:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785398870; cv=none; b=BCNHG9Su4uNEICfY5gXwfPv9ZS+DmwivLmLAQfsjjeQZPNt6djzfQy3mXapAMAWB2urH89V0qQmIes5risZ4iJFJjUvrGgRj47+18Dz/7mUcix0TPY5hoRizyt8gAvEKH3Qvad5QsnhjWrQBrqLCLTBD+zXuMxojNscfh2KpgtM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785398870; c=relaxed/simple; bh=HKFOu1fNblOcn/HFOdu48EyT+lBa2UuOd8Ya8wh5870=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=FtuTVRtpfCrfhK/TfhYmnoPW5zNvVoPXR6MrUREeRtBUuajD6uRdCOyVuf5q8kvBOEziM1Ig1nQHxlcHvEDkOcg4uQ+jAd5EhQH27vZZPs2Lm0wn/gnNAddhgoMdN6ZmIHYhIMcVoiq+9k44CQoEyJ9J/Z/ZfkbGV2qNDz5jiro= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=Bb7aBCKL; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=bIpV8Ijp; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="Bb7aBCKL"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="bIpV8Ijp" Received: from pps.filterd (m0279867.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 66U82a5S1385280 for ; Thu, 30 Jul 2026 08:07:42 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:date:from:in-reply-to:message-id :mime-version:references:subject:to; s=qcppdkim1; bh=g0+lG/T+afF 4ySmlryIDom0iKLYnuD7FP3qAhyNGYbE=; b=Bb7aBCKLNQAAemXPgs1WjsrJ2eF TrLboo3xX+rVmqFXQFfT74Z/lS81Plv3XvNWJSKKsF8iVueb/NC8dzgR5j2U/2hI B3ZLR+nX8Kb+lJhje4N601vqOU7pfyx5lqvyEaxDgNh1njAcoRDwadIxQJMUYIKv RH35tAIDRrCtigMlykmOS5POIKdpgKBtHMgRbMce8GwQsZVz1tFtza9CejMer6zX BUtnkmc3BgZt6r30BozfaDBZPFYPEUDL9cmFmwZSnXaZeJyqe5U0ma3iXZzcmQl0 smJ/HeGJxXl0UZfA5lg127BLBq+/kTNuBWWOEd1QIsugCJTWdaCxf5a5smg== Received: from mail-pj1-f72.google.com (mail-pj1-f72.google.com [209.85.216.72]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4fr2rp00ta-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Thu, 30 Jul 2026 08:07:41 +0000 (GMT) Received: by mail-pj1-f72.google.com with SMTP id 98e67ed59e1d1-38dd87656d3so759062a91.2 for ; Thu, 30 Jul 2026 01:07:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1785398861; x=1786003661; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=g0+lG/T+afF4ySmlryIDom0iKLYnuD7FP3qAhyNGYbE=; b=bIpV8Ijp47+qub+7cEflu3SYHF3ep3bZBCUTNNGikXAfgXdB5mkOyHJxrF9RTb+LAs T9e9P3trW3d2GNcTHrmfMtafA2V+djp/JIdEt1tiz6naht/KTv2Euc3YN8U9vD0AM5xC DiWH3W0FojiJfkwV6dexjUi/60Mh0Ir/nWp1rj6oyOKL5AvNagmI1y/v7t4iC48ZnFT5 nOtnKAsZqi/9iUFFzrkdin95z4elHwLjCtaI7ZuOVL+Vc8weerw4Ul80cclDnBNK7ecS OG9WvwktQn19o+iyPjNXK4lO9JpCfxeOcRVaUHN5htb/IVtBSt8kT6nFbsxjmWV6xHV9 wW7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1785398861; x=1786003661; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=g0+lG/T+afF4ySmlryIDom0iKLYnuD7FP3qAhyNGYbE=; b=tCum23pHRFRVzXCkkVVp/hBwjMh2txEGG9cq9VszgBOWUK+hHJ91+4i8qJFga7Npsw fxhLSx7MrakOzxnUzMKi/VNYyjieIzARFjOXwz1qcpysAcmfSiGcNH6mQe8aISBm/+t9 7eKHH1JhW0mWoR6HL785ikN7jTu8g9OEt6UhVkmXkXezffZIafSXn3EEogKAAlqY6tLd xEMYdhjsJUxGSt+tr1VL6OKLQmIH8/d1iCFgNCzepsfp6zl1CyA7FRE+YInhs5CGqN3x 9HfjqyVhE9br0BdO5pTpvekAV9voUYUZlB88eiLXsonpjcj9bncv8Np4+kh0KkTV/4Te s5Rg== X-Forwarded-Encrypted: i=1; AHgh+RoJfVw99TzQuHkrbCm4Lr6Sc8eVm3NXsBMOOjFZe/xaEL7imE6NkzqQWSKgC0vShpWQZp1SZZH+BWDkRAE=@vger.kernel.org X-Gm-Message-State: AOJu0YyFRaNWNIY3LUssnRPWAZ9ty+Yk08VmZkYY+rqhW4qsSUP+8KqQ WAUbCM5R8uTcAkQ+np2T57nfeRcSBhTTHlvZDJNurVlc5uHf2a2+pdpfIOhnE1QLlup1cegUPwC ZBq0htMs9R9Qx8kpZeNAvwjjUrhaAANlo+bdo3a552ZHByKUtt2SvYjgyjmpckM060to= X-Gm-Gg: AR+sD121RDJnYgl9OL3xJiJYGNZuh6D5JdzRXfa/ILRyAqzrNQM9/9DsbJ7GFdZgP4Z PO8mmpC2huG2LLeXv25UDSmTgQb/W8b8UrQE4OoYmdJaebsL9zddDypyHDaxGeT8ZNHCYRxrzO/ 1DLhqPQcHukei81D8GgP8QtLOJ2LRPu/HKTo5OeAoLvkXEBxLrxzvPF1uS71n1cs7CzuCluNi/s c2xafsrEr1RXvzXbTV8PKGdGrxUpVXsCgDqaAstcaCk9WCeaCdy3KCi2SF226e4GEifiLgaX/RQ ZuvR2AF6UaZnnIa1jKQdf0TvGfweSs8rW5p8WMysk5FYd6vnSIiXvrRkpFGWQKBFddHfW0LkmVO nCr5tGk45fedb9w+IDv7+X6UY8AAJekx1/y73XeaFaef//VokdB6sitw= X-Received: by 2002:a17:90b:5745:b0:387:df8f:1408 with SMTP id 98e67ed59e1d1-38f9c08163bmr1501432a91.41.1785398860882; Thu, 30 Jul 2026 01:07:40 -0700 (PDT) X-Received: by 2002:a17:90b:5745:b0:387:df8f:1408 with SMTP id 98e67ed59e1d1-38f9c08163bmr1501395a91.41.1785398860393; Thu, 30 Jul 2026 01:07:40 -0700 (PDT) Received: from hu-songchai-lv.qualcomm.com (Global_NAT1.qualcomm.com. [129.46.96.20]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-38f9bab61desm619516a91.13.2026.07.30.01.07.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 30 Jul 2026 01:07:40 -0700 (PDT) From: Songwei Chai To: andersson@kernel.org, alexander.shishkin@linux.intel.com, mike.leach@linaro.org, konrad.dybcio@oss.qualcomm.com, suzuki.poulose@arm.com, james.clark@arm.com, krzk+dt@kernel.org, conor+dt@kernel.org Cc: Songwei Chai , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, coresight@lists.linaro.org, devicetree@vger.kernel.org, gregkh@linuxfoundation.org, Rob Herring Subject: [PATCH v16 1/7] dt-bindings: arm: Add support for Qualcomm TGU trace Date: Thu, 30 Jul 2026 01:06:58 -0700 Message-Id: <20260730080704.2903540-2-songwei.chai@oss.qualcomm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20260730080704.2903540-1-songwei.chai@oss.qualcomm.com> References: <20260730080704.2903540-1-songwei.chai@oss.qualcomm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Proofpoint-Spam-Info: AW1haW4tMjYwNzMwMDA1NyBTYWx0ZWRfX4/2lHh8K946M PMYG4mX5KFTPqPmI+Cu3PVM45p64X0S10okKVl25NIejGjWZMh3erBCpqTJNGqLrJovjR26DjHe g0b/TALxnYlRAzi+hPig/sXP+fMaY0Q= X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNzMwMDA1NyBTYWx0ZWRfXw65wcerIVOQD YqiAAQ2bh+iRMqB+REnd+BYnzxmx68IViZxw9jB9fYb42yQDzHh7Y/ZchcbEQXp5PGJK2st8g5L k/ruWDAZmAziBYqDK4M/oPqZryZklNtUGyySFv4sLymnauRo7SJj9nQC27u4GGs06EY5qhhFIig BkLih0zx2fKypV7HjeaSfxnPWLYwV9Ze5TdMdpPJ2yrpvfK+CTprAcT3X3w1OorHbq/YoaWEoe5 k2XD8fTrA5bZujLC9uELFvfNcUabq7RqYKqhfbuz0rLETQ6GkeRVUpYGy58Z4+1Syn4HriBsb0a rwdSadwRzrnLhNauFSArd478D7BCKpljo2cBcWkEMmBh1QOeR+4PmoLdDBBw8bMmZ84osvrJgKd Vr8IGRaJqS+TfusUENYiO0wELN3wJXi5NFNUQoNwL2/WOOyjLSKiKifiyta5U2JdeKvhzoDxxnr ngH5BO21dFTE9Hy1zQw== X-Proofpoint-GUID: ECs-1TL5qkDthuUe5B5c603I9Wj1JqVq X-Proofpoint-ORIG-GUID: ECs-1TL5qkDthuUe5B5c603I9Wj1JqVq X-Authority-Analysis: v=2.4 cv=OcOoyBTY c=1 sm=1 tr=0 ts=6a6b064d cx=c_pps a=RP+M6JBNLl+fLTcSJhASfg==:117 a=ouPCqIW2jiPt+lZRy3xVPw==:17 a=RAioF0-LDSMA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=eoimf2acIAo5FJnRuUoq:22 a=gEfo2CItAAAA:8 a=VwQbUJbxAAAA:8 a=EUspDBNiAAAA:8 a=N3VNWiZ0WD7Ir0aJMQYA:9 a=iS9zxrgQBfv6-_F4QbHw:22 a=sptkURWiP4Gy88Gu7hUp:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.134,FMLib:17.12.100.49 definitions=2026-07-30_02,2026-07-29_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 lowpriorityscore=0 priorityscore=1501 impostorscore=0 adultscore=0 phishscore=0 malwarescore=0 suspectscore=0 spamscore=0 clxscore=1015 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2607300057 The Trigger Generation Unit (TGU) is designed to detect patterns or sequences within a specific region of the System on Chip (SoC). Once configured and activated, it monitors sense inputs and can detect a pre-programmed state or sequence across clock cycles, subsequently producing a trigger. TGU configuration space offset table x-------------------------x | | | | | | Step configuration | | space layout | coresight management | x-------------x | registers | |---> | | | | | | reserve | | | | | | |-------------------------| | |-------------| | | | | priority[3] | | step[7] |<-- | |-------------| |-------------------------| | | | priority[2] | | | | | |-------------| | ... | |Steps region | | priority[1] | | | | | |-------------| |-------------------------| | | | priority[0] | | |<-- | |-------------| | step[0] |--------------------> | | |-------------------------| | condition | | | | | | control and status | x-------------x | space | | | x-------------------------x |Timer/Counter| | | x-------------x TGU Configuration in Hardware The TGU provides a step region for user configuration, similar to a flow chart. Each step region consists of three register clusters: 1.Priority Region: Sets the required signals with priority. 2.Condition Region: Defines specific requirements (e.g., signal A reaches three times) and the subsequent action once the requirement is met. 3.Timer/Counter (Optional): Provides timing or counting functionality. Add a new tgu.yaml file to describe the bindings required to define the TGU in the device trees. Reviewed-by: Rob Herring (Arm) Signed-off-by: Songwei Chai --- .../devicetree/bindings/arm/qcom,tgu.yaml | 71 +++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 Documentation/devicetree/bindings/arm/qcom,tgu.yaml diff --git a/Documentation/devicetree/bindings/arm/qcom,tgu.yaml b/Documentation/devicetree/bindings/arm/qcom,tgu.yaml new file mode 100644 index 000000000000..76440f2497b9 --- /dev/null +++ b/Documentation/devicetree/bindings/arm/qcom,tgu.yaml @@ -0,0 +1,71 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +# Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/arm/qcom,tgu.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Trigger Generation Unit - TGU + +description: | + The Trigger Generation Unit (TGU) is a Data Engine which can be utilized + to sense a plurality of signals and create a trigger into the CTI or + generate interrupts to processors. The TGU is like the trigger circuit + of a Logic Analyzer. The corresponding trigger logic can be realized by + configuring the conditions for each step after sensing the signal. + Once setup and enabled, it will observe sense inputs and based upon + the activity of those inputs, even over clock cycles, may detect a + preprogrammed state/sequence and then produce a trigger or interrupt. + + The primary use case of the TGU is to detect patterns or sequences on a + given set of signals within some region to identify the issue in time + once there is abnormal behavior in the subsystem. + +maintainers: + - Mao Jinlong + - Songwei Chai + +# Need a custom select here or 'arm,primecell' will match on lots of nodes +select: + properties: + compatible: + contains: + enum: + - qcom,tgu + required: + - compatible + +properties: + compatible: + items: + - const: qcom,tgu + - const: arm,primecell + + reg: + maxItems: 1 + + clocks: + maxItems: 1 + + clock-names: + items: + - const: apb_pclk + +required: + - compatible + - reg + - clocks + - clock-names + +additionalProperties: false + +examples: + - | + tgu@10b0e000 { + compatible = "qcom,tgu", "arm,primecell"; + reg = <0x10b0e000 0x1000>; + + clocks = <&aoss_qmp>; + clock-names = "apb_pclk"; + }; +... -- 2.34.1