Changes since v1: fixes due to Helen Koike and Andrzej Pietrasiewicz's comments (thanks for the review!): - split the first patch into two patches, one that fixes the bug and one cleanup patch - fix allignment issue - add a last patch that removes vimc_ent_sd_unregister since it is not needed anymore Dafna Hirschfeld (5): media: vimc: initialize vim entity pointers to NULL media: vimc: cleanup code that assigns entity in entities array media: vimc: sensor: register subdevice only after initialization media: vimc: move media_entity_cleanup to release callbacks media: vimc: remove the helper function vimc_ent_sd_unregister drivers/media/platform/vimc/vimc-capture.c | 2 +- drivers/media/platform/vimc/vimc-common.c | 6 ------ drivers/media/platform/vimc/vimc-common.h | 12 ----------- drivers/media/platform/vimc/vimc-core.c | 11 ++++------- drivers/media/platform/vimc/vimc-debayer.c | 3 ++- drivers/media/platform/vimc/vimc-scaler.c | 3 ++- drivers/media/platform/vimc/vimc-sensor.c | 23 +++++++++++----------- 7 files changed, 21 insertions(+), 39 deletions(-) -- 2.20.1