public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Dave Martin <Dave.Martin@arm.com>
To: Anurag Aggarwal <a.anurag@samsung.com>
Cc: "linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	Naveen Kumar <naveen.sel@samsung.com>,
	Narendra Meher <narendra.m1@samsung.com>,
	"nico@linaro.org" <nico@linaro.org>,
	Catalin Marinas <Catalin.Marinas@arm.com>,
	Will Deacon <Will.Deacon@arm.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Ashish Kalra <ashish.kalra@samsung.com>,
	"cpgs ." <cpgs@samsung.com>,
	"anurag19aggarwal@gmail.com" <anurag19aggarwal@gmail.com>,
	"naveenkrishna.ch@gmail.com" <naveenkrishna.ch@gmail.com>,
	Rajat Suri <rajat.suri@samsung.com>,
	Poorva Srivastava <poorva.s@samsung.com>,
	Mohammad Irfan Ansari <mohammad.a2@samsung.com>
Subject: Re: [PATCH V6] ARM : unwinder : Prevent data abort due to stack overflow
Date: Tue, 10 Dec 2013 17:31:46 +0000	[thread overview]
Message-ID: <20131210173137.GA23639@e103592.cambridge.arm.com> (raw)

On Tue, Dec 10, 2013 at 03:54:42AM +0000, Anurag Aggarwal wrote:
> >Reviewed-by: Dave Martin <Dave.Martin@arm.com>
> >
> >I can confirm that the kernel "doesn't crash" with this applied, and
> >that backtracing at least partially works.  But this is not really
> >sufficient to demontrate that the now code works better than the old
> >code in corner cases (which is the point of the patch).
> >
> >Can you give details of what additional testing you have, or plan to
> >do?
> 
> We saw a data abort in unwinder for one of Samsung Project, during a
> Samsung Automation test case. 
> After that I created the initial the patch, and the data abort has not been
> seen till now.
> 
> Is it possible for you to give an idea on what other kind of additional testing 
> do you have in mind.

To be sure how the stack checking code is behaving, it would be good to
see the overflow check being hit.  With just a single test case, it's
possible that the bug is now hidden, rather than fixed.

You could try adding some debug printks to see how the backtrace fails.
You could also try adding a few hand-crafted assembler functions
with appropriate code and unwind directives to trigger different kinds
of backtrace failure.  You might have to add a way to artificially limit
sp_high to check the cases where you run out of stack in the middle of
popping multiple registers.

When thinking about this, I could not think of a good way to integrate
tests upstream without it being very invasive -- it may be best to keep
debug code separate unless you can see a clean way to merge it.


Cheers
---Dave

             reply	other threads:[~2013-12-10 17:32 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-10 17:31 Dave Martin [this message]
  -- strict thread matches above, loose matches on Subject: below --
2014-01-07 13:53 [PATCH V6] ARM : unwinder : Prevent data abort due to stack overflow Dave Martin
2013-12-11  9:40 Anurag Aggarwal
2013-12-14 10:17 ` Anurag Aggarwal
2013-12-10  3:54 Anurag Aggarwal
2013-12-10 16:19 ` Anurag Aggarwal
2013-12-09 10:47 Anurag Aggarwal
2013-12-09 17:56 ` Dave Martin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20131210173137.GA23639@e103592.cambridge.arm.com \
    --to=dave.martin@arm.com \
    --cc=Catalin.Marinas@arm.com \
    --cc=Will.Deacon@arm.com \
    --cc=a.anurag@samsung.com \
    --cc=anurag19aggarwal@gmail.com \
    --cc=ashish.kalra@samsung.com \
    --cc=cpgs@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mohammad.a2@samsung.com \
    --cc=narendra.m1@samsung.com \
    --cc=naveen.sel@samsung.com \
    --cc=naveenkrishna.ch@gmail.com \
    --cc=nico@linaro.org \
    --cc=poorva.s@samsung.com \
    --cc=rajat.suri@samsung.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox