From patchwork Fri Oct 18 04:33:38 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: You-Sheng Yang X-Patchwork-Id: 1179111 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 46vY833z2Yz9sPV; Fri, 18 Oct 2019 15:33:55 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1iLJxX-0004pE-Er; Fri, 18 Oct 2019 04:33:51 +0000 Received: from mail-pl1-f195.google.com ([209.85.214.195]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1iLJxV-0004o2-Dp for kernel-team@lists.ubuntu.com; Fri, 18 Oct 2019 04:33:49 +0000 Received: by mail-pl1-f195.google.com with SMTP id c3so2227427plo.2 for ; Thu, 17 Oct 2019 21:33:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=GfNpvUSjwinzLddhxs6r+7k1B+KIaAjLxlfdsJpm6q8=; b=lp9EwYUUa/ZpL3ZDogzzEz42JoRKbLDdmyTyuj2jrHxwpLMXUsoR3l2mQFUUGf6pip y1lHVFS4PhFKBHk8XPZLvOuKn3MHwKHrWvqnp6PVhzn8Y+RRuSI3u/Ct68xIb+zxkWhJ Uw2vKo86jWgqcab38d6rKX1yJt8ZCA0jtkgQiiFTVZRNi7PtaIbFejkcRgo9Hrzyj8Wb ifshr+A+tep/rCZayW0/MTKweYaGcMBH/KHotdWAZMtiK1pAv9Du2O6isY4rScXMDrcO 9FRoYostAOo84FWqg4p0SefcIYqojzWpUBD/YFmq/ERmFotwWZXWeNsL9wHpdHL19g+Y wG9w== X-Gm-Message-State: APjAAAVymwNu6bui5gaQCv6olc1iFWx1P6hgDuh1I7630UZoOKSf9Q5F jqa8pKqTNcu0+G2Pk9qqc5MbZKAr X-Google-Smtp-Source: APXvYqzzQGNP3/VL0j15ZmJO2Bxe2IoX2EwfJlHSSa42uICwZF1imWiK3mkoEi6/0QYasA9WYtFZRw== X-Received: by 2002:a17:902:bf02:: with SMTP id bi2mr296228plb.255.1571373227204; Thu, 17 Oct 2019 21:33:47 -0700 (PDT) Received: from localhost (61-220-137-34.HINET-IP.hinet.net. [61.220.137.34]) by smtp.gmail.com with ESMTPSA id q143sm4511965pfq.103.2019.10.17.21.33.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 17 Oct 2019 21:33:46 -0700 (PDT) From: You-Sheng Yang To: kernel-team@lists.ubuntu.com Subject: [PATCH 2/2][SRU][B/D/E/OEM-B/OEM-OSP1-B] iwlwifi: exclude GEO SAR support for 3168 Date: Fri, 18 Oct 2019 12:33:38 +0800 Message-Id: <20191018043338.11725-3-vicamo.yang@canonical.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191018043338.11725-1-vicamo.yang@canonical.com> References: <20191018043338.11725-1-vicamo.yang@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" From: Luca Coelho BugLink: https://bugs.launchpad.net/bugs/1846016 We currently support two NICs in FW version 29, namely 7265D and 3168. Out of these, only 7265D supports GEO SAR, so adjust the function that checks for it accordingly. Signed-off-by: Luca Coelho Fixes: f5a47fae6aa3 ("iwlwifi: mvm: fix version check for GEO_TX_POWER_LIMIT support") Signed-off-by: Luca Coelho (cherry picked from commit 12e36d98d3e5acf5fc57774e0a15906d55f30cb9 https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git) Signed-off-by: You-Sheng Yang Acked-By: AceLan Kao --- drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/fw.c b/drivers/net/wireless/intel/iwlwifi/mvm/fw.c index 5fadbb0f025e..5c70abda4af5 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/fw.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/fw.c @@ -795,15 +795,17 @@ static bool iwl_mvm_sar_geo_support(struct iwl_mvm *mvm) * firmware versions. Unfortunately, we don't have a TLV API * flag to rely on, so rely on the major version which is in * the first byte of ucode_ver. This was implemented - * initially on version 38 and then backported to29 and 17. - * The intention was to have it in 36 as well, but not all - * 8000 family got this feature enabled. The 8000 family is - * the only one using version 36, so skip this version - * entirely. + * initially on version 38 and then backported to 17. It was + * also backported to 29, but only for 7265D devices. The + * intention was to have it in 36 as well, but not all 8000 + * family got this feature enabled. The 8000 family is the + * only one using version 36, so skip this version entirely. */ return IWL_UCODE_SERIAL(mvm->fw->ucode_ver) >= 38 || - IWL_UCODE_SERIAL(mvm->fw->ucode_ver) == 29 || - IWL_UCODE_SERIAL(mvm->fw->ucode_ver) == 17; + IWL_UCODE_SERIAL(mvm->fw->ucode_ver) == 17 || + (IWL_UCODE_SERIAL(mvm->fw->ucode_ver) == 29 && + ((mvm->trans->hw_rev & CSR_HW_REV_TYPE_MSK) == + CSR_HW_REV_TYPE_7265D)); } int iwl_mvm_get_sar_geo_profile(struct iwl_mvm *mvm)