summaryrefslogtreecommitdiffstats
path: root/camera/inc/CameraHal.h
diff options
context:
space:
mode:
authorSundar Raman <sunds@ti.com>2011-09-13 22:37:08 -0700
committerIliyan Malchev <malchev@google.com>2011-09-14 16:00:42 -0700
commitfc41c90312b7e7d0d49521f7735ce0215990ab30 (patch)
tree360707c417ac88860580559112da53b3e1792df4 /camera/inc/CameraHal.h
parent1da4a98a2fc97ce823c76ce76880a6936af2743f (diff)
downloadhardware_ti_omap4-fc41c90312b7e7d0d49521f7735ce0215990ab30.zip
hardware_ti_omap4-fc41c90312b7e7d0d49521f7735ce0215990ab30.tar.gz
hardware_ti_omap4-fc41c90312b7e7d0d49521f7735ce0215990ab30.tar.bz2
Camera HAL: Crash media server in case of camera hardware errors
Applications do not handle errors other then CAMERA_SERVER_DIED. So there is no way for the application to know about fatal errors other than killing the media server when they happen. So this patch aborts media server whenever the ducati throws a fatal exception or when it hangs so that the apps notify the user of the error and then close. The user will be able to restart the application since the media server restarts automatically and the ducati is also restored by syslink automatically. Change-Id: Ic3e93130818edbe281affca99b808e09e08614c5 Signed-off-by: Sundar Raman <sunds@ti.com>
Diffstat (limited to 'camera/inc/CameraHal.h')
-rw-r--r--camera/inc/CameraHal.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/camera/inc/CameraHal.h b/camera/inc/CameraHal.h
index baf24df..38727a2 100644
--- a/camera/inc/CameraHal.h
+++ b/camera/inc/CameraHal.h
@@ -285,6 +285,13 @@ class CameraFrame
///@todo add other member vars like stride etc
};
+enum CameraHalError
+{
+ CAMERA_ERROR_FATAL = 0x1, //Fatal errors can only be recovered by restarting media server
+ CAMERA_ERROR_HARD = 0x2, // Hard errors are hardware hangs that may be recoverable by resetting the hardware internally within the adapter
+ CAMERA_ERROR_SOFT = 0x4, // Soft errors are non fatal errors that can be recovered from without needing to stop use-case
+};
+
///Common Camera Hal Event class which is visible to CameraAdapter,DisplayAdapter and AppCallbackNotifier
///@todo Rename this class to CameraEvent
class CameraHalEvent