Re: [PATCH v2 9/9] drm/panel: Add Ronbo RB070D30 panel

Maxime Ripard
2019-02-11T14:40:53Z

[-- Attachment #1.1: Type: text/plain, Size: 570 bytes --]

hi,

On Fri, Feb 08, 2019 at 03:24:12PM +0300, Konstantin Sudakov wrote:
> Hello, Maxime!
>
> >+mode = drm_mode_duplicate(panel->drm, &default_mode);
> >+if (!mode) {
> >+DRM_DEV_ERROR(&ctx->dsi->dev,
> >+ "Failed to add mode " DRM_MODE_FMT "\n",
> >+ DRM_MODE_ARG(mode));
> >+return -EINVAL;
> >+}
>
> Just small fix: DRM_MODE_ARG(mode) -> DRM_MODE_ARG(&default_mode).
> The "mode" variable is NULL, it leads to the UB.

Good catch, thanks!
Maxime

--
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

[-- Attachment #2: Type: text/plain, Size: 176 bytes --]