From 1b081a4c1e740d0a0cbdca7402a06415a1532b4d Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Wed, 5 Jul 2023 23:30:01 +0200 Subject: [PATCH] media: ipu-bridge: Drop early setting of sensor->adev sensor->adev is no longer dereferenced before it is permanently set by: sensor->adev = acpi_dev_get(adev); So the early assignment with a borrowed reference can be dropped. Signed-off-by: Hans de Goede Signed-off-by: Sakari Ailus Signed-off-by: Mauro Carvalho Chehab --- drivers/media/pci/intel/ipu-bridge.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/drivers/media/pci/intel/ipu-bridge.c b/drivers/media/pci/intel/ipu-bridge.c index a752e938979a..31cf9f98b4bc 100644 --- a/drivers/media/pci/intel/ipu-bridge.c +++ b/drivers/media/pci/intel/ipu-bridge.c @@ -342,11 +342,6 @@ static int ipu_bridge_connect_sensor(const struct ipu_sensor_config *cfg, } sensor = &bridge->sensors[bridge->n_sensors]; - /* - * Borrow our adev ref to the sensor for now, on success - * acpi_dev_get(adev) is done further below. - */ - sensor->adev = adev; ret = ipu_bridge_parse_ssdb(adev, sensor); if (ret)