Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2420891pxb; Sun, 28 Feb 2021 00:17:16 -0800 (PST) X-Google-Smtp-Source: ABdhPJz2c/Ao07tXDetNI9Ub7tjL5Xcu3SK2laHWmzrCr653u81FoKVUrPgaofGeNxtwyxmGTiIn X-Received: by 2002:a17:906:2a8b:: with SMTP id l11mr10855685eje.1.1614500236332; Sun, 28 Feb 2021 00:17:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614500236; cv=none; d=google.com; s=arc-20160816; b=gSSJ+y3ZwF6tKJ7kTgXg173a5CAap7K4d+dhgaYtcLICU6+Dqsmi1j2IY3+84LB4Or LU3qw18vcZH7tceRK0dQlVr4UlvfTsD4DmkiEQnSJMCsdNojxOwTRz3Zkm+CTmrUGNZ1 hXr3VB35S3QvYiJUnDUseBRDMuZqgbSAhUvgpgeR92rYFqCQavWzdfCD0OzMcL692KeD H1KHqYxQU7jUxRKR8uAki2ezlCalWI3Kr+qPr58CgbHeYZAognBPHKe6CtANjaSdjSfl 90VC9VaRL90WatldOl/jv+Oorh0RouWRtvwopdzxm+2TuFlFCGUXFOJVOSOHuayZH567 XIZw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:references:in-reply-to :subject:cc:to:from:message-id:date; bh=AqSZQU3NBFPlxJSEQL/+vu24Zegh90ZWr1FQOkNF3tY=; b=eQO9PDvppv/gkeHWQUjo5g/8wTlORAIJIVCVh5BVCDO5nDphq26IwIBI4bK7AVxc4r ccKQeVahsdrw1MGnmB1hlwRkDUkUoWl3fSHuVtB/jwTtaGbxK1MbRu2B1eIIDWt+9knm PwBOXS3e1RNnlxT813OimIM8mKV/WK1obM0/Dt6fUGP9dEJk1eQAlCJUbVJdvUD278gP cry1goz4KSmqrVhST30hNJNYCEGouhhSKUDo+Ed4/v4OaxV1dalFRaulxHVVbHCgOJD2 v8OwvRyml7kDDOjaiRhZVtINuMLtkA7hCEiZS2cZ27miPIl1KmAMnWlSNOldWqXLOoGz 6qGQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bl4si8929345ejb.691.2021.02.28.00.16.52; Sun, 28 Feb 2021 00:17:16 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230299AbhB1IOU (ORCPT + 99 others); Sun, 28 Feb 2021 03:14:20 -0500 Received: from mx2.suse.de ([195.135.220.15]:43836 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230075AbhB1IOT (ORCPT ); Sun, 28 Feb 2021 03:14:19 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id F07BAAB8C; Sun, 28 Feb 2021 08:12:54 +0000 (UTC) Date: Sun, 28 Feb 2021 09:12:54 +0100 Message-ID: From: Takashi Iwai To: Colin King Cc: Jaroslav Kysela , Takashi Iwai , Pierre-Louis Bossart , Wai Yew CHAY , alsa-devel@alsa-project.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] ALSA: ctxfi: cthw20k2: fix mask on conf to allow 4 bits In-Reply-To: <20210227001527.1077484-1-colin.king@canonical.com> References: <20210227001527.1077484-1-colin.king@canonical.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/25.3 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 27 Feb 2021 01:15:27 +0100, Colin King wrote: > > From: Colin Ian King > > Currently the mask operation on variable conf is just 3 bits so > the switch statement case value of 8 is unreachable dead code. > The function daio_mgr_dao_init can be passed a 4 bit value, > function dao_rsc_init calls it with conf set to: > > conf = (desc->msr & 0x7) | (desc->passthru << 3); > > so clearly when desc->passthru is set to 1 then conf can be > at least 8. > > Fix this by changing the mask to 0xf. > > Fixes: 8cc72361481f ("ALSA: SB X-Fi driver merge") > Signed-off-by: Colin Ian King Applied, thanks. Takashi