From: Fred Fettinger Date: Tue, 5 Jan 2010 22:54:03 +0000 (-0600) Subject: libhardware_legacy: add gps debug extension X-Git-Tag: android-x86-2.2~8 X-Git-Url: http://git.osdn.net/view?p=android-x86%2Fhardware-libhardware_legacy.git;a=commitdiff_plain;h=7d675d8ea8cfe856839398bc83a17f8d068a0d41 libhardware_legacy: add gps debug extension The gps debug extension provides a single function that allows the native gps implementation to include an arbitrary string in bugreports. Change-Id: I1bd8e403e421847784804c47d83e3600340b3fea Signed-off-by: Fred Fettinger Signed-off-by: Mike Lockwood --- diff --git a/include/hardware_legacy/gps.h b/include/hardware_legacy/gps.h index 0cd9f04..c8ef980 100755 --- a/include/hardware_legacy/gps.h +++ b/include/hardware_legacy/gps.h @@ -114,6 +114,11 @@ typedef uint16_t AGpsStatusValue; #define GPS_XTRA_INTERFACE "gps-xtra" /** + * Name for the GPS DEBUG interface. + */ +#define GPS_DEBUG_INTERFACE "gps-debug" + +/** * Name for the AGPS interface. */ #define AGPS_INTERFACE "agps" @@ -268,6 +273,15 @@ typedef struct { int (*inject_xtra_data)( char* data, int length ); } GpsXtraInterface; +/** Extended interface for DEBUG support. */ +typedef struct { + /** + * This function should return any information that the native + * implementation wishes to include in a bugreport. + */ + size_t (*get_internal_state)(char* buffer, size_t bufferSize); +} GpsDebugInterface; + /** Represents the status of AGPS. */ typedef struct { AGpsType type;