lkml.org 
[lkml]   [2023]   [May]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH v2 2/2] iopoll: Do not use timekeeping in read_poll_timeout_atomic()
    Hi,

    * Geert Uytterhoeven <geert+renesas@glider.be> [230510 13:23]:
    > read_poll_timeout_atomic() uses ktime_get() to implement the timeout
    > feature, just like its non-atomic counterpart. However, there are
    > several issues with this, due to its use in atomic contexts:
    >
    > 1. When called in the s2ram path (as typically done by clock or PM
    > domain drivers), timekeeping may be suspended, triggering the
    > WARN_ON(timekeeping_suspended) in ktime_get():

    Maybe add a comment to read_poll_timeout_atomic() saying it can be
    used also with timekeeping_suspended?

    Otherwise a few years later it might get broken when somebody goes
    to patch it without testing it with timekeeping_suspended :)

    Other than that looks good to me:

    Reviewed-by: Tony Lindgren <tony@atomide.com>

    \
     
     \ /
      Last update: 2023-05-11 08:48    [W:7.053 / U:0.304 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site