Re: [PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-24 Thread Kamalesh Babulal
* Torsten Duwe [2016-03-24 11:27:57]: > On Thu, Mar 24, 2016 at 03:44:55PM +0530, Kamalesh Babulal wrote: > > * Torsten Duwe [2016-03-23 16:58:58]: > > > > > > > > Since nobody liked the extra stack frame nor its workarounds, here is > > > the next attempt.

Re: [PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-24 Thread Michael Ellerman
On Thu, 2016-03-24 at 09:04 +0100, Torsten Duwe wrote: > On Thu, Mar 24, 2016 at 01:23:01PM +1100, Balbir Singh wrote: > > On 24/03/16 02:58, Torsten Duwe wrote: > > > > > > 1. Heuristics are bad. The better they are, the more subtly the > > >way they might fail. > [...] > > This CR+4 code

Re: [PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-24 Thread Torsten Duwe
On Thu, Mar 24, 2016 at 03:44:55PM +0530, Kamalesh Babulal wrote: > * Torsten Duwe [2016-03-23 16:58:58]: > > > > > Since nobody liked the extra stack frame nor its workarounds, here is > > the next attempt. Assumptions: > > > > 1. Heuristics are bad. The better they are, the more

Re: [PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-24 Thread Kamalesh Babulal
* Torsten Duwe [2016-03-23 16:58:58]: > > Since nobody liked the extra stack frame nor its workarounds, here is > the next attempt. Assumptions: > > 1. Heuristics are bad. The better they are, the more subtly the >way they might fail. > > 2. The TOC pointer is usually

Re: [PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-24 Thread Torsten Duwe
On Thu, Mar 24, 2016 at 01:23:01PM +1100, Balbir Singh wrote: > On 24/03/16 02:58, Torsten Duwe wrote: > > > > 1. Heuristics are bad. The better they are, the more subtly the > >way they might fail. [...] > I missed this yesterday, not on cc, but caught it on the list today I replied to

Re: [PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-23 Thread Balbir Singh
On 24/03/16 02:58, Torsten Duwe wrote: > Since nobody liked the extra stack frame nor its workarounds, here is > the next attempt. Assumptions: > > 1. Heuristics are bad. The better they are, the more subtly the >way they might fail. > > 2. The TOC pointer is usually dividable by 4, if not

[PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-23 Thread Torsten Duwe
Since nobody liked the extra stack frame nor its workarounds, here is the next attempt. Assumptions: 1. Heuristics are bad. The better they are, the more subtly the way they might fail. 2. The TOC pointer is usually dividable by 4, if not by 8. An odd value never occurs. Conclusively,