media: atomisp: Remove duplication between runtime-pm and normal-pm code
authorHans de Goede <hdegoede@redhat.com>
Mon, 14 Nov 2022 15:44:49 +0000 (15:44 +0000)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Fri, 25 Nov 2022 08:23:41 +0000 (08:23 +0000)
commit6736a68fe15640e007a75f873cec86bdf9cc47a6
tree08355f76e594b2098805b6f4ad0ffbbebf379da7
parentf1219d9efab15a95c28df85269db72669f6206a5
media: atomisp: Remove duplication between runtime-pm and normal-pm code

atomisp_suspend() contains a 1:1 copy of atomisp_runtime_suspend() and
the same goes for the resume() functions.

Rename the runtime functions to atomisp_power_on()/_off() and use these
as runtime-pm handlers as well as helper in other places to remove
the code duplication.

Reviewed-by: Andy Shevchenko <andy@kernel.org>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/staging/media/atomisp/pci/atomisp_cmd.c
drivers/staging/media/atomisp/pci/atomisp_cmd.h
drivers/staging/media/atomisp/pci/atomisp_v4l2.c