brintos

brintos / linux-shallow public Read only

0
0
Text · 3.4 KiB · f8e7053 Raw
102 lines · plain
1What:		/sys/class/extcon/.../2Date:		February 20123Contact:	MyungJoo Ham <myungjoo.ham@samsung.com>4Description:5		Provide a place in sysfs for the extcon objects.6		This allows accessing extcon specific variables.7		The name of extcon object denoted as ... is the name given8		with extcon_dev_register.9 10		One extcon device denotes a single external connector11		port. An external connector may have multiple cables12		attached simultaneously. Many of docks, cradles, and13		accessory cables have such capability. For example,14		the 30-pin port of Nuri board (/arch/arm/mach-exynos)15		may have both HDMI and Charger attached, or analog audio,16		video, and USB cables attached simultaneously.17 18		If there are cables mutually exclusive with each other,19		such binary relations may be expressed with extcon_dev's20		mutually_exclusive array.21 22What:		/sys/class/extcon/.../name23Date:		February 201224Contact:	MyungJoo Ham <myungjoo.ham@samsung.com>25Description:26		The /sys/class/extcon/.../name shows the name of the extcon27		object. If the extcon object has an optional callback28		"show_name" defined, the callback will provide the name with29		this sysfs node.30 31What:		/sys/class/extcon/.../state32Date:		February 201233Contact:	MyungJoo Ham <myungjoo.ham@samsung.com>34Description:35		The /sys/class/extcon/.../state shows and stores the cable36		attach/detach information of the corresponding extcon object.37		If the extcon object has an optional callback "show_state"38		defined, the showing function is overridden with the optional39		callback.40 41		If the default callback for showing function is used, the42		format is like this::43 44		    # cat state45		    USB_OTG=146		    HDMI=047		    TA=148		    EAR_JACK=049		    #50 51		In this example, the extcon device has USB_OTG and TA52		cables attached and HDMI and EAR_JACK cables detached.53 54		In order to update the state of an extcon device, enter a hex55		state number starting with 0x::56 57		    # echo 0xHEX > state58 59		This updates the whole state of the extcon device.60		Inputs of all the methods are required to meet the61		mutually_exclusive conditions if they exist.62 63		It is recommended to use this "global" state interface if64		you need to set the value atomically. The later state65		interface associated with each cable cannot update66		multiple cable states of an extcon device simultaneously.67 68What:		/sys/class/extcon/.../cable.X/name69Date:		February 201270Contact:	MyungJoo Ham <myungjoo.ham@samsung.com>71Description:72		The /sys/class/extcon/.../cable.X/name shows the name of cable73		"X" (integer between 0 and 31) of an extcon device.74 75What:		/sys/class/extcon/.../cable.X/state76Date:		February 201277Contact:	MyungJoo Ham <myungjoo.ham@samsung.com>78Description:79		The /sys/class/extcon/.../cable.X/state shows and stores the80		state of cable "X" (integer between 0 and 31) of an extcon81		device. The state value is either 0 (detached) or 182		(attached).83 84What:		/sys/class/extcon/.../mutually_exclusive/...85Date:		December 201186Contact:	MyungJoo Ham <myungjoo.ham@samsung.com>87Description:88		Shows the relations of mutually exclusiveness. For example,89		if the mutually_exclusive array of extcon device is90		{0x3, 0x5, 0xC, 0x0}, then the output is::91 92		    # ls mutually_exclusive/93		    0x394		    0x595		    0xc96		    #97 98		Note that mutually_exclusive is a sub-directory of the extcon99		device and the file names under the mutually_exclusive100		directory show the mutually-exclusive sets, not the contents101		of the files.102