From: Harry Wentland <harry.wentland@amd.com>
To: "Christian König" <ckoenig.leichtzumerken@gmail.com>,
"James Flowers" <bold.zone2373@fastmail.com>,
sunpeng.li@amd.com, siqueira@igalia.com,
alexander.deucher@amd.com, christian.koenig@amd.com,
airlied@gmail.com, simona@ffwll.ch, aurabindo.pillai@amd.com,
alex.hung@amd.com, skhan@linuxfoundation.org
Cc: amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
linux-kernel-mentees@lists.linux.dev,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drm/amd/display: replace use of msleep(<20) with usleep_range for better accuracy
Date: Mon, 31 Mar 2025 14:20:53 -0400 [thread overview]
Message-ID: <81cac86c-dece-4f0d-abd7-efd888a08db0@amd.com> (raw)
In-Reply-To: <2a2e9a4c-b888-45e1-a191-847dd8e7cb9d@gmail.com>
On 2025-03-31 08:34, Christian König wrote:
> Am 26.03.25 um 08:00 schrieb James Flowers:
>> msleep < 20ms will often sleep for ~20ms (according to Documentation/timers/timers-howto.rst).
>
> Our display team has to decide but I don't think that this patch is justified.
>
> The time given to msleep is just the minimum time necessary for some HW action to take place. Waiting longer than that is usually not harmful except when you want to optimize total operation time.
>
Agreed. Little timing changes often have unintended effects.
I have no desire to change working code unless it's required
to fix a real-life issue.
Harry
> Regards,
> Christian.
>
>>
>> Signed-off-by: James Flowers <bold.zone2373@fastmail.com>
>> ---
>> drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c
>> index 2cd35392e2da..2d225735602b 100644
>> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c
>> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c
>> @@ -682,7 +682,7 @@ static bool execute_synaptics_rc_command(struct drm_dp_aux *aux,
>> if (rc_cmd == cmd)
>> // active is 0
>> break;
>> - msleep(10);
>> + usleep_range(10000, 10200);
>> }
>>
>> // read rc result
>
next prev parent reply other threads:[~2025-03-31 18:21 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-26 7:00 [PATCH] drm/amd/display: replace use of msleep(<20) with usleep_range for better accuracy James Flowers
2025-03-28 22:46 ` Shuah Khan
2025-03-29 6:54 ` James
2025-03-31 12:34 ` Christian König
2025-03-31 18:20 ` Harry Wentland [this message]
2025-04-01 4:23 ` James
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=81cac86c-dece-4f0d-abd7-efd888a08db0@amd.com \
--to=harry.wentland@amd.com \
--cc=airlied@gmail.com \
--cc=alex.hung@amd.com \
--cc=alexander.deucher@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=aurabindo.pillai@amd.com \
--cc=bold.zone2373@fastmail.com \
--cc=christian.koenig@amd.com \
--cc=ckoenig.leichtzumerken@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel-mentees@lists.linux.dev \
--cc=linux-kernel@vger.kernel.org \
--cc=simona@ffwll.ch \
--cc=siqueira@igalia.com \
--cc=skhan@linuxfoundation.org \
--cc=sunpeng.li@amd.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox