linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] cgroup, netclassid: remove double cond_resched
@ 2020-04-20  7:04 Jiri Slaby
  2020-04-21 22:44 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Jiri Slaby @ 2020-04-20  7:04 UTC (permalink / raw)
  To: davem
  Cc: kuba, netdev, linux-kernel, Jiri Slaby, Dmitry Yakunin,
	Konstantin Khlebnikov

Commit 018d26fcd12a ("cgroup, netclassid: periodically release file_lock
on classid") added a second cond_resched to write_classid indirectly by
update_classid_task. Remove the one in write_classid.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Dmitry Yakunin <zeil@yandex-team.ru>
Cc: Konstantin Khlebnikov <khlebnikov@yandex-team.ru>
Cc: David S. Miller <davem@davemloft.net>
---
 net/core/netclassid_cgroup.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/net/core/netclassid_cgroup.c b/net/core/netclassid_cgroup.c
index b4c87fe31be2..41b24cd31562 100644
--- a/net/core/netclassid_cgroup.c
+++ b/net/core/netclassid_cgroup.c
@@ -127,10 +127,8 @@ static int write_classid(struct cgroup_subsys_state *css, struct cftype *cft,
 	cs->classid = (u32)value;
 
 	css_task_iter_start(css, 0, &it);
-	while ((p = css_task_iter_next(&it))) {
+	while ((p = css_task_iter_next(&it)))
 		update_classid_task(p, cs->classid);
-		cond_resched();
-	}
 	css_task_iter_end(&it);
 
 	return 0;
-- 
2.26.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] cgroup, netclassid: remove double cond_resched
  2020-04-20  7:04 [PATCH] cgroup, netclassid: remove double cond_resched Jiri Slaby
@ 2020-04-21 22:44 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2020-04-21 22:44 UTC (permalink / raw)
  To: jslaby; +Cc: kuba, netdev, linux-kernel, zeil, khlebnikov

From: Jiri Slaby <jslaby@suse.cz>
Date: Mon, 20 Apr 2020 09:04:24 +0200

> Commit 018d26fcd12a ("cgroup, netclassid: periodically release file_lock
> on classid") added a second cond_resched to write_classid indirectly by
> update_classid_task. Remove the one in write_classid.
> 
> Signed-off-by: Jiri Slaby <jslaby@suse.cz>

Applied, thanks Jiri.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-04-21 22:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-20  7:04 [PATCH] cgroup, netclassid: remove double cond_resched Jiri Slaby
2020-04-21 22:44 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).