Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8d9330cf authored by Package Warehouse Build User's avatar Package Warehouse Build User Committed by Gerrit - the friendly Code Review server
Browse files

Merge "dma-buf: skip fd iteration for threads created with CLONE_FILES" into msm-4.14

parents 252d57a6 840c1159
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -1393,6 +1393,8 @@ static int dma_procs_debug_show(struct seq_file *s, void *unused)

	read_lock(&tasklist_lock);
	for_each_process(task) {
		struct files_struct *group_leader_files = NULL;

		tmp = kzalloc(sizeof(*tmp), GFP_ATOMIC);
		if (!tmp) {
			ret = -ENOMEM;
@@ -1402,8 +1404,11 @@ static int dma_procs_debug_show(struct seq_file *s, void *unused)
		INIT_LIST_HEAD(&tmp->dma_bufs);
		for_each_thread(task, thread) {
			task_lock(thread);
			if (unlikely(!group_leader_files))
				group_leader_files = task->group_leader->files;
			files = thread->files;
			if (files)
			if (files && (group_leader_files != files ||
				      thread == task->group_leader))
				ret = iterate_fd(files, 0, get_dma_info, tmp);
			task_unlock(thread);
		}