Message ID | 728da6e11d34a39f717be07e246dcc4964b0fd51.1690542871.git.daniel@makrotopia.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:918b:0:b0:3e4:2afc:c1 with SMTP id s11csp434174vqg; Fri, 28 Jul 2023 06:27:40 -0700 (PDT) X-Google-Smtp-Source: APBJJlEx2m8FfQn9rB8nfWPVFtY3BVBki6TuKT85Gv/SDYnQgjYHSU5WSRYW9XtDvDcMEJruRFUo X-Received: by 2002:a05:6e02:1ca5:b0:348:b910:313d with SMTP id x5-20020a056e021ca500b00348b910313dmr3492645ill.14.1690550859936; Fri, 28 Jul 2023 06:27:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690550859; cv=none; d=google.com; s=arc-20160816; b=SASxMtFcwA+iu0PQsc8QzdXNvYYOylGspR9f365pyJOEKC8xAHFTIaMUAsI4mON/pT /9LZFwDH7fu1PYjvGc2hWdQcJF3KaY0iWNr+/Ke6GbhPbirmCLVCpXpxtIz9UtQ0esOS ZkERR94cwD9iGoAQjRcwE/EJ4er6D7U4T/alp4wkJIsgORc22DdwiDQ9CVCUrTn9jHWE D6KEaJDmXMWPP6xnz0Z3VDQrb3UHE/p3KSUWFZQZultfUnnNzT74onvp4hKOJkfYeajt WJT70YkV2sCcVjqb2WMCLo87VqUDK07Q1VUB6OmJvQL3jBxbnV1HxgcVeGju0QqOxneL gFCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-disposition:mime-version:message-id :subject:to:from:date; bh=Q+IKxVOnN5iNmEaAVUcqXnDTnmBHpXXICSNDsx/H3DM=; fh=ZqLowDVvVpVxcrlw7MM/IM9y2WQ53COJXAUeTF8s64E=; b=s61yADlOx9s8SaLZ79BT+dBIVIJ4qkGu+xngcfdsXN7M36pU2ZO0BhNLq2PGLx8xR4 29qghwFY+fz7JkeSsY8Xd6E5qdpl2cH9EqGTy2axmmgsNPYgRay2Xqo1TmFvg2WChbUe HPUBtqpJFlgq/BFBGRZ6n4UxQxdrxHfaHamsw/Q2qTlT1DjEIA/aVaMNi0LTBt572mzP V8O58ZcHVdLvQc9ydufVXZluD4HEx/Kz6ukHvQJZhCdfLGp8zOI5YtJieHoVdcmgl1qz ElIr9+Mm0+reNFvgskhtkhKwPYSClsvMnhATrOMRGN3jXKrlJMWHVDCG3Bauh3EIMhKc FvEQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b2-20020a17090a9bc200b0024753ec4dccsi3228773pjw.124.2023.07.28.06.27.24; Fri, 28 Jul 2023 06:27:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235543AbjG1Mba (ORCPT <rfc822;hanasaki@gmail.com> + 99 others); Fri, 28 Jul 2023 08:31:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47780 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235314AbjG1Mb2 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 28 Jul 2023 08:31:28 -0400 Received: from pidgin.makrotopia.org (pidgin.makrotopia.org [185.142.180.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C4FBB10FC; Fri, 28 Jul 2023 05:31:27 -0700 (PDT) Received: from local by pidgin.makrotopia.org with esmtpsa (TLS1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.96) (envelope-from <daniel@makrotopia.org>) id 1qPMck-0003Lx-2p; Fri, 28 Jul 2023 12:31:14 +0000 Date: Fri, 28 Jul 2023 13:30:58 +0100 From: Daniel Golle <daniel@makrotopia.org> To: Pavel Machek <pavel@ucw.cz>, Lee Jones <lee@kernel.org>, Daniel Golle <daniel@makrotopia.org>, Johannes Berg <johannes.berg@intel.com>, Andrew Morton <akpm@linux-foundation.org>, Richard Purdie <rpurdie@linux.intel.com>, linux-leds@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] led: trig: timer: stop offloading on deactivation Message-ID: <728da6e11d34a39f717be07e246dcc4964b0fd51.1690542871.git.daniel@makrotopia.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1772671058756265355 X-GMAIL-MSGID: 1772671058756265355 |
Series |
led: trig: timer: stop offloading on deactivation
|
|
Commit Message
Daniel Golle
July 28, 2023, 12:30 p.m. UTC
Stop hardware blinking when switching from 'timer' to another trigger.
Fixes: 5ada28bf7675 ("led-class: always implement blinking")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
---
drivers/leds/trigger/ledtrig-timer.c | 2 ++
1 file changed, 2 insertions(+)
Comments
On Fri 2023-07-28 13:30:58, Daniel Golle wrote: > Stop hardware blinking when switching from 'timer' to another trigger. > > Fixes: 5ada28bf7675 ("led-class: always implement blinking") > Signed-off-by: Daniel Golle <daniel@makrotopia.org> ACK. BR, Pavel
On Fri, 28 Jul 2023, Pavel Machek wrote: > On Fri 2023-07-28 13:30:58, Daniel Golle wrote: > > Stop hardware blinking when switching from 'timer' to another trigger. > > > > Fixes: 5ada28bf7675 ("led-class: always implement blinking") > > Signed-off-by: Daniel Golle <daniel@makrotopia.org> > > ACK. Could I have that in full please, such that b4 can pick it up?
Hi Daniel, kernel test robot noticed the following build warnings: [auto build test WARNING on lee-leds/for-leds-next] [also build test WARNING on wireless-next/main wireless/main linus/master pavel-leds/for-next v6.5-rc3 next-20230728] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Daniel-Golle/led-trig-timer-stop-offloading-on-deactivation/20230728-203243 base: https://git.kernel.org/pub/scm/linux/kernel/git/lee/leds.git for-leds-next patch link: https://lore.kernel.org/r/728da6e11d34a39f717be07e246dcc4964b0fd51.1690542871.git.daniel%40makrotopia.org patch subject: [PATCH] led: trig: timer: stop offloading on deactivation config: mips-randconfig-r093-20230728 (https://download.01.org/0day-ci/archive/20230729/202307290641.SUCRTRMI-lkp@intel.com/config) compiler: mips-linux-gcc (GCC) 12.3.0 reproduce: (https://download.01.org/0day-ci/archive/20230729/202307290641.SUCRTRMI-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202307290641.SUCRTRMI-lkp@intel.com/ sparse warnings: (new ones prefixed by >>) >> drivers/leds/trigger/ledtrig-timer.c:129:47: sparse: sparse: Using plain integer as NULL pointer drivers/leds/trigger/ledtrig-timer.c:129:50: sparse: sparse: Using plain integer as NULL pointer vim +129 drivers/leds/trigger/ledtrig-timer.c 123 124 static void timer_trig_deactivate(struct led_classdev *led_cdev) 125 { 126 /* Stop blinking */ 127 led_set_brightness(led_cdev, LED_OFF); 128 if (led_cdev->blink_set) > 129 led_cdev->blink_set(led_cdev, 0, 0); 130 } 131
diff --git a/drivers/leds/trigger/ledtrig-timer.c b/drivers/leds/trigger/ledtrig-timer.c index b4688d1d9d2b2..fb6b207b052b8 100644 --- a/drivers/leds/trigger/ledtrig-timer.c +++ b/drivers/leds/trigger/ledtrig-timer.c @@ -125,6 +125,8 @@ static void timer_trig_deactivate(struct led_classdev *led_cdev) { /* Stop blinking */ led_set_brightness(led_cdev, LED_OFF); + if (led_cdev->blink_set) + led_cdev->blink_set(led_cdev, 0, 0); } static struct led_trigger timer_led_trigger = {