From: Li Jun Date: Thu, 27 Jul 2017 15:27:15 +0000 (+0800) Subject: MLK-16013-26 staging: typec: tcpm: update PD timing X-Git-Tag: C0P2-H0.0--20200415~1907 X-Git-Url: https://git.somdevices.com/?a=commitdiff_plain;h=236b5af940c189785e9c73ed3a1526cd68c0ac1d;p=linux.git MLK-16013-26 staging: typec: tcpm: update PD timing This patch is to update several PD timings for PD compliance, all those timing definitions should be configurable via user config, this can be improved later, for now I just update its values in PD spec defined range. Reviewed-by: Peter Chen Signed-off-by: Li Jun --- diff --git a/drivers/staging/typec/pd.h b/drivers/staging/typec/pd.h index c93abb84eabf..7fdc1294dbb3 100644 --- a/drivers/staging/typec/pd.h +++ b/drivers/staging/typec/pd.h @@ -253,13 +253,13 @@ static inline unsigned int rdo_max_power(u32 rdo) #define PD_T_SENDER_RESPONSE 25 /* 24 - 30 ms, relaxed */ #define PD_T_SOURCE_ACTIVITY 45 #define PD_T_SINK_ACTIVITY 135 -#define PD_T_SINK_WAIT_CAP 240 +#define PD_T_SINK_WAIT_CAP 400 #define PD_T_PS_TRANSITION 500 #define PD_T_SRC_TRANSITION 35 #define PD_T_DRP_SNK 40 #define PD_T_DRP_SRC 30 -#define PD_T_PS_SOURCE_OFF 920 -#define PD_T_PS_SOURCE_ON 480 +#define PD_T_PS_SOURCE_OFF 790 +#define PD_T_PS_SOURCE_ON 400 #define PD_T_PS_HARD_RESET 30 #define PD_T_SRC_RECOVER 760 #define PD_T_SRC_RECOVER_MAX 1000 @@ -272,8 +272,8 @@ static inline unsigned int rdo_max_power(u32 rdo) #define PD_T_DRP_TRY 100 /* 75 - 150 ms */ #define PD_T_DRP_TRYWAIT 600 /* 400 - 800 ms */ -#define PD_T_CC_DEBOUNCE 200 /* 100 - 200 ms */ -#define PD_T_PD_DEBOUNCE 20 /* 10 - 20 ms */ +#define PD_T_CC_DEBOUNCE 110 /* 100 - 200 ms */ +#define PD_T_PD_DEBOUNCE 10 /* 10 - 20 ms */ #define PD_N_CAPS_COUNT (PD_T_NO_RESPONSE / PD_T_SEND_SOURCE_CAP) #define PD_N_HARD_RESET_COUNT 2