extcon: remove unused support for mutually exclusive cables
PATCH 1/1 extcon: remove unused support for mutually exclusive cables
1fe189bfb0fa ("extcon: palmas: Remove the mutually_exclusive array") removed the last user of the mutually exclusive cable support in 2015. As no user has shown up in the last 11 yrs, let's drop support for mutually exclusive cables.
Note: Removing the sysfs attributes is fine as they (incl. directory "mutually_exclusive") were created only if a user declared mutually exclusive cables. Means this doesn't break any userspace application.
Signed-off-by Heiner Kallweit <[email protected]>
--- Documentation/ABI/testing/sysfs-class-extcon | 25 ----- drivers/extcon/extcon.c | 102 ------------------- drivers/extcon/extcon.h | 14 --- 3 files changed, 141 deletions(-)
Documentation/ABI/testing/sysfs-class-extcon +0 -25
@@ -15,10 +15,6 @@ Description: may have both HDMI and Charger attached, or analog audio, video, and USB cables attached simultaneously. - If there are cables mutually exclusive with each other, - such binary relations may be expressed with extcon_dev's - mutually_exclusive array. - What: /sys/class/extcon/.../name Date: February 2012 Contact: MyungJoo Ham <[email protected]>
@@ -57,8 +53,6 @@ Description: # echo 0xHEX > state This updates the whole state of the extcon device. - Inputs of all the methods are required to meet the - mutually_exclusive conditions if they exist. It is recommended to use this "global" state interface if you need to set the value atomically. The later state
@@ -80,22 +74,3 @@ Description: state of cable "X" (integer between 0 and 31) of an extcon device. The state value is either 0 (detached) or 1 (attached). - -What: /sys/class/extcon/.../mutually_exclusive/... -Date: December 2011 -Contact: MyungJoo Ham <[email protected]> -Description: - Shows the relations of mutually exclusiveness. For example, - if the mutually_exclusive array of extcon device is - {0x3, 0x5, 0xC, 0x0}, then the output is:: - - # ls mutually_exclusive/ - 0x3 - 0x5 - 0xc - # - - Note that mutually_exclusive is a sub-directory of the extcon - device and the file names under the mutually_exclusive - directory show the mutually-exclusive sets, not the contents - of the files.
drivers/extcon/extcon.c +0 -102
150 lines not on this page · raw message
drivers/extcon/extcon.h +0 -14
@@ -11,14 +11,6 @@* @supported_cable: Array of supported cable names ending with EXTCON_NONE. * If supported_cable is NULL, cable name related APIs * are disabled. -* @mutually_exclusive: Array of mutually exclusive set of cables that cannot -* be attached simultaneously. The array should be -* ending with 0 or be NULL (no mutually exclusive cables). -* For example, if it is {0x7, 0x30, 0}, then, -* {0, 1}, {0, 1, 2}, {0, 2}, {1, 2}, or {4, 5} cannot -* be attached simulataneously. {0x7, 0} is equivalent to -* {0x3, 0x6, 0x5, 0}. If it is {0xFFFFFFFF, 0}, there -* can be no simultaneous connections. * @dev: Device of this extcon. * @id: Unique device ID of this extcon. * @state: Attach/detach state of this extcon. Do not provide at
@@ -43,7 +35,6 @@ struct extcon_dev {/* Optional user initializing data */ const char *name;const unsigned int *supported_cable; -const u32 *mutually_exclusive;/* Internal data. Please do not set. */ struct device dev;
@@ -58,11 +49,6 @@ struct extcon_dev {/* /sys/class/extcon/.../cable.n/... */ struct device_type extcon_dev_type; struct extcon_cable *cables; - -/* /sys/class/extcon/.../mutually_exclusive/... */ -struct attribute_group attr_g_muex; -struct attribute **attrs_muex; - struct device_attribute *d_attrs_muex; };#endif /* __LINUX_EXTCON_INTERNAL_H__ */
Signature · 1 line
2.53.0