Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B9F4EEB64DC for ; Sat, 15 Jul 2023 12:30:21 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4ED7D8565A; Sat, 15 Jul 2023 14:30:19 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=xs4all.nl Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; secure) header.d=xs4all.nl header.i=@xs4all.nl header.b="KV6OrLZR"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 6F2068565A; Sat, 15 Jul 2023 14:30:18 +0200 (CEST) Received: from ewsoutbound.kpnmail.nl (ewsoutbound.kpnmail.nl [195.121.94.184]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 29410846EE for ; Sat, 15 Jul 2023 14:30:16 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=xs4all.nl Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=mark.kettenis@xs4all.nl X-KPN-MessageId: 14b25531-230b-11ee-ac30-005056994fde Received: from smtp.kpnmail.nl (unknown [10.31.155.5]) by ewsoutbound.so.kpn.org (Halon) with ESMTPS id 14b25531-230b-11ee-ac30-005056994fde; Sat, 15 Jul 2023 14:28:19 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=xs4all01; h=subject:to:from:message-id:date; bh=xuAqzOMKe5/J52dkfFj3YyJ4yhJr36Tip1v0sd1BQZo=; b=KV6OrLZR6wti+yG8uoPFU0aQGM5rCSrFjG+5RC20lA9dZDqdA//Kj4wqCoRwn79tehi1/Wy2PHz7D ClaS2Ugm1+oRgAF7VS5lSVhkEH758sVhaK51WOv5FHviFGitt15m955FaXRGcdxvQAch0/TeZgRHdz /FbmlU5Xbk3HuqMB/flBxgrkuyDvFWtYWZ0nl3Ks+A9i2ilAOLTgBc/sGtdkOuaRbEg+pJiDRp0m13 E/9apDXSoqHvObDKNreEMJQwpZBPS0mFcQmKj6rQo0TkMFLbwrJmORovdvc97XggvbzcXO+ksB1lE0 e5pECXfU5ywfcj+IujYFN3bfulePycQ== X-KPN-MID: 33|IPdyYyPptZEhkMe8xrfemb9Dtfb2tL8Yz1jOaXGc1xp+NUAhMdooEKpCHH67p19 5l1oIvayrmru9kpmMnQ3/dHnLCOuEa1L3/yr1UUZEzfQ= X-KPN-VerifiedSender: Yes X-CMASSUN: 33|vAdYAFNGCfdCGmXab3a+7Wqs+hPhULjXIqQM9+vMFWpQx/zKP7SMctQqVCDjU3t JSx4+Z2iCEjEZg2eRHioYIQ== X-Originating-IP: 80.61.163.207 Received: from bloch.sibelius.xs4all.nl (80-61-163-207.fixed.kpn.net [80.61.163.207]) by smtp.xs4all.nl (Halon) with ESMTPSA id 5972ef2c-230b-11ee-aef8-00505699b758; Sat, 15 Jul 2023 14:30:15 +0200 (CEST) Date: Sat, 15 Jul 2023 14:30:14 +0200 Message-Id: <87351ppdbd.fsf@bloch.sibelius.xs4all.nl> From: Mark Kettenis To: Marek Vasut Cc: kettenis@openbsd.org, u-boot@lists.denx.de, bmeng.cn@gmail.com In-Reply-To: <9b8f7ebd-fdf2-fc12-a881-f00aab9d9344@denx.de> (message from Marek Vasut on Fri, 14 Jul 2023 23:22:00 +0200) Subject: Re: [PATCH 2/3] iopoll: Add readb_poll_sleep_timeout References: <20230714204323.27220-1-kettenis@openbsd.org> <20230714204323.27220-3-kettenis@openbsd.org> <9b8f7ebd-fdf2-fc12-a881-f00aab9d9344@denx.de> X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean > Date: Fri, 14 Jul 2023 23:22:00 +0200 > From: Marek Vasut > > On 7/14/23 22:43, Mark Kettenis wrote: > > Add a variant of readl_poll_sleep_timeout that reads a single > > byte to match the readb_poll_timeout API that Linux has. > > > > Signed-off-by: Mark Kettenis > > --- > > include/linux/iopoll.h | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/include/linux/iopoll.h b/include/linux/iopoll.h > > index 0ee2bddaa8..89990e95e9 100644 > > --- a/include/linux/iopoll.h > > +++ b/include/linux/iopoll.h > > @@ -49,6 +49,9 @@ > > #define readl_poll_sleep_timeout(addr, val, cond, sleep_us, timeout_us) \ > > readx_poll_sleep_timeout(readl, addr, val, cond, sleep_us, timeout_us) > > > > +#define readb_poll_sleep_timeout(addr, val, cond, sleep_us, timeout_us) \ > > + readx_poll_sleep_timeout(readb, addr, val, cond, sleep_us, timeout_us) > > readb variant should go before readl variant I think. That makes to order consistent, so that makes sense. I'll fix that in the next revision.