[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3] Undefine SWP instruction unless SCTLR.SW bit
From: |
Alexey Starikovskiy |
Subject: |
Re: [Qemu-devel] [PATCH v3] Undefine SWP instruction unless SCTLR.SW bit is set |
Date: |
Tue, 17 Apr 2012 17:11:20 +0400 |
> Adding this brace is incorrectly changing behaviour.
> (I agree that it's pretty obscure and halfway to being an
> outright bug. It all goes away with the cp15 rework anyway.)
Should I add tb_flush() without braces too or set second if() only to
avoid changing the bogus behavior?
>> + /* This may enable/disable SWP instruction, so do TB flush too
>> */
>> + tb_flush(env);
>> + }
> This is not the reason. You can perfectly well run user-mode with
> a specific -cpu option. The reason for this ifdef is that the
> Linux kernel has SWP emulation code, so SWP has to work either
> because we force the implementation here to work, or by making
> it take an UNDEF exception and then implementing it inside
> linux-user/main.c. Doing the former is slightly simpler.
Linux kernel _might_ have emulation for SWP depending on config.
So, what should I do? Change comment?
- [Qemu-devel] [RFC PATCH] disable execution of SWP/SWPB, Alexey Starikovskiy, 2012/04/17
- Re: [Qemu-devel] [RFC PATCH] disable execution of SWP/SWPB, Peter Maydell, 2012/04/17
- [Qemu-devel] [PATCH] Undefine SWP instruction unless SCTLR.SW bit is set, Alexey Starikovskiy, 2012/04/17
- Re: [Qemu-devel] [PATCH] Undefine SWP instruction unless SCTLR.SW bit is set, Peter Maydell, 2012/04/17
- Re: [Qemu-devel] [PATCH] Undefine SWP instruction unless SCTLR.SW bit is set, Alexey Starikovskiy, 2012/04/17
- Re: [Qemu-devel] [PATCH] Undefine SWP instruction unless SCTLR.SW bit is set, Peter Maydell, 2012/04/17
- [Qemu-devel] [PATCH v2] Undefine SWP instruction unless SCTLR.SW bit is set, Alexey Starikovskiy, 2012/04/17
- Re: [Qemu-devel] [PATCH v2] Undefine SWP instruction unless SCTLR.SW bit is set, Peter Maydell, 2012/04/17
- [Qemu-devel] [PATCH v3] Undefine SWP instruction unless SCTLR.SW bit is set, Alexey Starikovskiy, 2012/04/17
- Re: [Qemu-devel] [PATCH v3] Undefine SWP instruction unless SCTLR.SW bit is set, Peter Maydell, 2012/04/17
- Re: [Qemu-devel] [PATCH v3] Undefine SWP instruction unless SCTLR.SW bit is set,
Alexey Starikovskiy <=
- Re: [Qemu-devel] [PATCH v3] Undefine SWP instruction unless SCTLR.SW bit is set, Peter Maydell, 2012/04/17
- [Qemu-devel] [PATCH v4] Undefine SWP instruction unless SCTLR.SW bit is set, Alexey Starikovskiy, 2012/04/17