Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp766814rwl; Fri, 31 Mar 2023 02:00:10 -0700 (PDT) X-Google-Smtp-Source: AK7set8ckBcjJX/8xz3qKRmamFh2bo36oXtPG+/4pODzrOzjzxcmQvXFKgk3TFeOHzbJEiBsPt1q X-Received: by 2002:a05:6a20:7da6:b0:d9:3de:541e with SMTP id v38-20020a056a207da600b000d903de541emr23508879pzj.6.1680253209660; Fri, 31 Mar 2023 02:00:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680253209; cv=none; d=google.com; s=arc-20160816; b=dc7y8/SKLMVy5+nHgd5Q2nWDi/sA3zoNDpPnjCLIHvTIiFkgkEOtDFWdErjqy6J4SI WNbhxqIw6Xmic5ewH75fxH0zlGtAYhkRU5mP/e40gHKGmwng8oyW+FgKgGUUQFVwFLrG ihAn/rhPQSTb7wLS5Nx2HXyetHvQjJn9Cxb9Y+kyE2vlLld9aaYl459MT43WUfsms7II LU3V/q1MJF3pYyYhwCXgMLib+kwKuWSyojhkc2bEun53G8SYtW/7L7pHAlREP5B+tNRn DWU9mnfk/ifp8C5VmtVUOmMDYf6qqGCI4mLrUj2+v2k2Q4mpMQ7ES+H8PYWaYqfF/IxS w4yA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=P7mIGFgNyYE5uGkfP0nPrR/RJNf7URueYiHpyg/dgpo=; b=GMTZrtTMOPKFJOUj5FVJSJWu46NZGRHSf32fQtJKybtkev9srP5c9vrPdltSkxoVyw Cq1hTeu7q/3/+Gb32LOeJx0/0whs6tJZKLa9Qdamlnq8S5myrB5pmWOkenm5CroA/yft QmnS0jDFOXtskw2JjXR9GEZuCq1eENOhahUO90kEkd4PM0XFXnEGVWr4L8QPNu87tKbv AaB0mqBGa9SbBvV7ed1gBUzgyACyacciDmmtQbkOY+87x0TVw6Pub5gXZnpL0mGdait1 UXF7/ydq52skBWfufBDAq8wZ/L/bu3/gUUw+y1GqC75h4hb1lL1eF0rkOAVeVd1BBDv+ h9lg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ZCTbpWPM; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b7-20020a656687000000b0050be5c0b5d6si1830290pgw.617.2023.03.31.01.59.57; Fri, 31 Mar 2023 02:00:09 -0700 (PDT) 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=@kernel.org header.s=k20201202 header.b=ZCTbpWPM; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230491AbjCaIsp (ORCPT + 99 others); Fri, 31 Mar 2023 04:48:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53294 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229441AbjCaIso (ORCPT ); Fri, 31 Mar 2023 04:48:44 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4FBBF5BAD for ; Fri, 31 Mar 2023 01:48:43 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id DFE5EB82D5A for ; Fri, 31 Mar 2023 08:48:41 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 92128C433A0 for ; Fri, 31 Mar 2023 08:48:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1680252520; bh=uOPIzovJQaN2uF3uCRFfcTfMui228WfnHJ8oPe20zeQ=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=ZCTbpWPMhYqpd++CTJoOKG+UybwN/OuqSGHgGJgjGO/4eJ1Cy4ofOmSB1IjLXjIm1 oxTAid3k44j4vdfVOw22nT4C3SI7a4WtOwNgmHOpDho/mzdFPdQGfxBIfEndtSQSIg xFnhT6PZpCHV0U6lrY4uBcoYqsq3+WutRhNyl7QXfBLoprcjEzT/0dvBC61ugS5fP2 vF+a8xUxC+yU5hCk4VFC8Kgct7635ohqqbbwOvobnYhPa907srZs3WzzUhwsxMmduP LVv1fX9FBc8u7E8YyVbPLNTO9JmtHXHqZKmdUe/MACGtGaVIkCTWG4Bt1elvVKLKeO lSyqVmpl8Jo7g== Received: by mail-pg1-f182.google.com with SMTP id d8so12986650pgm.3 for ; Fri, 31 Mar 2023 01:48:40 -0700 (PDT) X-Gm-Message-State: AAQBX9fRzp9IfzLtpfJngwnC9BgJPm7SZOudRLt5hJ/8zKNFuCBckkci tleSJ+0TW0QLtuiU2SMqDdmmbmqGe8Th8+OvsVZdFg== X-Received: by 2002:a63:dd0f:0:b0:4fc:a80e:e6ec with SMTP id t15-20020a63dd0f000000b004fca80ee6ecmr7342372pgg.5.1680252520141; Fri, 31 Mar 2023 01:48:40 -0700 (PDT) MIME-Version: 1.0 References: <20230331030204.1179524-1-treapking@chromium.org> In-Reply-To: <20230331030204.1179524-1-treapking@chromium.org> From: Robert Foss Date: Fri, 31 Mar 2023 10:48:29 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] drm/bridge: ps8640: Use constant sleep time for polling hpd To: Pin-yen Lin Cc: Douglas Anderson , Andrzej Hajda , Neil Armstrong , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-5.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable 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 On Fri, Mar 31, 2023 at 5:02=E2=80=AFAM Pin-yen Lin wrote: > > The default hpd_wait_us in panel_edp.c is 2 seconds. This makes the > sleep time in the polling of _ps8640_wait_hpd_asserted become 200ms. > Change it to a constant 20ms to speed up the function. > > Signed-off-by: Pin-yen Lin > --- > > drivers/gpu/drm/bridge/parade-ps8640.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/bridge/parade-ps8640.c b/drivers/gpu/drm/bri= dge/parade-ps8640.c > index b823e55650b1..c3eb45179405 100644 > --- a/drivers/gpu/drm/bridge/parade-ps8640.c > +++ b/drivers/gpu/drm/bridge/parade-ps8640.c > @@ -184,7 +184,7 @@ static int _ps8640_wait_hpd_asserted(struct ps8640 *p= s_bridge, unsigned long wai > * actually connected to GPIO9). > */ > ret =3D regmap_read_poll_timeout(map, PAGE2_GPIO_H, status, > - status & PS_GPIO9, wait_us / 10, w= ait_us); > + status & PS_GPIO9, 20000, wait_us)= ; > > /* > * The first time we see HPD go high after a reset we delay an ex= tra > -- > 2.40.0.348.gf938b09366-goog > Snoozing for a few days before applying. Reviewed-by: Robert Foss