Lines Matching +full:- +full:30 +full:mv

1 /* SPDX-License-Identifier: GPL-2.0 */
11 #define PDO_TYPE_SHIFT 30
26 #define PDO_FIXED_VOLT_SHIFT 10 /* 50mV units */
29 #define PDO_FIXED_VOLT(mv) ((((mv) / 50) & PDO_VOLT_MASK) << PDO_FIXED_VOLT_SHIFT) argument
32 #define PDO_FIXED(mv, ma, flags) \ argument
34 PDO_FIXED_VOLT(mv) | PDO_FIXED_CURR(ma))
36 #define VSAFE5V 5000 /* mv units */
38 #define PDO_BATT_MAX_VOLT_SHIFT 20 /* 50mV units */
39 #define PDO_BATT_MIN_VOLT_SHIFT 10 /* 50mV units */
42 #define PDO_BATT_MIN_VOLT(mv) ((((mv) / 50) & PDO_VOLT_MASK) << PDO_BATT_MIN_VOLT_SHIFT) argument
43 #define PDO_BATT_MAX_VOLT(mv) ((((mv) / 50) & PDO_VOLT_MASK) << PDO_BATT_MAX_VOLT_SHIFT) argument
50 #define PDO_VAR_MAX_VOLT_SHIFT 20 /* 50mV units */
51 #define PDO_VAR_MIN_VOLT_SHIFT 10 /* 50mV units */
54 #define PDO_VAR_MIN_VOLT(mv) ((((mv) / 50) & PDO_VOLT_MASK) << PDO_VAR_MIN_VOLT_SHIFT) argument
55 #define PDO_VAR_MAX_VOLT(mv) ((((mv) / 50) & PDO_VOLT_MASK) << PDO_VAR_MAX_VOLT_SHIFT) argument
64 #define PDO_APDO_TYPE_SHIFT 28 /* Only valid value currently is 0x0 - PPS */
69 #define PDO_PPS_APDO_MAX_VOLT_SHIFT 17 /* 100mV units */
70 #define PDO_PPS_APDO_MIN_VOLT_SHIFT 8 /* 100mV units */
76 #define PDO_PPS_APDO_MIN_VOLT(mv) \ argument
77 ((((mv) / 100) & PDO_PPS_APDO_VOLT_MASK) << PDO_PPS_APDO_MIN_VOLT_SHIFT)
78 #define PDO_PPS_APDO_MAX_VOLT(mv) \ argument
79 ((((mv) / 100) & PDO_PPS_APDO_VOLT_MASK) << PDO_PPS_APDO_MAX_VOLT_SHIFT)
89 * Based on "Table 6-14 Fixed Supply PDO - Sink" of "USB Power Delivery Specification Revision 3.0,
99 * --------------------
101 * <30> :: data capable as a USB device
107 * <15:0> :: USB-IF assigned VID for this cable vendor
133 ((usbh) << 31 | (usbd) << 30 | ((ufp_cable) & 0x7) << 27 \
139 * -------------
140 * <31:0> : USB-IF assigned XID for this cable
146 * -----------
154 * --------
215 * --------
236 * ---------
240 * <19:18> :: type-C to Type-A/B/C/Captive (00b == A, 01 == B, 10 == C, 11 == Captive)
254 * ---------
259 * <19:18> :: Type-C to Type-C/Captive (10b == C, 11b == Captive)
263 * <10:9> :: Maximum Vbus voltage (00b == 20V, 01b == 30V, 10b == 40V, 11b == 50V)
270 * ---------
279 * <10:9> :: Maximum Vbus voltage (00b == 20V, 01b == 30V, 10b == 40V, 11b == 50V)
358 * ---------
412 * ---------
441 * ---------
446 * <16:15> :: Maximum Vbus voltage (00b == 20V, 01b == 30V, 10b == 40V, 11b == 50V)