From patchwork Mon Sep 18 14:07:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Marek_Beh=C3=BAn?= X-Patchwork-Id: 724540 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 E49A1CD37B0 for ; Mon, 18 Sep 2023 16:41:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229436AbjIRQlb (ORCPT ); Mon, 18 Sep 2023 12:41:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40966 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229905AbjIRQlA (ORCPT ); Mon, 18 Sep 2023 12:41:00 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 713AA30C3 for ; Mon, 18 Sep 2023 09:37:32 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E8341C3277B; Mon, 18 Sep 2023 14:07:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1695046049; bh=sIT9k1TK/Df2T/mR4SCR2OKfZ0n5lS5Q9qwaQdUZ+NU=; h=From:To:Cc:Subject:Date:From; b=nX15XlwZh/VvT/QyzTlaZz/f8egJCWLh7rm6e4nRCj63iOmqzvJxditVgHGGcC1Lt DuGFhrd+L9JQvezQzdDfCq5YJxH/Ui47/YI3j0jQionnOV0OcP4fd0o5AjKxLnb1rJ t4wnv6wStx5Vh34R7ewwO6n5iw22QEssFGs+Nysq6KEzG+VICiyvmd+dwxyIZYDrkO +RtUscwb0tdcCzl2PkNSA0D7vKrA8LRPs5/jal1AB4Iwc1sjnW9hPsaCzMmzLSX4pv LJbP25QjI7MMp2eTLF2VB7HW0HOM1ud+giSB2OwQ0nm+8sJCAccW8btoDQ1vwZIm3M Nrzl2xTbxiZNg== From: =?utf-8?q?Marek_Beh=C3=BAn?= To: Pavel Machek , Lee Jones , linux-leds@vger.kernel.org, Da Xue Cc: =?utf-8?q?Marek_Beh=C3=BAn?= Subject: [PATCH] leds: Drop BUG_ON check for LED_COLOR_ID_MULTI Date: Mon, 18 Sep 2023 16:07:24 +0200 Message-ID: <20230918140724.18634-1-kabel@kernel.org> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-leds@vger.kernel.org Commit c3f853184bed ("leds: Fix BUG_ON check for LED_COLOR_ID_MULTI that is always false") fixed a no-op BUG_ON. This turned out to cause a regression, since some in-tree device-tree files already use LED_COLOR_ID_MULTI. Drop the BUG_ON altogether. Fixes: c3f853184bed ("leds: Fix BUG_ON check for LED_COLOR_ID_MULTI that is always false") Reported-by: Da Xue Closes: https://lore.kernel.org/linux-leds/ZQLelWcNjjp2xndY@duo.ucw.cz/T/ Signed-off-by: Marek BehĂșn --- drivers/leds/led-core.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/drivers/leds/led-core.c b/drivers/leds/led-core.c index 04f9ea675f2c..214ed81eb0e9 100644 --- a/drivers/leds/led-core.c +++ b/drivers/leds/led-core.c @@ -479,10 +479,6 @@ int led_compose_name(struct device *dev, struct led_init_data *init_data, led_parse_fwnode_props(dev, fwnode, &props); - /* We want to label LEDs that can produce full range of colors - * as RGB, not multicolor */ - BUG_ON(props.color == LED_COLOR_ID_MULTI); - if (props.label) { /* * If init_data.devicename is NULL, then it indicates that