summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorKrzysztof Opasiak <k.opasiak@samsung.com>2014-04-03 16:57:26 +0200
committerKrzysztof Opasiak <k.opasiak@samsung.com>2014-07-05 10:27:50 +0200
commitb3fa72ad1512f47c058a7f28e52ea8768566fa6c (patch)
treee9256a8366b5edf78eaacbb043789a9147631cd1 /include
parent38943f9ae0842bf11e1c2aad6413261a8e59d321 (diff)
downloadlibusbg-b3fa72ad1512f47c058a7f28e52ea8768566fa6c.tar.gz
libusbg-b3fa72ad1512f47c058a7f28e52ea8768566fa6c.tar.bz2
libusbg-b3fa72ad1512f47c058a7f28e52ea8768566fa6c.zip
libusbg: Add remove gadget functionality.
Add function which allow to remove USB gadget. This functions also remove gadget from internal library structures what means that after this operation all pointers to removed gadget are invalid. Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
Diffstat (limited to 'include')
-rw-r--r--include/usbg/usbg.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/usbg/usbg.h b/include/usbg/usbg.h
index 4b04551..282485b 100644
--- a/include/usbg/usbg.h
+++ b/include/usbg/usbg.h
@@ -312,6 +312,15 @@ extern int usbg_rm_config(usbg_config *c, int opts);
extern int usbg_rm_function(usbg_function *f, int opts);
/**
+ * @brief Remove existing USB gadget
+ * @details This function frees also the memory allocated for gadget
+ * @param g Gadget to be removed
+ * @param opts Additional options for configuration removal.
+ * @return 0 on success, usbg_error if error occurred
+ */
+extern int usbg_rm_gadget(usbg_gadget *g, int opts);
+
+/**
* @brief Remove configuration strings for given language
* @param c Pointer to configuration
* @param lang Language of strings which should be deleted