From nobody Wed Apr 8 10:18:55 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EAA80C04A95 for ; Tue, 25 Oct 2022 14:08:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232903AbiJYOIL (ORCPT ); Tue, 25 Oct 2022 10:08:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39514 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232625AbiJYOH2 (ORCPT ); Tue, 25 Oct 2022 10:07:28 -0400 Received: from andre.telenet-ops.be (andre.telenet-ops.be [IPv6:2a02:1800:120:4::f00:15]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BA57017A03A for ; Tue, 25 Oct 2022 07:03:49 -0700 (PDT) Received: from ramsan.of.borg ([IPv6:2a02:1810:ac12:ed10:9dd:efb4:9ae5:d7b4]) by andre.telenet-ops.be with bizsmtp id cE3m2800S1HY1Pb01E3mMj; Tue, 25 Oct 2022 16:03:47 +0200 Received: from rox.of.borg ([192.168.97.57]) by ramsan.of.borg with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.93) (envelope-from ) id 1onKWw-001R1Q-Cp; Tue, 25 Oct 2022 16:03:46 +0200 Received: from geert by rox.of.borg with local (Exim 4.93) (envelope-from ) id 1onKWv-00ERYC-NG; Tue, 25 Oct 2022 16:03:45 +0200 From: Geert Uytterhoeven To: Thierry Reding , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Cc: Biju Das , linux-pwm@vger.kernel.org, linux-kernel@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH] pwm: Add missing dummy for devm_pwmchip_add() Date: Tue, 25 Oct 2022 16:03:42 +0200 Message-Id: <12f2142991690d2b1d6890821f6e7779a4d4bdc0.1666706435.git.geert+renesas@glider.be> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" The PWM subsystem supports compile-testing if CONFIG_PWM is disabled. However, no dummy is provided for devm_pwmchip_add(), which may lead to build failures. Fixes: bcda91bf86c1ff76 ("pwm: Add a device-managed function to add PWM chi= ps") Signed-off-by: Geert Uytterhoeven --- include/linux/pwm.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/linux/pwm.h b/include/linux/pwm.h index d70c6e5a839d6902..bba492eea96c5552 100644 --- a/include/linux/pwm.h +++ b/include/linux/pwm.h @@ -478,6 +478,11 @@ static inline int pwmchip_remove(struct pwm_chip *chip) return -EINVAL; } =20 +static inline int devm_pwmchip_add(struct device *dev, struct pwm_chip *ch= ip) +{ + return -EINVAL; +} + static inline struct pwm_device *pwm_request_from_chip(struct pwm_chip *ch= ip, unsigned int index, const char *label) --=20 2.25.1