From patchwork Fri Jan 13 10:37:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Herve Codina X-Patchwork-Id: 43151 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp196379wrt; Fri, 13 Jan 2023 02:41:08 -0800 (PST) X-Google-Smtp-Source: AMrXdXvh3xlQy4HQjgmEtH4sJ63aUA1eFaFtqT0jx+n0WW6d++bSFvwTkJTSy8ePl/Jth+lU6mgv X-Received: by 2002:aa7:d61a:0:b0:499:376e:6b2d with SMTP id c26-20020aa7d61a000000b00499376e6b2dmr20758584edr.0.1673606468495; Fri, 13 Jan 2023 02:41:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673606468; cv=none; d=google.com; s=arc-20160816; b=dTE+xWzVl6EI3l75ZU6BFxZa3iM//8AA55udx+X0q+jVqUf1RMP4Lboxh92M/A60wD gPhgbiyW6YZZIZBp4BeSmkCJzy4cFRUt+B2ObJG1KYn+p0RVT3H3gr/cPnKYZ7To9IKi rV2pjfBPUlDkH8KBNpJe9odOWLD1jiGoq6jMk2Ay3yWU/197atleld/+34YCcFlP81Zj HEfTN97xEdQzSjrkryZiinz66nFZT60Yt8UebJCa+0Zjc9prdLM0+mwwU+TVTr6XLKhp L543Bnv191qEtmDXa2XEe8qpYlzNf5CJigv+pjXdlNNVHhfICjV/djhUmAjdCYkW0T3S 0dQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=X0nZ3w9CqerSXAQbiCUvKKTb+HHkCbI3OfzoSex6DYA=; b=qMYtBA0cW3IWkDVs001TwYNsXeAZjMsQRl4+5yKcZv8M7c7+O9hWQGRDj8nIDAJIvb 3udzEIJAGhqXGuEzlxXJ0UOKcZ8RPB5tUUo4VbTDk/bcvJMupgpd76PrkMKvVQ/TMvOu mqgM/7b3/kn4+Eje7AJhc+EjzlCDfDokuYVVAt32zlbX2Se2LKe+9s8tz+8OJ4ZPTjq1 XV/wDb5BC1OiHxwwkaaRnsz8v2u31zaM5rIXOepC3wCHIGUxssgbbSojr2vAlrS8tm3Y SXMUnrlkHg8ae960YsGyi1LBldPTb3fZDzZ5QHQ1OmbUaDjY5Z8sHLnypob9AcGcMIYU Q5Wg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=k8iMp5IT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id eb6-20020a0564020d0600b0046dbf1fd79csi25187105edb.612.2023.01.13.02.40.44; Fri, 13 Jan 2023 02:41:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=k8iMp5IT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240277AbjAMKjz (ORCPT + 99 others); Fri, 13 Jan 2023 05:39:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39572 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232777AbjAMKix (ORCPT ); Fri, 13 Jan 2023 05:38:53 -0500 Received: from relay9-d.mail.gandi.net (relay9-d.mail.gandi.net [217.70.183.199]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A22F2777D0; Fri, 13 Jan 2023 02:38:21 -0800 (PST) Received: (Authenticated sender: herve.codina@bootlin.com) by mail.gandi.net (Postfix) with ESMTPA id 2FDE1FF80B; Fri, 13 Jan 2023 10:38:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1673606300; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=X0nZ3w9CqerSXAQbiCUvKKTb+HHkCbI3OfzoSex6DYA=; b=k8iMp5ITpNaaYjkn0ArN3waHtog2m2s4fg8ogSRiClFowHzS9QYZGBGbohy6a6AFjjlRsv BnnOpA30G5ntc+FmlvuF1VH7GMmfv2UIE/lX8qM7uceDFFjykSFog+An2Iw+ajtLrF+Ixp SbsBu5pPdrhk4POs+F3jF8M1C9fpd5agNRFC+nvgH0rocywPhMx3ebng9/jw3Az/nV3RpE VdI+Q0PlUXJOwa3+2uOJewxH92TsGdK4IFwZrFCVOJzjvxkZRv+43hV88aLGakDL3wozY1 oUmCAUF1DWC5iV3q3+ObsImsZtQ6o6uyyHjxrP632wquRRjJ/9IqKKOm+cxTTA== From: Herve Codina To: Herve Codina , Li Yang , Rob Herring , Krzysztof Kozlowski , Liam Girdwood , Mark Brown , Christophe Leroy , Michael Ellerman , Nicholas Piggin , Qiang Zhao , Jaroslav Kysela , Takashi Iwai , Shengjiu Wang , Xiubo Li , Fabio Estevam , Nicolin Chen Cc: linuxppc-dev@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, Thomas Petazzoni Subject: [PATCH v3 04/10] powerpc/8xx: Use a larger CPM1 command check mask Date: Fri, 13 Jan 2023 11:37:53 +0100 Message-Id: <20230113103759.327698-5-herve.codina@bootlin.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230113103759.327698-1-herve.codina@bootlin.com> References: <20230113103759.327698-1-herve.codina@bootlin.com> MIME-Version: 1.0 X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1754903576271672045?= X-GMAIL-MSGID: =?utf-8?q?1754903576271672045?= The CPM1 command mask is defined for use with the standard CPM1 command register as described in the user's manual: 0 |1 3|4 7|8 11|12 14| 15| RST| - |OPCODE|CH_NUM| - |FLG| In the QMC extension the CPM1 command register is redefined (QMC supplement user's manuel) with the following mapping: 0 |1 3|4 7|8 13|14| 15| RST|QMC OPCODE| 1110|CHANNEL_NUMBER| -|FLG| Extend the check command mask in order to support both the standard CH_NUM field and the QMC extension CHANNEL_NUMBER field. Signed-off-by: Herve Codina Acked-by: Christophe Leroy --- arch/powerpc/platforms/8xx/cpm1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/platforms/8xx/cpm1.c b/arch/powerpc/platforms/8xx/cpm1.c index 8ef1f4392086..6b828b9f90d9 100644 --- a/arch/powerpc/platforms/8xx/cpm1.c +++ b/arch/powerpc/platforms/8xx/cpm1.c @@ -100,7 +100,7 @@ int cpm_command(u32 command, u8 opcode) int i, ret; unsigned long flags; - if (command & 0xffffff0f) + if (command & 0xffffff03) return -EINVAL; spin_lock_irqsave(&cmd_lock, flags);