xf86-video-intel: src/i830_display.c src/scripts/clock.5c src/scripts/clock-graph.5c

Keith Packard keithp at kemper.freedesktop.org
Tue Nov 13 22:28:44 PST 2007


 src/i830_display.c         |   18 +++++++++++++++---
 src/scripts/clock-graph.5c |    6 +++---
 src/scripts/clock.5c       |    4 ++--
 3 files changed, 20 insertions(+), 8 deletions(-)

New commits:
commit 26194e19e1c80615697016e25640d4c8c244353f
Author: Keith Packard <keithp at koto.keithp.com>
Date:   Tue Nov 13 22:26:40 2007 -0800

    Review PLL spreadsheet and update register ranges.
    
    The PLL spreadsheet makes the precise register ranges allowed for each mode
    quite clear, and shows a few inaccuracies in the b-spec. In particular, the
    N register value may range from 1 to 6 instead of 3 to 8. This should close
    the gap we've seen in the reachable frequencies.

diff --git a/src/i830_display.c b/src/i830_display.c
index d988b86..ea10c8a 100644
--- a/src/i830_display.c
+++ b/src/i830_display.c
@@ -100,14 +100,26 @@ typedef struct {
 #define I9XX_DOT_MAX		 400000
 #define I9XX_VCO_MIN		1400000
 #define I9XX_VCO_MAX		2800000
-#define I9XX_N_MIN		      3
-#define I9XX_N_MAX		      8
+
+/* Haven't found any reason to go this fast, but newer chips support it */
+#define I96X_VCO_MAX		3200000
+
+/*
+ * These values are taken from the broadwater/crestline PLL spreadsheet.
+ * All of the defines here are for the programmed register value, not
+ * the 'counter' value (e.g. Ncounter = Nregister + 2)
+ */
+#define I9XX_N_MIN		      1
+#define I9XX_N_MAX		      6
 #define I9XX_M_MIN		     70
 #define I9XX_M_MAX		    120
+
+/* these two come from the calm1 macro */
 #define I9XX_M1_MIN		     10
-#define I9XX_M1_MAX		     20
+#define I9XX_M1_MAX		     22
 #define I9XX_M2_MIN		      5
 #define I9XX_M2_MAX		      9
+
 #define I9XX_P_SDVO_DAC_MIN	      5
 #define I9XX_P_SDVO_DAC_MAX	     80
 #define I9XX_P_LVDS_MIN		      7
diff --git a/src/scripts/clock-graph.5c b/src/scripts/clock-graph.5c
index e39e559..324febf 100644
--- a/src/scripts/clock-graph.5c
+++ b/src/scripts/clock-graph.5c
@@ -9,7 +9,7 @@ int max_vco = 2800000000;
 int min = 0xffffffff;
 int max = 0;
 
-int max_clocks = 1000;
+int max_clocks = 2000;
 int[4][max_clocks] clocks;
 int[4][max_clocks] vcos;
 int[4] clock_count = {0...};
@@ -35,9 +35,9 @@ void calc_p2(int p2i)
 		max_p = 80;
 	}
 
-	for (int m1 = 10; m1 <= 20; m1++) {
+	for (int m1 = 10; m1 <= 22; m1++) {
 		for (int m2 = 5; m2 <= 9; m2++) {
-			for (int n = 3; n <= 8; n++) {
+			for (int n = 1; n <= 5; n++) {
 				for (int p1 = 1; p1 <= 8; p1++) {
 					int ref = 96000000;
 					int m = 5 * (m1 + 2) + (m2 + 2);
diff --git a/src/scripts/clock.5c b/src/scripts/clock.5c
index 8ee9d90..c83c689 100644
--- a/src/scripts/clock.5c
+++ b/src/scripts/clock.5c
@@ -11,9 +11,9 @@ if (p2 == 7 || p2 == 14) {
 	max_p = 80;
 }
 
-for (int m1 = 10; m1 <= 20; m1++) {
+for (int m1 = 10; m1 <= 22; m1++) {
 	for (int m2 = 5; m2 <= 9; m2++) {
-		for (int n = 3; n <= 8; n++) {
+		for (int n = 1; n <= 6; n++) {
 			for (int p1 = 1; p1 <= 8; p1++) {
 				int ref = 96000000;
 				int m = 5 * (m1 + 2) + (m2 + 2);


More information about the xorg-commit mailing list