From nobody Tue Apr 7 02:56:18 2026 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 E41D62DB7AE for ; Tue, 17 Mar 2026 03:26:53 +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=1773718017; cv=none; b=oBLsNcVF1Jabivdlz8+tgobzqCP6rNfJbjIyQUrEdRd+mCgb75KK4azlmbsNuLax4BDBHQQDXYjlNmIl3vbLVqoTIVrq7/afhcDfgw+IfGUQ5D+Iw0jjv34/WL9VqtTUJsDqhP3tnSLgzEGsd2HlCMwcf0WCTYPhTILxoQbdJs0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773718017; c=relaxed/simple; bh=ZEyK/NvC8XhHV1VMN7UZRw/1Zd8JOXVVzsp0ONavdKc=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=lxH1ip/yFIDeHw/D6aD1yCiet2DyA8E3LiBQNO5JssBfTVEeomS7KDF568+o+WjLXIJ7jXEZAgRJU6KnreHdb5C+ckEbcj2z+w5KXxiNmFYenUnIwXu75DY7bTxGmnOHwcWlIHwfcRZqPwML6SHTVNfzz7ToYieJMH5E11pSUFw= 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=baDrXJIh; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=YNwxejWu; 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="baDrXJIh"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="YNwxejWu" Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 62H2VYKE3101993 for ; Tue, 17 Mar 2026 03:26:53 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=rjTMyY/nVZ5 E0ydjO3Px6iHuenx+E5iNzGh3OC3CnXU=; b=baDrXJIh7x2gDW1lg/mOJoYi7Gp MxmF4JWQSzPyHdyOZq0hKN6PMukY7SZ9WyrLe3TAul16AGmYylLAbxKdQv65Hc+j Rfo5h4/KmeLXUD+eYpGeckJvn41bP+4hm6aASlJGy849lFsFs86re8TXO0FGWw5y pUdHkh7T0eZYPaud5JmTgfZObNz9pPxyMp1p9jWSGr7PBTs2WD+JMxz5mjyBJbRt 2b8tw04OmAZPclkQJIRy7Nok4NOl29wjsk5cpHkCSz0ODeZ9372E2xrjrpU461QY AMysuBv1lbM8W8tVocA4BsJTJ3EDysXaMT/KUAXfUfz473p+lDk/w6Qr5SQ== Received: from mail-dy1-f197.google.com (mail-dy1-f197.google.com [74.125.82.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4cxnb79x1r-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Tue, 17 Mar 2026 03:26:53 +0000 (GMT) Received: by mail-dy1-f197.google.com with SMTP id 5a478bee46e88-2bea80a5849so77043182eec.0 for ; Mon, 16 Mar 2026 20:26:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1773718012; x=1774322812; 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; bh=rjTMyY/nVZ5E0ydjO3Px6iHuenx+E5iNzGh3OC3CnXU=; b=YNwxejWuMiVkxehY+myeuj/+Um9pKz66+VfA6aG6Uos543C+u9RMQm5rKDJvOrxD8T UCPX1IS/0koUw7H7rpqoT8BOV+mBCMaey96IEwgTERPPYB5aWvXKdWih5Nrp16+07hfe KyuyAkr/aGBVISDxv0v0f1qARSbvWdp9tPyiC7tBTtdrkAHQwIkBLbHCcOCwtFRdAtKb LJL3JT0QkU/mwEV8sEyqZwBYGWzQwgm3hOXcb/zbacGMP0TITmeV3bsKZGWojHB3invX DtQ4dbm9tZommBuUcNc5vQk0HwP2DMAFG+emkzn3eW3ys1V/pCO+F3/U2rXEqDg8SR24 uY6A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1773718012; x=1774322812; 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; bh=rjTMyY/nVZ5E0ydjO3Px6iHuenx+E5iNzGh3OC3CnXU=; b=XsTnB8PvrccJRB6E7NroMCgrPa1ikIFUChSHltiuli5BHVNqIcwlkCXGg69KjdWxQX 19C396Kn40VZb76qSvK0mH88wOzRfvsX2BPgxcCNSlDV7PpHDgIoEuv6isR4zMsl+oBZ Z7Gs5D8/BDlLPO3bwT8KQIy9popxrP4EpBJtLGLLtVURdc4/+nwTmWpgPIZRh1Xq2if4 19W1HKtsC63m+cUdeHk5p4kBCUnaykAAt3jT4UEaj3W6KvO87XpzzLL9UCl+JNAPLRDz tb/wBHxEtPkN15pyN4QfnWthcnhaPGtcAeoRAt8OGjjzO/TByByIXfzaFJQZFYtJG0Cr Pcnw== X-Forwarded-Encrypted: i=1; AJvYcCWosxjjNdj/PfMKuChFY+gARaz6NdB/IFJfhGA2MT3YXkDH3Bq31S3Wj3qda9d8+uGoBMV6owrtwdG+L38=@vger.kernel.org X-Gm-Message-State: AOJu0YwPY7fZDcA+LAp58YRZoC+xSMZcE/oS2QZCW/kQeKfTxUcmjwY2 zsyzFqxf9es+zDTRVYHb1zdXmud+T1y3RBLrMtCeIa5OvL1HkBY9akIZyngJ2SoydD2ZOHV2UuC EA1NWolOdMzU+U0NDr/9ExslZsIgr6c2kuiLrZe33klDkv4cUjIL4abxs1G8ZOaPwMHY= X-Gm-Gg: ATEYQzxhzKeahxg4ZdbXRDD0Z6a2NO6wK72YgBhf4WrlXRYit4VD3gHCyG9GKqcVsRm 6qhzrailWdh8BhwpD5VTLTuc/54fJ0b/VUI6ffIOsyD3Q+yV+mN88ggtrMhMY/bEJm7wI6HUlkk ayR75lTGtArIg0o4lx1KOOCVcAMz18XyivYELlCPxcrW+RXhEs+GwVB6dc7+ed0158AEOYveSTu KrpMz8XlQOXlsRw7ogcpSTTfqAs1RJbPEEflx2EMkyDOIvdJ/M/gHYuqavXFe2N5Is2GNLfJVlz uqiR7+jBrDEdQ37zmh8n1WhH1nzzp1s1aMYJr78m0D+y5pwWS8kWLX6L3ZXcCvinpqVNzfvVogr ndZUlWfvHJWWisqgTo8ufFX6ciNDvV8ogUv9jkYEA3oSPOUSVEKGOrg2txhOPrzyWzOncG6X10D j+ X-Received: by 2002:a05:7301:1f17:b0:2c0:c63d:e02e with SMTP id 5a478bee46e88-2c0c63de76amr2980182eec.3.1773718012313; Mon, 16 Mar 2026 20:26:52 -0700 (PDT) X-Received: by 2002:a05:7301:1f17:b0:2c0:c63d:e02e with SMTP id 5a478bee46e88-2c0c63de76amr2980160eec.3.1773718011716; Mon, 16 Mar 2026 20:26:51 -0700 (PDT) Received: from hu-songchai-lv.qualcomm.com (Global_NAT1.qualcomm.com. [129.46.96.20]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-2beab3ef844sm17445895eec.15.2026.03.16.20.26.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Mar 2026 20:26:50 -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 Subject: [PATCH v12 2/7] qcom-tgu: Add TGU driver Date: Mon, 16 Mar 2026 20:26:34 -0700 Message-Id: <20260317032639.2393221-3-songwei.chai@oss.qualcomm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20260317032639.2393221-1-songwei.chai@oss.qualcomm.com> References: <20260317032639.2393221-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: quoted-printable X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwMzE3MDAyNyBTYWx0ZWRfX7bB3tpO+02Ha ey7EDpEw1nNnYAT7UeTQ1OIp5MohXrbSqOXpvQGffvom4LFqOu4fkU53CjlLii3NdHAUd33l2xk XQV+VLqbgOfMZrOpG4oDjpEDoDa3NT3485UXyvckIt0XtTLnIeD02GHfUJGq7C0DfP4Z29g/ZJy xwS6aeK1VhzJSN1il7aqSzuetujMhOc+8IjMgq+FJNWvHo6aRAlmAmzDXtn+3FvksmZghA3EMOG 85DFpuPp/w0YXS4tr/i/OKM4bHmKZrwzmPZJpefxOxG748BqI79kTD5XPhLiFvxLEfOQKWtaOrA RCDLMrDv2EBI55hl3NBaxmgxqyDQD220+OfKAvjd/LDnZXzjm05hnhT76cvUV5JCuWdC983YPRV BE4pHoXxdj6BwucEpVLt4FsdRE5zBnGjlJQJZF0/e9NjkdnNsn1IRPtkarfFVDP+mbyhpbdC7Xv McvOVFeNVUURVjyy3Zw== X-Authority-Analysis: v=2.4 cv=D7pK6/Rj c=1 sm=1 tr=0 ts=69b8c9fd cx=c_pps a=Uww141gWH0fZj/3QKPojxA==:117 a=ouPCqIW2jiPt+lZRy3xVPw==:17 a=Yq5XynenixoA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=DJpcGTmdVt4CTyJn9g5Z:22 a=EUspDBNiAAAA:8 a=h99DN6MNysFgGb7_OMAA:9 a=PxkB5W3o20Ba91AHUih5:22 X-Proofpoint-ORIG-GUID: IBzv9NAVwgzGw6eUJpWjmxQJcOlBwzsp X-Proofpoint-GUID: IBzv9NAVwgzGw6eUJpWjmxQJcOlBwzsp X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.51,FMLib:17.12.100.49 definitions=2026-03-17_01,2026-03-16_06,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 adultscore=0 clxscore=1015 suspectscore=0 spamscore=0 malwarescore=0 lowpriorityscore=0 phishscore=0 bulkscore=0 impostorscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2603050001 definitions=main-2603170027 Content-Type: text/plain; charset="utf-8" Add driver to support device TGU (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. Add probe/enable/disable functions for tgu. Signed-off-by: Songwei Chai Reviewed-by: Jie Gan --- .../ABI/testing/sysfs-bus-amba-devices-tgu | 9 + drivers/Makefile | 1 + drivers/hwtracing/Kconfig | 2 + drivers/hwtracing/qcom/Kconfig | 18 ++ drivers/hwtracing/qcom/Makefile | 3 + drivers/hwtracing/qcom/tgu.c | 183 ++++++++++++++++++ drivers/hwtracing/qcom/tgu.h | 51 +++++ 7 files changed, 267 insertions(+) create mode 100644 Documentation/ABI/testing/sysfs-bus-amba-devices-tgu create mode 100644 drivers/hwtracing/qcom/Kconfig create mode 100644 drivers/hwtracing/qcom/Makefile create mode 100644 drivers/hwtracing/qcom/tgu.c create mode 100644 drivers/hwtracing/qcom/tgu.h diff --git a/Documentation/ABI/testing/sysfs-bus-amba-devices-tgu b/Documen= tation/ABI/testing/sysfs-bus-amba-devices-tgu new file mode 100644 index 000000000000..ead237bb7d89 --- /dev/null +++ b/Documentation/ABI/testing/sysfs-bus-amba-devices-tgu @@ -0,0 +1,9 @@ +What: /sys/bus/amba/devices//enable_tgu +Date: March 2026 +KernelVersion 7.1 +Contact: Jinlong Mao , Songwei Chai +Description: + (RW) Set/Get the enable/disable status of TGU + Accepts only one of the 2 values - 0 or 1. + 0 : disable TGU. + 1 : enable TGU. diff --git a/drivers/Makefile b/drivers/Makefile index 53fbd2e0acdd..82b712a12a26 100644 --- a/drivers/Makefile +++ b/drivers/Makefile @@ -177,6 +177,7 @@ obj-$(CONFIG_RAS) +=3D ras/ obj-$(CONFIG_USB4) +=3D thunderbolt/ obj-$(CONFIG_CORESIGHT) +=3D hwtracing/coresight/ obj-y +=3D hwtracing/intel_th/ +obj-y +=3D hwtracing/qcom/ obj-$(CONFIG_STM) +=3D hwtracing/stm/ obj-$(CONFIG_HISI_PTT) +=3D hwtracing/ptt/ obj-y +=3D android/ diff --git a/drivers/hwtracing/Kconfig b/drivers/hwtracing/Kconfig index 911ee977103c..8a640218eed8 100644 --- a/drivers/hwtracing/Kconfig +++ b/drivers/hwtracing/Kconfig @@ -7,4 +7,6 @@ source "drivers/hwtracing/intel_th/Kconfig" =20 source "drivers/hwtracing/ptt/Kconfig" =20 +source "drivers/hwtracing/qcom/Kconfig" + endmenu diff --git a/drivers/hwtracing/qcom/Kconfig b/drivers/hwtracing/qcom/Kconfig new file mode 100644 index 000000000000..d6f6d4b0f28e --- /dev/null +++ b/drivers/hwtracing/qcom/Kconfig @@ -0,0 +1,18 @@ +# SPDX-License-Identifier: GPL-2.0-only +# +# QCOM specific hwtracing drivers +# +menu "Qualcomm specific hwtracing drivers" + +config QCOM_TGU + tristate "QCOM Trigger Generation Unit driver" + help + This driver provides support for Trigger Generation Unit that is + used to detect patterns or sequences on a given set of signals. + TGU is used to monitor a particular bus within a given region to + detect illegal transaction sequences or slave responses. It is also + used to monitor a data stream to detect protocol violations and to + provide a trigger point for centering data around a specific event + within the trace data buffer. + +endmenu diff --git a/drivers/hwtracing/qcom/Makefile b/drivers/hwtracing/qcom/Makef= ile new file mode 100644 index 000000000000..5a0a868c1ea0 --- /dev/null +++ b/drivers/hwtracing/qcom/Makefile @@ -0,0 +1,3 @@ +# SPDX-License-Identifier: GPL-2.0 + +obj-$(CONFIG_QCOM_TGU) +=3D tgu.o diff --git a/drivers/hwtracing/qcom/tgu.c b/drivers/hwtracing/qcom/tgu.c new file mode 100644 index 000000000000..58c19f12f3d7 --- /dev/null +++ b/drivers/hwtracing/qcom/tgu.c @@ -0,0 +1,183 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries. + */ + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "tgu.h" + +static void tgu_write_all_hw_regs(struct tgu_drvdata *drvdata) +{ + TGU_UNLOCK(drvdata->base); + /* Enable TGU to program the triggers */ + writel(1, drvdata->base + TGU_CONTROL); + TGU_LOCK(drvdata->base); +} + +static int tgu_enable(struct device *dev) +{ + struct tgu_drvdata *drvdata =3D dev_get_drvdata(dev); + + guard(spinlock)(&drvdata->lock); + if (drvdata->enabled) + return -EBUSY; + + tgu_write_all_hw_regs(drvdata); + drvdata->enabled =3D true; + + return 0; +} + +static void tgu_do_disable(struct tgu_drvdata *drvdata) +{ + TGU_UNLOCK(drvdata->base); + writel(0, drvdata->base + TGU_CONTROL); + TGU_LOCK(drvdata->base); + + drvdata->enabled =3D false; +} + +static void tgu_disable(struct device *dev) +{ + struct tgu_drvdata *drvdata =3D dev_get_drvdata(dev); + + guard(spinlock)(&drvdata->lock); + if (!drvdata->enabled) + return; + + tgu_do_disable(drvdata); +} + +static ssize_t enable_tgu_show(struct device *dev, + struct device_attribute *attr, char *buf) +{ + struct tgu_drvdata *drvdata =3D dev_get_drvdata(dev); + bool enabled; + + guard(spinlock)(&drvdata->lock); + enabled =3D drvdata->enabled; + + return sysfs_emit(buf, "%d\n", !!enabled); +} + +/* enable_tgu_store - Configure Trace and Gating Unit (TGU) triggers. */ +static ssize_t enable_tgu_store(struct device *dev, + struct device_attribute *attr, + const char *buf, + size_t size) +{ + unsigned long val; + int ret; + + ret =3D kstrtoul(buf, 0, &val); + if (ret || val > 1) + return -EINVAL; + + if (val) { + ret =3D pm_runtime_resume_and_get(dev); + if (ret) + return ret; + ret =3D tgu_enable(dev); + if (ret) { + pm_runtime_put(dev); + return ret; + } + } else { + tgu_disable(dev); + pm_runtime_put(dev); + } + + return size; +} +static DEVICE_ATTR_RW(enable_tgu); + +static struct attribute *tgu_common_attrs[] =3D { + &dev_attr_enable_tgu.attr, + NULL, +}; + +static const struct attribute_group tgu_common_grp =3D { + .attrs =3D tgu_common_attrs, + NULL, +}; + +static const struct attribute_group *tgu_attr_groups[] =3D { + &tgu_common_grp, + NULL, +}; + +static int tgu_probe(struct amba_device *adev, const struct amba_id *id) +{ + struct device *dev =3D &adev->dev; + struct tgu_drvdata *drvdata; + int ret; + + drvdata =3D devm_kzalloc(dev, sizeof(*drvdata), GFP_KERNEL); + if (!drvdata) + return -ENOMEM; + + drvdata->dev =3D &adev->dev; + dev_set_drvdata(dev, drvdata); + + drvdata->base =3D devm_ioremap_resource(dev, &adev->res); + if (IS_ERR(drvdata->base)) + return PTR_ERR(drvdata->base); + + spin_lock_init(&drvdata->lock); + + ret =3D sysfs_create_groups(&dev->kobj, tgu_attr_groups); + if (ret) { + dev_err(dev, "failed to create sysfs groups: %d\n", ret); + return ret; + } + + drvdata->enabled =3D false; + + pm_runtime_put(&adev->dev); + + return 0; +} + +static void tgu_remove(struct amba_device *adev) +{ + struct device *dev =3D &adev->dev; + + sysfs_remove_groups(&dev->kobj, tgu_attr_groups); + + tgu_disable(dev); +} + +static const struct amba_id tgu_ids[] =3D { + { + .id =3D 0x000f0e00, + .mask =3D 0x000fffff, + }, + { 0, 0, NULL }, +}; + +MODULE_DEVICE_TABLE(amba, tgu_ids); + +static struct amba_driver tgu_driver =3D { + .drv =3D { + .name =3D "qcom-tgu", + .suppress_bind_attrs =3D true, + }, + .probe =3D tgu_probe, + .remove =3D tgu_remove, + .id_table =3D tgu_ids, +}; + +module_amba_driver(tgu_driver); + +MODULE_AUTHOR("Songwei Chai "); +MODULE_AUTHOR("Jinlong Mao "); +MODULE_DESCRIPTION("Qualcomm Trigger Generation Unit driver"); +MODULE_LICENSE("GPL"); diff --git a/drivers/hwtracing/qcom/tgu.h b/drivers/hwtracing/qcom/tgu.h new file mode 100644 index 000000000000..dd7533b9d735 --- /dev/null +++ b/drivers/hwtracing/qcom/tgu.h @@ -0,0 +1,51 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries. + */ + +#ifndef _QCOM_TGU_H +#define _QCOM_TGU_H + +/* Register addresses */ +#define TGU_CONTROL 0x0000 +#define TGU_LAR 0xfb0 +#define TGU_UNLOCK_OFFSET 0xc5acce55 + +static inline void TGU_LOCK(void __iomem *addr) +{ + do { + /* Wait for things to settle */ + mb(); + writel_relaxed(0x0, addr + TGU_LAR); + } while (0); +} + +static inline void TGU_UNLOCK(void __iomem *addr) +{ + do { + writel_relaxed(TGU_UNLOCK_OFFSET, addr + TGU_LAR); + /* Make sure everyone has seen this */ + mb(); + } while (0); +} + +/** + * struct tgu_drvdata - Data structure for a TGU (Trigger Generator Unit) + * @base: Memory-mapped base address of the TGU device + * @dev: Pointer to the associated device structure + * @lock: Spinlock for handling concurrent access to private data + * @enabled: Flag indicating whether the TGU device is enabled + * + * This structure defines the data associated with a TGU device, + * including its base address, device pointers, clock, spinlock for + * synchronization, trigger data pointers, maximum limits for various + * trigger-related parameters, and enable status. + */ +struct tgu_drvdata { + void __iomem *base; + struct device *dev; + spinlock_t lock; + bool enabled; +}; + +#endif --=20 2.34.1