diff mbox

drm/i915: inverted brightness quirk for HP 2000 Notebook

Message ID 1377711509-2211-1-git-send-email-rodrigo.vivi@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Rodrigo Vivi Aug. 28, 2013, 5:38 p.m. UTC
01.org forum: https://01.org/linuxgraphics/node/199

Slot:  00:02.0
Class: VGA compatible controller [0300]
Vendor:	   Intel Corporation [8086]
Device:	   2nd Generation Core Processor Family Integrated Graphics Controller [0106]
SVendor:   Hewlett-Packard Company [103c]
SDevice:   Device [1854]
Rev:	   09

Reported-by: Laurent Chardon <laurent.chardon@gmail.com>
Cc: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@gmail.com>
---
 drivers/gpu/drm/i915/intel_display.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Daniel Vetter Aug. 28, 2013, 6:12 p.m. UTC | #1
On Wed, Aug 28, 2013 at 7:38 PM, Rodrigo Vivi <rodrigo.vivi@gmail.com> wrote:
> 01.org forum: https://01.org/linuxgraphics/node/199
>
> Slot:  00:02.0
> Class: VGA compatible controller [0300]
> Vendor:    Intel Corporation [8086]
> Device:    2nd Generation Core Processor Family Integrated Graphics Controller [0106]
> SVendor:   Hewlett-Packard Company [103c]
> SDevice:   Device [1854]
> Rev:       09
>
> Reported-by: Laurent Chardon <laurent.chardon@gmail.com>
> Cc: Jani Nikula <jani.nikula@intel.com>
> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@gmail.com>

All the inverted brightness machines we've seen have been gen4 and
Acer/Packard Bell. I suspect there's something amiss in our backlight
handling and at least for current platforms I don't want to merge
quirks before we've reasonably proven that we really need them. Which
means someone should show that Windows has specific code for this HP
laptop first ...

One thing I remember is that there's a linearization table in the vbt
somewhere, maybe that does the trick. Or we simply race our driver
against something in the firmware and inverting the brightness here
cures that.
-Daniel
Jani Nikula Aug. 28, 2013, 6:23 p.m. UTC | #2
On Wed, 28 Aug 2013, Daniel Vetter <daniel@ffwll.ch> wrote:
> On Wed, Aug 28, 2013 at 7:38 PM, Rodrigo Vivi <rodrigo.vivi@gmail.com> wrote:
>> 01.org forum: https://01.org/linuxgraphics/node/199
>>
>> Slot:  00:02.0
>> Class: VGA compatible controller [0300]
>> Vendor:    Intel Corporation [8086]
>> Device:    2nd Generation Core Processor Family Integrated Graphics Controller [0106]
>> SVendor:   Hewlett-Packard Company [103c]
>> SDevice:   Device [1854]
>> Rev:       09
>>
>> Reported-by: Laurent Chardon <laurent.chardon@gmail.com>
>> Cc: Jani Nikula <jani.nikula@intel.com>
>> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@gmail.com>
>
> All the inverted brightness machines we've seen have been gen4 and
> Acer/Packard Bell. I suspect there's something amiss in our backlight
> handling and at least for current platforms I don't want to merge
> quirks before we've reasonably proven that we really need them. Which
> means someone should show that Windows has specific code for this HP
> laptop first ...

Agreed. I'd be wary of adding inverted backlight quirks for anything
other than gen4 Acers (or their other brands).

> One thing I remember is that there's a linearization table in the vbt
> somewhere, maybe that does the trick. Or we simply race our driver
> against something in the firmware and inverting the brightness here
> cures that.

If you get the reporter to dump the i915_opregion file from debugfs, I
could check the table.

Cheers,
Jani.



> -Daniel
> -- 
> Daniel Vetter
> Software Engineer, Intel Corporation
> +41 (0) 79 365 57 48 - http://blog.ffwll.ch
Rodrigo Vivi Aug. 28, 2013, 6:46 p.m. UTC | #3
Hi Laurent,

is it possible to get the i915_opregion from your debugfs?
probably under /sys/kernel/debug/dri/0/i915_opregion

Thanks,
Rodrigo.

On Wed, Aug 28, 2013 at 3:23 PM, Jani Nikula <jani.nikula@intel.com> wrote:
> On Wed, 28 Aug 2013, Daniel Vetter <daniel@ffwll.ch> wrote:
>> On Wed, Aug 28, 2013 at 7:38 PM, Rodrigo Vivi <rodrigo.vivi@gmail.com> wrote:
>>> 01.org forum: https://01.org/linuxgraphics/node/199
>>>
>>> Slot:  00:02.0
>>> Class: VGA compatible controller [0300]
>>> Vendor:    Intel Corporation [8086]
>>> Device:    2nd Generation Core Processor Family Integrated Graphics Controller [0106]
>>> SVendor:   Hewlett-Packard Company [103c]
>>> SDevice:   Device [1854]
>>> Rev:       09
>>>
>>> Reported-by: Laurent Chardon <laurent.chardon@gmail.com>
>>> Cc: Jani Nikula <jani.nikula@intel.com>
>>> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@gmail.com>
>>
>> All the inverted brightness machines we've seen have been gen4 and
>> Acer/Packard Bell. I suspect there's something amiss in our backlight
>> handling and at least for current platforms I don't want to merge
>> quirks before we've reasonably proven that we really need them. Which
>> means someone should show that Windows has specific code for this HP
>> laptop first ...
>
> Agreed. I'd be wary of adding inverted backlight quirks for anything
> other than gen4 Acers (or their other brands).
>
>> One thing I remember is that there's a linearization table in the vbt
>> somewhere, maybe that does the trick. Or we simply race our driver
>> against something in the firmware and inverting the brightness here
>> cures that.
>
> If you get the reporter to dump the i915_opregion file from debugfs, I
> could check the table.
>
> Cheers,
> Jani.
>
>
>
>> -Daniel
>> --
>> Daniel Vetter
>> Software Engineer, Intel Corporation
>> +41 (0) 79 365 57 48 - http://blog.ffwll.ch
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index cee9c0d..f1be63b 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -9975,6 +9975,9 @@  static struct intel_quirk intel_quirks[] = {
 	/* Acer Aspire 4736Z */
 	{ 0x2a42, 0x1025, 0x0260, quirk_invert_brightness },
 
+	/* HP 2000 Notebook */
+	{ 0x0106, 0x103c, 0x1854, quirk_invert_brightness },
+
 	/* Dell XPS13 HD Sandy Bridge */
 	{ 0x0116, 0x1028, 0x052e, quirk_no_pcm_pwm_enable },
 	/* Dell XPS13 HD and XPS13 FHD Ivy Bridge */