Re: [PATCH v3 5/5] sched_ext: Replace bpf_ktime_get_ns() to scx_bpf_clock_get_ns()

From: Changwoo Min
Date: Wed Dec 04 2024 - 00:41:32 EST


Hello,

On 24. 12. 4. 08:40, Tejun Heo wrote:
On Tue, Dec 03, 2024 at 11:28:02PM +0900, Changwoo Min wrote:
@@ -245,7 +245,7 @@ void BPF_STRUCT_OPS(central_running, struct task_struct *p)
s32 cpu = scx_bpf_task_cpu(p);
u64 *started_at = ARRAY_ELEM_PTR(cpu_started_at, cpu, nr_cpu_ids);
if (started_at)
- *started_at = bpf_ktime_get_ns() ?: 1; /* 0 indicates idle */
+ *started_at = scx_bpf_clock_get_ns() ?: 1; /* 0 indicates idle */

Not from this commit, but how about scx_bpf_now_ns() for the name?

Thanks.


That sounds good. I will change the function name in the next version.

Regards,
Changwoo Min