aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/ABI/testing/sysfs-class-extcon
diff options
context:
space:
mode:
authorMyungJoo Ham <myungjoo.ham@samsung.com>2012-04-20 01:16:26 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-04-20 12:24:03 -0400
commitbde68e60b18208978c50c6fb9bdf29826d2887f3 (patch)
tree62b48807d48c2454c374bede680c9e9c6cf71a0d /Documentation/ABI/testing/sysfs-class-extcon
parent806d9dd71ff52ef09764585baaeec23afbb98560 (diff)
Extcon: support mutually exclusive relation between cables.
There could be cables that t recannot be attaches simulatenously. Extcon device drivers may express such information via mutually_exclusive in struct extcon_dev. For example, for an extcon device with 16 cables (bits 0 to 15 are available), if mutually_exclusive = { 0x7, 0xC0, 0x81, 0 }, then, the following attachments are prohibitted. {0, 1} {0, 2} {1, 2} {6, 7} {0, 7} and every attachment set that are superset of one of the above. For the detail, please refer to linux/include/linux/extcon.h. The concept is suggested by NeilBrown <neilb@suse.de> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> -- Changes from V5: - Updated sysfs format Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'Documentation/ABI/testing/sysfs-class-extcon')
-rw-r--r--Documentation/ABI/testing/sysfs-class-extcon22
1 files changed, 22 insertions, 0 deletions
diff --git a/Documentation/ABI/testing/sysfs-class-extcon b/Documentation/ABI/testing/sysfs-class-extcon
index 19b18e986a57..20ab361bd8c6 100644
--- a/Documentation/ABI/testing/sysfs-class-extcon
+++ b/Documentation/ABI/testing/sysfs-class-extcon
@@ -15,6 +15,10 @@ Description:
15 may have both HDMI and Charger attached, or analog audio, 15 may have both HDMI and Charger attached, or analog audio,
16 video, and USB cables attached simulteneously. 16 video, and USB cables attached simulteneously.
17 17
18 If there are cables mutually exclusive with each other,
19 such binary relations may be expressed with extcon_dev's
20 mutually_exclusive array.
21
18What: /sys/class/extcon/.../name 22What: /sys/class/extcon/.../name
19Date: February 2012 23Date: February 2012
20Contact: MyungJoo Ham <myungjoo.ham@samsung.com> 24Contact: MyungJoo Ham <myungjoo.ham@samsung.com>
@@ -73,3 +77,21 @@ Description:
73 state of cable "x" (integer between 0 and 31) of an extcon 77 state of cable "x" (integer between 0 and 31) of an extcon
74 device. The state value is either 0 (detached) or 1 78 device. The state value is either 0 (detached) or 1
75 (attached). 79 (attached).
80
81What: /sys/class/extcon/.../mutually_exclusive/...
82Date: December 2011
83Contact: MyungJoo Ham <myungjoo.ham@samsung.com>
84Description:
85 Shows the relations of mutually exclusiveness. For example,
86 if the mutually_exclusive array of extcon_dev is
87 {0x3, 0x5, 0xC, 0x0}, the, the output is:
88 # ls mutually_exclusive/
89 0x3
90 0x5
91 0xc
92 #
93
94 Note that mutually_exclusive is a sub-directory of the extcon
95 device and the file names under the mutually_exclusive
96 directory show the mutually-exclusive sets, not the contents
97 of the files.