From patchwork Thu Sep 3 11:45:03 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vinod Koul X-Patchwork-Id: 11753451 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1417E109A for ; Thu, 3 Sep 2020 11:51:39 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8D6FF206EB for ; Thu, 3 Sep 2020 11:51:38 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="nVXd/2eA"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="Kb9Kx0yW" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8D6FF206EB Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 09F541937; Thu, 3 Sep 2020 13:50:53 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 09F541937 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1599133897; bh=Fi7GM1/OYmb/9tAwU/ijFZG1CkTAIhIQV72ALoWrINI=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=nVXd/2eAQOCocOmskTVPdSE19tzWVnUgv/3k6CoByJCj2oiSpLeyI4PDhz8OP8Rx9 vJucGzlIAkzprCu93Tz+Suh9oD6vpfsfLRU6WzpUMuqAzfymVqTGYK2Nz6OHd0Djha IITuS+b4+bp1xXnST5v+Om9kUa0ihzT+nR4gGz7k= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id C8014F80329; Thu, 3 Sep 2020 13:45:54 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa1.perex.cz (Postfix, from userid 50401) id 98C9CF80323; Thu, 3 Sep 2020 13:45:50 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on alsa1.perex.cz X-Spam-Level: X-Spam-Status: No, score=-0.1 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE,SPF_PASS autolearn=disabled version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id BA04AF80316 for ; Thu, 3 Sep 2020 13:45:44 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz BA04AF80316 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="Kb9Kx0yW" Received: from localhost.localdomain (unknown [122.171.179.172]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DD9B42083B; Thu, 3 Sep 2020 11:45:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1599133543; bh=Fi7GM1/OYmb/9tAwU/ijFZG1CkTAIhIQV72ALoWrINI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Kb9Kx0yW/AcO7qcHXq14NAfIAbHpBwwPsKIZM6UwjL+fRI2y687nXl2m0sSkY26ub nJVhi6DHjplvRHliQJGa2MZ0iL8vZ7feP+x2nFQz323M3Mihk4kXhxOINNypNn/Ecq tJAt8D7mLfDX8BWn6JWdK3sIDq5KKcjSk2/ycaL0= From: Vinod Koul To: alsa-devel@alsa-project.org Subject: [PATCH v2 8/9] soundwire: intel_init: use FIELD_{GET|PREP} Date: Thu, 3 Sep 2020 17:15:03 +0530 Message-Id: <20200903114504.1202143-9-vkoul@kernel.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200903114504.1202143-1-vkoul@kernel.org> References: <20200903114504.1202143-1-vkoul@kernel.org> MIME-Version: 1.0 Cc: Srinivas Kandagatla , Sanyog Kale , Bard Liao , Pierre-Louis Bossart , Vinod Koul X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" use FIELD_{GET|PREP} in intel_init driver to get/set field values instead of open coding masks and shift operations. Signed-off-by: Vinod Koul --- drivers/soundwire/intel_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/soundwire/intel_init.c b/drivers/soundwire/intel_init.c index 65d9b9bd2106..cabdadb09a1b 100644 --- a/drivers/soundwire/intel_init.c +++ b/drivers/soundwire/intel_init.c @@ -383,7 +383,7 @@ static acpi_status sdw_intel_acpi_cb(acpi_handle handle, u32 level, * Name(_ADR, 0x40000000), with bits 31..28 representing the * SoundWire link so filter accordingly */ - if ((adr & GENMASK(31, 28)) >> 28 != SDW_LINK_TYPE) + if (FIELD_GET(GENMASK(31, 28), adr) != SDW_LINK_TYPE) return AE_OK; /* keep going */ /* device found, stop namespace walk */