Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 361543
b: refs/heads/master
c: 260b3f1
h: refs/heads/master
i:
  361541: 329755d
  361539: d422c12
  361535: 79934ac
v: v3
  • Loading branch information
Julia Lemire authored and Dave Airlie committed Mar 21, 2013
1 parent 5fd639d commit 99d82ef
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 236f651bf79ab7d521bdacf4753ddd0764334980
refs/heads/master: 260b3f1291a75a580d22ce8bfb1499c617272716
10 changes: 5 additions & 5 deletions trunk/drivers/gpu/drm/mgag200/mgag200_mode.c
Original file line number Diff line number Diff line change
Expand Up @@ -382,19 +382,19 @@ static int mga_g200eh_set_plls(struct mga_device *mdev, long clock)
m = n = p = 0;
vcomax = 800000;
vcomin = 400000;
pllreffreq = 3333;
pllreffreq = 33333;

delta = 0xffffffff;
permitteddelta = clock * 5 / 1000;

for (testp = 16; testp > 0; testp--) {
for (testp = 16; testp > 0; testp >>= 1) {
if (clock * testp > vcomax)
continue;
if (clock * testp < vcomin)
continue;

for (testm = 1; testm < 33; testm++) {
for (testn = 1; testn < 257; testn++) {
for (testn = 17; testn < 257; testn++) {
computed = (pllreffreq * testn) /
(testm * testp);
if (computed > clock)
Expand All @@ -404,11 +404,11 @@ static int mga_g200eh_set_plls(struct mga_device *mdev, long clock)
if (tmpdelta < delta) {
delta = tmpdelta;
n = testn - 1;
m = (testm - 1) | ((n >> 1) & 0x80);
m = (testm - 1);
p = testp - 1;
}
if ((clock * testp) >= 600000)
p |= 80;
p |= 0x80;
}
}
}
Expand Down

0 comments on commit 99d82ef

Please sign in to comment.