Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp3533061rwl; Sun, 9 Apr 2023 18:35:26 -0700 (PDT) X-Google-Smtp-Source: AKy350ZpubKPOYSpOa+4Du+0AFw6fVdNS0FXjiJgNLuha7nGxzdCPGeHmCZUruSJhRhOyb8pr2Jc X-Received: by 2002:a17:907:3e9b:b0:94a:9651:51f0 with SMTP id hs27-20020a1709073e9b00b0094a965151f0mr1153844ejc.58.1681090526238; Sun, 09 Apr 2023 18:35:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681090526; cv=none; d=google.com; s=arc-20160816; b=Mhe6gXGF8M/kjEIh3J8Zn4UAc3H4N0AMsA1mkO1+qOujxu0a7g4latm9vrhuVoaszR jr64m52nohFNiOR0K4tagtKJANJHiCAryz1trRU15nNLXACL2NQikQt0/oH0BbqzegJn b3Azaxw0bc3GpHEE5Dr6zdmhUk58xmvOqmRzkIVEtKugxWp5pmKGwLpTUWOEeSDguVlr 8dgrJt+PEpmR2oQ2kT43nVu4/gv3UdTNgQZ7svi9YrXHkuZXp68q5ti1ZestsAEniPWo 8NP0KxgmWZ3ZZnnN6RyQmxUi5dwwh7sMzqxmFAFupfgj0ELC42roo/wFqL5QOTNYahTT ndCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:authenticated-by; bh=6pHYoqfiPZftjvpblfUHx1iydbdWqJMbRUWt5QA38jc=; b=I9HyasPGu8DuQ1+nivZs4mq39MW4MrfIzIa4uYPbPRcxQE5LhyDx7nzh+7OBVCt6H9 51B3gQsU6A+C/uyNp+tsWaRgVVyWgl7kN1/9tD/TN4/VkPPlIS5jRPR8MfDN8ZwzJPqD 3Ohk/MZG1Bi2v3k3yTVpQMSOD04aBtfFlFhH0BvYSgst+awSYzyUaA17U650NxcU68sL 7S5hLrj3Npig7pRnAHZbquzICOKK5XTHWlvuo4MgmB9eJkA/XCWxvmN+eQA9/dnEUmSw ZxcDE6pRfVHrkWJqM69e68xzyg2kfiT5hCJ8RmsBBpHaPs2VccnUvJSIeoki9P0ctTzp rt5w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-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 v15-20020aa7cd4f000000b0050482eefe67si6191145edw.138.2023.04.09.18.35.07; Sun, 09 Apr 2023 18:35:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-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-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229617AbjDJAUo (ORCPT + 61 others); Sun, 9 Apr 2023 20:20:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59548 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229445AbjDJAUm (ORCPT ); Sun, 9 Apr 2023 20:20:42 -0400 Received: from rtits2.realtek.com.tw (rtits2.realtek.com [211.75.126.72]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0451330F9 for ; Sun, 9 Apr 2023 17:20:40 -0700 (PDT) Authenticated-By: X-SpamFilter-By: ArmorX SpamTrap 5.77 with qID 33A0KGuyC007162, This message is accepted by code: ctloc85258 Received: from mail.realtek.com (rtexh36506.realtek.com.tw[172.21.6.27]) by rtits2.realtek.com.tw (8.15.2/2.81/5.90) with ESMTPS id 33A0KGuyC007162 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=OK); Mon, 10 Apr 2023 08:20:16 +0800 Received: from RTEXMBS03.realtek.com.tw (172.21.6.96) by RTEXH36506.realtek.com.tw (172.21.6.27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.17; Mon, 10 Apr 2023 08:20:37 +0800 Received: from RTEXMBS04.realtek.com.tw (172.21.6.97) by RTEXMBS03.realtek.com.tw (172.21.6.96) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.7; Mon, 10 Apr 2023 08:20:36 +0800 Received: from RTEXMBS04.realtek.com.tw ([fe80::b4a2:2bcc:48d1:8b02]) by RTEXMBS04.realtek.com.tw ([fe80::b4a2:2bcc:48d1:8b02%5]) with mapi id 15.01.2375.007; Mon, 10 Apr 2023 08:20:36 +0800 From: Ping-Ke Shih To: Bitterblue Smith , "linux-wireless@vger.kernel.org" CC: Jes Sorensen Subject: RE: [PATCH 1/2] wifi: rtl8xxxu: Clean up some messy ifs Thread-Topic: [PATCH 1/2] wifi: rtl8xxxu: Clean up some messy ifs Thread-Index: AQHZZA3VOb/3C7mk9kGPYLUdN/MokK8df2cQgAUMeYCAAS/x4A== Date: Mon, 10 Apr 2023 00:20:36 +0000 Message-ID: References: <04d4ca3e27924ea6b2ad6e5b00ddb424@realtek.com> <541f26bb-5022-2c2d-200a-68dc2c6fb5fe@gmail.com> In-Reply-To: <541f26bb-5022-2c2d-200a-68dc2c6fb5fe@gmail.com> Accept-Language: en-US, zh-TW Content-Language: zh-TW X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [172.21.69.188] x-kse-serverinfo: RTEXMBS03.realtek.com.tw, 9 x-kse-attachmentfiltering-interceptor-info: no applicable attachment filtering rules found x-kse-antivirus-interceptor-info: scan successful x-kse-antivirus-info: =?utf-8?B?Q2xlYW4sIGJhc2VzOiAyMDIzLzQvOSDkuIvljYggMTA6MDA6MDA=?= x-kse-bulkmessagesfiltering-scan-result: protection disabled Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-Spam-Status: No, score=0.0 required=5.0 tests=SPF_HELO_NONE,SPF_PASS autolearn=unavailable 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-wireless@vger.kernel.org DQoNCj4gLS0tLS1PcmlnaW5hbCBNZXNzYWdlLS0tLS0NCj4gRnJvbTogQml0dGVyYmx1ZSBTbWl0 aCA8cnRsODgyMWNlcmZlMkBnbWFpbC5jb20+DQo+IFNlbnQ6IFN1bmRheSwgQXByaWwgOSwgMjAy MyAxMDoxMSBQTQ0KPiBUbzogUGluZy1LZSBTaGloIDxwa3NoaWhAcmVhbHRlay5jb20+OyBsaW51 eC13aXJlbGVzc0B2Z2VyLmtlcm5lbC5vcmcNCj4gQ2M6IEplcyBTb3JlbnNlbiA8SmVzLlNvcmVu c2VuQGdtYWlsLmNvbT4NCj4gU3ViamVjdDogUmU6IFtQQVRDSCAxLzJdIHdpZmk6IHJ0bDh4eHh1 OiBDbGVhbiB1cCBzb21lIG1lc3N5IGlmcw0KPiANCj4gT24gMDYvMDQvMjAyMyAwNDoxNiwgUGlu Zy1LZSBTaGloIHdyb3RlOg0KPiA+DQo+ID4NCj4gPj4gLS0tLS1PcmlnaW5hbCBNZXNzYWdlLS0t LS0NCj4gPj4gRnJvbTogQml0dGVyYmx1ZSBTbWl0aCA8cnRsODgyMWNlcmZlMkBnbWFpbC5jb20+ DQo+ID4+IFNlbnQ6IFNhdHVyZGF5LCBBcHJpbCAxLCAyMDIzIDQ6MTcgQU0NCj4gPj4gVG86IGxp bnV4LXdpcmVsZXNzQHZnZXIua2VybmVsLm9yZw0KPiA+PiBDYzogSmVzIFNvcmVuc2VuIDxKZXMu U29yZW5zZW5AZ21haWwuY29tPjsg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