From: kernel test robot <lkp@intel.com>
To: "Griffin Kroah-Hartman" <griffin.kroah@fairphone.com>,
"Mauro Carvalho Chehab" <mchehab@kernel.org>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzk@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
"André Apitzsch" <git@apitzsch.eu>,
"Luca Weiss" <luca.weiss@fairphone.com>,
"Daniel Scally" <dan.scally@ideasonboard.com>,
"Sakari Ailus" <sakari.ailus@linux.intel.com>,
"Bjorn Andersson" <andersson@kernel.org>,
"Konrad Dybcio" <konradybcio@kernel.org>,
"Hans Verkuil" <hverkuil@kernel.org>
Cc: oe-kbuild-all@lists.linux.dev, linux-media@vger.kernel.org,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-msm@vger.kernel.org, stable@vger.kernel.org,
Griffin Kroah-Hartman <griffin.kroah@fairphone.com>
Subject: Re: [PATCH v3 2/3] media: i2c: dw9719: Update DW9800K driver
Date: Fri, 6 Nov 2026 02:14:55 +0800 [thread overview]
Message-ID: <202611060251.DGnOao2F-lkp@intel.com> (raw)
In-Reply-To: <20261105-b4-dw9800k_cleanup-v3-2-6850ee6a5a5a@fairphone.com>
Hi Griffin,
kernel test robot noticed the following build errors:
[auto build test ERROR on bc71431221f5ba8bb33918399552636e059c2c45]
url: https://github.com/intel-lab-lkp/linux/commits/Griffin-Kroah-Hartman/dt-bindings-media-i2c-dw9800-Redocument-DW9800K/20261105-112900
base: bc71431221f5ba8bb33918399552636e059c2c45
patch link: https://lore.kernel.org/r/20261105-b4-dw9800k_cleanup-v3-2-6850ee6a5a5a%40fairphone.com
patch subject: [PATCH v3 2/3] media: i2c: dw9719: Update DW9800K driver
config: nios2-randconfig-1001-20261105 (https://download.01.org/0day-ci/archive/20261106/202611060251.DGnOao2F-lkp@intel.com/config)
compiler: nios2-linux-gcc (GCC) 10.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20261106/202611060251.DGnOao2F-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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202611060251.DGnOao2F-lkp@intel.com/
All errors (new ones prefixed by >>):
drivers/media/i2c/dw9719.c: In function 'dw9719_power_up':
>> drivers/media/i2c/dw9719.c:207:3: error: a label can only be part of a statement and a declaration is not a statement
207 | int ring, sac;
| ^~~
vim +207 drivers/media/i2c/dw9719.c
122
123 static int dw9719_power_up(struct dw9719_device *dw9719, bool detect)
124 {
125 u32 reg_pwr = dw9719->model == DW9718S ? DW9718S_PD : DW9719_CONTROL;
126 u64 val;
127 int ret;
128 int err;
129
130 ret = regulator_enable(dw9719->regulator);
131 if (ret)
132 return ret;
133
134 /*
135 * Need 100us to transition from SHUTDOWN to STANDBY.
136 * Jiggle the SCL pin to wake up the device (even when the regulator is
137 * shared) and wait double the time to be sure, as 100us is not enough
138 * at least on the DW9718S as found on the motorola-nora smartphone,
139 * then retry the write.
140 */
141 cci_write(dw9719->regmap, reg_pwr, DW9719_STANDBY, NULL);
142 /* the jiggle is expected to fail, don't even log that as error */
143 fsleep(200);
144 cci_write(dw9719->regmap, reg_pwr, DW9719_STANDBY, &ret);
145
146 if (detect) {
147 /* These models do not have an INFO register */
148 switch (dw9719->model) {
149 case DW9718S:
150 dw9719->sac_mode = DW9718S_DEFAULT_SAC;
151 dw9719->vcm_freq = DW9718S_DEFAULT_VCM_FREQ;
152 goto props;
153 default:
154 break;
155 }
156
157 ret = cci_read(dw9719->regmap, DW9719_INFO, &val, NULL);
158 if (ret < 0)
159 return ret;
160
161 switch (val) {
162 case DW9719_ID:
163 dw9719->model = DW9719;
164 dw9719->mode_low_bits = 0x00;
165 dw9719->sac_mode = DW9719_DEFAULT_SAC;
166 dw9719->vcm_freq = DW9719_DEFAULT_VCM_FREQ;
167 break;
168 case DW9761_ID:
169 dw9719->model = DW9761;
170 dw9719->mode_low_bits = 0x01;
171 dw9719->sac_mode = DW9761_DEFAULT_SAC;
172 dw9719->vcm_freq = DW9761_DEFAULT_VCM_FREQ;
173 break;
174 case DW9800K_ID:
175 dw9719->sac_mode = DW9800K_DEFAULT_SAC;
176 dw9719->vcm_freq = DW9800K_DEFAULT_DIV;
177 dw9719->sac_time = DW9800K_DEFAULT_SACT;
178 break;
179 default:
180 dev_err(dw9719->dev,
181 "Error unknown device id 0x%02llx\n", val);
182 return -ENXIO;
183 }
184
185 props:
186 /* Optional indication of SAC mode select */
187 device_property_read_u32(dw9719->dev, "dongwoon,sac-mode",
188 &dw9719->sac_mode);
189
190 /* Optional indication of VCM frequency */
191 err = device_property_read_u32(dw9719->dev, "dongwoon,vcm-freq",
192 &dw9719->vcm_freq);
193 if (err == 0)
194 dev_warn(dw9719->dev, "dongwoon,vcm-freq property is deprecated, please use dongwoon,vcm-prescale\n");
195
196 /* Optional indication of VCM prescale */
197 device_property_read_u32(dw9719->dev, "dongwoon,vcm-prescale",
198 &dw9719->vcm_freq);
199
200 /* Optional indication of SAC timing */
201 device_property_read_u32(dw9719->dev, "dongwoon,timing-control",
202 &dw9719->sac_time);
203 }
204
205 switch (dw9719->model) {
206 case DW9800K:
> 207 int ring, sac;
208
209 /*
210 * Enable ringing for SAC3-SAC5
211 *
212 * sac_mode reg Mode
213 * ===========================
214 * 0 0X Direct
215 * 1 1X LSC
216 * 2 00 SAC2
217 * 3 01 SAC3
218 * 4 10 SAC4
219 * 5 11 SAC5
220 */
221 switch (dw9719->sac_mode) {
222 case 0:
223 ring = 0;
224 sac = 0;
225 break;
226 case 1:
227 ring = 0;
228 sac = 2;
229 break;
230 default:
231 ring = DW9719_ENABLE_RINGING;
232 sac = dw9719->sac_mode - 2;
233 break;
234 }
235 cci_write(dw9719->regmap, DW9719_CONTROL, ring, &ret);
236 /* DIV is 3 bits split over the bottom bit in reg 6 and the top 2 bits in reg 7 */
237 cci_write(dw9719->regmap, DW9719_MODE,
238 (sac << DW9800K_MODE_SAC_SHIFT) |
239 (dw9719->vcm_freq >> DW9800K_DIV_LOW_SHIFT), &ret);
240 cci_write(dw9719->regmap, DW9800K_RESONANCE,
241 (dw9719->vcm_freq << DW9800K_DIV_SHIFT) |
242 dw9719->sac_time, &ret);
243 break;
244 case DW9718S:
245 /* Datasheet says [OCP/UVLO] should be disabled below 2.5V */
246 dw9719->sac_mode &= DW9718S_CONTROL_SAC_MASK;
247 cci_write(dw9719->regmap, DW9718S_CONTROL,
248 DW9718S_CONTROL_SW_LINEAR |
249 (dw9719->sac_mode << DW9718S_CONTROL_SAC_SHIFT) |
250 DW9718S_CONTROL_OCP_DISABLE |
251 DW9718S_CONTROL_UVLO_DISABLE, &ret);
252 cci_write(dw9719->regmap, DW9718S_SACT,
253 DW9718S_SACT_PERIOD_8_8MS, &ret);
254 cci_write(dw9719->regmap, DW9718S_SW,
255 dw9719->vcm_freq & DW9718S_SW_VCM_FREQ_MASK, &ret);
256 break;
257 case DW9761:
258 cci_write(dw9719->regmap, DW9761_VCM_PRELOAD,
259 DW9761_DEFAULT_VCM_PRELOAD, &ret);
260 fallthrough;
261 case DW9719:
262 cci_write(dw9719->regmap, DW9719_CONTROL, DW9719_ENABLE_RINGING, &ret);
263 cci_write(dw9719->regmap, DW9719_MODE, dw9719->mode_low_bits |
264 (dw9719->sac_mode << DW9719_MODE_SAC_SHIFT), &ret);
265 cci_write(dw9719->regmap, DW9719_VCM_FREQ, dw9719->vcm_freq, &ret);
266 }
267
268 if (ret)
269 dw9719_power_down(dw9719);
270
271 return ret;
272 }
273
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next prev parent reply other threads:[~2026-11-05 18:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-05 10:28 [PATCH v3 0/3] Dongwoon DW9800K update patchset Griffin Kroah-Hartman
2026-11-05 10:29 ` [PATCH v3 1/3] dt-bindings: media: i2c: dw9800: Redocument DW9800K Griffin Kroah-Hartman
2026-11-05 12:03 ` Rob Herring (Arm)
2026-11-05 10:29 ` [PATCH v3 2/3] media: i2c: dw9719: Update DW9800K driver Griffin Kroah-Hartman
2026-11-05 18:14 ` kernel test robot [this message]
2026-11-05 10:29 ` [PATCH v3 3/3] arm64: dts: qcom: qcm6490-fairphone-fp5: Fix DW9800K support Griffin Kroah-Hartman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202611060251.DGnOao2F-lkp@intel.com \
--to=lkp@intel.com \
--cc=andersson@kernel.org \
--cc=conor+dt@kernel.org \
--cc=dan.scally@ideasonboard.com \
--cc=devicetree@vger.kernel.org \
--cc=git@apitzsch.eu \
--cc=griffin.kroah@fairphone.com \
--cc=hverkuil@kernel.org \
--cc=konradybcio@kernel.org \
--cc=krzk@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=luca.weiss@fairphone.com \
--cc=mchehab@kernel.org \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=robh@kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®