🎈 perf: perf rt_hw_interrupt_disable/enable (#8042)

Signed-off-by: Shell <smokewood@qq.com>
Co-authored-by: Shell <smokewood@qq.com>
This commit is contained in:
xqyjlj
2023-10-25 20:31:25 +08:00
committed by GitHub
parent 91fc52df36
commit 3283f54c7a
80 changed files with 2478 additions and 1962 deletions

View File

@@ -800,11 +800,13 @@ struct dfs_fdtable *dfs_fdtable_get_pid(int pid)
struct rt_lwp *lwp = RT_NULL;
struct dfs_fdtable *fdt = RT_NULL;
lwp = lwp_from_pid(pid);
lwp_pid_lock_take();
lwp = lwp_from_pid_locked(pid);
if (lwp)
{
fdt = &lwp->fdt;
}
lwp_pid_lock_release();
return fdt;
}

View File

@@ -401,11 +401,13 @@ struct dfs_fdtable *dfs_fdtable_get_pid(int pid)
struct rt_lwp *lwp = RT_NULL;
struct dfs_fdtable *fdt = RT_NULL;
lwp = lwp_from_pid(pid);
lwp_pid_lock_take();
lwp = lwp_from_pid_locked(pid);
if (lwp)
{
fdt = &lwp->fdt;
}
lwp_pid_lock_release();
return fdt;
}