Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

blocking required while iterating over process list #34

Closed
milabs opened this issue Jun 12, 2018 · 1 comment
Closed

blocking required while iterating over process list #34

milabs opened this issue Jun 12, 2018 · 1 comment

Comments

@milabs
Copy link

milabs commented Jun 12, 2018

for_each_process(p) {

rcu_read_lock()
for_each_process() { ... }
rcu_read_unlock()

Or:

read_lock(&tasklist_lock)
for_each_process() { ... }
read_unlock(&tasklist_lock)

Also get_task_struct() required for returning tasks.

See get_pid_task

@f0rb1dd3n
Copy link
Owner

fixed at:

rcu_read_lock();

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants