From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7555FC43461 for ; Fri, 16 Apr 2021 15:39:29 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4C65461222 for ; Fri, 16 Apr 2021 15:39:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343832AbhDPPjx (ORCPT ); Fri, 16 Apr 2021 11:39:53 -0400 Received: from mail.kernel.org ([198.145.29.99]:52402 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236141AbhDPPjv (ORCPT ); Fri, 16 Apr 2021 11:39:51 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id F040561222; Fri, 16 Apr 2021 15:39:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1618587567; bh=ysgpDz+BTTXYH0RnwQoQvpA6pJla49qmtt338wMhnUQ=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=sA/oNszQk49bAP/+H3BmykaTAQenh0iw/Gpf7uZ+GwDgztxBf05slIkJ18rtE3vgt 6QAX+ltavm9lwirWjcgh+xIT+8pAJF2SmfSKB3ljq+JiNQFSUUiYMRQ+i4yM9C9gxd j3phuIcFMg2fM8hlack0KOlcPk1Fzlx3ZzuSd0FHbGz3rBtMVfgHCwJM9kij8xZkaj w3hZ74yumnv50xxRMCuJfBdxa3mJmGkWGbAK/83+9CyOGbmJDOd5kr6cwNXQwCRk09 kLMQIvZlBpeA5eH5Uq5CWKBvRRjVkjpbGo7ub8jYpasd2QZ800U5T+kQM8XziNmiVA KGLAmXuUUfXLw== Received: by mail-ej1-f46.google.com with SMTP id w23so26962029ejb.9; Fri, 16 Apr 2021 08:39:26 -0700 (PDT) X-Gm-Message-State: AOAM531eCdSgwLYf3jaXNtVYynLhC/Kq37Ha//da4IFdtBVKyk2lUhWD jyOMojJGLZiL4Y/Y7sfZyiC2xjhkd5dpCYPgpA== X-Google-Smtp-Source: ABdhPJzFqy5Zhk2BT4rI/0OIAYEXZHtqzMK+r4zLrmuDcRgl1XfMcGCbqbDrhsyfDhzhIy4/n6neYfSAgSfwWszGhb8= X-Received: by 2002:a17:906:7806:: with SMTP id u6mr8390324ejm.130.1618587565661; Fri, 16 Apr 2021 08:39:25 -0700 (PDT) MIME-Version: 1.0 References: <20210412132745.76609-1-clemens.gruber@pqgruber.com> <20210412132745.76609-4-clemens.gruber@pqgruber.com> In-Reply-To: From: Rob Herring Date: Fri, 16 Apr 2021 10:39:12 -0500 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v8 4/8] dt-bindings: pwm: Support new PWM_USAGE_POWER flag To: Thierry Reding Cc: Clemens Gruber , Linux PWM List , Sven Van Asbroeck , =?UTF-8?Q?Uwe_Kleine=2DK=C3=B6nig?= , devicetree@vger.kernel.org, "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Apr 16, 2021 at 8:54 AM Thierry Reding wrote: > > On Mon, Apr 12, 2021 at 03:27:41PM +0200, Clemens Gruber wrote: > > Add the flag and corresponding documentation for PWM_USAGE_POWER. > > > > Cc: Rob Herring > > Signed-off-by: Clemens Gruber > > --- > > Documentation/devicetree/bindings/pwm/pwm.txt | 3 +++ > > include/dt-bindings/pwm/pwm.h | 1 + > > 2 files changed, 4 insertions(+) > > Rob, what are your thoughts on this? I've been thinking about this some > more and I'm having second thoughts about putting this into device tree > because it doesn't actually describe a property of the PWM hardware but > rather a use-case specific hint. It's a bit of a gray area because this > is just part of the PWM specifier which already has use-case specific > "configuration", such as the period and the polarity. I'm pretty neutral. My main hesitation from what I've followed is 'power' seems a bit indirect. A PWM signal doesn't have a 'power' any more than a GPIO signal does. > Perhaps a better place for this is within the PWM API? We could add the > same information into struct pwm_state and then consumers that don't > care about specifics of the signal (such as pwm-backlight) can set that > flag when they request a state to be applied. Yeah, seems like this is fairly well tied to the class of consumer. Rob