All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] New documentation for the LatticeMicro32 target
@ 2017-07-09 15:39 Programmingkid
  2017-07-17  5:40 ` Michael Walle
  0 siblings, 1 reply; 13+ messages in thread
From: Programmingkid @ 2017-07-09 15:39 UTC (permalink / raw)
  To: michael; +Cc: qemu-devel@nongnu.org qemu-devel

I just made a documentation page for the LatticeMicro32 target. I need to know its current status, how much of this system is implemented, what software runs on it. If anyone could supply more information that would be appreciated. Pictures of this target running would be great as well. Thanks.

Here is the page: http://wiki.qemu.org/Documentation/Platforms/LatticeMico32

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] New documentation for the LatticeMicro32 target
  2017-07-09 15:39 [Qemu-devel] New documentation for the LatticeMicro32 target Programmingkid
@ 2017-07-17  5:40 ` Michael Walle
  2017-07-17 14:56   ` Programmingkid
  0 siblings, 1 reply; 13+ messages in thread
From: Michael Walle @ 2017-07-17  5:40 UTC (permalink / raw)
  To: Programmingkid; +Cc: qemu-devel@nongnu.org qemu-devel

Am 2017-07-09 17:39, schrieb Programmingkid:
> I just made a documentation page for the LatticeMicro32 target. I need
> to know its current status, how much of this system is implemented,
> what software runs on it. If anyone could supply more information that
> would be appreciated. Pictures of this target running would be great
> as well. Thanks.
> 
> Here is the page: 
> http://wiki.qemu.org/Documentation/Platforms/LatticeMico32

Hi,

thank you for your efforts. I have to admit that the current status is 
unknown.

I've just compiled the latest head and it looks like the BQL is missing 
for the interrupt helpers. I'll post a patch soon. With the patch, the 
basic stuff is working but there seems to be an issue with OpenGL.

You can read the quickstart instructions at:
http://milkymist.walle.cc/README.qemu

The flash image isn't working because it will boot right into the 
visualization mode, which is using the OpenGL stuff. The "-kernel 
flickernoise" method is working though. You can get the flickernoise 
binary at:
http://milkymist.walle.cc/updates/current/flickernoise

Besides the milkymist emulation, there is plain lm32 emulation based on 
the Lattice reference design which should be ok, because the tests are 
working (make -C tests/tcg/lm32 check)

-michael

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] New documentation for the LatticeMicro32 target
  2017-07-17  5:40 ` Michael Walle
@ 2017-07-17 14:56   ` Programmingkid
  2017-07-17 15:18     ` Programmingkid
  0 siblings, 1 reply; 13+ messages in thread
From: Programmingkid @ 2017-07-17 14:56 UTC (permalink / raw)
  To: Michael Walle; +Cc: qemu-devel@nongnu.org qemu-devel


> On Jul 17, 2017, at 1:40 AM, Michael Walle <michael@walle.cc> wrote:
> 
> Am 2017-07-09 17:39, schrieb Programmingkid:
>> I just made a documentation page for the LatticeMicro32 target. I need
>> to know its current status, how much of this system is implemented,
>> what software runs on it. If anyone could supply more information that
>> would be appreciated. Pictures of this target running would be great
>> as well. Thanks.
>> Here is the page: http://wiki.qemu.org/Documentation/Platforms/LatticeMico32
> 
> Hi,
> 
> thank you for your efforts. I have to admit that the current status is unknown.
> 
> I've just compiled the latest head and it looks like the BQL is missing for the interrupt helpers. I'll post a patch soon. With the patch, the basic stuff is working but there seems to be an issue with OpenGL.
> 
> You can read the quickstart instructions at:
> http://milkymist.walle.cc/README.qemu
> 
> The flash image isn't working because it will boot right into the visualization mode, which is using the OpenGL stuff. The "-kernel flickernoise" method is working though. You can get the flickernoise binary at:
> http://milkymist.walle.cc/updates/current/flickernoise
> 
> Besides the milkymist emulation, there is plain lm32 emulation based on the Lattice reference design which should be ok, because the tests are working (make -C tests/tcg/lm32 check)
> 
> -michael

Thank you for all this information. It has been added to the wiki page. 

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] New documentation for the LatticeMicro32 target
  2017-07-17 14:56   ` Programmingkid
@ 2017-07-17 15:18     ` Programmingkid
  2017-07-18 11:44       ` Michael Walle
  0 siblings, 1 reply; 13+ messages in thread
From: Programmingkid @ 2017-07-17 15:18 UTC (permalink / raw)
  To: Michael Walle; +Cc: qemu-devel@nongnu.org qemu-devel


> On Jul 17, 2017, at 10:56 AM, Programmingkid <programmingkidx@gmail.com> wrote:
> 
> 
>> On Jul 17, 2017, at 1:40 AM, Michael Walle <michael@walle.cc> wrote:
>> 
>> Am 2017-07-09 17:39, schrieb Programmingkid:
>>> I just made a documentation page for the LatticeMicro32 target. I need
>>> to know its current status, how much of this system is implemented,
>>> what software runs on it. If anyone could supply more information that
>>> would be appreciated. Pictures of this target running would be great
>>> as well. Thanks.
>>> Here is the page: http://wiki.qemu.org/Documentation/Platforms/LatticeMico32
>> 
>> Hi,
>> 
>> thank you for your efforts. I have to admit that the current status is unknown.
>> 
>> I've just compiled the latest head and it looks like the BQL is missing for the interrupt helpers. I'll post a patch soon. With the patch, the basic stuff is working but there seems to be an issue with OpenGL.
>> 
>> You can read the quickstart instructions at:
>> http://milkymist.walle.cc/README.qemu
>> 
>> The flash image isn't working because it will boot right into the visualization mode, which is using the OpenGL stuff. The "-kernel flickernoise" method is working though. You can get the flickernoise binary at:
>> http://milkymist.walle.cc/updates/current/flickernoise
>> 
>> Besides the milkymist emulation, there is plain lm32 emulation based on the Lattice reference design which should be ok, because the tests are working (make -C tests/tcg/lm32 check)
>> 
>> -michael
> 
> Thank you for all this information. It has been added to the wiki page. 
> 

I just tried qemu-system-lm32 and it crashed.

Command-line: qemu-system-lm32 -M milkymist -kernel flickernoise

Error message: audio: Failed to create voice `mm_ac97.in'
**
ERROR: /accel/tcg/tcg-all.c:42:tcg_handle_interrupt: assertion failed: (qemu_mutex_iothread_locked())
Abort trap: 6

Host: Mac OS 10.12.5

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] New documentation for the LatticeMicro32 target
  2017-07-17 15:18     ` Programmingkid
@ 2017-07-18 11:44       ` Michael Walle
  2017-07-18 14:05         ` Programmingkid
  2018-01-09 11:58         ` Peter Maydell
  0 siblings, 2 replies; 13+ messages in thread
From: Michael Walle @ 2017-07-18 11:44 UTC (permalink / raw)
  To: Programmingkid; +Cc: qemu-devel@nongnu.org qemu-devel

Am 2017-07-17 17:18, schrieb Programmingkid:
>> On Jul 17, 2017, at 10:56 AM, Programmingkid 
>> <programmingkidx@gmail.com> wrote:
>> 
>> 
>>> On Jul 17, 2017, at 1:40 AM, Michael Walle <michael@walle.cc> wrote:
>>> 
>>> Am 2017-07-09 17:39, schrieb Programmingkid:
>>>> I just made a documentation page for the LatticeMicro32 target. I 
>>>> need
>>>> to know its current status, how much of this system is implemented,
>>>> what software runs on it. If anyone could supply more information 
>>>> that
>>>> would be appreciated. Pictures of this target running would be great
>>>> as well. Thanks.
>>>> Here is the page: 
>>>> http://wiki.qemu.org/Documentation/Platforms/LatticeMico32
>>> 
>>> Hi,
>>> 
>>> thank you for your efforts. I have to admit that the current status 
>>> is unknown.
>>> 
>>> I've just compiled the latest head and it looks like the BQL is 
>>> missing for the interrupt helpers. I'll post a patch soon. With the 
>>> patch, the basic stuff is working but there seems to be an issue with 
>>> OpenGL.
>>> 
>>> You can read the quickstart instructions at:
>>> http://milkymist.walle.cc/README.qemu
>>> 
>>> The flash image isn't working because it will boot right into the 
>>> visualization mode, which is using the OpenGL stuff. The "-kernel 
>>> flickernoise" method is working though. You can get the flickernoise 
>>> binary at:
>>> http://milkymist.walle.cc/updates/current/flickernoise
>>> 
>>> Besides the milkymist emulation, there is plain lm32 emulation based 
>>> on the Lattice reference design which should be ok, because the tests 
>>> are working (make -C tests/tcg/lm32 check)
>>> 
>>> -michael
>> 
>> Thank you for all this information. It has been added to the wiki 
>> page.
>> 
> 
> I just tried qemu-system-lm32 and it crashed.
> 
> Command-line: qemu-system-lm32 -M milkymist -kernel flickernoise
> 
> Error message: audio: Failed to create voice `mm_ac97.in'
> **
> ERROR: /accel/tcg/tcg-all.c:42:tcg_handle_interrupt: assertion failed:
> (qemu_mutex_iothread_locked())
> Abort trap: 6
> 
> Host: Mac OS 10.12.5

As I said before, I guess the BQL is missing here. Try the following 
patch:

diff --git a/target/lm32/op_helper.c b/target/lm32/op_helper.c
index 2177c8ad12..93b8d09794 100644
--- a/target/lm32/op_helper.c
+++ b/target/lm32/op_helper.c
@@ -102,12 +102,16 @@ void HELPER(wcsr_dc)(CPULM32State *env, uint32_t 
dc)

  void HELPER(wcsr_im)(CPULM32State *env, uint32_t im)
  {
+    qemu_mutex_lock_iothread();
      lm32_pic_set_im(env->pic_state, im);
+    qemu_mutex_unlock_iothread();
  }

  void HELPER(wcsr_ip)(CPULM32State *env, uint32_t im)
  {
+    qemu_mutex_lock_iothread();
      lm32_pic_set_ip(env->pic_state, im);
+    qemu_mutex_unlock_iothread();
  }

  void HELPER(wcsr_jtx)(CPULM32State *env, uint32_t jtx)



-michael

^ permalink raw reply related	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] New documentation for the LatticeMicro32 target
  2017-07-18 11:44       ` Michael Walle
@ 2017-07-18 14:05         ` Programmingkid
  2018-01-09 11:58         ` Peter Maydell
  1 sibling, 0 replies; 13+ messages in thread
From: Programmingkid @ 2017-07-18 14:05 UTC (permalink / raw)
  To: Michael Walle; +Cc: qemu-devel@nongnu.org qemu-devel


> On Jul 18, 2017, at 7:44 AM, Michael Walle <michael@walle.cc> wrote:
> 
> Am 2017-07-17 17:18, schrieb Programmingkid:
>>> On Jul 17, 2017, at 10:56 AM, Programmingkid <programmingkidx@gmail.com> wrote:
>>>> On Jul 17, 2017, at 1:40 AM, Michael Walle <michael@walle.cc> wrote:
>>>> Am 2017-07-09 17:39, schrieb Programmingkid:
>>>>> I just made a documentation page for the LatticeMicro32 target. I need
>>>>> to know its current status, how much of this system is implemented,
>>>>> what software runs on it. If anyone could supply more information that
>>>>> would be appreciated. Pictures of this target running would be great
>>>>> as well. Thanks.
>>>>> Here is the page: http://wiki.qemu.org/Documentation/Platforms/LatticeMico32
>>>> Hi,
>>>> thank you for your efforts. I have to admit that the current status is unknown.
>>>> I've just compiled the latest head and it looks like the BQL is missing for the interrupt helpers. I'll post a patch soon. With the patch, the basic stuff is working but there seems to be an issue with OpenGL.
>>>> You can read the quickstart instructions at:
>>>> http://milkymist.walle.cc/README.qemu
>>>> The flash image isn't working because it will boot right into the visualization mode, which is using the OpenGL stuff. The "-kernel flickernoise" method is working though. You can get the flickernoise binary at:
>>>> http://milkymist.walle.cc/updates/current/flickernoise
>>>> Besides the milkymist emulation, there is plain lm32 emulation based on the Lattice reference design which should be ok, because the tests are working (make -C tests/tcg/lm32 check)
>>>> -michael
>>> Thank you for all this information. It has been added to the wiki page.
>> I just tried qemu-system-lm32 and it crashed.
>> Command-line: qemu-system-lm32 -M milkymist -kernel flickernoise
>> Error message: audio: Failed to create voice `mm_ac97.in'
>> **
>> ERROR: /accel/tcg/tcg-all.c:42:tcg_handle_interrupt: assertion failed:
>> (qemu_mutex_iothread_locked())
>> Abort trap: 6
>> Host: Mac OS 10.12.5
> 
> As I said before, I guess the BQL is missing here. Try the following patch:
> 
> diff --git a/target/lm32/op_helper.c b/target/lm32/op_helper.c
> index 2177c8ad12..93b8d09794 100644
> --- a/target/lm32/op_helper.c
> +++ b/target/lm32/op_helper.c
> @@ -102,12 +102,16 @@ void HELPER(wcsr_dc)(CPULM32State *env, uint32_t dc)
> 
> void HELPER(wcsr_im)(CPULM32State *env, uint32_t im)
> {
> +    qemu_mutex_lock_iothread();
>     lm32_pic_set_im(env->pic_state, im);
> +    qemu_mutex_unlock_iothread();
> }
> 
> void HELPER(wcsr_ip)(CPULM32State *env, uint32_t im)
> {
> +    qemu_mutex_lock_iothread();
>     lm32_pic_set_ip(env->pic_state, im);
> +    qemu_mutex_unlock_iothread();
> }
> 
> void HELPER(wcsr_jtx)(CPULM32State *env, uint32_t jtx)
> 
> 
> 
> -michael
> 

Thank you very much for the patch. It fixed the problem. Now I can take a picture of the screen and add it to the wiki page. 

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] New documentation for the LatticeMicro32 target
  2017-07-18 11:44       ` Michael Walle
  2017-07-18 14:05         ` Programmingkid
@ 2018-01-09 11:58         ` Peter Maydell
  2018-01-09 17:01           ` [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register Michael Walle
  2018-01-09 17:04           ` [Qemu-devel] New documentation for the LatticeMicro32 target Michael Walle
  1 sibling, 2 replies; 13+ messages in thread
From: Peter Maydell @ 2018-01-09 11:58 UTC (permalink / raw)
  To: Michael Walle; +Cc: Programmingkid, qemu-devel@nongnu.org qemu-devel

On 18 July 2017 at 12:44, Michael Walle <michael@walle.cc> wrote:
> Am 2017-07-17 17:18, schrieb Programmingkid:
>> I just tried qemu-system-lm32 and it crashed.
>>
>> Command-line: qemu-system-lm32 -M milkymist -kernel flickernoise
>>
>> Error message: audio: Failed to create voice `mm_ac97.in'
>> **
>> ERROR: /accel/tcg/tcg-all.c:42:tcg_handle_interrupt: assertion failed:
>> (qemu_mutex_iothread_locked())
>> Abort trap: 6
>>
>> Host: Mac OS 10.12.5
>
>
> As I said before, I guess the BQL is missing here. Try the following patch:
>
> diff --git a/target/lm32/op_helper.c b/target/lm32/op_helper.c
> index 2177c8ad12..93b8d09794 100644
> --- a/target/lm32/op_helper.c
> +++ b/target/lm32/op_helper.c
> @@ -102,12 +102,16 @@ void HELPER(wcsr_dc)(CPULM32State *env, uint32_t dc)
>
>  void HELPER(wcsr_im)(CPULM32State *env, uint32_t im)
>  {
> +    qemu_mutex_lock_iothread();
>      lm32_pic_set_im(env->pic_state, im);
> +    qemu_mutex_unlock_iothread();
>  }
>
>  void HELPER(wcsr_ip)(CPULM32State *env, uint32_t im)
>  {
> +    qemu_mutex_lock_iothread();
>      lm32_pic_set_ip(env->pic_state, im);
> +    qemu_mutex_unlock_iothread();
>  }
>
>  void HELPER(wcsr_jtx)(CPULM32State *env, uint32_t jtx)

I just fell over this, it looks like this fix never made it into master.

Michael, could you submit this as a full patch with a commit message
and signed-off-by, please? cc: qemu-stable@nongnu.org as well, since
it fixes a "breaks the board completely" bug.

thanks
-- PMM

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register
  2018-01-09 11:58         ` Peter Maydell
@ 2018-01-09 17:01           ` Michael Walle
  2018-02-01  9:09             ` Michael Walle
  2018-05-10 13:00             ` Alex Bennée
  2018-01-09 17:04           ` [Qemu-devel] New documentation for the LatticeMicro32 target Michael Walle
  1 sibling, 2 replies; 13+ messages in thread
From: Michael Walle @ 2018-01-09 17:01 UTC (permalink / raw)
  To: qemu-devel; +Cc: peter.maydell, Programmingkid, Michael Walle, qemu-stable

Writing to these registers may raise an interrupt request. Actually,
this prevents the milkymist board from starting.

Cc: qemu-stable@nongnu.org
Signed-off-by: Michael Walle <michael@walle.cc>
---
 target/lm32/op_helper.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/target/lm32/op_helper.c b/target/lm32/op_helper.c
index 30f670eee8..a766a1ece4 100644
--- a/target/lm32/op_helper.c
+++ b/target/lm32/op_helper.c
@@ -102,12 +102,16 @@ void HELPER(wcsr_dc)(CPULM32State *env, uint32_t dc)
 
 void HELPER(wcsr_im)(CPULM32State *env, uint32_t im)
 {
+    qemu_mutex_lock_iothread();
     lm32_pic_set_im(env->pic_state, im);
+    qemu_mutex_unlock_iothread();
 }
 
 void HELPER(wcsr_ip)(CPULM32State *env, uint32_t im)
 {
+    qemu_mutex_lock_iothread();
     lm32_pic_set_ip(env->pic_state, im);
+    qemu_mutex_unlock_iothread();
 }
 
 void HELPER(wcsr_jtx)(CPULM32State *env, uint32_t jtx)
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] New documentation for the LatticeMicro32 target
  2018-01-09 11:58         ` Peter Maydell
  2018-01-09 17:01           ` [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register Michael Walle
@ 2018-01-09 17:04           ` Michael Walle
  1 sibling, 0 replies; 13+ messages in thread
From: Michael Walle @ 2018-01-09 17:04 UTC (permalink / raw)
  To: Peter Maydell; +Cc: Programmingkid, qemu-devel@nongnu.org qemu-devel

Am 2018-01-09 12:58, schrieb Peter Maydell:
> I just fell over this, it looks like this fix never made it into 
> master.
> 
> Michael, could you submit this as a full patch with a commit message
> and signed-off-by, please? cc: qemu-stable@nongnu.org as well, since
> it fixes a "breaks the board completely" bug.

oops, sorry about that :(

-michael

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register
  2018-01-09 17:01           ` [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register Michael Walle
@ 2018-02-01  9:09             ` Michael Walle
  2018-05-09 19:45               ` Philippe Mathieu-Daudé
  2018-05-10 13:00             ` Alex Bennée
  1 sibling, 1 reply; 13+ messages in thread
From: Michael Walle @ 2018-02-01  9:09 UTC (permalink / raw)
  To: qemu-devel; +Cc: peter.maydell, Programmingkid, qemu-stable


Hi Peter,

do you apply this patch? Or do I have to send a pull request?

-michael

Am 2018-01-09 18:01, schrieb Michael Walle:
> Writing to these registers may raise an interrupt request. Actually,
> this prevents the milkymist board from starting.
> 
> Cc: qemu-stable@nongnu.org
> Signed-off-by: Michael Walle <michael@walle.cc>
> ---
>  target/lm32/op_helper.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/target/lm32/op_helper.c b/target/lm32/op_helper.c
> index 30f670eee8..a766a1ece4 100644
> --- a/target/lm32/op_helper.c
> +++ b/target/lm32/op_helper.c
> @@ -102,12 +102,16 @@ void HELPER(wcsr_dc)(CPULM32State *env, uint32_t 
> dc)
> 
>  void HELPER(wcsr_im)(CPULM32State *env, uint32_t im)
>  {
> +    qemu_mutex_lock_iothread();
>      lm32_pic_set_im(env->pic_state, im);
> +    qemu_mutex_unlock_iothread();
>  }
> 
>  void HELPER(wcsr_ip)(CPULM32State *env, uint32_t im)
>  {
> +    qemu_mutex_lock_iothread();
>      lm32_pic_set_ip(env->pic_state, im);
> +    qemu_mutex_unlock_iothread();
>  }
> 
>  void HELPER(wcsr_jtx)(CPULM32State *env, uint32_t jtx)

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register
  2018-02-01  9:09             ` Michael Walle
@ 2018-05-09 19:45               ` Philippe Mathieu-Daudé
  2018-05-10 13:35                 ` Paolo Bonzini
  0 siblings, 1 reply; 13+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-05-09 19:45 UTC (permalink / raw)
  To: Michael Walle, peter.maydell, Paolo Bonzini
  Cc: qemu-devel, qemu-stable, Programmingkid

On 02/01/2018 06:09 AM, Michael Walle wrote:
> 
> Hi Peter,
> 
> do you apply this patch? Or do I have to send a pull request?

Cc'ing Paolo.

> 
> -michael
> 
> Am 2018-01-09 18:01, schrieb Michael Walle:
>> Writing to these registers may raise an interrupt request. Actually,
>> this prevents the milkymist board from starting.
>>
>> Cc: qemu-stable@nongnu.org
>> Signed-off-by: Michael Walle <michael@walle.cc>

Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

>> ---
>>  target/lm32/op_helper.c | 4 ++++
>>  1 file changed, 4 insertions(+)
>>
>> diff --git a/target/lm32/op_helper.c b/target/lm32/op_helper.c
>> index 30f670eee8..a766a1ece4 100644
>> --- a/target/lm32/op_helper.c
>> +++ b/target/lm32/op_helper.c
>> @@ -102,12 +102,16 @@ void HELPER(wcsr_dc)(CPULM32State *env, uint32_t
>> dc)
>>
>>  void HELPER(wcsr_im)(CPULM32State *env, uint32_t im)
>>  {
>> +    qemu_mutex_lock_iothread();
>>      lm32_pic_set_im(env->pic_state, im);
>> +    qemu_mutex_unlock_iothread();
>>  }
>>
>>  void HELPER(wcsr_ip)(CPULM32State *env, uint32_t im)
>>  {
>> +    qemu_mutex_lock_iothread();
>>      lm32_pic_set_ip(env->pic_state, im);
>> +    qemu_mutex_unlock_iothread();
>>  }
>>
>>  void HELPER(wcsr_jtx)(CPULM32State *env, uint32_t jtx)
> 

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register
  2018-01-09 17:01           ` [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register Michael Walle
  2018-02-01  9:09             ` Michael Walle
@ 2018-05-10 13:00             ` Alex Bennée
  1 sibling, 0 replies; 13+ messages in thread
From: Alex Bennée @ 2018-05-10 13:00 UTC (permalink / raw)
  To: Michael Walle; +Cc: qemu-devel, peter.maydell, qemu-stable, Programmingkid


Michael Walle <michael@walle.cc> writes:

> Writing to these registers may raise an interrupt request. Actually,
> this prevents the milkymist board from starting.
>
> Cc: qemu-stable@nongnu.org
> Signed-off-by: Michael Walle <michael@walle.cc>

Reviewed-by: Alex Bennée <alex.bennee@linaro.org>

> ---
>  target/lm32/op_helper.c | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/target/lm32/op_helper.c b/target/lm32/op_helper.c
> index 30f670eee8..a766a1ece4 100644
> --- a/target/lm32/op_helper.c
> +++ b/target/lm32/op_helper.c
> @@ -102,12 +102,16 @@ void HELPER(wcsr_dc)(CPULM32State *env, uint32_t dc)
>
>  void HELPER(wcsr_im)(CPULM32State *env, uint32_t im)
>  {
> +    qemu_mutex_lock_iothread();
>      lm32_pic_set_im(env->pic_state, im);
> +    qemu_mutex_unlock_iothread();
>  }
>
>  void HELPER(wcsr_ip)(CPULM32State *env, uint32_t im)
>  {
> +    qemu_mutex_lock_iothread();
>      lm32_pic_set_ip(env->pic_state, im);
> +    qemu_mutex_unlock_iothread();
>  }
>
>  void HELPER(wcsr_jtx)(CPULM32State *env, uint32_t jtx)


--
Alex Bennée

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register
  2018-05-09 19:45               ` Philippe Mathieu-Daudé
@ 2018-05-10 13:35                 ` Paolo Bonzini
  0 siblings, 0 replies; 13+ messages in thread
From: Paolo Bonzini @ 2018-05-10 13:35 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, Michael Walle, peter.maydell
  Cc: qemu-devel, qemu-stable, Programmingkid

On 09/05/2018 21:45, Philippe Mathieu-Daudé wrote:
> On 02/01/2018 06:09 AM, Michael Walle wrote:
>>
>> Hi Peter,
>>
>> do you apply this patch? Or do I have to send a pull request?
> 
> Cc'ing Paolo.

Please send a pull request.

Paolo

>>
>> -michael
>>
>> Am 2018-01-09 18:01, schrieb Michael Walle:
>>> Writing to these registers may raise an interrupt request. Actually,
>>> this prevents the milkymist board from starting.
>>>
>>> Cc: qemu-stable@nongnu.org
>>> Signed-off-by: Michael Walle <michael@walle.cc>
> 
> Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> 
>>> ---
>>>  target/lm32/op_helper.c | 4 ++++
>>>  1 file changed, 4 insertions(+)
>>>
>>> diff --git a/target/lm32/op_helper.c b/target/lm32/op_helper.c
>>> index 30f670eee8..a766a1ece4 100644
>>> --- a/target/lm32/op_helper.c
>>> +++ b/target/lm32/op_helper.c
>>> @@ -102,12 +102,16 @@ void HELPER(wcsr_dc)(CPULM32State *env, uint32_t
>>> dc)
>>>
>>>  void HELPER(wcsr_im)(CPULM32State *env, uint32_t im)
>>>  {
>>> +    qemu_mutex_lock_iothread();
>>>      lm32_pic_set_im(env->pic_state, im);
>>> +    qemu_mutex_unlock_iothread();
>>>  }
>>>
>>>  void HELPER(wcsr_ip)(CPULM32State *env, uint32_t im)
>>>  {
>>> +    qemu_mutex_lock_iothread();
>>>      lm32_pic_set_ip(env->pic_state, im);
>>> +    qemu_mutex_unlock_iothread();
>>>  }
>>>
>>>  void HELPER(wcsr_jtx)(CPULM32State *env, uint32_t jtx)
>>

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2018-05-10 13:35 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-09 15:39 [Qemu-devel] New documentation for the LatticeMicro32 target Programmingkid
2017-07-17  5:40 ` Michael Walle
2017-07-17 14:56   ` Programmingkid
2017-07-17 15:18     ` Programmingkid
2017-07-18 11:44       ` Michael Walle
2017-07-18 14:05         ` Programmingkid
2018-01-09 11:58         ` Peter Maydell
2018-01-09 17:01           ` [Qemu-devel] [PATCH] lm32: take BQL before writing IP/IM register Michael Walle
2018-02-01  9:09             ` Michael Walle
2018-05-09 19:45               ` Philippe Mathieu-Daudé
2018-05-10 13:35                 ` Paolo Bonzini
2018-05-10 13:00             ` Alex Bennée
2018-01-09 17:04           ` [Qemu-devel] New documentation for the LatticeMicro32 target Michael Walle

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.