* [Qemu-devel] Commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) causing qemu crash
@ 2014-02-07 23:17 Guenter Roeck
2014-02-08 2:31 ` Edgar E. Iglesias
0 siblings, 1 reply; 6+ messages in thread
From: Guenter Roeck @ 2014-02-07 23:17 UTC (permalink / raw)
To: Michal Simek; +Cc: microblaze-uclinux, linux-kernel, qemu-devel
Michal,
commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) results
in the following qemu crash in 3.14-rc1.
/opt/buildbot/bin/qemu-system-microblaze -M petalogix-s3adsp1800 -kernel arch/microblaze/boot/linux.bin -no-reboot -append "console=ttyUL0,115200 " -nographic
qemu: fatal: fetching nop sequence
IN: PC=20
rmsr=4300 resr=7 rear=c0389fe8 debug=0 imm=ffffffd0 iflags=0 fsr=0
btaken=1 btarget=c03a9f24 mode=kernel(saved=kernel) eip=512 ie=0
r00=00000000 r01=c0389fcc r02=c0386a52 r03=000000c0
r04=00004100 r05=9052fab4 r06=00000000 r07=90530ab4
r08=00000000 r09=00400000 r10=00400000 r11=c03a9f24
r12=00621000 r13=40aef0c0 r14=00000000 r15=c0000294
r16=00000000 r17=c03a9f28 r18=00000000 r19=00000000
r20=00000000 r21=00000000 r22=00000000 r23=00000000
r24=00000000 r25=00000000 r26=00000000 r27=00000000
r28=00000000 r29=00400000 r30=00000300 r31=c03932d4
Aborted (core dumped)
I have seen this with qemu 1.6.0 and 1.7.0.
Reverting the patch solves the problem.
Is this a qemu bug, a bug in the code, or a bug in my configuration ?
Any idea what I can do about it ?
Thanks,
Guenter
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] Commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) causing qemu crash
2014-02-07 23:17 [Qemu-devel] Commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) causing qemu crash Guenter Roeck
@ 2014-02-08 2:31 ` Edgar E. Iglesias
2014-02-08 3:43 ` Guenter Roeck
2014-02-10 9:05 ` Michal Simek
0 siblings, 2 replies; 6+ messages in thread
From: Edgar E. Iglesias @ 2014-02-08 2:31 UTC (permalink / raw)
To: Guenter Roeck; +Cc: microblaze-uclinux, Michal Simek, linux-kernel, qemu-devel
On Fri, Feb 07, 2014 at 03:17:31PM -0800, Guenter Roeck wrote:
> Michal,
>
> commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) results
> in the following qemu crash in 3.14-rc1.
>
> /opt/buildbot/bin/qemu-system-microblaze -M petalogix-s3adsp1800 -kernel arch/microblaze/boot/linux.bin -no-reboot -append "console=ttyUL0,115200 " -nographic
> qemu: fatal: fetching nop sequence
>
> IN: PC=20
> rmsr=4300 resr=7 rear=c0389fe8 debug=0 imm=ffffffd0 iflags=0 fsr=0
> btaken=1 btarget=c03a9f24 mode=kernel(saved=kernel) eip=512 ie=0
> r00=00000000 r01=c0389fcc r02=c0386a52 r03=000000c0
> r04=00004100 r05=9052fab4 r06=00000000 r07=90530ab4
> r08=00000000 r09=00400000 r10=00400000 r11=c03a9f24
> r12=00621000 r13=40aef0c0 r14=00000000 r15=c0000294
> r16=00000000 r17=c03a9f28 r18=00000000 r19=00000000
> r20=00000000 r21=00000000 r22=00000000 r23=00000000
> r24=00000000 r25=00000000 r26=00000000 r27=00000000
> r28=00000000 r29=00400000 r30=00000300 r31=c03932d4
>
>
> Aborted (core dumped)
>
> I have seen this with qemu 1.6.0 and 1.7.0.
>
> Reverting the patch solves the problem.
>
> Is this a qemu bug, a bug in the code, or a bug in my configuration ?
> Any idea what I can do about it ?
Hi Guenter,
Seems to be a typo in the kernel, the following should fix it.
Cheers,
Edgar
---8<---
From: "Edgar E. Iglesias" <edgar.iglesias@xilinx.com>
Date: Sat, 8 Feb 2014 10:59:59 +1000
Subject: [PATCH] microblaze: Fix a typo when disabling stack protection
Correct a typo causing the stack protector to be left enabled.
0xFFFFFFF -> 0xFFFFFFFF
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
---
arch/microblaze/kernel/head.S | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/microblaze/kernel/head.S b/arch/microblaze/kernel/head.S
index b7fb043..17645b2 100644
--- a/arch/microblaze/kernel/head.S
+++ b/arch/microblaze/kernel/head.S
@@ -66,7 +66,7 @@ real_start:
mts rmsr, r0
/* Disable stack protection from bootloader */
mts rslr, r0
- addi r8, r0, 0xFFFFFFF
+ addi r8, r0, 0xFFFFFFFF
mts rshr, r8
/*
* According to Xilinx, msrclr instruction behaves like 'mfs rX,rpc'
--
1.9.rc2
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] Commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) causing qemu crash
2014-02-08 2:31 ` Edgar E. Iglesias
@ 2014-02-08 3:43 ` Guenter Roeck
2014-02-10 6:45 ` Michal Simek
2014-02-10 9:05 ` Michal Simek
1 sibling, 1 reply; 6+ messages in thread
From: Guenter Roeck @ 2014-02-08 3:43 UTC (permalink / raw)
To: Edgar E. Iglesias
Cc: microblaze-uclinux, Michal Simek, linux-kernel, qemu-devel
On 02/07/2014 06:31 PM, Edgar E. Iglesias wrote:
> On Fri, Feb 07, 2014 at 03:17:31PM -0800, Guenter Roeck wrote:
>> Michal,
>>
>> commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) results
>> in the following qemu crash in 3.14-rc1.
>>
>> /opt/buildbot/bin/qemu-system-microblaze -M petalogix-s3adsp1800 -kernel arch/microblaze/boot/linux.bin -no-reboot -append "console=ttyUL0,115200 " -nographic
>> qemu: fatal: fetching nop sequence
>>
>> IN: PC=20
>> rmsr=4300 resr=7 rear=c0389fe8 debug=0 imm=ffffffd0 iflags=0 fsr=0
>> btaken=1 btarget=c03a9f24 mode=kernel(saved=kernel) eip=512 ie=0
>> r00=00000000 r01=c0389fcc r02=c0386a52 r03=000000c0
>> r04=00004100 r05=9052fab4 r06=00000000 r07=90530ab4
>> r08=00000000 r09=00400000 r10=00400000 r11=c03a9f24
>> r12=00621000 r13=40aef0c0 r14=00000000 r15=c0000294
>> r16=00000000 r17=c03a9f28 r18=00000000 r19=00000000
>> r20=00000000 r21=00000000 r22=00000000 r23=00000000
>> r24=00000000 r25=00000000 r26=00000000 r27=00000000
>> r28=00000000 r29=00400000 r30=00000300 r31=c03932d4
>>
>>
>> Aborted (core dumped)
>>
>> I have seen this with qemu 1.6.0 and 1.7.0.
>>
>> Reverting the patch solves the problem.
>>
>> Is this a qemu bug, a bug in the code, or a bug in my configuration ?
>> Any idea what I can do about it ?
>
> Hi Guenter,
>
> Seems to be a typo in the kernel, the following should fix it.
>
> Cheers,
> Edgar
>
> ---8<---
> From: "Edgar E. Iglesias" <edgar.iglesias@xilinx.com>
> Date: Sat, 8 Feb 2014 10:59:59 +1000
> Subject: [PATCH] microblaze: Fix a typo when disabling stack protection
>
> Correct a typo causing the stack protector to be left enabled.
> 0xFFFFFFF -> 0xFFFFFFFF
>
> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
Hi Edgar,
you are right, that fixes the problem.
Tested-by: Guenter Roeck <linux@roeck-us.net>
Thanks!
Guenter
> ---
> arch/microblaze/kernel/head.S | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/microblaze/kernel/head.S b/arch/microblaze/kernel/head.S
> index b7fb043..17645b2 100644
> --- a/arch/microblaze/kernel/head.S
> +++ b/arch/microblaze/kernel/head.S
> @@ -66,7 +66,7 @@ real_start:
> mts rmsr, r0
> /* Disable stack protection from bootloader */
> mts rslr, r0
> - addi r8, r0, 0xFFFFFFF
> + addi r8, r0, 0xFFFFFFFF
> mts rshr, r8
> /*
> * According to Xilinx, msrclr instruction behaves like 'mfs rX,rpc'
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] Commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) causing qemu crash
2014-02-08 3:43 ` Guenter Roeck
@ 2014-02-10 6:45 ` Michal Simek
0 siblings, 0 replies; 6+ messages in thread
From: Michal Simek @ 2014-02-10 6:45 UTC (permalink / raw)
To: Guenter Roeck; +Cc: qemu-devel, Edgar E. Iglesias, LKML, microblaze-uclinux
[-- Attachment #1: Type: text/plain, Size: 1990 bytes --]
2014-02-08 Guenter Roeck <linux@roeck-us.net>:
> On 02/07/2014 06:31 PM, Edgar E. Iglesias wrote:
>
>> On Fri, Feb 07, 2014 at 03:17:31PM -0800, Guenter Roeck wrote:
>>
>>> Michal,
>>>
>>> commit 34b9c07a3 (microblaze: Disable stack protection from bootloader)
>>> results
>>> in the following qemu crash in 3.14-rc1.
>>>
>>> /opt/buildbot/bin/qemu-system-microblaze -M petalogix-s3adsp1800
>>> -kernel arch/microblaze/boot/linux.bin -no-reboot -append
>>> "console=ttyUL0,115200 " -nographic
>>> qemu: fatal: fetching nop sequence
>>>
>>> IN: PC=20
>>> rmsr=4300 resr=7 rear=c0389fe8 debug=0 imm=ffffffd0 iflags=0 fsr=0
>>> btaken=1 btarget=c03a9f24 mode=kernel(saved=kernel) eip=512 ie=0
>>> r00=00000000 r01=c0389fcc r02=c0386a52 r03=000000c0
>>> r04=00004100 r05=9052fab4 r06=00000000 r07=90530ab4
>>> r08=00000000 r09=00400000 r10=00400000 r11=c03a9f24
>>> r12=00621000 r13=40aef0c0 r14=00000000 r15=c0000294
>>> r16=00000000 r17=c03a9f28 r18=00000000 r19=00000000
>>> r20=00000000 r21=00000000 r22=00000000 r23=00000000
>>> r24=00000000 r25=00000000 r26=00000000 r27=00000000
>>> r28=00000000 r29=00400000 r30=00000300 r31=c03932d4
>>>
>>>
>>> Aborted (core dumped)
>>>
>>> I have seen this with qemu 1.6.0 and 1.7.0.
>>>
>>> Reverting the patch solves the problem.
>>>
>>> Is this a qemu bug, a bug in the code, or a bug in my configuration ?
>>> Any idea what I can do about it ?
>>>
>>
>> Hi Guenter,
>>
>> Seems to be a typo in the kernel, the following should fix it.
>>
>> Cheers,
>> Edgar
>>
>> ---8<---
>> From: "Edgar E. Iglesias" <edgar.iglesias@xilinx.com>
>> Date: Sat, 8 Feb 2014 10:59:59 +1000
>> Subject: [PATCH] microblaze: Fix a typo when disabling stack protection
>>
>> Correct a typo causing the stack protector to be left enabled.
>> 0xFFFFFFF -> 0xFFFFFFFF
>>
>> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
>>
>
> Hi Edgar,
>
> you are right, that fixes the problem.
>
> Tested-by: Guenter Roeck <linux@roeck-us.net>
Applied.
Thanks,
Michal
[-- Attachment #2: Type: text/html, Size: 2931 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] Commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) causing qemu crash
2014-02-08 2:31 ` Edgar E. Iglesias
2014-02-08 3:43 ` Guenter Roeck
@ 2014-02-10 9:05 ` Michal Simek
2014-02-10 16:31 ` linux
1 sibling, 1 reply; 6+ messages in thread
From: Michal Simek @ 2014-02-10 9:05 UTC (permalink / raw)
To: Edgar E. Iglesias; +Cc: microblaze-uclinux, LKML, Guenter Roeck, qemu-devel
[-- Attachment #1: Type: text/plain, Size: 1331 bytes --]
Hi Edgar and Guenter,
2014-02-08 Edgar E. Iglesias <edgar.iglesias@gmail.com>:
> On Fri, Feb 07, 2014 at 03:17:31PM -0800, Guenter Roeck wrote:
> > Michal,
> >
> > commit 34b9c07a3 (microblaze: Disable stack protection from bootloader)
> results
> > in the following qemu crash in 3.14-rc1.
> >
> > /opt/buildbot/bin/qemu-system-microblaze -M petalogix-s3adsp1800 -kernel
> arch/microblaze/boot/linux.bin -no-reboot -append "console=ttyUL0,115200 "
> -nographic
> > qemu: fatal: fetching nop sequence
> >
> > IN: PC=20
> > rmsr=4300 resr=7 rear=c0389fe8 debug=0 imm=ffffffd0 iflags=0 fsr=0
> > btaken=1 btarget=c03a9f24 mode=kernel(saved=kernel) eip=512 ie=0
> > r00=00000000 r01=c0389fcc r02=c0386a52 r03=000000c0
> > r04=00004100 r05=9052fab4 r06=00000000 r07=90530ab4
> > r08=00000000 r09=00400000 r10=00400000 r11=c03a9f24
> > r12=00621000 r13=40aef0c0 r14=00000000 r15=c0000294
> > r16=00000000 r17=c03a9f28 r18=00000000 r19=00000000
> > r20=00000000 r21=00000000 r22=00000000 r23=00000000
> > r24=00000000 r25=00000000 r26=00000000 r27=00000000
> > r28=00000000 r29=00400000 r30=00000300 r31=c03932d4
> >
>
Can you please check that these 2 registers are not available when
microblaze is configured with full MMU?
Because I expect that you are testing MMU kernel but these two writes
should be just nops.
Thanks,
Michal
[-- Attachment #2: Type: text/html, Size: 1904 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] Commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) causing qemu crash
2014-02-10 9:05 ` Michal Simek
@ 2014-02-10 16:31 ` linux
0 siblings, 0 replies; 6+ messages in thread
From: linux @ 2014-02-10 16:31 UTC (permalink / raw)
To: Michal Simek; +Cc: qemu-devel, Edgar E. Iglesias, LKML, microblaze-uclinux
Quoting Michal Simek <monstr@monstr.eu>:
> Hi Edgar and Guenter,
>
>
> 2014-02-08 Edgar E. Iglesias <edgar.iglesias@gmail.com>:
>
>> On Fri, Feb 07, 2014 at 03:17:31PM -0800, Guenter Roeck wrote:
>> > Michal,
>> >
>> > commit 34b9c07a3 (microblaze: Disable stack protection from bootloader)
>> results
>> > in the following qemu crash in 3.14-rc1.
>> >
>> > /opt/buildbot/bin/qemu-system-microblaze -M petalogix-s3adsp1800 -kernel
>> arch/microblaze/boot/linux.bin -no-reboot -append "console=ttyUL0,115200 "
>> -nographic
>> > qemu: fatal: fetching nop sequence
>> >
>> > IN: PC=20
>> > rmsr=4300 resr=7 rear=c0389fe8 debug=0 imm=ffffffd0 iflags=0 fsr=0
>> > btaken=1 btarget=c03a9f24 mode=kernel(saved=kernel) eip=512 ie=0
>> > r00=00000000 r01=c0389fcc r02=c0386a52 r03=000000c0
>> > r04=00004100 r05=9052fab4 r06=00000000 r07=90530ab4
>> > r08=00000000 r09=00400000 r10=00400000 r11=c03a9f24
>> > r12=00621000 r13=40aef0c0 r14=00000000 r15=c0000294
>> > r16=00000000 r17=c03a9f28 r18=00000000 r19=00000000
>> > r20=00000000 r21=00000000 r22=00000000 r23=00000000
>> > r24=00000000 r25=00000000 r26=00000000 r27=00000000
>> > r28=00000000 r29=00400000 r30=00000300 r31=c03932d4
>> >
>>
>
> Can you please check that these 2 registers are not available when
> microblaze is configured with full MMU?
> Because I expect that you are testing MMU kernel but these two writes
> should be just nops.
>
Hi Michal,
I can send you my configuration if that is what you are
looking for. Other than that, I am pretty clueless when
it comes to Microblaze details - all I do is to build
an image and check if it boots with qemu. This is part of
my sanity tests of upcoming -stable kernel versions.
It will have to wait until tonight, though - my home internet
connection is down and I can not connect to the system right
now.
Guenter
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2014-02-10 16:32 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-07 23:17 [Qemu-devel] Commit 34b9c07a3 (microblaze: Disable stack protection from bootloader) causing qemu crash Guenter Roeck
2014-02-08 2:31 ` Edgar E. Iglesias
2014-02-08 3:43 ` Guenter Roeck
2014-02-10 6:45 ` Michal Simek
2014-02-10 9:05 ` Michal Simek
2014-02-10 16:31 ` linux
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).