upstream: [media] em28xx: add suspend/resume to em28xx_ops
authorShuah Khan <shuah.kh@samsung.com>
Sat, 22 Feb 2014 00:50:13 +0000 (21:50 -0300)
committerChanho Park <chanho61.park@samsung.com>
Tue, 18 Nov 2014 02:54:46 +0000 (11:54 +0900)
commitc95f2a6a074d76aec347a76458ecee2a782b1c15
tree73c1f8334a4c3917372cd3cf064794e2cf89046d
parentb0f9acd23205e45adba4943ac3d0f178a3363341
upstream: [media] em28xx: add suspend/resume to em28xx_ops

em28xx usb driver will have to suspend and resume its extensions. Adding
suspend and resume to em28xx_ops gives extensions the ability to install
suspend and resume that can be invoked from em28xx_usb driver suspend()
and resume() interfaces.

Approach:
Add power management support to em28xx usb driver. This driver works in
conjunction with extensions for each of the functions on the USB device
for video/audio/dvb/remote functionality that is present on media USB
devices it supports. During suspend and resume each of these extensions
will have to do their part in suspending the components they control.

Adding suspend and resume hooks to the existing struct em28xx_ops will
enable the extensions the ability to implement suspend and resume hooks
to be called from em28xx driver. The overall approach is as follows:

-- add suspend and resume hooks to em28xx_ops
-- add suspend and resume routines to em28xx-core to invoke suspend
   and resume hooks for all registered extensions.
-- change em28xx dvb, audio, input, and video extensions to implement
   em28xx_ops: suspend and resume hooks. These hooks do what is necessary
   to suspend and resume the devices they control.

Signed-off-by: Shuah Khan <shuah.kh@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/media/usb/em28xx/em28xx-core.c
drivers/media/usb/em28xx/em28xx.h