diff options
author | Dave Jones <davej@redhat.com> | 2006-12-12 23:41:41 +0100 |
---|---|---|
committer | Dave Jones <davej@redhat.com> | 2006-12-12 23:41:41 +0100 |
commit | c4366889dda8110247be59ca41fddb82951a8c26 (patch) | |
tree | 705c1a996bed8fd48ce94ff33ec9fd00f9b94875 /drivers/video/aty/aty128fb.c | |
parent | [CPUFREQ] Longhaul - Add support for CN400 (diff) | |
parent | [PATCH] remove config ordering/dependency between ucb1400-ts and sound subsystem (diff) | |
download | linux-c4366889dda8110247be59ca41fddb82951a8c26.tar.xz linux-c4366889dda8110247be59ca41fddb82951a8c26.zip |
Merge ../linus
Conflicts:
drivers/cpufreq/cpufreq.c
Diffstat (limited to 'drivers/video/aty/aty128fb.c')
-rw-r--r-- | drivers/video/aty/aty128fb.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/video/aty/aty128fb.c b/drivers/video/aty/aty128fb.c index 276a21530b95..3feddf89d100 100644 --- a/drivers/video/aty/aty128fb.c +++ b/drivers/video/aty/aty128fb.c @@ -1333,6 +1333,8 @@ static int aty128_var_to_pll(u32 period_in_ps, struct aty128_pll *pll, if (vclk * 12 < c.ppll_min) vclk = c.ppll_min/12; + pll->post_divider = -1; + /* now, find an acceptable divider */ for (i = 0; i < sizeof(post_dividers); i++) { output_freq = post_dividers[i] * vclk; @@ -1342,6 +1344,9 @@ static int aty128_var_to_pll(u32 period_in_ps, struct aty128_pll *pll, } } + if (pll->post_divider < 0) + return -EINVAL; + /* calculate feedback divider */ n = c.ref_divider * output_freq; d = c.ref_clk; |