lkml.org 
[lkml]   [2012]   [Aug]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: awful kconfig help texts.
On 08/01/2012 02:46 PM, Steven Rostedt wrote:
> On Wed, 2012-08-01 at 12:56 +0200, Lars-Peter Clausen wrote:
>
>> You could do that by using a construct like below, but well...
>>
>> config HAS_PWM
>> bool
>>
>> config PWM
>> bool "PWM
>> depends on HAS_PWM
>>
>> config PWM_CAN_BUILD_DRIVER_X
>> defbool I2C
>> select HAS_PWM
>>
>> config PWM_DRIVER_X
>> tristate "PWM chip X support"
>> depends on PWM && PWM_CAN_BUILD_DRIVER_X
>>
>> config PWM_CAN_BUILD_DRIVER_Y
>> defbool ARCH_Y
>> select HAS_PWM
>>
>> config PWM_DRIVER_Y
>> tristate "PWM chip Y support"
>> depends on PWM && PWM_CAN_BUILD_DRIVER_Y
>
> What selects the 'PWM_CAN_BUILD_DRIVER_FOO'?
>

Its def_bool statement, which lists the prerequisites to build the driver.
E.g. for a I2C PWM expander I2S support, for a on-SoC PWM core support for
the SoC family, etc.. So it will be true if the driver can actually be built
and false otherwise. If one of the PWM_CAN_BUILD_DRIVER_FOO symbols is true
also HAS_PWM will be true and PWM becomes selectable.

But it seems to be a bid tedious to have these extra lines for each driver
and I guess it is not a PWM subsystem specific issue. There are other
subsystems where this probably applies as well, e.g. the MFD subsystem.
Also such a solution would rule out out-of-tree PWM driver modules, since it
is not possible to get CONFIG_PWM selected.

- Lars



\
 
 \ /
  Last update: 2012-08-01 15:41    [W:0.055 / U:1.032 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site