* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception")
@ 2016-08-03 2:51 Guenter Roeck
2016-08-03 8:38 ` Russell King - ARM Linux
0 siblings, 1 reply; 9+ messages in thread
From: Guenter Roeck @ 2016-08-03 2:51 UTC (permalink / raw)
To: linux-arm-kernel
Hi,
I see the following crash when running a qemu arm 'kzm' runtime test with the current mainline.
Failed to create /dev/root: -14
[ followed by panic ]
A complete log file is at [1].
Bisect points to commit e6978e4bf1 ("ARM: save and reset the address limit when entering
an exception"). Some additional debugging shows lots of similar error returns from
strncpy_from_user(). For the error case resulting in the crash, the call chain
is as follows.
sys_mknod
sys_mknodat()
user_path_create()
getname()
getname_flags()
strncpy_from_user()
Reverting the patch fixes the problem.
I don't see the problem with any other qemu arm test.
It looks like the kernel runs in exception context. My gut feeling is that qemu may be
to blame, but I am not really sure.
Any idea how to track this down ?
Thanks,
Guenter
---
[1] http://kerneltests.org/builders/qemu-arm-master/builds/615
^ permalink raw reply [flat|nested] 9+ messages in thread* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") 2016-08-03 2:51 "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") Guenter Roeck @ 2016-08-03 8:38 ` Russell King - ARM Linux 2016-08-03 15:07 ` Guenter Roeck 0 siblings, 1 reply; 9+ messages in thread From: Russell King - ARM Linux @ 2016-08-03 8:38 UTC (permalink / raw) To: linux-arm-kernel On Tue, Aug 02, 2016 at 07:51:45PM -0700, Guenter Roeck wrote: > Hi, > > I see the following crash when running a qemu arm 'kzm' runtime test with > the current mainline. >... > Failed to create /dev/root: -14 > > [ followed by panic ] > > A complete log file is at [1]. I think it's because of those undefined instructions you're hitting with the hw-breakpoint code... can you try the patch below please? arch/arm/kernel/entry-armv.S | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S index bc5f50799d75..9f157e7c51e7 100644 --- a/arch/arm/kernel/entry-armv.S +++ b/arch/arm/kernel/entry-armv.S @@ -295,6 +295,7 @@ __und_svc_fault: bl __und_fault __und_svc_finish: + get_thread_info tsk ldr r5, [sp, #S_PSR] @ Get SVC cpsr svc_exit r5 @ return from exception UNWIND(.fnend ) -- RMK's Patch system: http://www.armlinux.org.uk/developer/patches/ FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up according to speedtest.net. ^ permalink raw reply related [flat|nested] 9+ messages in thread
* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") 2016-08-03 8:38 ` Russell King - ARM Linux @ 2016-08-03 15:07 ` Guenter Roeck 2016-08-04 10:07 ` Russell King - ARM Linux 0 siblings, 1 reply; 9+ messages in thread From: Guenter Roeck @ 2016-08-03 15:07 UTC (permalink / raw) To: linux-arm-kernel On 08/03/2016 01:38 AM, Russell King - ARM Linux wrote: > On Tue, Aug 02, 2016 at 07:51:45PM -0700, Guenter Roeck wrote: >> Hi, >> >> I see the following crash when running a qemu arm 'kzm' runtime test with >> the current mainline. >> ... >> Failed to create /dev/root: -14 >> >> [ followed by panic ] >> >> A complete log file is at [1]. > > I think it's because of those undefined instructions you're hitting > with the hw-breakpoint code... can you try the patch below please? > > arch/arm/kernel/entry-armv.S | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S > index bc5f50799d75..9f157e7c51e7 100644 > --- a/arch/arm/kernel/entry-armv.S > +++ b/arch/arm/kernel/entry-armv.S > @@ -295,6 +295,7 @@ __und_svc_fault: > bl __und_fault > > __und_svc_finish: > + get_thread_info tsk > ldr r5, [sp, #S_PSR] @ Get SVC cpsr > svc_exit r5 @ return from exception > UNWIND(.fnend ) > Yes, that fixes the problem. Assuming you'll create a patch: Tested-by: Guenter Roeck <linux@roeck-us.net> Does that need to be addressed in qemu, or is it a Linux bug ? Thanks, Guenter ^ permalink raw reply [flat|nested] 9+ messages in thread
* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") 2016-08-03 15:07 ` Guenter Roeck @ 2016-08-04 10:07 ` Russell King - ARM Linux 2016-08-09 15:06 ` Gregory CLEMENT 0 siblings, 1 reply; 9+ messages in thread From: Russell King - ARM Linux @ 2016-08-04 10:07 UTC (permalink / raw) To: linux-arm-kernel On Wed, Aug 03, 2016 at 08:07:02AM -0700, Guenter Roeck wrote: > On 08/03/2016 01:38 AM, Russell King - ARM Linux wrote: > >On Tue, Aug 02, 2016 at 07:51:45PM -0700, Guenter Roeck wrote: > >>Hi, > >> > >>I see the following crash when running a qemu arm 'kzm' runtime test with > >>the current mainline. > >>... > >>Failed to create /dev/root: -14 > >> > >>[ followed by panic ] > >> > >>A complete log file is at [1]. > > > >I think it's because of those undefined instructions you're hitting > >with the hw-breakpoint code... can you try the patch below please? > > > > arch/arm/kernel/entry-armv.S | 1 + > > 1 file changed, 1 insertion(+) > > > >diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S > >index bc5f50799d75..9f157e7c51e7 100644 > >--- a/arch/arm/kernel/entry-armv.S > >+++ b/arch/arm/kernel/entry-armv.S > >@@ -295,6 +295,7 @@ __und_svc_fault: > > bl __und_fault > > > > __und_svc_finish: > >+ get_thread_info tsk > > ldr r5, [sp, #S_PSR] @ Get SVC cpsr > > svc_exit r5 @ return from exception > > UNWIND(.fnend ) > > > > Yes, that fixes the problem. > > Assuming you'll create a patch: > > Tested-by: Guenter Roeck <linux@roeck-us.net> > > Does that need to be addressed in qemu, or is it a Linux bug ? It's a Linux bug provoked by qemu not implementing the hardware breakpoints. Well worth fixing in Linux. -- RMK's Patch system: http://www.armlinux.org.uk/developer/patches/ FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up according to speedtest.net. ^ permalink raw reply [flat|nested] 9+ messages in thread
* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") 2016-08-04 10:07 ` Russell King - ARM Linux @ 2016-08-09 15:06 ` Gregory CLEMENT 2016-08-09 16:12 ` Guenter Roeck 2016-08-10 23:34 ` Kevin Hilman 0 siblings, 2 replies; 9+ messages in thread From: Gregory CLEMENT @ 2016-08-09 15:06 UTC (permalink / raw) To: linux-arm-kernel Hi Russell King, On jeu., ao?t 04 2016, Russell King - ARM Linux <linux@armlinux.org.uk> wrote: > On Wed, Aug 03, 2016 at 08:07:02AM -0700, Guenter Roeck wrote: >> On 08/03/2016 01:38 AM, Russell King - ARM Linux wrote: >> >On Tue, Aug 02, 2016 at 07:51:45PM -0700, Guenter Roeck wrote: >> >>Hi, >> >> >> >>I see the following crash when running a qemu arm 'kzm' runtime test with >> >>the current mainline. >> >>... >> >>Failed to create /dev/root: -14 >> >> >> >>[ followed by panic ] >> >> >> >>A complete log file is at [1]. >> > >> >I think it's because of those undefined instructions you're hitting >> >with the hw-breakpoint code... can you try the patch below please? >> > >> > arch/arm/kernel/entry-armv.S | 1 + >> > 1 file changed, 1 insertion(+) >> > >> >diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S >> >index bc5f50799d75..9f157e7c51e7 100644 >> >--- a/arch/arm/kernel/entry-armv.S >> >+++ b/arch/arm/kernel/entry-armv.S >> >@@ -295,6 +295,7 @@ __und_svc_fault: >> > bl __und_fault >> > >> > __und_svc_finish: >> >+ get_thread_info tsk >> > ldr r5, [sp, #S_PSR] @ Get SVC cpsr >> > svc_exit r5 @ return from exception >> > UNWIND(.fnend ) >> > >> >> Yes, that fixes the problem. >> >> Assuming you'll create a patch: >> >> Tested-by: Guenter Roeck <linux@roeck-us.net> >> >> Does that need to be addressed in qemu, or is it a Linux bug ? > > It's a Linux bug provoked by qemu not implementing the hardware > breakpoints. Well worth fixing in Linux. The Armada XP base platform were hit by the same bug as we can see on kernlci: https://storage.kernelci.org/mainline/v4.8-rc1/arm-mvebu_v7_defconfig/lab-baylibre-seattle/boot-armada-xp-openblocks-ax3-4.html Your patch solves the issue too. Will you push this patch for v4.8-rc2 ? Also I wonder if it is something expected to have this issue on a "real" hardware. You can also add my: Tested-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Thanks, Gregory > > -- > RMK's Patch system: http://www.armlinux.org.uk/developer/patches/ > FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up > according to speedtest.net. > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel at lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel -- Gregory Clement, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com ^ permalink raw reply [flat|nested] 9+ messages in thread
* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") 2016-08-09 15:06 ` Gregory CLEMENT @ 2016-08-09 16:12 ` Guenter Roeck 2016-08-10 23:34 ` Kevin Hilman 1 sibling, 0 replies; 9+ messages in thread From: Guenter Roeck @ 2016-08-09 16:12 UTC (permalink / raw) To: linux-arm-kernel On Tue, Aug 09, 2016 at 05:06:51PM +0200, Gregory CLEMENT wrote: > Hi Russell King, > > On jeu., ao?t 04 2016, Russell King - ARM Linux <linux@armlinux.org.uk> wrote: > > > On Wed, Aug 03, 2016 at 08:07:02AM -0700, Guenter Roeck wrote: > >> On 08/03/2016 01:38 AM, Russell King - ARM Linux wrote: > >> >On Tue, Aug 02, 2016 at 07:51:45PM -0700, Guenter Roeck wrote: > >> >>Hi, > >> >> > >> >>I see the following crash when running a qemu arm 'kzm' runtime test with > >> >>the current mainline. > >> >>... > >> >>Failed to create /dev/root: -14 > >> >> > >> >>[ followed by panic ] > >> >> > >> >>A complete log file is at [1]. > >> > > >> >I think it's because of those undefined instructions you're hitting > >> >with the hw-breakpoint code... can you try the patch below please? > >> > > >> > arch/arm/kernel/entry-armv.S | 1 + > >> > 1 file changed, 1 insertion(+) > >> > > >> >diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S > >> >index bc5f50799d75..9f157e7c51e7 100644 > >> >--- a/arch/arm/kernel/entry-armv.S > >> >+++ b/arch/arm/kernel/entry-armv.S > >> >@@ -295,6 +295,7 @@ __und_svc_fault: > >> > bl __und_fault > >> > > >> > __und_svc_finish: > >> >+ get_thread_info tsk > >> > ldr r5, [sp, #S_PSR] @ Get SVC cpsr > >> > svc_exit r5 @ return from exception > >> > UNWIND(.fnend ) > >> > > >> > >> Yes, that fixes the problem. > >> > >> Assuming you'll create a patch: > >> > >> Tested-by: Guenter Roeck <linux@roeck-us.net> > >> > >> Does that need to be addressed in qemu, or is it a Linux bug ? > > > > It's a Linux bug provoked by qemu not implementing the hardware > > breakpoints. Well worth fixing in Linux. > > The Armada XP base platform were hit by the same bug as we can see on > kernlci: > https://storage.kernelci.org/mainline/v4.8-rc1/arm-mvebu_v7_defconfig/lab-baylibre-seattle/boot-armada-xp-openblocks-ax3-4.html > > Your patch solves the issue too. > > Will you push this patch for v4.8-rc2 ? > > Also I wonder if it is something expected to have this issue on a "real" > hardware. > It would be expected if hardware breakpoint implementation is optional and not all real CPUs implement it. Guenter ^ permalink raw reply [flat|nested] 9+ messages in thread
* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") 2016-08-09 15:06 ` Gregory CLEMENT 2016-08-09 16:12 ` Guenter Roeck @ 2016-08-10 23:34 ` Kevin Hilman 2016-08-10 23:43 ` Russell King - ARM Linux 1 sibling, 1 reply; 9+ messages in thread From: Kevin Hilman @ 2016-08-10 23:34 UTC (permalink / raw) To: linux-arm-kernel On Tue, Aug 9, 2016 at 10:06 AM, Gregory CLEMENT <gregory.clement@free-electrons.com> wrote: > Hi Russell King, > > On jeu., ao?t 04 2016, Russell King - ARM Linux <linux@armlinux.org.uk> wrote: > >> On Wed, Aug 03, 2016 at 08:07:02AM -0700, Guenter Roeck wrote: >>> On 08/03/2016 01:38 AM, Russell King - ARM Linux wrote: >>> >On Tue, Aug 02, 2016 at 07:51:45PM -0700, Guenter Roeck wrote: >>> >>Hi, >>> >> >>> >>I see the following crash when running a qemu arm 'kzm' runtime test with >>> >>the current mainline. >>> >>... >>> >>Failed to create /dev/root: -14 >>> >> >>> >>[ followed by panic ] >>> >> >>> >>A complete log file is at [1]. >>> > >>> >I think it's because of those undefined instructions you're hitting >>> >with the hw-breakpoint code... can you try the patch below please? >>> > >>> > arch/arm/kernel/entry-armv.S | 1 + >>> > 1 file changed, 1 insertion(+) >>> > >>> >diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S >>> >index bc5f50799d75..9f157e7c51e7 100644 >>> >--- a/arch/arm/kernel/entry-armv.S >>> >+++ b/arch/arm/kernel/entry-armv.S >>> >@@ -295,6 +295,7 @@ __und_svc_fault: >>> > bl __und_fault >>> > >>> > __und_svc_finish: >>> >+ get_thread_info tsk >>> > ldr r5, [sp, #S_PSR] @ Get SVC cpsr >>> > svc_exit r5 @ return from exception >>> > UNWIND(.fnend ) >>> > >>> >>> Yes, that fixes the problem. >>> >>> Assuming you'll create a patch: >>> >>> Tested-by: Guenter Roeck <linux@roeck-us.net> >>> >>> Does that need to be addressed in qemu, or is it a Linux bug ? >> >> It's a Linux bug provoked by qemu not implementing the hardware >> breakpoints. Well worth fixing in Linux. > > The Armada XP base platform were hit by the same bug as we can see on > kernlci: > https://storage.kernelci.org/mainline/v4.8-rc1/arm-mvebu_v7_defconfig/lab-baylibre-seattle/boot-armada-xp-openblocks-ax3-4.html > > Your patch solves the issue too. > > Will you push this patch for v4.8-rc2 ? > > Also I wonder if it is something expected to have this issue on a "real" > hardware. > > You can also add my: > Tested-by: Gregory CLEMENT <gregory.clement@free-electrons.com> I also tested this fixes the boot issue on Armada XP. Tested-by: Kevin Hilman <khilman@baylibre.com> Kevin ^ permalink raw reply [flat|nested] 9+ messages in thread
* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") 2016-08-10 23:34 ` Kevin Hilman @ 2016-08-10 23:43 ` Russell King - ARM Linux 2016-08-11 0:46 ` Kevin Hilman 0 siblings, 1 reply; 9+ messages in thread From: Russell King - ARM Linux @ 2016-08-10 23:43 UTC (permalink / raw) To: linux-arm-kernel On Wed, Aug 10, 2016 at 06:34:22PM -0500, Kevin Hilman wrote: > I also tested this fixes the boot issue on Armada XP. > > Tested-by: Kevin Hilman <khilman@baylibre.com> It should be in the current linux-next. I'll send them on in the usual way over the weekend for -rc2, with your ack for this one. Thanks. -- RMK's Patch system: http://www.armlinux.org.uk/developer/patches/ FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up according to speedtest.net. ^ permalink raw reply [flat|nested] 9+ messages in thread
* "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") 2016-08-10 23:43 ` Russell King - ARM Linux @ 2016-08-11 0:46 ` Kevin Hilman 0 siblings, 0 replies; 9+ messages in thread From: Kevin Hilman @ 2016-08-11 0:46 UTC (permalink / raw) To: linux-arm-kernel On Wed, Aug 10, 2016 at 6:43 PM, Russell King - ARM Linux <linux@armlinux.org.uk> wrote: > On Wed, Aug 10, 2016 at 06:34:22PM -0500, Kevin Hilman wrote: >> I also tested this fixes the boot issue on Armada XP. >> >> Tested-by: Kevin Hilman <khilman@baylibre.com> > > It should be in the current linux-next. I'll send them on in the > usual way over the weekend for -rc2, with your ack for this one. Also, I noticed your for-next branch is going through boot testing right now in my kernelci lab, and I see it passed on the Armada XP, so that's more evidence for the fix. Thanks, Kevin ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2016-08-11 0:46 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-03 2:51 "Failed to create /dev/root: -14" after commit e6978e4bf1 ("ARM: save and reset the address limit when entering an exception") Guenter Roeck
2016-08-03 8:38 ` Russell King - ARM Linux
2016-08-03 15:07 ` Guenter Roeck
2016-08-04 10:07 ` Russell King - ARM Linux
2016-08-09 15:06 ` Gregory CLEMENT
2016-08-09 16:12 ` Guenter Roeck
2016-08-10 23:34 ` Kevin Hilman
2016-08-10 23:43 ` Russell King - ARM Linux
2016-08-11 0:46 ` Kevin Hilman
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).