lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Fri, 15 Dec 2023 13:52:38 -0500
From: Vineeth Remanan Pillai <vineeth@...byteword.org>
To: Thomas Gleixner <tglx@...utronix.de>
Cc: Ben Segall <bsegall@...gle.com>, Borislav Petkov <bp@...en8.de>, 
	Daniel Bristot de Oliveira <bristot@...hat.com>, Dave Hansen <dave.hansen@...ux.intel.com>, 
	Dietmar Eggemann <dietmar.eggemann@....com>, "H . Peter Anvin" <hpa@...or.com>, Ingo Molnar <mingo@...hat.com>, 
	Juri Lelli <juri.lelli@...hat.com>, Mel Gorman <mgorman@...e.de>, 
	Paolo Bonzini <pbonzini@...hat.com>, Andy Lutomirski <luto@...nel.org>, 
	Peter Zijlstra <peterz@...radead.org>, Sean Christopherson <seanjc@...gle.com>, 
	Steven Rostedt <rostedt@...dmis.org>, Valentin Schneider <vschneid@...hat.com>, 
	Vincent Guittot <vincent.guittot@...aro.org>, Vitaly Kuznetsov <vkuznets@...hat.com>, 
	Wanpeng Li <wanpengli@...cent.com>, Suleiman Souhlal <suleiman@...gle.com>, 
	Masami Hiramatsu <mhiramat@...gle.com>, kvm@...r.kernel.org, linux-kernel@...r.kernel.org, 
	x86@...nel.org, Joel Fernandes <joel@...lfernandes.org>
Subject: Re: [RFC PATCH 8/8] irq: boost/unboost in irq/nmi entry/exit and softirq

[...snip..]
> > +#ifdef CONFIG_PARAVIRT_SCHED
> > +     if (pv_sched_enabled() && !in_hardirq() && !local_softirq_pending() &&
> > +                     !need_resched() && !task_is_realtime(current))
> > +             pv_sched_unboost_vcpu();
> > +#endif
>
> Symmetry is overrated. Just pick a spot and slap your hackery in.
>
> Aside of that this whole #ifdeffery is tasteless at best.
>
> >       instrumentation_end();
>
> > +#ifdef CONFIG_PARAVIRT_SCHED
> > +     if (pv_sched_enabled())
> > +             pv_sched_boost_vcpu_lazy();
> > +#endif
>
> But what's worse is that this is just another approach of sprinkling
> random hints all over the place and see what sticks.
>
Understood. WIll have a full re-write of guest side logic for v2.

> Abusing KVM as the man in the middle to communicate between guest and
> host scheduler is creative, but ill defined.
>
> From the host scheduler POV the vCPU is just a user space thread and
> making the guest special is just the wrong approach.
>
> The kernel has no proper general interface to convey information from a
> user space task to the scheduler.
>
> So instead of adding some ad-hoc KVM hackery the right thing is to solve
> this problem from ground up in a generic way and KVM can just utilize
> that instead of having the special snow-flake hackery which is just a
> maintainability nightmare.
>
We had a constructive and productive discussion on the cover letter
thread and reaching a consensus on the kvm side of the design. Will
work towards that and post iterative revisions.

Thanks,
Vineeth

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ