나는 리눅스 커널에 대해 공부에서 "현재"무엇이며, 전류 -> 파일이 나는는 리눅스 커널 소스
내가 많은 리눅스 커널 소스 파일을 볼 문제가 있습니다. 그래서 "현재"는 무엇입니까?
struct file *fget(unsigned int fd)
{
struct file *file;
struct files_struct *files = current->files;
rcu_read_lock();
file = fcheck_files(files, fd);
if (file) {
/* File object ref couldn't be taken */
if (file->f_mode & FMODE_PATH ||
!atomic_long_inc_not_zero(&file->f_count))
file = NULL;
}
rcu_read_unlock();
return file;
}
예? 'current'는 정말로 일반적인 변수 이름입니다. – nneonneo