Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 33771
b: refs/heads/master
c: a930363
h: refs/heads/master
i:
  33769: 8b7f79f
  33767: f5a1de8
v: v3
  • Loading branch information
Benjamin Herrenschmidt authored and Linus Torvalds committed Sep 1, 2006
1 parent 53b66fe commit 182ed7c
Show file tree
Hide file tree
Showing 7 changed files with 45 additions and 40 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: 4cfb04a9d3d6865d932d02616b27b89d3a634026
refs/heads/master: a930363881c225fb52824145d1ba8f1a8c447dd8
4 changes: 2 additions & 2 deletions trunk/drivers/macintosh/via-pmu-backlight.c
Original file line number Diff line number Diff line change
Expand Up @@ -167,11 +167,11 @@ void __init pmu_backlight_init()
pmu_backlight_data.max_brightness / 15);
}

up(&bd->sem);
down(&bd->sem);
bd->props->brightness = level;
bd->props->power = FB_BLANK_UNBLANK;
bd->props->update_status(bd);
down(&bd->sem);
up(&bd->sem);

mutex_lock(&pmac_backlight_mutex);
if (!pmac_backlight)
Expand Down
19 changes: 10 additions & 9 deletions trunk/drivers/video/aty/aty128fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1800,14 +1800,15 @@ static struct backlight_properties aty128_bl_data = {

static void aty128_bl_set_power(struct fb_info *info, int power)
{
if (info->bl_dev == NULL)
return;

mutex_lock(&info->bl_mutex);
up(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__aty128_bl_update_status(info->bl_dev);
down(&info->bl_dev->sem);

if (info->bl_dev) {
down(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__aty128_bl_update_status(info->bl_dev);
up(&info->bl_dev->sem);
}

mutex_unlock(&info->bl_mutex);
}

Expand Down Expand Up @@ -1842,11 +1843,11 @@ static void aty128_bl_init(struct aty128fb_par *par)
219 * FB_BACKLIGHT_MAX / MAX_LEVEL);
mutex_unlock(&info->bl_mutex);

up(&bd->sem);
down(&bd->sem);
bd->props->brightness = aty128_bl_data.max_brightness;
bd->props->power = FB_BLANK_UNBLANK;
bd->props->update_status(bd);
down(&bd->sem);
up(&bd->sem);

#ifdef CONFIG_PMAC_BACKLIGHT
mutex_lock(&pmac_backlight_mutex);
Expand Down
19 changes: 10 additions & 9 deletions trunk/drivers/video/aty/atyfb_base.c
Original file line number Diff line number Diff line change
Expand Up @@ -2199,14 +2199,15 @@ static struct backlight_properties aty_bl_data = {

static void aty_bl_set_power(struct fb_info *info, int power)
{
if (info->bl_dev == NULL)
return;

mutex_lock(&info->bl_mutex);
up(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__aty_bl_update_status(info->bl_dev);
down(&info->bl_dev->sem);

if (info->bl_dev) {
down(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__aty_bl_update_status(info->bl_dev);
up(&info->bl_dev->sem);
}

mutex_unlock(&info->bl_mutex);
}

Expand Down Expand Up @@ -2237,11 +2238,11 @@ static void aty_bl_init(struct atyfb_par *par)
0xFF * FB_BACKLIGHT_MAX / MAX_LEVEL);
mutex_unlock(&info->bl_mutex);

up(&bd->sem);
down(&bd->sem);
bd->props->brightness = aty_bl_data.max_brightness;
bd->props->power = FB_BLANK_UNBLANK;
bd->props->update_status(bd);
down(&bd->sem);
up(&bd->sem);

#ifdef CONFIG_PMAC_BACKLIGHT
mutex_lock(&pmac_backlight_mutex);
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/video/aty/radeon_backlight.c
Original file line number Diff line number Diff line change
Expand Up @@ -195,11 +195,11 @@ void radeonfb_bl_init(struct radeonfb_info *rinfo)
217 * FB_BACKLIGHT_MAX / MAX_RADEON_LEVEL);
mutex_unlock(&rinfo->info->bl_mutex);

up(&bd->sem);
down(&bd->sem);
bd->props->brightness = radeon_bl_data.max_brightness;
bd->props->power = FB_BLANK_UNBLANK;
bd->props->update_status(bd);
down(&bd->sem);
up(&bd->sem);

#ifdef CONFIG_PMAC_BACKLIGHT
mutex_lock(&pmac_backlight_mutex);
Expand Down
18 changes: 10 additions & 8 deletions trunk/drivers/video/nvidia/nv_backlight.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,15 @@ static struct backlight_properties nvidia_bl_data = {

void nvidia_bl_set_power(struct fb_info *info, int power)
{
if (info->bl_dev == NULL)
return;
mutex_lock(&info->bl_mutex);
up(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__nvidia_bl_update_status(info->bl_dev);
down(&info->bl_dev->sem);

if (info->bl_dev) {
down(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__nvidia_bl_update_status(info->bl_dev);
up(&info->bl_dev->sem);
}

mutex_unlock(&info->bl_mutex);
}

Expand Down Expand Up @@ -153,11 +155,11 @@ void nvidia_bl_init(struct nvidia_par *par)
0x534 * FB_BACKLIGHT_MAX / MAX_LEVEL);
mutex_unlock(&info->bl_mutex);

up(&bd->sem);
down(&bd->sem);
bd->props->brightness = nvidia_bl_data.max_brightness;
bd->props->power = FB_BLANK_UNBLANK;
bd->props->update_status(bd);
down(&bd->sem);
up(&bd->sem);

#ifdef CONFIG_PMAC_BACKLIGHT
mutex_lock(&pmac_backlight_mutex);
Expand Down
19 changes: 10 additions & 9 deletions trunk/drivers/video/riva/fbdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -354,14 +354,15 @@ static struct backlight_properties riva_bl_data = {

static void riva_bl_set_power(struct fb_info *info, int power)
{
if (info->bl_dev == NULL)
return;

mutex_lock(&info->bl_mutex);
up(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__riva_bl_update_status(info->bl_dev);
down(&info->bl_dev->sem);

if (info->bl_dev) {
down(&info->bl_dev->sem);
info->bl_dev->props->power = power;
__riva_bl_update_status(info->bl_dev);
up(&info->bl_dev->sem);
}

mutex_unlock(&info->bl_mutex);
}

Expand Down Expand Up @@ -396,11 +397,11 @@ static void riva_bl_init(struct riva_par *par)
0x534 * FB_BACKLIGHT_MAX / MAX_LEVEL);
mutex_unlock(&info->bl_mutex);

up(&bd->sem);
down(&bd->sem);
bd->props->brightness = riva_bl_data.max_brightness;
bd->props->power = FB_BLANK_UNBLANK;
bd->props->update_status(bd);
down(&bd->sem);
up(&bd->sem);

#ifdef CONFIG_PMAC_BACKLIGHT
mutex_lock(&pmac_backlight_mutex);
Expand Down

0 comments on commit 182ed7c

Please sign in to comment.