linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tomi Valkeinen <tomi.valkeinen@ti.com>
To: linux-fbdev@vger.kernel.org
Subject: Re: [PATCH] lcd: Provide dummy functions if CONFIG_LCD_CLASS_DEVICE is not set
Date: Thu, 13 Mar 2014 09:04:34 +0000	[thread overview]
Message-ID: <532174A2.2030102@ti.com> (raw)
In-Reply-To: <1394695879-22845-1-git-send-email-shc_work@mail.ru>

[-- Attachment #1: Type: text/plain, Size: 1975 bytes --]

On 13/03/14 10:48, Alexander Shiyan wrote:
> Четверг, 13 марта 2014, 10:23 +02:00 от Tomi Valkeinen <tomi.valkeinen@ti.com>:
>> On 13/03/14 09:31, Alexander Shiyan wrote:
>>> Provide dummy functions for LCD register()/unregister() if
>>> CONFIG_LCD_CLASS_DEVICE is not set.
>>
>> Hmm, why do you want to do that? If a driver needs the LCD class, it
>> should depend on or select it.
> 
> I inspect my recent changes for the imxfb driver.
> I use the LCD class for power management and contrast, nevertheless,
> if it lack in the kernel this leads to an error.

So is the CONFIG_LCD_CLASS_DEVICE optional for imxfb? It works fine with
or without the LCD class support? Is there some reason to run it without
LCD class support?

> Yes, we can choose the LCD_CLASS_DEVICE symbol for the imxfb driver,
> but at the same time we must choose BACKLIGHT_LCD_SUPPORT.
> I do not think it's a good way.

Why not?

> In any case, I would like to revise the patch to use NULL as a result
> if there is no support LCD_CLASS_DEVICE in the kernel.

Why do you want to run imxfb without LCD_CLASS_DEVICE? Isn't it simpler
to just depend on it?

> Additionally, I have a plan to convert "menuconfig" entry for
> BACKLIGHT_LCD_SUPPORT to the "menu".

Hmm. That does make sense, as I don't see BACKLIGHT_LCD_SUPPORT
affecting anything, except enabling the BL & LCD Kconfig menu.

However, many of the items in BL & LCD menu have, for some reason,
"default y" or "default m". So if you make BACKLIGHT_LCD_SUPPORT a menu,
it means all those subitems are always enabled. So there definitely will
be a side effect to that change.

I guess there's legacy reasons why many of the items are enabled by
default. It would make sense to me to have BACKLIGHT_LCD_SUPPORT as a
menu, as you suggest, and having all the subitems disabled by default.
But again, that would change the current behavior, which may or may not
cause issues.

 Tomi



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 901 bytes --]

      parent reply	other threads:[~2014-03-13  9:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-13  7:31 [PATCH] lcd: Provide dummy functions if CONFIG_LCD_CLASS_DEVICE is not set Alexander Shiyan
2014-03-13  8:23 ` Tomi Valkeinen
2014-03-13  9:04 ` Tomi Valkeinen [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=532174A2.2030102@ti.com \
    --to=tomi.valkeinen@ti.com \
    --cc=linux-fbdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).