Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1674670
| Path | csiph.com!news.mixmin.net!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| 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 | Mon, 26 Jun 2017 14:20:02 +0200 |
| Message-ID | <tWB9M-2fr-31@gated-at.bofh.it> (permalink) |
| References | <tUTu9-26o-3@gated-at.bofh.it> <tUTu9-26o-1@gated-at.bofh.it> <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> |
| X-Google-Dkim-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=kXe4AAJH13iUr/38k9PTRcQFrR1Jtu/gNXeYFbJz3Jo=; b=PnbPDIzZuO2BREi4Ee4BoapKS5S0+XxE4oZH79cDyjgKqSE2G629cb80+SdNSQZOPe eO7tR8elPAson/Io5ItLlV035hYHFLUoolgbE55QaHuMjHetpWBxuazwMB9ST9m2zLT2 9a528FqF6vFKQdgm2GfQ5ASdNQQwYSSAZeSvziY8lXCjPuKRlCfkbSJ0fjwbWAYN2PVp bmH5HbriGyGZ8nllRv22it637hkCoef5kkf+WsTM2Z8nyXk3ZxH9WChTuArsI7P0FVCV O0z3aK4qCQKxH/HaYB5yT1kgj/6nSO8iVTB/m/dxpKWW/7dImSYHO9QmNzdpVJzWe0uM 1+WA== |
| X-Gm-Message-State | AKS2vOzTkggk8kqDhMuqV/YChQggts1VvH4ehLHxsuDjS502D1+VLDiV ++2saD+yquz+VH+dY2Ey0w== |
| X-Received | by 10.200.62.17 with SMTP id z17mr24638033qtf.162.1498479374913; Mon, 26 Jun 2017 05:16:14 -0700 (PDT) |
| User-Agent | Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.0 |
| MIME-Version | 1.0 |
| Content-Type | text/plain; charset=utf-8 |
| Content-Language | en-US |
| Content-Transfer-Encoding | 7bit |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 27 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | linux-rt-users <linux-rt-users@vger.kernel.org>, "Luis Claudio R . Goncalves" <lgoncalv@redhat.com>, Clark Williams <williams@redhat.com>, Luiz Capitulino <lcapitulino@redhat.com>, Sebastian Andrzej Siewior <bigeasy@linutronix.de>, Thomas Gleixner <tglx@linutronix.de>, Steven Rostedt <rostedt@goodmis.org>, Peter Zijlstra <peterz@infradead.org>, LKML <linux-kernel@vger.kernel.org> |
| X-Original-Date | Mon, 26 Jun 2017 14:16:10 +0200 |
| X-Original-Message-ID | <f7f9ee0a-706c-04d4-a21f-65bf6c214fde@redhat.com> |
| X-Original-References | <cover.1498068819.git.bristot@redhat.com> <a6c37371135c028dda5fb09133e093b234576ee3.1498068819.git.bristot@redhat.com> <20170622083830.5thlni7wy6ggdbh5@gmail.com> <5c90773d-1283-d3de-4282-e3855331d4e4@redhat.com> <20170622194943.ho4yekdqqeg2qiva@gmail.com> <ba3011dc-4437-b0ea-4537-83051b83c914@redhat.com> <20170624064157.tc7xogi4aa5t7maf@gmail.com> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1674670 |
Show key headers only | 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 | Next — Previous in thread | Find similar | Unroll 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