diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2012-01-04 08:20:47 +0100 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2012-02-01 06:27:43 +0100 |
commit | a9d993882008a1ae2c953064f0c2ca7e604b1333 (patch) | |
tree | 6e17ed7bc6158d103fbe558b5ec84c292021d9f9 /drivers/gpu/drm/nouveau/nv50_pm.c | |
parent | drm/nouveau/gem: fix fence_sync race / oops (diff) | |
download | linux-a9d993882008a1ae2c953064f0c2ca7e604b1333.tar.xz linux-a9d993882008a1ae2c953064f0c2ca7e604b1333.zip |
drm/nv50/pm: signedness bug in nv50_pm_clocks_pre()
calc_mclk() returns zero on success and negative on failure but clk is
a u32.
v2: Martin Peres:
- clk should be an int, not a u32
Signed-off-by: Martin Peres <martin.peres@labri.fr>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to '')
-rw-r--r-- | drivers/gpu/drm/nouveau/nv50_pm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/nouveau/nv50_pm.c b/drivers/gpu/drm/nouveau/nv50_pm.c index 03937212e9d8..ec5481dfcd82 100644 --- a/drivers/gpu/drm/nouveau/nv50_pm.c +++ b/drivers/gpu/drm/nouveau/nv50_pm.c @@ -495,9 +495,9 @@ nv50_pm_clocks_pre(struct drm_device *dev, struct nouveau_pm_level *perflvl) struct drm_nouveau_private *dev_priv = dev->dev_private; struct nv50_pm_state *info; struct pll_lims pll; - int ret = -EINVAL; + int clk, ret = -EINVAL; int N, M, P1, P2; - u32 clk, out; + u32 out; if (dev_priv->chipset == 0xaa || dev_priv->chipset == 0xac) |