On 1/24/24 2:28 AM, Christoph Hellwig wrote: > On Tue, Jan 23, 2024 at 10:30:34AM -0700, Jens Axboe wrote: >> Convert any user of ktime_get_ns() to use blk_time_get_ns(), and >> ktime_get() to blk_time_get(), so we have a unified API for querying the >> current time in nanoseconds or as ktime. >> >> No functional changes intended, this patch just wraps ktime_get_ns() >> and ktime_get() with a block helper. > > Given that the helper only is (and only should be) used in the > block layer code, any reason not to keep it private in block/ ? I did originally put it in there, but you then run into dependency issues with needing the struct definitions too, eg for struct blk_plug. Hence not sure it makes sense, even if logically it'd fit better there. -- Jens Axboe