lkml.org 
[lkml]   [2021]   [Jan]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    Date
    SubjectRe: [PATCH v5 2/7] pwm: pca9685: Support hardware readout
    Hi Clemens,

    On Fri, Jan 29, 2021 at 4:24 PM Sven Van Asbroeck <thesven73@gmail.com> wrote:
    >
    > LEN_ON = 409, LED_OFF = 1228 and
    > LED_ON = 419, LED_OFF = 1238
    > produce the same result. you can't see the difference between the two
    > when scoping the channel. there are probably more ways to do this,
    > some might surprise us. It's a tricky chip.

    Please ignore this example, it's bogus. In my defence, it's a Friday
    afternoon here :)

    But consider the following: imagine the bootloader has enabled a few
    pwm channels, and the driver's .probe() has left them on/unchanged.
    Then the user enables another pwm channel, and tries to change the
    period/prescaler. How would pca9685_may_change_prescaler() know
    if changing the prescaler is allowed?

    And the following: imagine the bootloader has enabled a few
    pwm channels, and the driver's .probe() has left them on/unchanged.
    After .probe(), the runtime_pm will immediately put the chip to sleep,
    because it's unaware that some channels are alive.

    I'm sure I'm overlooking a few complications here. probe not changing
    the existing configuration, will add a lot of complexity to the driver.
    I'm not saying this is necessarily bad, just a tradeoff. Or, a management
    decision.

    Sven

    \
     
     \ /
      Last update: 2021-01-29 23:20    [W:2.495 / U:0.032 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site