Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp2089365ybl; Tue, 3 Dec 2019 18:24:17 -0800 (PST) X-Google-Smtp-Source: APXvYqygMTkOXQozIJU5y48Rel/sMfDGVhtvBBOCJiUyxLXqv5WydYepB6UGLrbUJzlxIt2A24wW X-Received: by 2002:aca:d502:: with SMTP id m2mr719353oig.41.1575426257852; Tue, 03 Dec 2019 18:24:17 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1575426257; cv=pass; d=google.com; s=arc-20160816; b=fbtTiC6UwmtFpeUFDhUl0OIvUDF3oWSpKu4kAThcnfxbohN2PTpOiQS1c96axnbAO3 /xErJT23vWmopCf23GSJjsA6Tafk+GecnlM+KRyVV9ZBE+gphRVvi28HIeem2ZcT4vEp aG+W4EnBIxNEapinekckwtX5VK2Zj/xoautd0B1UZfVXlKTAqNmLW+ooqBsXBxNQ+FYW xD8XfLmYdkq9/Im76wAYb/p/0bVLDjOmQizyJweZir4fSql7NglUxnbXHp1dVTYd4u9W 0sFhY0Q42ybeXNPfhcQb/IBZNWAg9Cx5yYTVXvEjhnlUY8OrkpbSq8r6zKPYuhDK8Csq Odfg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:dkim-signature; bh=DbJxBly5TyryvPHM5vQVZjy9njGk9fxennF/bq0h/S8=; b=s6VxBOiamhByrbtO5mpJcuX/aIb7miA9ake4JTmHaga6hpRHnbPXKCnSc/nxmTUWyA vZXQwPxBaF9iRQyNXgUpJrU+aojSYL75SU8mrpbz3T7u7Bhy2493mDq22rHAdm2DEluY wRVsS8iaA6CYZ6HD8GQNw6aXTh1ipy9aE0XtuLtDYf/VfrccKKyrEukrYP6ffch00GCD dLNoPaVvMPpPILtJaqzDXvsr7v+CA4Wpfr8YLNUPCpdzsrwfKgfjE7Sefeh/wrW1SlB+ 8qqYrzd+c6vuIYT6lz7hGGY84BYO/2yRJf0mKsgMztOVrAD6imVR/p1QKGAQAbIkhpyv dYKw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=obsjUILe; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q9si2435496oif.92.2019.12.03.18.23.40; Tue, 03 Dec 2019 18:24:17 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=obsjUILe; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726897AbfLDCWj (ORCPT + 99 others); Tue, 3 Dec 2019 21:22:39 -0500 Received: from mail-eopbgr140074.outbound.protection.outlook.com ([40.107.14.74]:63214 "EHLO EUR01-VE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726162AbfLDCWi (ORCPT ); Tue, 3 Dec 2019 21:22:38 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EWXpsGUqmnSoSL+D9JlGrMBaOKJzjY2XsFGPM+W61/ld9BL9GTNQjxmoylC3ToaWnv8QyeUBVBOHcDzmTujSaxgCGQCTxOSqSn6Ey8dEWT7AQncFv0PlK6K5xQdY3TIcrUDvDeKLBmIfSlB0+RvVSMN4uerMzObfm8tyUZH/c1nAj7qYGyG0PtuB3MVPeNQuG1xZ2BkxNdq99z3v86M2kI1t0YBl0CxlO85ipl9w8JnHBoYYtvOLojKZOJwJ+tg3HiXXQn3fzlrwFUezXTN6iTdqJLpCrhBINBZkkRF2Gt2XnDgFnTwRCDArPy21Atzib/6hc2YSZZd7HJc72bRZew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=DbJxBly5TyryvPHM5vQVZjy9njGk9fxennF/bq0h/S8=; b=Gfx2HF0jt1MOmVazZ1LOfX34recCKCwqlVDOKr097FuxCj1/zpHqScTMwIuxZ7H6RLCu/J8OmqXCLj6+6ZJT64IsUNegZwJSZ4iy5Hv+03BL3W2/OWtaz+0Bfegcsx7l/3A0zA7cn+6OtwfOdW54az+nu3plvJF7zbTAO3vN3dWv4sqdzvQNocOT0jjEg27LufG/kEKbKNbXUYOJzFzYvoHBCsKKITAC3P9DKwDbzGb1YpVTLxmsV0L7hpNd9PcPZRkiqgpQcGv25L+jju0S0DDl5KrIHfyHAW7eZegSBiVnLGxLkR0IbsSpctaDcuxv2EmMv2mBNGPjolNwgWWd0w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=DbJxBly5TyryvPHM5vQVZjy9njGk9fxennF/bq0h/S8=; b=obsjUILeJyx3tedyCjXh8WB8lmZEIuqCh8EvNfi4O8EOgqx/w+4dpp8u5otApOV+GIK8Qwr7fsOGq6RQxPr4RH5rT0ZDlVCsXrzt9s21eZBwAUStd2gSzqRwmMI7xMu3WnT67S90n9lGRf3hDqYJUzrsdAIZNitVGdqz8nqhihI= Received: from AM0PR04MB4481.eurprd04.prod.outlook.com (52.135.147.15) by AM0PR04MB4786.eurprd04.prod.outlook.com (20.177.42.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2495.21; Wed, 4 Dec 2019 02:22:35 +0000 Received: from AM0PR04MB4481.eurprd04.prod.outlook.com ([fe80::f16d:a26a:840:f97c]) by AM0PR04MB4481.eurprd04.prod.outlook.com ([fe80::f16d:a26a:840:f97c%4]) with mapi id 15.20.2495.014; Wed, 4 Dec 2019 02:22:35 +0000 From: Peng Fan To: Shawn Guo CC: "sboyd@kernel.org" , "s.hauer@pengutronix.de" , "festevam@gmail.com" , Abel Vesa , "kernel@pengutronix.de" , dl-linux-imx , Aisheng Dong , "linux-clk@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , Leonard Crestez Subject: RE: [PATCH] clk: imx: pll14xx: fix clk_pll14xx_wait_lock Thread-Topic: [PATCH] clk: imx: pll14xx: fix clk_pll14xx_wait_lock Thread-Index: AQHVlGNoepC2TDBj7kaCYRyt+h3yD6epaaSAgAAAaIA= Date: Wed, 4 Dec 2019 02:22:34 +0000 Message-ID: References: <1573018178-14939-1-git-send-email-peng.fan@nxp.com> <20191204021908.GN9767@dragon> In-Reply-To: <20191204021908.GN9767@dragon> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=peng.fan@nxp.com; x-originating-ip: [119.31.174.71] x-ms-publictraffictype: Email x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: d01cdf88-d1a0-4354-54dd-08d77860d321 x-ms-traffictypediagnostic: AM0PR04MB4786:|AM0PR04MB4786: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:6108; x-forefront-prvs: 0241D5F98C x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(4636009)(376002)(346002)(136003)(366004)(396003)(39860400002)(189003)(199004)(6116002)(186003)(11346002)(3846002)(44832011)(446003)(52536014)(4326008)(7696005)(76176011)(6916009)(478600001)(14454004)(6506007)(8676002)(71190400001)(102836004)(71200400001)(25786009)(81166006)(81156014)(26005)(5660300002)(66476007)(2906002)(33656002)(66446008)(66556008)(64756008)(305945005)(66946007)(14444005)(86362001)(229853002)(55016002)(8936002)(9686003)(7736002)(256004)(74316002)(316002)(6246003)(99286004)(6436002)(54906003)(76116006);DIR:OUT;SFP:1101;SCL:1;SRVR:AM0PR04MB4786;H:AM0PR04MB4481.eurprd04.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: jB5wnzL9ifjnbHUL6Zt6wdNhFMZm0bMiZE3MWa4DY4O77bsEHBpS1bTSaXDBv1lyxbtFRVachYSlKMYlX4RL8fWPVbcsfK42Ih5jICJQP4kr2kelo3yuFnwtJAUManzeO6TpCtjkW95kT4ViPuVcDicXuFD4YAQKsERmXq3xiovx7L4pKe7Z+M/Txs45kQNaMzlKfi7nxNn4WIeYD3bUMKHuUskbkj4ZA2J+uYVrCwgrpGwjqM3bXWlOOdAMSoNFU5ldzlR0v6zmDkrL3wsr6DTcQ+RlkHzFt5e22lHnQy0dsCeyfbv2/Mc/H8/jZ9/BycCVgLyJs/D/uLZ/uzY7tI3QmQ/p/mm2ul1tHzEnb2Vg9rwESIEXn6yejFHN/+wfHZhbVC1mmR20BzhuGgpPrlHvK3CwYGJ6VCsreiqkaIwqrKS6+nZtslzoGgM99v3g Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: d01cdf88-d1a0-4354-54dd-08d77860d321 X-MS-Exchange-CrossTenant-originalarrivaltime: 04 Dec 2019 02:22:34.9645 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 8zHnylVv9WZUNY0q/sK3wRhd7h2v8lTLBn+vp/zliJm/83ROl3CcjjirzWvKZ7O+Co5Lm6pp75fWWYAu3do02Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR04MB4786 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Shawn, > Subject: Re: [PATCH] clk: imx: pll14xx: fix clk_pll14xx_wait_lock >=20 > On Wed, Nov 06, 2019 at 05:31:15AM +0000, Peng Fan wrote: > > From: Peng Fan > > > > The usage of readl_poll_timeout is wrong, the cond should be "val & > > LOCK_STATUS" not "val & LOCK_TIMEOUT_US". >=20 > Is this caught just by code inspection or a real world bug?=20 Code inspection. If you want this > get into -rc (and stable kernel) as a fix, you should add more informatio= n > about the bug, like how it's been triggered, what's the consequence of th= e > bug, and kernel dump message etc. >=20 > > > > Fixes: 8646d4dcc7fb ("clk: imx: Add PLLs driver for imx8mm soc") > > Signed-off-by: Peng Fan > > --- > > > > V1: > > Hi Shawn, > > This patch is made based on 5.4-rc6, not your for-next branch, >=20 > Please rebase it on 5.5-rc1 which will be coming next Monday. ok. I'll wait 5.5-rc1, then rebase and post v2. >=20 > > not sure whether this patch could catch 5.4 release. >=20 > You can Cc stable kernel, so that it will be back ported. ok. Thanks, Peng. >=20 > Shawn >=20 > > > > drivers/clk/imx/clk-pll14xx.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/clk/imx/clk-pll14xx.c > > b/drivers/clk/imx/clk-pll14xx.c index 7a815ec76aa5..d43b4a3c0de8 > > 100644 > > --- a/drivers/clk/imx/clk-pll14xx.c > > +++ b/drivers/clk/imx/clk-pll14xx.c > > @@ -153,7 +153,7 @@ static int clk_pll14xx_wait_lock(struct > > clk_pll14xx *pll) { > > u32 val; > > > > - return readl_poll_timeout(pll->base, val, val & LOCK_TIMEOUT_US, 0, > > + return readl_poll_timeout(pll->base, val, val & LOCK_STATUS, 0, > > LOCK_TIMEOUT_US); > > } > > > > -- > > 2.16.4 > >