Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp20243pxb; Wed, 30 Mar 2022 21:42:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyRyLWHQeiNmfCq9w37DTV0v2GRpTKe0Iv+2tcA+AOrRbVqtG2lhWt1KPE+ZatqY9Fn+dAs X-Received: by 2002:a17:902:e74f:b0:154:6052:55b2 with SMTP id p15-20020a170902e74f00b00154605255b2mr3179442plf.106.1648701739871; Wed, 30 Mar 2022 21:42:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648701739; cv=none; d=google.com; s=arc-20160816; b=TsVHwJ19MYs1NRbpL1gd+K/0OwavdyV7ASeXNxspPa/bNfiezIpG7aDTswL1VAiZel kaOyRn3UYvBxwRjVU22rCQrTAJQGMUL67frxA5WsOEL9qaFS7Su1FjWOYbHYLnfuVN1m KtscZoH7aWkAT/UBubeYDSptrpH0jhebBn1L6UyJcPClfI46xVg4v/Xy8YoVKY2a/0Oi E+XEUNKeGRHzb8o9rCQOzScdTBBG4RLwDM/Fqn9RXKD3LwJBTN7g6Mk12rt9ZbCVnP+S UjPRnVeuQCfekBRy3mS15svyArFKwWqXM9t4e793Wna7lMYZxMF4rajOPAohwxfB9H3n Y5Lw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=q/TKDSGPWiR5sjyWXgzan7M3cRBG/ZwgmVrCHxx0MAo=; b=ESCELD3PUYJqhheL/aw9T68F7qjArk77BChlcIl5SAP8b+ycT9vrmpaLuN8P8QOQFu 83OBUYVl/X4m8DnRKKhP3L9PcFY5GCXCgyX4jiDFhAO5JJyicLBC7Gv0x13y+Cs1OXuK hREUQi24+QJb9dc4V3LIYW1fel/5or6MDHs5ISElYgxbGmc9YF86LXhS6+cqMMT6EVYJ tCZQSWs8gXyUAOlROvhBU9k6G0459sWJn/evrDJhg8uqA7oGsqbEeuGshYfk+1fXIFEH tAn6iCmtZQV2ugSzboVLQkIUnPLtZZ4ir9uDPze9sSWvn7+wW3y10oXmDtHXxQwoNNuu Xq5w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=TVSCUvG6; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id g20-20020a170902869400b00153b2d164aasi22164806plo.178.2022.03.30.21.42.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 30 Mar 2022 21:42:19 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=TVSCUvG6; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id D302A261317; Wed, 30 Mar 2022 20:38:35 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1351814AbiC3XbM (ORCPT + 99 others); Wed, 30 Mar 2022 19:31:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54838 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347974AbiC3XbK (ORCPT ); Wed, 30 Mar 2022 19:31:10 -0400 Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [46.235.227.227]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 07B8327B28 for ; Wed, 30 Mar 2022 16:29:24 -0700 (PDT) Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: nfraprado) with ESMTPSA id EBAFA1F46057 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1648682962; bh=2Aw59J1GMFNx5W0R3ALTAtEuLxi4M5bwfjRhWuhb7CI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=TVSCUvG6BhBxf3w4gp8U+feiK3EkK70kObxUTlaxb2xQVluRaXmi/y/hLQ339geZ1 QqYcTFAAsY/lVTIL/sdmD1W3y0Mp3zj4+VfKvtij9HBU8061fpkCFIixRD+QjAQu4S N1KDDEdg44pTf73esJyoqXXepcu0i/anBeuYsrYgXVZ6o844Dy6zNXTx+RwmQiAcTS DJi4iMlzN4gIoOtBvTtStVOOrmiFXwNWu6efyM23eECPNumpcreR87W+2bJs8ks4rd 4X9m+85LRJpClzB44uaiuFwNFCbmEBsU2oRblsgP0IscHw5pl2i1zILhjheOSfNMCe OwxccEyp5um6g== Date: Wed, 30 Mar 2022 19:29:17 -0400 From: =?utf-8?B?TsOtY29sYXMgRi4gUi4gQS4=?= Prado To: AngeloGioacchino Del Regno Cc: matthias.bgg@gmail.com, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/3] soc: mediatek: pwrap: Use readx_poll_timeout() instead of custom function Message-ID: <20220330232917.uu7337hv6dqh34xv@notapiano> References: <20220329152245.124341-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20220329152245.124341-1-angelogioacchino.delregno@collabora.com> X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE, UNPARSEABLE_RELAY autolearn=no 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 Hi Angelo, On Tue, Mar 29, 2022 at 05:22:43PM +0200, AngeloGioacchino Del Regno wrote: > @@ -1303,7 +1297,8 @@ static int pwrap_read32(struct pmic_wrapper *wrp, u32 adr, u32 *rdata) > pwrap_writel(wrp, ((msb << 30) | (adr << 16)), > PWRAP_WACS2_CMD); > > - ret = pwrap_wait_for_state(wrp, pwrap_is_fsm_vldclr); > + ret = readx_poll_timeout(pwrap_is_fsm_idle, wrp, tmp, tmp, Should be pwrap_is_fsm_vldclr. Thanks, N?colas > + PWRAP_POLL_DELAY_US, PWRAP_POLL_TIMEOUT_US); > if (ret) > return ret; >