From patchwork Sat Jun 14 13:27:38 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rickard Strandqvist X-Patchwork-Id: 4352481 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.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 0343F9F333 for ; Sat, 14 Jun 2014 13:27:18 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2B9D42021B for ; Sat, 14 Jun 2014 13:27:17 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6735A201E4 for ; Sat, 14 Jun 2014 13:27:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754837AbaFNN0z (ORCPT ); Sat, 14 Jun 2014 09:26:55 -0400 Received: from mail-lb0-f173.google.com ([209.85.217.173]:45732 "EHLO mail-lb0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754816AbaFNN0n (ORCPT ); Sat, 14 Jun 2014 09:26:43 -0400 Received: by mail-lb0-f173.google.com with SMTP id s7so1925081lbd.32 for ; Sat, 14 Jun 2014 06:26:42 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=n9Pum5KBuEInzBY1O4560pqXd+tmfl7fZm+94AcnPEI=; b=RyP+FUrBM237+5l9uKDQ8tgC+mRun3YuTfOdnd9fHW0mr0xmSAlF2iC/r4OT/g8A2x yg2jOffy/cEw+jL0u8lUNswqBn0Q4aau8g3m6lu2id8d8RJqpkzs6xyS8K1s7jB77EWe VGyHt8oesv3h81LEx3foWFWxiI2NOmCgQmnK6ArOxkM41XDvNTvKVUkU57bilEoW27Cs QNV4YfVK8nI4uk+W8YqXcMrYgbXWG733k3CwXrNDXYXbf6BhMjvJCVsnebasZDhlijrU y27DWXEwMqMbEnIB/7o+gYPXXNtNt+M9ng+OIbSpUQie+E2rU8yiwGZzvKRyUpAiZN6s 901A== X-Gm-Message-State: ALoCoQlxbp7KCNGXoH1omkJWfqrY/fgqthAiOWpOpNz//zq09I72YjxCqsHvhJSv/IFBTQGcSGm+ X-Received: by 10.112.34.210 with SMTP id b18mr5605024lbj.42.1402752402223; Sat, 14 Jun 2014 06:26:42 -0700 (PDT) Received: from localhost.localdomain (h-245-62.a218.priv.bahnhof.se. [85.24.245.62]) by mx.google.com with ESMTPSA id l8sm3931156lbh.26.2014.06.14.06.26.40 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 14 Jun 2014 06:26:41 -0700 (PDT) From: Rickard Strandqvist To: Larry Finger , Chaoming Li Cc: Rickard Strandqvist , "John W. Linville" , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2] net: wireless: rtlwifi: rtl8188ee: reg.h: Cleaning up if statement that always evaluates to false Date: Sat, 14 Jun 2014 15:27:38 +0200 Message-Id: <1402752458-13836-2-git-send-email-rickard_strandqvist@spectrumdigital.se> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1402752458-13836-1-git-send-email-rickard_strandqvist@spectrumdigital.se> References: <1402752458-13836-1-git-send-email-rickard_strandqvist@spectrumdigital.se> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham 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 I found a logical error in an if statement that always evaluates to false. This has after same discussion resulted in that we add a macro to handle this. Signed-off-by: Rickard Strandqvist --- drivers/net/wireless/rtlwifi/rtl8188ee/reg.h | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/wireless/rtlwifi/rtl8188ee/reg.h b/drivers/net/wireless/rtlwifi/rtl8188ee/reg.h index 7af85cf..cd7e7a5 100644 --- a/drivers/net/wireless/rtlwifi/rtl8188ee/reg.h +++ b/drivers/net/wireless/rtlwifi/rtl8188ee/reg.h @@ -411,6 +411,7 @@ #define MSR_ADHOC 0x01 #define MSR_INFRA 0x02 #define MSR_AP 0x03 +#define MSR_MASK 0x03 #define RRSR_RSC_OFFSET 21 #define RRSR_SHORT_OFFSET 23