On Mon, May 28, 2018 at 07:17:54AM -0300, Mauro Carvalho Chehab wrote: > This (obviously wrong patch) shut up the warning: > > --- a/drivers/media/platform/vsp1/vsp1_drm.c > +++ b/drivers/media/platform/vsp1/vsp1_drm.c > @@ -248,6 +248,9 @@ static int vsp1_du_pipeline_setup_brx(struct vsp1_device *vsp1, > else > brx = &vsp1->brs->entity; > > + if (pipe->brx == brx) > + pipe->brx = &vsp1->brs->entity; > + > /* Switch BRx if needed. */ > if (brx != pipe->brx) { > struct vsp1_entity *released_brx = NULL; > Just to be clear. After this patch, Smatch does *NOT* think that "pipe->brx" is necessarily non-NULL. What this patch does it that Smatch says "pipe->brx has been modified on every code path since we checked for NULL, so forget about the earlier check". regards, dan carpenter