Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1039672AbdDUNbQ (ORCPT ); Fri, 21 Apr 2017 09:31:16 -0400 Received: from mail-qt0-f193.google.com ([209.85.216.193]:36267 "EHLO mail-qt0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1039200AbdDUNbO (ORCPT ); Fri, 21 Apr 2017 09:31:14 -0400 MIME-Version: 1.0 In-Reply-To: <20170421120018.22232-1-horia.geanta@nxp.com> References: <20170421120018.22232-1-horia.geanta@nxp.com> From: Stuart Yoder Date: Fri, 21 Apr 2017 08:31:12 -0500 Message-ID: Subject: Re: [PATCH] bus: fsl-mc: dpio: fix alter FQ state command To: =?UTF-8?Q?Horia_Geant=C4=83?= Cc: gregkh@linuxfoundation.org, Roy Pledge , devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, Haiying Wang , Ioana Radulescu Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by mail.home.local id v3LDVRGL011754 Content-Length: 1069 Lines: 27 On Fri, Apr 21, 2017 at 7:00 AM, Horia Geantă wrote: > > When checking the response verb, the valid bit should be masked out, > since its value flips depending on what Response Register > (RR0 /RR1) it's been read from. > > Fixes: 321eecb06bfb ("bus: fsl-mc: dpio: add QBMan portal APIs for DPAA2") > Signed-off-by: Horia Geantă > --- > drivers/staging/fsl-mc/bus/dpio/qbman-portal.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/staging/fsl-mc/bus/dpio/qbman-portal.c b/drivers/staging/fsl-mc/bus/dpio/qbman-portal.c > index 2a3ea29d9b43..5d020fb98c66 100644 > --- a/drivers/staging/fsl-mc/bus/dpio/qbman-portal.c > +++ b/drivers/staging/fsl-mc/bus/dpio/qbman-portal.c > @@ -963,7 +963,7 @@ int qbman_swp_alt_fq_state(struct qbman_swp *s, u32 fqid, > } > > /* Decode the outcome */ > - WARN_ON(r->verb != alt_fq_verb); > + WARN_ON((r->verb & 0x7f) != alt_fq_verb); Don't use magic constants like that. Create a #define for the valid bit. Thanks, Stuart