[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202507021422.Zj4Hv0CG-lkp@intel.com>
Date: Wed, 2 Jul 2025 14:34:02 +0800
From: kernel test robot <lkp@...el.com>
To: Leo Yan <leo.yan@....com>, Suzuki K Poulose <suzuki.poulose@....com>,
Mike Leach <mike.leach@...aro.org>,
James Clark <james.clark@...aro.org>,
Levi Yun <yeoreum.yun@....com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Yabin Cui <yabinc@...gle.com>, Keita Morisaki <keyz@...gle.com>,
Yuanfang Zhang <quic_yuanfang@...cinc.com>
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
coresight@...ts.linaro.org, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org, Leo Yan <leo.yan@....com>
Subject: Re: [PATCH v2 11/28] coresight: Populate CPU ID into the
coresight_device structure
Hi Leo,
kernel test robot noticed the following build errors:
[auto build test ERROR on 66701750d5565c574af42bef0b789ce0203e3071]
url: https://github.com/intel-lab-lkp/linux/commits/Leo-Yan/coresight-Change-device-mode-to-atomic-type/20250701-230354
base: 66701750d5565c574af42bef0b789ce0203e3071
patch link: https://lore.kernel.org/r/20250701-arm_cs_pm_fix_v3-v2-11-23ebb864fcc1%40arm.com
patch subject: [PATCH v2 11/28] coresight: Populate CPU ID into the coresight_device structure
config: arm-randconfig-004-20250702 (https://download.01.org/0day-ci/archive/20250702/202507021422.Zj4Hv0CG-lkp@intel.com/config)
compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250702/202507021422.Zj4Hv0CG-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202507021422.Zj4Hv0CG-lkp@intel.com/
All errors (new ones prefixed by >>):
>> drivers/hwtracing/coresight/coresight-dummy.c:182:11: error: incompatible integer to pointer conversion assigning to 'struct device *' from 'int' [-Wint-conversion]
182 | desc.dev = -1;
| ^ ~~
1 error generated.
vim +182 drivers/hwtracing/coresight/coresight-dummy.c
113
114 static int dummy_probe(struct platform_device *pdev)
115 {
116 struct device *dev = &pdev->dev;
117 struct device_node *node = dev->of_node;
118 struct coresight_platform_data *pdata;
119 struct dummy_drvdata *drvdata;
120 struct coresight_desc desc = { 0 };
121 int ret = 0, trace_id = 0;
122
123 drvdata = devm_kzalloc(dev, sizeof(*drvdata), GFP_KERNEL);
124 if (!drvdata)
125 return -ENOMEM;
126
127 if (of_device_is_compatible(node, "arm,coresight-dummy-source")) {
128
129 desc.name = coresight_alloc_device_name(&source_devs, dev);
130 if (!desc.name)
131 return -ENOMEM;
132
133 desc.type = CORESIGHT_DEV_TYPE_SOURCE;
134 desc.subtype.source_subtype =
135 CORESIGHT_DEV_SUBTYPE_SOURCE_OTHERS;
136 desc.ops = &dummy_source_cs_ops;
137 desc.groups = coresight_dummy_groups;
138
139 ret = coresight_get_static_trace_id(dev, &trace_id);
140 if (!ret) {
141 /* Get the static id if id is set in device tree. */
142 ret = coresight_trace_id_get_static_system_id(trace_id);
143 if (ret < 0) {
144 dev_err(dev, "Fail to get static id.\n");
145 return ret;
146 }
147 } else {
148 /* Get next available id if id is not set in device tree. */
149 trace_id = coresight_trace_id_get_system_id();
150 if (trace_id < 0) {
151 ret = trace_id;
152 return ret;
153 }
154 }
155 drvdata->traceid = (u8)trace_id;
156
157 } else if (of_device_is_compatible(node, "arm,coresight-dummy-sink")) {
158 desc.name = coresight_alloc_device_name(&sink_devs, dev);
159 if (!desc.name)
160 return -ENOMEM;
161
162 desc.type = CORESIGHT_DEV_TYPE_SINK;
163 desc.subtype.sink_subtype = CORESIGHT_DEV_SUBTYPE_SINK_DUMMY;
164 desc.ops = &dummy_sink_cs_ops;
165 } else {
166 dev_err(dev, "Device type not set\n");
167 return -EINVAL;
168 }
169
170 pdata = coresight_get_platform_data(dev);
171 if (IS_ERR(pdata)) {
172 ret = PTR_ERR(pdata);
173 goto free_id;
174 }
175 pdev->dev.platform_data = pdata;
176
177 drvdata->dev = &pdev->dev;
178 platform_set_drvdata(pdev, drvdata);
179
180 desc.pdata = pdev->dev.platform_data;
181 desc.dev = &pdev->dev;
> 182 desc.dev = -1;
183 drvdata->csdev = coresight_register(&desc);
184 if (IS_ERR(drvdata->csdev)) {
185 ret = PTR_ERR(drvdata->csdev);
186 goto free_id;
187 }
188
189 pm_runtime_enable(dev);
190 dev_dbg(dev, "Dummy device initialized\n");
191
192 ret = 0;
193 goto out;
194
195 free_id:
196 if (IS_VALID_CS_TRACE_ID(drvdata->traceid))
197 coresight_trace_id_put_system_id(drvdata->traceid);
198
199 out:
200 return ret;
201 }
202
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists