Re: [PATCH 2/2] drm/i915/vlv_dsi: Control panel and backlight enable GPIOs on BYT

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 02 Dec 2019, Linus Walleij <linus.walleij@xxxxxxxxxx> wrote:
> Hi Hans,
>
> thank you for your patch!
>
> On Fri, Nov 29, 2019 at 7:58 PM Hans de Goede <hdegoede@xxxxxxxxxx> wrote:
>
>> -       /* GPIO Desc for CRC based Panel control */
>> +       /* GPIO Desc for panel and backlight control */
>>         struct gpio_desc *gpio_panel;
>> +       struct gpio_desc *gpio_backlight;
>
> I think what happens here is that you reimplement
> drivers/video/backlight/gpio_backlight.c
>
> The existing power control GPIO also reimplements
> drivers/regulator/fixed.c in a sense but I am under the
> impression that x86 in general and ACPI in particular
> has a problem with the regulator subsystem so I am
> uncertain about that one.
>
> When I look at the code I get more confused because
> nominally panels should have their own drivers in
> drivers/gpu/drm/panel/* especially DSI panels, and the
> panels control their own GPIOs or regulators for power
> and backlight.
>
> I was under the impression that Heikki's and Dmitry's
> recent additions to software nodes would make it
> possible to actually spawn devices like the GPIO backlight
> and/or fixed regulator and put references to them so
> that the drivers can pick them up from the respective
> frameworks and manage them?
>
> Maybe I misunderstood things here though, I am a bit
> under the impression that elder DRM drivers are
> considered "elder gods" and do not need to use separate
> panel drivers, backlight abstraction etc, and in that
> case just go ahead, I guess.
>
> But I suspect some separation
> would help the day the i915 driver wants to reuse some
> really complex DSI panel from drivers/gpu/drm/panel/*
> though.

Sadly I don't think that's going to happen, though.

For i915 the panels are described by VBT, or Video BIOS Tables. We don't
really know the make or model of the panels, we just get the timings and
sequences etc. from there. There's no info to probe a separate panel
driver. So we just have a "generic" DSI driver that's part of i915 which
uses the data from the VBT to drive all the possible panels.

We do use some of the drm DSI framework as a library to abstract things
a bit better, but that's about it.

The sequences should include details about GPIOs to toggle as well, so
in that sense I feel like the gpio calls should be bolted there.

BR,
Jani.


-- 
Jani Nikula, Intel Open Source Graphics Center



[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux