summaryrefslogtreecommitdiff
path: root/include/linux/extcon.h
diff options
context:
space:
mode:
authorChanwoo Choi <cw00.choi@samsung.com>2016-07-11 16:34:52 +0900
committerChanwoo Choi <cw00.choi@samsung.com>2016-08-08 11:17:20 +0900
commit55e4e2f129c6664c14166a30f4e0e933ebb61d9b (patch)
treeeb55520c120255375921cf39749520442e651d51 /include/linux/extcon.h
parent2c8116a1110a93f298b10339d773fb055a0c04d7 (diff)
extcon: Add the extcon_type to gather each connector into five category
This patch adds the new extcon type to group the each connecotr into following five category. This type would be used to handle the connectors as a group unit instead of a connector unit. - EXTCON_TYPE_USB : USB connector - EXTCON_TYPE_CHG : Charger connector - EXTCON_TYPE_JACK : Jack connector - EXTCON_TYPE_DISP : Display connector - EXTCON_TYPE_MISC : Miscellaneous connector Also, each external connector is possible to belong to one more extcon type. In caes of EXTCON_CHG_USB_SDP, it have the EXTCON_TYPE_CHG and EXTCON_TYPE_USB. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Tested-by: Chris Zhong <zyw@rock-chips.com> Tested-by: Guenter Roeck <groeck@chromium.org> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Reviewed-by: Guenter Roeck <groeck@chromium.org>
Diffstat (limited to 'include/linux/extcon.h')
-rw-r--r--include/linux/extcon.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/extcon.h b/include/linux/extcon.h
index 667b1d35af12..46d802892c82 100644
--- a/include/linux/extcon.h
+++ b/include/linux/extcon.h
@@ -29,6 +29,15 @@
#include <linux/device.h>
/*
+ * Define the type of supported external connectors
+ */
+#define EXTCON_TYPE_USB BIT(0) /* USB connector */
+#define EXTCON_TYPE_CHG BIT(1) /* Charger connector */
+#define EXTCON_TYPE_JACK BIT(2) /* Jack connector */
+#define EXTCON_TYPE_DISP BIT(3) /* Display connector */
+#define EXTCON_TYPE_MISC BIT(4) /* Miscellaneous connector */
+
+/*
* Define the unique id of supported external connectors
*/
#define EXTCON_NONE 0