mirror of
https://github.com/torvalds/linux.git
synced 2026-05-31 18:43:33 +02:00
media: ipu6: Remove redundant driver data checks
Both runtime PM resume and suspend callbacks check whether the driver's data is set for the device. This is done in probe(); drop the redundant checks. Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Reviewed-by: Bingbu Cao <bingbu.cao@intel.com> Tested-by: Mehdi Djait <mehdi.djait@linux.intel.com> # Dell XPS 9315 Reviewed-by: Mehdi Djait <mehdi.djait@linux.intel.com> Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
This commit is contained in:
parent
5b18b3816f
commit
312c74e6d3
|
|
@ -857,9 +857,6 @@ static int isys_runtime_pm_resume(struct device *dev)
|
|||
unsigned long flags;
|
||||
int ret;
|
||||
|
||||
if (!isys)
|
||||
return 0;
|
||||
|
||||
ret = ipu6_mmu_hw_init(adev->mmu);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
|
@ -884,13 +881,9 @@ static int isys_runtime_pm_resume(struct device *dev)
|
|||
static int isys_runtime_pm_suspend(struct device *dev)
|
||||
{
|
||||
struct ipu6_bus_device *adev = to_ipu6_bus_device(dev);
|
||||
struct ipu6_isys *isys;
|
||||
struct ipu6_isys *isys = dev_get_drvdata(dev);
|
||||
unsigned long flags;
|
||||
|
||||
isys = dev_get_drvdata(dev);
|
||||
if (!isys)
|
||||
return 0;
|
||||
|
||||
spin_lock_irqsave(&isys->power_lock, flags);
|
||||
isys->power = 0;
|
||||
spin_unlock_irqrestore(&isys->power_lock, flags);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user