Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3530093pxv; Mon, 19 Jul 2021 02:28:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw4XO/dtIGQ3x/4Z8bRTL7uS55rOgd4zEhBFhyDl3GkhO+hjWBGMm6ncV8kBF4naHD36Fdx X-Received: by 2002:a17:907:1b1b:: with SMTP id mp27mr25869905ejc.538.1626686891401; Mon, 19 Jul 2021 02:28:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626686891; cv=none; d=google.com; s=arc-20160816; b=e3FfUpakObzSNQoIPYi785VzdzkOHMDAKxuoK4DwTcxSXhaSpQbMi07WMY7OfHWv07 7MzjokPBon0lLefep6PiPJvx0RORojNeQkimN5VI8SNIG8pFv/CwlmBNRC4Dcc+X71vj YmKGNsB/waprm+sRrT+TfBuLKTcAtlrcMGb04XtxWTrP08O/HxIwZrJk8tq6uO4LyDHM Qlvrm+yTHLEQNTeEb4iMAiEhFopTVIbaGRLiNtRkiBx2mpIvTxiKU/3MSCVBdXAzqHYh WPBoIiLCgMBRRCe8wpFdSP2h4HL1fBpvRCrFMRGperBJVl9t2kjQE/Y1XuSpt3ozUOGm zuwA== 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=KfeoXYA6FAtVnL9pqwpm6Rlfaw4SHNyLHqSR71j5cS8=; b=BQEkGl4Cf+FI4wHMjlz6OM2Ay64CHhuj7rwg6eYwV1akFb58+HxIC6Mh3Xr7oaGeJ+ VkF05E0ikW/7sZew/kZK4W+87l0uuegILBd1wGiilXhb139Rm+c+Y1cuJIMNHjHTG1XB oRNcYS/Ryy7wniQaHPd270I4KKgHIK85/+ndKd3SkeY/gsiCMz4Xf7dbpofOqcdRpYB8 pJo/nkMPOiGaJBwLA6gEgOsN4Y0spd/6ap5oPslQgAIaC10KuE128qHc5Cx2LTbfw8mk tapberea58IH98xl99niN9mSRfObD18sLlVBcvPPtzzzs4sNSAyBSXXJhjHg7J4u3goT KOsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="O+zM/7TQ"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id gj23si2125253ejb.535.2021.07.19.02.27.48; Mon, 19 Jul 2021 02:28:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="O+zM/7TQ"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235832AbhGSIqB (ORCPT + 99 others); Mon, 19 Jul 2021 04:46:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34176 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235404AbhGSIpq (ORCPT ); Mon, 19 Jul 2021 04:45:46 -0400 Received: from mail-qk1-x731.google.com (mail-qk1-x731.google.com [IPv6:2607:f8b0:4864:20::731]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8A927C061574; Mon, 19 Jul 2021 01:27:34 -0700 (PDT) Received: by mail-qk1-x731.google.com with SMTP id q15so2462876qkm.8; Mon, 19 Jul 2021 02:26:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=KfeoXYA6FAtVnL9pqwpm6Rlfaw4SHNyLHqSR71j5cS8=; b=O+zM/7TQrw2PWROfcV5KenDe+huC/6iTcCfC7TZoCS2FAccbYtdUrHL7RvR8wCPXpv Iy8pW6YMY3xpX0kDdxQ4AEjKaXW7kCp8YTrjD0IvsUbMMZtg6HrH6NAnOHs88lpPifTO F4mD6j3TikLJ0Y9+ZNUtywj6MG5vzLfm8hw7x7bEymZUgwOuawoshGDXrc94jwOnTz/b za2bbIlgd0cGzDsqRhOlnOIqnYuc6SaFWpNqCs19pHaj+/DFeJYv1pz/sWSgtuoAVza9 /Y5JMkySAYSAe83r6bHAM3CQvp9qm+uQPm9TSvHjqz2Go4BVFbnlH35+P9qHIplKrIV/ 6oSw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=KfeoXYA6FAtVnL9pqwpm6Rlfaw4SHNyLHqSR71j5cS8=; b=Ah6WXzo6iT/pGh7euCANqUOC3TiwiNYCxdK5Nof+wdOcHA8EjI1Zx6dpFYG+xhoU++ pSwUB2ow3NpXO+pTbs36MqOeS4D6t9HOi8LChyWu0DJS9CzvaAzXE0rPGEURlvix1i7A QI9EVPXRum4YtkYRS6hofT8C0vYfF6NuK91GERpnLmDCfkjPxOsw6UXmSUZ4B2yDL6Mz 6qBCYFM8uBYZCZY65hy+M2r3bJiEq5CzCd51rGbycprUN3ExdTfSVJxwyo5i35rqHoNI anMamZ2rJG2Rx/JSQITxIXmCTj+oPSZuwsyeycyiw6KvzeaOTBXJ/hpS+uprfZZMhgdL RYbw== X-Gm-Message-State: AOAM531gVfocDbf82qhCsH74Fv+5sY2T6mDy1WSxtN851cXHFIcccRZ+ MPbTAG1B9oNalVUnGlm+8tODMYNlexspH1CAp2Y= X-Received: by 2002:a37:5646:: with SMTP id k67mr22482354qkb.309.1626686785944; Mon, 19 Jul 2021 02:26:25 -0700 (PDT) MIME-Version: 1.0 References: <20210705090050.15077-1-reniuschengl@gmail.com> <02c26834-f16e-e1c7-9ea9-36414d1c4403@intel.com> In-Reply-To: <02c26834-f16e-e1c7-9ea9-36414d1c4403@intel.com> From: Renius Chen Date: Mon, 19 Jul 2021 17:26:14 +0800 Message-ID: Subject: Re: [PATCH] [v2] mmc: sdhci-pci-gli: Improve Random 4K Read Performance of GL9763E To: Adrian Hunter Cc: Ulf Hansson , linux-mmc , Linux Kernel Mailing List , Ben Chuang Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Adrian Hunter =E6=96=BC 2021=E5=B9=B47=E6=9C=8816= =E6=97=A5 =E9=80=B1=E4=BA=94 =E4=B8=8B=E5=8D=886:27=E5=AF=AB=E9=81=93=EF=BC= =9A > > On 14/07/21 5:15 am, Renius Chen wrote: > > Hi Adrain, > > > > What do you think of this patch? > > Or do you have any ideas or suggestions about the modification for > > Ulf's comments? > > Perhaps try to define your power management requirements in terms of > latencies instead of request size, and then take the issue to the > power management mailing list and power management maintainers for > suggestions. You will probably need to point out why runtime PM doesn't > met your requirements. > Hi Adrain, Thanks for your advice. Our purpose is only to improve the performance of 4K reads, and we hope that it doesn't affect any other use cases. If we look into the latencies, it may affect not only 4K reads but also some other use cases. Behaviors of ASPM is controlled by circuits of hardware. Drivers only enable or disable ASPM or set some parameters for ASPM, and are not able to know when the device enters or exits the L0s/L1 state. So the PM part of drivers may not suit this case. This patch could be simply divided into two parts: 1. Monitor requests. 2. Set a vendor specific register of GL9763e. The part 2 is no problems we think. And Ulf thinks that the behaviors of part 1 should not be implemented in sdhci-pci-gli.c. Do you have any suggestions on where we can implement the monitoring? Thank you. Best regards, Renius > > > > Thank you. > > > > > > Best regards, > > > > Renius > > > > Renius Chen =E6=96=BC 2021=E5=B9=B47=E6=9C=887= =E6=97=A5 =E9=80=B1=E4=B8=89 =E4=B8=8B=E5=8D=889:49=E5=AF=AB=E9=81=93=EF=BC= =9A > >> > >> Ulf Hansson =E6=96=BC 2021=E5=B9=B47=E6=9C=88= 7=E6=97=A5 =E9=80=B1=E4=B8=89 =E4=B8=8B=E5=8D=888:16=E5=AF=AB=E9=81=93=EF= =BC=9A > >>> > >>> [...] > >>> > >>>> > >>>> Thanks, I understand what you mean. > >>>> > >>>> I simply searched for the keyword "MMC_READ_MULTIPLE_BLOCK" in the > >>>> drivers/mmc/host folder, and found that in some SD/MMC host controll= er > >>>> driver codes such as alcor.c, cavium.c, ...etc, there are also > >>>> behaviors for monitoring the request in their driver. What's the > >>>> difference between theirs and ours? > >>> > >>> Those checks are there to allow the HWs to be supported properly. > >>> > >>>> > >>>> And if the code that monitors the requstes does not belong the drive= r, > >>>> where should I implement the code and how to add some functions only > >>>> for GL9763e in that place, in your opinion? > >>> > >>> Honestly, I am not sure what suits your use case best. > >>> > >>> So far we have used runtime PM with a default auto suspend timeout, i= n > >>> combination with dev PM Qos. In other words, run as fast as possible > >>> to complete the requests in the queue then go back to idle and enter = a > >>> low power state. Clearly, that seems not to be sufficient for your us= e > >>> case, sorry. > >>> > >> Yes, the runtime PM, auto suspend, and PM Qos are all about the > >> suspend/resume behaviors of the system or related to power states such > >> as D0/D3 of the device. But these are totally different from the ASPM > >> L0s/L1 for link states. Entering/exiting the ASPM is pure hardware > >> behavior on the link layer and is not handled by any codes in > >> drivers/mmc/core or drivers/mmc/host. We'd like to try to modify the > >> patch by your opinions, but we are also confused about what or where > >> suits our use case best. So we wonder how to start the modification > >> and may need some suggestions to deal with the work, sorry. > >> > >> Thank you. > >> > >> > >> Best regards, > >> > >> Renius > >> > >> > >>> Kind regards > >>> Uffe >