Some usb module soc implementations can support usb charger type detection, which can be used by usb charger framework to control the charging current. user can define the charge detection api of the platform data if want to enable it. There are 2 api and one flag used for it, if the usb hardware can automatically complete the detection process, only platdata->usb_charger_det is required. Some imx platform need software implement the detection process, and need pull up and down DP line before and after secondary detection so platdata->usb_charger_secondary_det is also required and need set pull_dp_for_charger flag, tested with i.mx7d, support for i.mx6 will be added later. This patch set is based on Baolin's usb charger framework: http://comments.gmane.org/gmane.linux.power-management.general/74394 Li Jun (5): usb: chipidea: add usb charger detection support usb: chipidea: imx: add usb charger dectection for imx platforms usb: chipidea: imx: add imx7d usbmisc compatible string usb: chipidea: imx: add usb charger detection for imx7d doc: usb: ci-hdrc-usb2: add property usb-charger-detection .../devicetree/bindings/usb/ci-hdrc-usb2.txt | 2 + drivers/usb/chipidea/ci_hdrc_imx.c | 46 ++++- drivers/usb/chipidea/ci_hdrc_imx.h | 3 + drivers/usb/chipidea/udc.c | 40 +++++ drivers/usb/chipidea/usbmisc_imx.c | 194 +++++++++++++++++++++ include/linux/usb/chipidea.h | 4 + 6 files changed, 288 insertions(+), 1 deletion(-) -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html