Re: [PATCH v4 2/3] drm/panel: Add Ilitek ILI9881c panel driver
From: kbuild test robot
Date: Fri May 04 2018 - 23:49:19 EST
Hi Maxime,
I love your patch! Perhaps something to improve:
[auto build test WARNING on ]
url: https://github.com/0day-ci/linux/commits/Maxime-Ripard/drm-panel-Add-Ilitek-ILI9881c-controller-driver/20180505-104031
base:
config: sh-allmodconfig (attached as .config)
compiler: sh4-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=sh
All warnings (new ones prefixed by >>):
drivers/gpu/drm/panel/panel-ilitek-ili9881c.c: In function 'ili9881c_prepare':
>> drivers/gpu/drm/panel/panel-ilitek-ili9881c.c:303:34: warning: initialization discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
struct ili9881c_instr *instr = &ili9881c_init[i];
^
vim +/const +303 drivers/gpu/drm/panel/panel-ilitek-ili9881c.c
284
285 static int ili9881c_prepare(struct drm_panel *panel)
286 {
287 struct ili9881c *ctx = panel_to_ili9881c(panel);
288 unsigned int i;
289 int ret;
290
291 /* Power the panel */
292 gpiod_set_value(ctx->power, 1);
293 msleep(5);
294
295 /* And reset it */
296 gpiod_set_value(ctx->reset, 1);
297 msleep(20);
298
299 gpiod_set_value(ctx->reset, 0);
300 msleep(20);
301
302 for (i = 0; i < ARRAY_SIZE(ili9881c_init); i++) {
> 303 struct ili9881c_instr *instr = &ili9881c_init[i];
304
305 if (instr->op == ILI9881C_SWITCH_PAGE)
306 ret = ili9881c_switch_page(ctx, instr->arg.page);
307 else if (instr->op == ILI9881C_COMMAND)
308 ret = ili9881c_send_cmd_data(ctx, instr->arg.cmd.cmd,
309 instr->arg.cmd.data);
310
311 if (ret)
312 return ret;
313 }
314
315 ret = ili9881c_switch_page(ctx, 0);
316 if (ret)
317 return ret;
318
319 ret = mipi_dsi_dcs_set_tear_on(ctx->dsi, MIPI_DSI_DCS_TEAR_MODE_VBLANK);
320 if (ret)
321 return ret;
322
323 mipi_dsi_dcs_exit_sleep_mode(ctx->dsi);
324 if (ret)
325 return ret;
326
327 return 0;
328 }
329
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Attachment:
.config.gz
Description: application/gzip