29 May, 2020

1 commit


25 Mar, 2020

1 commit

  • extcon_get_edev_name() function provides client driver to request
    extcon dev's name. If extcon driver and client driver are compiled
    as loadable modules, extcon_get_edev_name() function symbol is not
    visible to client driver. Hence mark extcon_find_edev_name() function
    as exported symbol.

    Signed-off-by: Mayank Rana
    Signed-off-by: Chanwoo Choi

    Mayank Rana
     

05 Jun, 2019

1 commit

  • Based on 1 normalized pattern(s):

    this software is licensed under the terms of the gnu general public
    license version 2 as published by the free software foundation and
    may be copied distributed and modified under those terms this
    program is distributed in the hope that it will be useful but
    without any warranty without even the implied warranty of
    merchantability or fitness for a particular purpose see the gnu
    general public license for more details

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 285 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Alexios Zavras
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190529141900.642774971@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

28 Aug, 2018

2 commits


12 Jul, 2018

1 commit

  • Previously, extcon used the spinlock before calling the notifier_call_chain
    to prevent the scheduled out of task and to prevent the notification delay.
    When spinlock is locked for sending the notification, deadlock issue
    occured on the side of extcon consumer device. To fix this issue,
    extcon consumer device should always use the work. it is always not
    reasonable to use work.

    To fix this issue on extcon consumer device, release locking when sending
    the notification of connector state.

    Fixes: ab11af049f88 ("extcon: Add the synchronization extcon APIs to support the notification")
    Cc: stable@vger.kernel.org
    Cc: Roger Quadros
    Cc: Kishon Vijay Abraham I
    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     

13 Jun, 2018

1 commit

  • The kzalloc() function has a 2-factor argument form, kcalloc(). This
    patch replaces cases of:

    kzalloc(a * b, gfp)

    with:
    kcalloc(a * b, gfp)

    as well as handling cases of:

    kzalloc(a * b * c, gfp)

    with:

    kzalloc(array3_size(a, b, c), gfp)

    as it's slightly less ugly than:

    kzalloc_array(array_size(a, b), c, gfp)

    This does, however, attempt to ignore constant size factors like:

    kzalloc(4 * 1024, gfp)

    though any constants defined via macros get caught up in the conversion.

    Any factors with a sizeof() of "unsigned char", "char", and "u8" were
    dropped, since they're redundant.

    The Coccinelle script used for this was:

    // Fix redundant parens around sizeof().
    @@
    type TYPE;
    expression THING, E;
    @@

    (
    kzalloc(
    - (sizeof(TYPE)) * E
    + sizeof(TYPE) * E
    , ...)
    |
    kzalloc(
    - (sizeof(THING)) * E
    + sizeof(THING) * E
    , ...)
    )

    // Drop single-byte sizes and redundant parens.
    @@
    expression COUNT;
    typedef u8;
    typedef __u8;
    @@

    (
    kzalloc(
    - sizeof(u8) * (COUNT)
    + COUNT
    , ...)
    |
    kzalloc(
    - sizeof(__u8) * (COUNT)
    + COUNT
    , ...)
    |
    kzalloc(
    - sizeof(char) * (COUNT)
    + COUNT
    , ...)
    |
    kzalloc(
    - sizeof(unsigned char) * (COUNT)
    + COUNT
    , ...)
    |
    kzalloc(
    - sizeof(u8) * COUNT
    + COUNT
    , ...)
    |
    kzalloc(
    - sizeof(__u8) * COUNT
    + COUNT
    , ...)
    |
    kzalloc(
    - sizeof(char) * COUNT
    + COUNT
    , ...)
    |
    kzalloc(
    - sizeof(unsigned char) * COUNT
    + COUNT
    , ...)
    )

    // 2-factor product with sizeof(type/expression) and identifier or constant.
    @@
    type TYPE;
    expression THING;
    identifier COUNT_ID;
    constant COUNT_CONST;
    @@

    (
    - kzalloc
    + kcalloc
    (
    - sizeof(TYPE) * (COUNT_ID)
    + COUNT_ID, sizeof(TYPE)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(TYPE) * COUNT_ID
    + COUNT_ID, sizeof(TYPE)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(TYPE) * (COUNT_CONST)
    + COUNT_CONST, sizeof(TYPE)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(TYPE) * COUNT_CONST
    + COUNT_CONST, sizeof(TYPE)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(THING) * (COUNT_ID)
    + COUNT_ID, sizeof(THING)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(THING) * COUNT_ID
    + COUNT_ID, sizeof(THING)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(THING) * (COUNT_CONST)
    + COUNT_CONST, sizeof(THING)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(THING) * COUNT_CONST
    + COUNT_CONST, sizeof(THING)
    , ...)
    )

    // 2-factor product, only identifiers.
    @@
    identifier SIZE, COUNT;
    @@

    - kzalloc
    + kcalloc
    (
    - SIZE * COUNT
    + COUNT, SIZE
    , ...)

    // 3-factor product with 1 sizeof(type) or sizeof(expression), with
    // redundant parens removed.
    @@
    expression THING;
    identifier STRIDE, COUNT;
    type TYPE;
    @@

    (
    kzalloc(
    - sizeof(TYPE) * (COUNT) * (STRIDE)
    + array3_size(COUNT, STRIDE, sizeof(TYPE))
    , ...)
    |
    kzalloc(
    - sizeof(TYPE) * (COUNT) * STRIDE
    + array3_size(COUNT, STRIDE, sizeof(TYPE))
    , ...)
    |
    kzalloc(
    - sizeof(TYPE) * COUNT * (STRIDE)
    + array3_size(COUNT, STRIDE, sizeof(TYPE))
    , ...)
    |
    kzalloc(
    - sizeof(TYPE) * COUNT * STRIDE
    + array3_size(COUNT, STRIDE, sizeof(TYPE))
    , ...)
    |
    kzalloc(
    - sizeof(THING) * (COUNT) * (STRIDE)
    + array3_size(COUNT, STRIDE, sizeof(THING))
    , ...)
    |
    kzalloc(
    - sizeof(THING) * (COUNT) * STRIDE
    + array3_size(COUNT, STRIDE, sizeof(THING))
    , ...)
    |
    kzalloc(
    - sizeof(THING) * COUNT * (STRIDE)
    + array3_size(COUNT, STRIDE, sizeof(THING))
    , ...)
    |
    kzalloc(
    - sizeof(THING) * COUNT * STRIDE
    + array3_size(COUNT, STRIDE, sizeof(THING))
    , ...)
    )

    // 3-factor product with 2 sizeof(variable), with redundant parens removed.
    @@
    expression THING1, THING2;
    identifier COUNT;
    type TYPE1, TYPE2;
    @@

    (
    kzalloc(
    - sizeof(TYPE1) * sizeof(TYPE2) * COUNT
    + array3_size(COUNT, sizeof(TYPE1), sizeof(TYPE2))
    , ...)
    |
    kzalloc(
    - sizeof(TYPE1) * sizeof(THING2) * (COUNT)
    + array3_size(COUNT, sizeof(TYPE1), sizeof(TYPE2))
    , ...)
    |
    kzalloc(
    - sizeof(THING1) * sizeof(THING2) * COUNT
    + array3_size(COUNT, sizeof(THING1), sizeof(THING2))
    , ...)
    |
    kzalloc(
    - sizeof(THING1) * sizeof(THING2) * (COUNT)
    + array3_size(COUNT, sizeof(THING1), sizeof(THING2))
    , ...)
    |
    kzalloc(
    - sizeof(TYPE1) * sizeof(THING2) * COUNT
    + array3_size(COUNT, sizeof(TYPE1), sizeof(THING2))
    , ...)
    |
    kzalloc(
    - sizeof(TYPE1) * sizeof(THING2) * (COUNT)
    + array3_size(COUNT, sizeof(TYPE1), sizeof(THING2))
    , ...)
    )

    // 3-factor product, only identifiers, with redundant parens removed.
    @@
    identifier STRIDE, SIZE, COUNT;
    @@

    (
    kzalloc(
    - (COUNT) * STRIDE * SIZE
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kzalloc(
    - COUNT * (STRIDE) * SIZE
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kzalloc(
    - COUNT * STRIDE * (SIZE)
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kzalloc(
    - (COUNT) * (STRIDE) * SIZE
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kzalloc(
    - COUNT * (STRIDE) * (SIZE)
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kzalloc(
    - (COUNT) * STRIDE * (SIZE)
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kzalloc(
    - (COUNT) * (STRIDE) * (SIZE)
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kzalloc(
    - COUNT * STRIDE * SIZE
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    )

    // Any remaining multi-factor products, first at least 3-factor products,
    // when they're not all constants...
    @@
    expression E1, E2, E3;
    constant C1, C2, C3;
    @@

    (
    kzalloc(C1 * C2 * C3, ...)
    |
    kzalloc(
    - (E1) * E2 * E3
    + array3_size(E1, E2, E3)
    , ...)
    |
    kzalloc(
    - (E1) * (E2) * E3
    + array3_size(E1, E2, E3)
    , ...)
    |
    kzalloc(
    - (E1) * (E2) * (E3)
    + array3_size(E1, E2, E3)
    , ...)
    |
    kzalloc(
    - E1 * E2 * E3
    + array3_size(E1, E2, E3)
    , ...)
    )

    // And then all remaining 2 factors products when they're not all constants,
    // keeping sizeof() as the second factor argument.
    @@
    expression THING, E1, E2;
    type TYPE;
    constant C1, C2, C3;
    @@

    (
    kzalloc(sizeof(THING) * C2, ...)
    |
    kzalloc(sizeof(TYPE) * C2, ...)
    |
    kzalloc(C1 * C2 * C3, ...)
    |
    kzalloc(C1 * C2, ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(TYPE) * (E2)
    + E2, sizeof(TYPE)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(TYPE) * E2
    + E2, sizeof(TYPE)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(THING) * (E2)
    + E2, sizeof(THING)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - sizeof(THING) * E2
    + E2, sizeof(THING)
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - (E1) * E2
    + E1, E2
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - (E1) * (E2)
    + E1, E2
    , ...)
    |
    - kzalloc
    + kcalloc
    (
    - E1 * E2
    + E1, E2
    , ...)
    )

    Signed-off-by: Kees Cook

    Kees Cook
     

08 Mar, 2018

1 commit


23 Oct, 2017

1 commit


16 Aug, 2017

2 commits


19 Jul, 2017

1 commit


23 May, 2017

2 commits


06 Apr, 2017

2 commits


04 Apr, 2017

1 commit

  • The extcon core already provides the extcon_register_notifier() function
    in order to register the notifier block which is used to monitor
    the state change for the specific external connector such as EXTCON_USB,
    EXTCON_USB_HOST and so on. The extcon consumer uses the this function.

    The extcon consumer might need to monitor the all supported external
    connectors from the extcon device. In this case, The extcon consumer
    should have each notifier_block structure for each external connector.

    This patch adds the new extcon_register_notifier_all() function
    that extcon consumer is able to monitor the state change of all
    supported external connectors by using only one notifier_block structure.

    - List of new added functions:
    int extcon_register_notifier_all(struct extcon_dev *edev,
    struct notifier_block *nb);
    int extcon_unregister_notifier_all(struct extcon_dev *edev,
    struct notifier_block *nb);
    int devm_extcon_register_notifier_all(struct device *dev,
    struct extcon_dev *edev, struct notifier_block *nb);
    void devm_extcon_unregister_notifier_all(struct device *dev,
    struct extcon_dev *edev, struct notifier_block *nb);

    Suggested-by: Hans de Goede
    Signed-off-by: Chanwoo Choi
    Tested-by: Hans de Goede
    Acked-by: Hans de Goede

    Chanwoo Choi
     

09 Jan, 2017

5 commits

  • This patch renames the EXTCON_USB_HOST by using '-' char because
    the name of all external connector use the '-' char instead of '_' char.
    - "USB_HOST" -> "USB-HOST"

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     
  • This patch adds the new EXTCON_CHG_USB_PD for USB PD (Power Delivery)[1].
    The USB Power Delivery specification specifies that USB cable provides
    the increased power more than 7.5W to device with larger power demand.
    The EXTCON_CHG_USB_PD has the EXTCON_TYPE_CHG and EXTCON_TYPE_USB type.

    [1] https://en.wikipedia.org/wiki/USB#PD

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     
  • This patch moves the 'struct extcon_dev' of extcon subsystem
    to driver/extcon/extcon.h header file because the struct extcon_dev have to
    be handled by extcon API to guarantee the consistency of strcut extcon_dev.
    If external drivers are able to touch the struct extcon_dev directly, it might
    cause the critical and unknown problem.

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     
  • This patch removes the potential problem of extcon_register_notifier()
    when edev parameter is NULL. When edev is NULL, this function returns
    the first extcon device which includes the sepecific external connector
    of second paramter. But, it don't guarantee the same operation in all cases.
    To remove this confusion and potential problem, this patch fixes it.

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     
  • Function get_zeroed_page() returns a NULL pointer if there is no enough
    memory. In function extcon_sync(), it returns 0 if the call to
    get_zeroed_page() fails. The return value 0 indicates success in the
    context, which is incosistent with the execution status. This patch
    fixes the bug by returning -ENOMEM.

    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188611

    Signed-off-by: Pan Bian
    Signed-off-by: Chanwoo Choi

    Pan Bian
     

08 Aug, 2016

12 commits

  • This patchs add the new EXTCON_CHG_WPT for Wireless Power Transfer[1].
    The Wireless Power Transfer is the transmission of electronical energy
    from a power source. The EXTCON_CHG_WPT has the EXTCON_TYPE_CHG.

    [1] https://en.wikipedia.org/wiki/Wireless_power_transfer

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     
  • This patch adds the new EXTCON_DISP_HMD id for Head-mounted Display[1] device.
    The HMD device is usually for USB connector type So, the HMD connector
    has the two extcon types of both EXTCON_TYPE_DISP and EXTCON_TYPE_USB.

    [1] https://en.wikipedia.org/wiki/Head-mounted_display

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     
  • Add EXTCON_DISP_DP for the Display external connector. For Type-C
    connector the DisplayPort can work as an Alternate Mode(VESA DisplayPort
    Alt Mode on USB Type-C Standard). The Type-C support both normal
    and flipped orientation, so add a property to extcon.

    Signed-off-by: Chris Zhong
    Signed-off-by: Chanwoo Choi
    Tested-by: Chris Zhong
    Tested-by: Guenter Roeck
    Reviewed-by: Guenter Roeck

    Chris Zhong
     
  • This patch adds the synchronization extcon APIs to support the notifications
    for both state and property. When extcon_*_sync() functions is called,
    the extcon informs the information from extcon provider to extcon client.

    The extcon driver may need to change the both state and multiple properties
    at the same time. After setting the data of a external connector,
    the extcon send the notification to client driver with the extcon_*_sync().

    The list of new extcon APIs as following:
    - extcon_sync() : Send the notification for each external connector to
    synchronize the information between extcon provider driver
    and extcon client driver.
    - extcon_set_state_sync() : Set the state of external connector with noti.
    - extcon_set_property_sync() : Set the property of external connector with noti.

    For example,
    case 1, change the state of external connector and synchronized the data.
    extcon_set_state_sync(edev, EXTCON_USB, 1);

    case 2, change both the state and property of external connector
    and synchronized the data.
    extcon_set_state(edev, EXTCON_USB, 1);
    extcon_set_property(edev, EXTCON_USB, EXTCON_PROP_USB_VBUS 1);
    extcon_sync(edev, EXTCON_USB);

    case 3, change the property of external connector and synchronized the data.
    extcon_set_property(edev, EXTCON_USB, EXTCON_PROP_USB_VBUS, 0);
    extcon_sync(edev, EXTCON_USB);

    case 4, change the property of external connector and synchronized the data.
    extcon_set_property_sync(edev, EXTCON_USB, EXTCON_PROP_USB_VBUS, 0);

    Signed-off-by: Chanwoo Choi
    Tested-by: Chris Zhong
    Tested-by: Guenter Roeck
    Reviewed-by: Guenter Roeck

    Chanwoo Choi
     
  • This patch just renames the existing extcon_get/set_cable_state_()
    as following because of maintaining the function naming pattern
    like as extcon APIs for property.
    - extcon_set_cable_state_() -> extcon_set_state()
    - extcon_get_cable_state_() -> extcon_get_state()

    But, this patch remains the old extcon_set/get_cable_state_() functions
    to prevent the build break. After altering new APIs, remove the old APIs.

    Signed-off-by: Chanwoo Choi
    Tested-by: Chris Zhong
    Tested-by: Guenter Roeck
    Reviewed-by: Guenter Roeck

    Chanwoo Choi
     
  • This patch adds the support of the property capability setting. This function
    decides the supported properties of each external connector on extcon provider
    driver.

    Ths list of new extcon APIs to get/set the capability of property as following:
    - int extcon_get_property_capability(struct extcon_dev *edev,
    unsigned int id, unsigned int prop);
    - int extcon_set_property_capability(struct extcon_dev *edev,
    unsigned int id, unsigned int prop);

    Signed-off-by: Chanwoo Choi
    Tested-by: Chris Zhong
    Tested-by: Guenter Roeck
    Reviewed-by: Guenter Roeck

    Chanwoo Choi
     
  • This patch support the extcon property for the external connector
    because each external connector might have the property according to
    the H/W design and the specific characteristics.

    - EXTCON_PROP_USB_[property name]
    - EXTCON_PROP_CHG_[property name]
    - EXTCON_PROP_JACK_[property name]
    - EXTCON_PROP_DISP_[property name]

    Add the new extcon APIs to get/set the property value as following:
    - int extcon_get_property(struct extcon_dev *edev, unsigned int id,
    unsigned int prop,
    union extcon_property_value *prop_val)
    - int extcon_set_property(struct extcon_dev *edev, unsigned int id,
    unsigned int prop,
    union extcon_property_value prop_val)

    Signed-off-by: Chanwoo Choi
    Tested-by: Chris Zhong
    Tested-by: Guenter Roeck
    Reviewed-by: Guenter Roeck

    Chanwoo Choi
     
  • 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
    Tested-by: Chris Zhong
    Tested-by: Guenter Roeck
    Signed-off-by: MyungJoo Ham
    Reviewed-by: Guenter Roeck

    Chanwoo Choi
     
  • This patch fixes below compilation warning:-
    drivers/extcon/extcon.c: In function extcon_register_notifier:
    drivers/extcon/extcon.c:455:6: warning: idx may be used uninitialized in this function [-Wmaybe-uninitialized]
    if (idx >= 0) {

    Signed-off-by: Vaneet Narang
    Signed-off-by: Maninder Singh
    [cw00.choi : Modify the patch title using the a captical letter for first char]
    Signed-off-by: Chanwoo Choi

    Maninder Singh
     
  • This patch restrict the usage of extcon_update_state() in the extcon
    core because the extcon_update_state() use the bit masking to change
    the state of external connector. When this function is used in device drivers,
    it may occur the probelm with the handling mistake of bit masking.

    Also, this patch removes the extcon_get/set_state() functions because these
    functions use the bit masking which is reluctant way. Instead, extcon
    provides the extcon_set/get_cable_state_() functions.

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     
  • This patch removes the state_store() which change the state of external
    connectors with bit masking on user-space. It is wrong access to modify
    the change the state of external connectors.

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     
  • Sometimes drivers may call this API and expect it to fail because
    the extcon they're looking for is optional. Let's move these
    prints to debug level so it doesn't look like there's a problem
    when there isn't one.

    Signed-off-by: Stephen Boyd
    Signed-off-by: Chanwoo Choi

    Stephen Boyd
     

02 Jul, 2016

1 commit


27 Jun, 2016

2 commits


23 Jun, 2016

1 commit


10 Jun, 2016

1 commit

  • This patch removes the deprecated extcon functions using string type
    to identify the type of external connector. The Commit 2a9de9c0f08d61
    ("extcon: Use the unique id for external connector instead of string)
    uses the unique id to separate the type of external connector instead of
    string name.
    - extcon_register_interest()
    - extcon_unregister_interest()
    - extcon_set_cable_state()
    - extcon_get_cable_state()

    And, extcon_register_interest() finds the first extcon device to include the
    requested external connector from extcon client device and then register the
    notifier if extcon device argument is NULL. Instead, extcon_register_notifier()
    supports this feature.

    But, this patch remains the deprecatd function definition to prevent
    the build break.

    Signed-off-by: Chanwoo Choi

    Chanwoo Choi
     

16 Oct, 2015

1 commit

  • This patch modifies the id and name of external connector with the
    additional prefix to clarify both attribute and meaning of external
    connector as following:
    - EXTCON_CHG_* mean the charger connector.
    - EXTCON_JACK_* mean the jack connector.
    - EXTCON_DISP_* mean the display port connector.

    Following table show the new name of external connector with old name:
    --------------------------------------------------
    Old extcon name | New extcon name |
    --------------------------------------------------
    EXTCON_TA | EXTCON_CHG_USB_DCP |
    EXTCON_CHARGE_DOWNSTREAM| EXTCON_CHG_USB_CDP |
    EXTCON_FAST_CHARGER | EXTCON_CHG_USB_FAST |
    EXTCON_SLOW_CHARGER | EXTCON_CHG_USB_SLOW |
    --------------------------------------------------
    EXTCON_MICROPHONE | EXTCON_JACK_MICROPHONE |
    EXTCON_HEADPHONE | EXTCON_JACK_HEADPHONE |
    EXTCON_LINE_IN | EXTCON_JACK_LINE_IN |
    EXTCON_LINE_OUT | EXTCON_JACK_LINE_OUT |
    EXTCON_VIDEO_IN | EXTCON_JACK_VIDEO_IN |
    EXTCON_VIDEO_OUT | EXTCON_JACK_VIDEO_OUT |
    EXTCON_SPDIF_IN | EXTCON_JACK_SPDIF_IN |
    EXTCON_SPDIF_OUT | EXTCON_JACK_SPDIF_OUT |
    --------------------------------------------------
    EXTCON_HMDI | EXTCON_DISP_HDMI |
    EXTCON_MHL | EXTCON_DISP_MHL |
    EXTCON_DVI | EXTCON_DISP_DVI |
    EXTCON_VGA | EXTCON_DISP_VGA |
    --------------------------------------------------

    And, when altering the name of USB charger connector, EXTCON refers to the
    "Battery Charging v1.2 Spec and Adopters Agreement"[1] to use the standard
    name of USB charging port as following. Following name of USB charging port
    are already used in power_supply subsystem. We chan check it on patch[2].
    - EXTCON_CHG_USB_SDP /* Standard Downstream Port */
    - EXTCON_CHG_USB_DCP /* Dedicated Charging Port */
    - EXTCON_CHG_USB_CDP /* Charging Downstream Port */
    - EXTCON_CHG_USB_ACA /* Accessory Charger Adapter */

    [1] www.usb.org/developers/docs/devclass_docs/BCv1.2_070312.zip
    [2] commit 85efc8a18ced ("power_supply: Add types for USB chargers")

    Signed-off-by: Chanwoo Choi
    [ckeepax: For the Arizona changes]
    Acked-by: Charles Keepax
    Reviewed-by: Roger Quadros

    Chanwoo Choi