[coreboot-gerrit] Change in coreboot[master]: [WIP]src/soc/intel/cannonlake: Define USB AFE params

Pratikkumar V Prajapati (Code Review) gerrit at coreboot.org
Sat Sep 2 07:37:54 CEST 2017


Pratikkumar V Prajapati has uploaded this change for review. ( https://review.coreboot.org/21339


Change subject: [WIP]src/soc/intel/cannonlake: Define USB AFE params
......................................................................

[WIP]src/soc/intel/cannonlake: Define USB AFE params

Change-Id: I42243950366d672e886158eb1934350f47b4ff1f
Signed-off-by: Pratik Prajapati <pratikkumar.v.prajapati at intel.com>
---
M src/soc/intel/cannonlake/include/soc/usb.h
1 file changed, 49 insertions(+), 0 deletions(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/39/21339/1

diff --git a/src/soc/intel/cannonlake/include/soc/usb.h b/src/soc/intel/cannonlake/include/soc/usb.h
index eac017e..c02949f 100644
--- a/src/soc/intel/cannonlake/include/soc/usb.h
+++ b/src/soc/intel/cannonlake/include/soc/usb.h
@@ -19,6 +19,25 @@
 
 #include <stdint.h>
 
+/* Per Port HS Transmitter Emphasis */
+#define USB2_EMP_OFF			0
+#define USB2_DE_EMP_ON			1
+#define USB2_PRE_EMP_ON			2
+#define USB2_DE_EMP_ON_PRE_EMP_ON	3
+
+/* Per Port Half Bit Pre-emphasis */
+#define USB2_FULL_BIT_PRE_EMP	0
+#define USB2_HALF_BIT_PRE_EMP	1
+
+/* Per Port HS Preemphasis Bias */
+#define USB2_BIAS_0MV		0
+#define USB2_BIAS_11P25MV	1
+#define USB2_BIAS_16P9MV	2
+#define USB2_BIAS_28P15MV	3
+#define USB2_BIAS_39P35MV	5
+#define USB2_BIAS_45MV		6
+#define USB2_BIAS_56P3MV	7
+
 struct usb2_port_config {
 	uint8_t enable;
 	uint8_t ocpin;
@@ -28,6 +47,29 @@
 	uint8_t pre_emp_bit;
 };
 
+/* USB Overcurrent pins definition */
+enum {
+	OC0 = 0,
+	OC1,
+	OC2,
+	OC3,
+	OC4,
+	OC5,
+	OC6,
+	OC7,
+	OCMAX,
+	OC_SKIP = 0xff, /* Skip OC programming */
+};
+
+#define USB2_PORT_EMPTY { \
+	.enable        = 0, \
+	.ocpin         = OC_SKIP, \
+	.tx_bias       = USB2_BIAS_0MV, \
+	.tx_emp_enable = USB2_EMP_OFF, \
+	.pre_emp_bias  = USB2_BIAS_0MV, \
+	.pre_emp_bit   = USB2_HALF_BIT_PRE_EMP, \
+}
+
 struct usb3_port_config {
 	uint8_t enable;
 	uint8_t ocpin;
@@ -35,4 +77,11 @@
 	uint8_t tx_downscale_amp;
 };
 
+#define USB3_PORT_EMPTY { \
+	.enable           = 0, \
+	.ocpin            = OC_SKIP, \
+	.tx_de_emp        = 0x00, \
+	.tx_downscale_amp = 0x00, \
+}
+
 #endif

-- 
To view, visit https://review.coreboot.org/21339
To unsubscribe, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I42243950366d672e886158eb1934350f47b4ff1f
Gerrit-Change-Number: 21339
Gerrit-PatchSet: 1
Gerrit-Owner: Pratikkumar V Prajapati <pratikkumar.v.prajapati at intel.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20170902/c6cd0eb9/attachment-0001.html>


More information about the coreboot-gerrit mailing list