Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 260065
b: refs/heads/master
c: 83c871e
h: refs/heads/master
i:
  260063: 558bc70
v: v3
  • Loading branch information
Alan Cox authored and Greg Kroah-Hartman committed Jul 15, 2011
1 parent bef0320 commit c1ec242
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 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: f642062fc7a6bebdd857408e7a9f678bfd2e4004
refs/heads/master: 83c871ee2b60619d74d03eaf6f75a7d9c3cb0e45
12 changes: 5 additions & 7 deletions trunk/drivers/staging/gma500/mrst_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -157,14 +157,12 @@ static int device_backlight_init(struct drm_device *dev)
value /= bl_max_freq;
value /= blc_pwm_precision_factor;

if (value > (unsigned long long)MRST_BLC_MAX_PWM_REG_FREQ)
return -ERANGE;

if (gma_power_begin(dev, false)) {
if (value > (unsigned long long)MRST_BLC_MAX_PWM_REG_FREQ)
return -ERANGE;
else {
REG_WRITE(BLC_PWM_CTL2,
(0x80000000 | REG_READ(BLC_PWM_CTL2)));
REG_WRITE(BLC_PWM_CTL, value | (value << 16));
}
REG_WRITE(BLC_PWM_CTL2, (0x80000000 | REG_READ(BLC_PWM_CTL2)));
REG_WRITE(BLC_PWM_CTL, value | (value << 16));
gma_power_end(dev);
}
return 0;
Expand Down

0 comments on commit c1ec242

Please sign in to comment.