Skip to content

Commit

Permalink
staging: gma500: Resync the patch queue with GregKH's space cleanup.
Browse files Browse the repository at this point in the history
Remove all sorts of bits we can get rid of. We are now a very simple KMS
driver relying on the stolen memory for our framebuffer base (which is for
the moment hardcoded).

To support multiple frame buffers and some accel bits we will need some kind
of memory allocator, possibly a minimal use of GEM.

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Alan Cox authored and Greg Kroah-Hartman committed Mar 7, 2011
1 parent 2145cff commit 487e873
Show file tree
Hide file tree
Showing 9 changed files with 365 additions and 772 deletions.
10 changes: 6 additions & 4 deletions drivers/staging/gma500/psb_bl.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* psb backlight using HAL
* psb backlight interface
*
* Copyright (c) 2009, Intel Corporation.
*
Expand Down Expand Up @@ -73,6 +73,8 @@ int psb_get_brightness(struct backlight_device *bd)
DRM_DEBUG_DRIVER("brightness = 0x%x\n", psb_brightness);

/* return locally cached var instead of HW read (due to DPST etc.) */
/* FIXME: ideally return actual value in case firmware fiddled with
it */
return psb_brightness;
}

Expand All @@ -83,7 +85,7 @@ static const struct backlight_ops psb_ops = {

static int device_backlight_init(struct drm_device *dev)
{
unsigned long CoreClock;
unsigned long core_clock;
/* u32 bl_max_freq; */
/* unsigned long value; */
u16 bl_max_freq;
Expand All @@ -102,9 +104,9 @@ static int device_backlight_init(struct drm_device *dev)
blc_brightnesscmd = dev_priv->lvds_bl->brightnesscmd;
blc_type = dev_priv->lvds_bl->type;

CoreClock = dev_priv->core_freq;
core_clock = dev_priv->core_freq;

value = (CoreClock * MHz) / BLC_PWM_FREQ_CALC_CONSTANT;
value = (core_clock * MHz) / BLC_PWM_FREQ_CALC_CONSTANT;
value *= blc_pwm_precision_factor;
value /= bl_max_freq;
value /= blc_pwm_precision_factor;
Expand Down
Loading

0 comments on commit 487e873

Please sign in to comment.