Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp2129604rwi; Sat, 15 Oct 2022 08:22:33 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4ish1o+k65W0whrMxmrfXJeC8gnXLhoytTkYRitzvpIOE69mIII0+uDypJwCufz6+Y0tiM X-Received: by 2002:a17:902:b089:b0:178:54cf:d692 with SMTP id p9-20020a170902b08900b0017854cfd692mr3266768plr.1.1665847352926; Sat, 15 Oct 2022 08:22:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665847352; cv=none; d=google.com; s=arc-20160816; b=Brb4ViSXTRb7n2Fsh+j3MVLa3ezmL/M+mrQvdxXDc2hic6ImMX+lzVLrblZskPnXMk Ygauc83C9uT0euvX0zpojBaXK43olyPR9YZMsRVd1TNf47NPf/R3SpAEG3ttfl+036Fr 7/sJCy/xHO6+RJMbka2VLd7u+kZ1aVTWgIPfdDdjZXx6cDsRQ+H6AIyeuV9ysqsdNBvm KzwlgqA6AfUTBjsRpdzcYocl+CGuRt9Wd8C9lhzPE9p9zi7NAQELLdc8YkgFWJ0RCfjt VPCXoRk83C58yCsupwDOKyFOdFELVQxOOVE5ZKMvxVqmguZOtC9HaCwFT3n/5mEMZE81 mZdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=JlSf0l9NyfcSLSG0+gfuA289BMwlKNxFIacZk+dZJAs=; b=AwStyk8xezBWh1ysBTdzDHxvBwo3QTp3aLeF4z0cHrhi1JhnME9RXj2UsuFRUVeHwu VpO04E3Bl7A6IV5545DnGEHrE9FhXkv1RYHh3cNcbqNrJCmejoxXYSzL9VxzZb0JFYGT Ds+7CuCnwbiUJ+L8XqgTGOSOpdd6G8sLMy464/axY61ZkVIwdol/4DsLG6alqjP5TyBM AhYouIam/NyIFH1AS45hKGPCo8ChRG67Qjt73uO7DvKf4O7E0YnfpsAywhtAUMrFMnlX I0wdW7H7MrnYjUaEWAlSItZus+nOeoADUeABxgnOXhTqgMAjlkEM6s7tT6sNcv9yZyft 7c6A== 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z5-20020aa79905000000b005638548d0a1si5940629pff.326.2022.10.15.08.22.19; Sat, 15 Oct 2022 08:22:32 -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 S229699AbiJOPMW (ORCPT + 99 others); Sat, 15 Oct 2022 11:12:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38850 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229780AbiJOPLq (ORCPT ); Sat, 15 Oct 2022 11:11:46 -0400 Received: from viti.kaiser.cx (viti.kaiser.cx [IPv6:2a01:238:43fe:e600:cd0c:bd4a:7a3:8e9f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7956443AD3 for ; Sat, 15 Oct 2022 08:11:41 -0700 (PDT) Received: from ipservice-092-217-066-135.092.217.pools.vodafone-ip.de ([92.217.66.135] helo=martin-debian-2.paytec.ch) by viti.kaiser.cx with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1ojip8-0006sp-Mt; Sat, 15 Oct 2022 17:11:38 +0200 From: Martin Kaiser To: Greg Kroah-Hartman Cc: Larry Finger , Phillip Potter , Michael Straube , Pavel Skripkin , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, Martin Kaiser Subject: [PATCH 09/10] staging: r8188eu: set two more state variables Date: Sat, 15 Oct 2022 17:11:14 +0200 Message-Id: <20221015151115.232095-10-martin@kaiser.cx> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221015151115.232095-1-martin@kaiser.cx> References: <20221015151115.232095-1-martin@kaiser.cx> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_NONE 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: X-Mailing-List: linux-kernel@vger.kernel.org Set two more state variables in the blink worker when scan blinking and tx/rx blinking are finished. bLedBlinkInProgress is true during tx/rx blinking, bLedScanBlinkInProgress is true during scan blinking. If we doing neither of the two, we may safely set both variables to false. This change makes the scan and tx/rx cases almost identical, we are now ready to summarize the two cases. Signed-off-by: Martin Kaiser --- drivers/staging/r8188eu/core/rtw_led.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/staging/r8188eu/core/rtw_led.c b/drivers/staging/r8188eu/core/rtw_led.c index 2dbd7b5ffdd0..f8bd183fba1e 100644 --- a/drivers/staging/r8188eu/core/rtw_led.c +++ b/drivers/staging/r8188eu/core/rtw_led.c @@ -90,6 +90,7 @@ static void blink_work(struct work_struct *work) pLed->CurrLedState = LED_BLINK_SLOWLY; schedule_delayed_work(&pLed->blink_work, LED_BLINK_NO_LINK_INTVL); } + pLed->bLedBlinkInProgress = false; pLed->bLedScanBlinkInProgress = false; } else { schedule_delayed_work(&pLed->blink_work, LED_BLINK_SCAN_INTVL); @@ -106,6 +107,7 @@ static void blink_work(struct work_struct *work) schedule_delayed_work(&pLed->blink_work, LED_BLINK_NO_LINK_INTVL); } pLed->bLedBlinkInProgress = false; + pLed->bLedScanBlinkInProgress = false; } else { schedule_delayed_work(&pLed->blink_work, LED_BLINK_FASTER_INTVL); } -- 2.30.2