From patchwork Tue Jan 13 14:07:34 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin King X-Patchwork-Id: 5620691 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 793A39F3A0 for ; Tue, 13 Jan 2015 14:08:47 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 891F82039E for ; Tue, 13 Jan 2015 14:08:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 43EE9202F0 for ; Tue, 13 Jan 2015 14:08:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751423AbbAMOIn (ORCPT ); Tue, 13 Jan 2015 09:08:43 -0500 Received: from youngberry.canonical.com ([91.189.89.112]:35309 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751133AbbAMOIm (ORCPT ); Tue, 13 Jan 2015 09:08:42 -0500 Received: from cpc3-craw6-2-0-cust180.croy.cable.virginm.net ([77.100.248.181] helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1YB294-0000Wn-Q1; Tue, 13 Jan 2015 14:08:34 +0000 From: Colin King To: Larry Finger , Chaoming Li , Kalle Valo , "John W. Linville" , linux-wireless@vger.kernel.org, netdev@vger.kernel.org Cc: linux-kernel@vger.kernel.org Subject: [PATCH] rtlwifi/rtl8192de: remove redundant else if check Date: Tue, 13 Jan 2015 14:07:34 +0000 Message-Id: <1421158054-22566-1-git-send-email-colin.king@canonical.com> X-Mailer: git-send-email 2.1.4 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Colin Ian King The else if check condition checks for the opposite of the if check, hence the else if check is redundant and can be replaced with a simple else: if (rtlpriv->rtlhal.macphymode == SINGLEMAC_SINGLEPHY) { .. } else if (rtlpriv->rtlhal.macphymode != SINGLEMAC_SINGLEPHY) { .. } replaced with: if (rtlpriv->rtlhal.macphymode == SINGLEMAC_SINGLEPHY) { .. } else { .. } Signed-off-by: Colin Ian King Acked-by: Larry Finger --- drivers/net/wireless/rtlwifi/rtl8192de/hw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/rtlwifi/rtl8192de/hw.c b/drivers/net/wireless/rtlwifi/rtl8192de/hw.c index 280c3da..01bcc2d 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192de/hw.c +++ b/drivers/net/wireless/rtlwifi/rtl8192de/hw.c @@ -546,7 +546,7 @@ static bool _rtl92de_llt_table_init(struct ieee80211_hw *hw) txpktbuf_bndy = 246; value8 = 0; value32 = 0x80bf0d29; - } else if (rtlpriv->rtlhal.macphymode != SINGLEMAC_SINGLEPHY) { + } else { maxPage = 127; txpktbuf_bndy = 123; value8 = 0;