Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

typec: tcpm: Move out of staging

Move tcpm (USB Type-C Port Manager) out of staging.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Guenter Roeck and committed by
Greg Kroah-Hartman
4b4e02c8 70cd90be

+17 -28
-8
drivers/staging/typec/Kconfig
··· 1 1 menu "USB Power Delivery and Type-C drivers" 2 2 3 - config TYPEC_TCPM 4 - tristate "USB Type-C Port Controller Manager" 5 - depends on USB 6 - select TYPEC 7 - help 8 - The Type-C Port Controller Manager provides a USB PD and USB Type-C 9 - state machine for use with Type-C Port Controllers. 10 - 11 3 if TYPEC_TCPM 12 4 13 5 config TYPEC_TCPCI
-1
drivers/staging/typec/Makefile
··· 1 - obj-$(CONFIG_TYPEC_TCPM) += tcpm.o 2 1 obj-$(CONFIG_TYPEC_TCPCI) += tcpci.o 3 2 obj-y += fusb302/
-10
drivers/staging/typec/TODO
··· 1 - tcpm: 2 - - Add documentation (at the very least for the API to low level drivers) 3 - - Split PD code into separate file 4 - - Check if it makes sense to use tracepoints instead of debugfs for debug logs 5 - - Implement Alternate Mode handling 6 - - Address "#if 0" code if not addressed with the above 7 - - Validate all comments marked with "XXX"; either address or remove comments 8 - - Add support for USB PD 3.0. While not mandatory, at least fast role swap 9 - as well as authentication support would be very desirable. 10 - 11 1 tcpci: 12 2 - Test with real hardware 13 3
+2 -2
drivers/staging/typec/fusb302/fusb302.c
··· 37 37 #include <linux/string.h> 38 38 #include <linux/types.h> 39 39 #include <linux/usb/typec.h> 40 + #include <linux/usb/tcpm.h> 41 + #include <linux/usb/pd.h> 40 42 #include <linux/workqueue.h> 41 43 42 44 #include "fusb302_reg.h" 43 - #include "../tcpm.h" 44 - #include "../pd.h" 45 45 46 46 /* 47 47 * When the device is SNK, BC_LVL interrupt is used to monitor cc pins
drivers/staging/typec/pd.h include/linux/usb/pd.h
drivers/staging/typec/pd_bdo.h include/linux/usb/pd_bdo.h
drivers/staging/typec/pd_vdo.h include/linux/usb/pd_vdo.h
+2 -2
drivers/staging/typec/tcpci.c
··· 20 20 #include <linux/i2c.h> 21 21 #include <linux/interrupt.h> 22 22 #include <linux/regmap.h> 23 + #include <linux/usb/pd.h> 24 + #include <linux/usb/tcpm.h> 23 25 #include <linux/usb/typec.h> 24 26 25 - #include "pd.h" 26 27 #include "tcpci.h" 27 - #include "tcpm.h" 28 28 29 29 #define PD_RETRY_COUNT 3 30 30
+4 -5
drivers/staging/typec/tcpm.c drivers/usb/typec/tcpm.c
··· 26 26 #include <linux/seq_file.h> 27 27 #include <linux/slab.h> 28 28 #include <linux/spinlock.h> 29 + #include <linux/usb/pd.h> 30 + #include <linux/usb/pd_bdo.h> 31 + #include <linux/usb/pd_vdo.h> 32 + #include <linux/usb/tcpm.h> 29 33 #include <linux/usb/typec.h> 30 34 #include <linux/workqueue.h> 31 - 32 - #include "pd.h" 33 - #include "pd_vdo.h" 34 - #include "pd_bdo.h" 35 - #include "tcpm.h" 36 35 37 36 #define FOREACH_STATE(S) \ 38 37 S(INVALID_STATE), \
drivers/staging/typec/tcpm.h include/linux/usb/tcpm.h
+8
drivers/usb/typec/Kconfig
··· 4 4 config TYPEC 5 5 tristate 6 6 7 + config TYPEC_TCPM 8 + tristate "USB Type-C Port Controller Manager" 9 + depends on USB 10 + select TYPEC 11 + help 12 + The Type-C Port Controller Manager provides a USB PD and USB Type-C 13 + state machine for use with Type-C Port Controllers. 14 + 7 15 config TYPEC_WCOVE 8 16 tristate "Intel WhiskeyCove PMIC USB Type-C PHY driver" 9 17 depends on ACPI
+1
drivers/usb/typec/Makefile
··· 1 1 obj-$(CONFIG_TYPEC) += typec.o 2 + obj-$(CONFIG_TYPEC_TCPM) += tcpm.o 2 3 obj-$(CONFIG_TYPEC_WCOVE) += typec_wcove.o 3 4 obj-$(CONFIG_TYPEC_UCSI) += ucsi/