From patchwork Fri Jan 6 16:37:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Herve Codina X-Patchwork-Id: 40193 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp916589wrt; Fri, 6 Jan 2023 08:44:09 -0800 (PST) X-Google-Smtp-Source: AMrXdXsQVTZ7HafmysHwxCIV/J6QEwH0Rs9vRyuxf0TQXcUs/mJs4fypBpeVW6XugFYO5RM0k0H6 X-Received: by 2002:a05:6a20:e61b:b0:af:7ed7:d370 with SMTP id my27-20020a056a20e61b00b000af7ed7d370mr64044808pzb.43.1673023449043; Fri, 06 Jan 2023 08:44:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673023449; cv=none; d=google.com; s=arc-20160816; b=c84bcZUI5uJwZb4Ek5YsJfJ0R67qu7kjs3p9GZYXtny+npoJ7A3c8PjMUZsnSh7cCp W7E6t2iJ/1DnGvDPKKvTAwdF9Yutgmgz0HyHJX3XYv/P9LQplYfBQJ7mtvwEPNs4W1Im gPj3MYf5dEt7fSiXSUGf7IQbSmrYBdSMW6U2tJ3zHGaAuWgSrMWME+pborTapktopIqA VgaPJe/sFv+UX2Ury0dmrYY96kSVC79O2iRguzfRXjveXq/NzQg/xLrTsZmuajhIIQBa L2IzhzRJRFCjowsWEOeDRhRrFui0iI3UIKAvbwlGhNLzu9d7jyj3nsdp2RZXWs7yJMec 9SHA== 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=zHdG5dWGsORYS6XG1CcUMN1p2tcFBkBpXeEXIVWBo8Q=; b=WrED17zS1GDSxj1NdNzS3l14zSEnu5/rGNZCVyYmXXJgtpFKAOxzMaBE/DSk44byox cRIUCnkmS8cHvwDRH4pwwk9URbsZPb+Xbzuy5OMfwQ8B0yhth5r67eDAuwSKzd0pC3R1 h6PvXv7LHacKimIR1bbg9XRkV0rNrC8IKeWd8YgRgvRRJJHKihY1MhaLAv1CPmNu80UG 8UdTlrwYLq2y0nGFajmh1bZaAwVkL4Jx7RlptVSWK1K7FO3m1SgmcnfHNneuv4k06iV5 vUsd9MFdOZKYqeGC4ilwyk3MjnMeYVRi9YWoIJcVa9dssZKmU0a/Sg+dNtgLNciEkNhT lkZA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=bWdAElX6; 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 q76-20020a632a4f000000b0049fa3a102ecsi1813562pgq.444.2023.01.06.08.43.56; Fri, 06 Jan 2023 08:44:09 -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=bWdAElX6; 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 S235729AbjAFQio (ORCPT + 99 others); Fri, 6 Jan 2023 11:38:44 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54722 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235584AbjAFQiK (ORCPT ); Fri, 6 Jan 2023 11:38:10 -0500 Received: from relay11.mail.gandi.net (relay11.mail.gandi.net [217.70.178.231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1BCB578A5A; Fri, 6 Jan 2023 08:38:09 -0800 (PST) Received: (Authenticated sender: herve.codina@bootlin.com) by mail.gandi.net (Postfix) with ESMTPA id 5FC2910000B; Fri, 6 Jan 2023 16:38:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1673023088; 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=zHdG5dWGsORYS6XG1CcUMN1p2tcFBkBpXeEXIVWBo8Q=; b=bWdAElX63nV5KAJ3lRli5wH/z0GpLUVccEehfCFnrwsSnOjFjpJrHYugerQBdc7xuNRDeg e/gRypGCodVzNgI/7yw+pEHQY2fB4hE20o9otuqohv0QxUG2+IdbRPnS6DsrexRdu4aorm PfSxcZpAqaIiVw9gJoEJYamqYN46Hw2Rp4VCDj3iT7qpnQulPL4vskv7xFGh0c8/WUVDrz vy7IVWjynd8eqxYxbdg/n0ZDSfJflU45u3idxmMIK8Hw+aygdcEkOaG8dQaxtt9lC9VYwd WXteZg5jAX5U7B7+z7mm+aPcXe2Et/F9xwPgKqXKhAAmQRdsrW9essLYrvr6Cg== 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 v2 04/10] powerpc/8xx: Use a larger CPM1 command check mask Date: Fri, 6 Jan 2023 17:37:40 +0100 Message-Id: <20230106163746.439717-5-herve.codina@bootlin.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230106163746.439717-1-herve.codina@bootlin.com> References: <20230106163746.439717-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?1754292235680126549?= X-GMAIL-MSGID: =?utf-8?q?1754292235680126549?= 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 (As maintainer --- 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);