* [PATCH] sched: remove noop function task_fork_dl
@ 2019-11-27 17:03 Tom Rix
2019-11-29 7:13 ` Ingo Molnar
0 siblings, 1 reply; 2+ messages in thread
From: Tom Rix @ 2019-11-27 17:03 UTC (permalink / raw)
To: mingo, peterz, juri.lelli, vincent.guittot, dietmar.eggemann,
dietmar.eggemann, bsegall, mgorman, linux-kernel
task_fork_dl is an empty function used only for dl's
sched_class.task_fork. Removing it cleans up the code a bit
and saves a function call in sched_fork.
Signed-off-by: Tom Rix <trix@redhat.com>
---
kernel/sched/deadline.c | 10 ----------
1 file changed, 10 deletions(-)
diff --git a/kernel/sched/deadline.c b/kernel/sched/deadline.c
index a8a08030a8f7..fbafd97d883a 100644
--- a/kernel/sched/deadline.c
+++ b/kernel/sched/deadline.c
@@ -1821,14 +1821,6 @@ static void task_tick_dl(struct rq *rq, struct task_struct *p, int queued)
start_hrtick_dl(rq, p);
}
-static void task_fork_dl(struct task_struct *p)
-{
- /*
- * SCHED_DEADLINE tasks cannot fork and this is achieved through
- * sched_fork()
- */
-}
-
#ifdef CONFIG_SMP
/* Only try algorithms three times */
@@ -2451,8 +2443,6 @@ const struct sched_class dl_sched_class = {
#endif
.task_tick = task_tick_dl,
- .task_fork = task_fork_dl,
-
.prio_changed = prio_changed_dl,
.switched_from = switched_from_dl,
.switched_to = switched_to_dl,
--
2.23.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] sched: remove noop function task_fork_dl
2019-11-27 17:03 [PATCH] sched: remove noop function task_fork_dl Tom Rix
@ 2019-11-29 7:13 ` Ingo Molnar
0 siblings, 0 replies; 2+ messages in thread
From: Ingo Molnar @ 2019-11-29 7:13 UTC (permalink / raw)
To: Tom Rix
Cc: mingo, peterz, juri.lelli, vincent.guittot, dietmar.eggemann,
bsegall, mgorman, linux-kernel
* Tom Rix <trix@redhat.com> wrote:
>
> task_fork_dl is an empty function used only for dl's
> sched_class.task_fork. Removing it cleans up the code a bit
> and saves a function call in sched_fork.
>
> Signed-off-by: Tom Rix <trix@redhat.com>
> ---
> kernel/sched/deadline.c | 10 ----------
> 1 file changed, 10 deletions(-)
>
> diff --git a/kernel/sched/deadline.c b/kernel/sched/deadline.c
> index a8a08030a8f7..fbafd97d883a 100644
> --- a/kernel/sched/deadline.c
> +++ b/kernel/sched/deadline.c
> @@ -1821,14 +1821,6 @@ static void task_tick_dl(struct rq *rq, struct task_struct *p, int queued)
> start_hrtick_dl(rq, p);
> }
>
> -static void task_fork_dl(struct task_struct *p)
> -{
> - /*
> - * SCHED_DEADLINE tasks cannot fork and this is achieved through
> - * sched_fork()
> - */
> -}
> -
> #ifdef CONFIG_SMP
>
> /* Only try algorithms three times */
> @@ -2451,8 +2443,6 @@ const struct sched_class dl_sched_class = {
> #endif
>
> .task_tick = task_tick_dl,
> - .task_fork = task_fork_dl,
> -
> .prio_changed = prio_changed_dl,
> .switched_from = switched_from_dl,
> .switched_to = switched_to_dl,
Patch got whitespace-damaged - please see Documentation/process/email-clients.rst
of how to send patches with your mail client.
Your patch looks good otherwise.
Thanks,
Ingo
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-11-29 7:14 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-11-27 17:03 [PATCH] sched: remove noop function task_fork_dl Tom Rix
2019-11-29 7:13 ` Ingo Molnar
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).