Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1674670

Re: [PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when enabling/disabling migration

From Daniel Bristot de Oliveira <bristot@redhat.com>
Newsgroups linux.kernel
Subject Re: [PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when enabling/disabling migration
Date 2017-06-26 14:20 +0200
Message-ID <tWB9M-2fr-31@gated-at.bofh.it> (permalink)
References (2 earlier) <tV5OF-29T-1@gated-at.bofh.it> <tVav0-5lU-29@gated-at.bofh.it> <tVgqJ-Ev-5@gated-at.bofh.it> <tVwYz-2KP-31@gated-at.bofh.it> <tVN3k-4qY-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 06/24/2017 08:41 AM, Ingo Molnar wrote:
>> +enum inc_dec_migratory {
>> +	DEC_NR_MIGRATORY = -1,
>> +	INC_NR_MIGRATORY = 1,
>> +};
>> +
>> +static inline void
>> +inc_dec_nr_migratory(struct task_struct *p, enum inc_dec_migratory id)
>> +{
>> +	if (unlikely((p->sched_class == &rt_sched_class ||
>> +		      p->sched_class == &dl_sched_class) &&
>> +		      p->nr_cpus_allowed > 1)) {
>> +		if (p->sched_class == &rt_sched_class)
>> +			task_rq(p)->rt.rt_nr_migratory += id;
>> +		else
>> +			task_rq(p)->dl.dl_nr_migratory += id;
>> +	}
>> +}
> How about just 'long delta', pass in +1 or -1 and do away with the 
> inc_dec_migratory complication?

Ack! I am cooking a v2 using a long delta, rather than the
inc_dec_migratory complication (yeah, I exaggerated hehe).

Thanks!

-- Daniel

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when enabling/disabling migration Daniel Bristot de Oliveira <bristot@redhat.com> - 2017-06-21 21:30 +0200
  Re: [PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when  enabling/disabling migration Ingo Molnar <mingo@kernel.org> - 2017-06-22 10:40 +0200
    Re: [PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when  enabling/disabling migration Daniel Bristot de Oliveira <bristot@redhat.com> - 2017-06-22 15:40 +0200
      Re: [PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when  enabling/disabling migration Ingo Molnar <mingo@kernel.org> - 2017-06-22 22:00 +0200
        Re: [PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when  enabling/disabling migration Daniel Bristot de Oliveira <bristot@redhat.com> - 2017-06-23 15:40 +0200
          Re: [PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when  enabling/disabling migration Ingo Molnar <mingo@kernel.org> - 2017-06-24 08:50 +0200
            Re: [PATCH 2/2] rt: Increase/decrease the nr of migratory tasks when  enabling/disabling migration Daniel Bristot de Oliveira <bristot@redhat.com> - 2017-06-26 14:20 +0200

csiph-web