drm/msm: dpu: Fix "WARNING: invalid free of devm_ allocated data"
authorYueHaibing <yuehaibing@huawei.com>
Fri, 16 Nov 2018 11:25:26 +0000 (19:25 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 21 Dec 2018 13:15:18 +0000 (14:15 +0100)
commit38b579de0b9ac3919475819d6fb2e543c5dbf5eb
tree346185aea43f645f1ae1cd8a58986870704563ea
parentb7c819a03ae804839fc32314a6dd63ceaf329f4c
drm/msm: dpu: Fix "WARNING: invalid free of devm_ allocated data"

[ Upstream commit ce25aa3ee6939d83979cccf7adc5737cba9a0cb7 ]

'dpu_enc' is a member of 'drm_enc'
And 'drm_enc' got allocated with devm_kzalloc in dpu_encoder_init.

This gives this error message:
./drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c:459:1-6:
 WARNING: invalid free of devm_ allocated data

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: Rob Clark <robdclark@gmail.com>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c