[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller mod
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller model |
Date: |
Mon, 16 Jul 2012 18:13:28 +0100 |
On 5 July 2012 05:04, Peter A. G. Crosthwaite
<address@hidden> wrote:
> From: Igor Mitsyanko <address@hidden>
>
> Custom Exynos4210 SD/MMC host controller, based on SD association standard
> host
> controller ver. 2.00.
>
> Signed-off-by: Igor Mitsyanko <address@hidden>
> ---
> changed from v4 (Igor):
> set irq on SLOTINT status instead of interrupt registers status; instead;
The IRQ handling code still looks really weird. I would expect
that the code would be:
[code which updates various kinds of irq related state]
sdhci_update_irq();
where sdhci_update_irq() calls qemu_set_irq() based on the state.
At the moment it looks as if you're using slotint as a cached value
of the expression
"((s->norintsts & s->norintsigen) || (s->errintsts & s->errintsigen) ||
((s->norintsts & SDHC_NIS_INSERT) && (s->wakcon & SDHC_WKUP_ON_INS)) ||
((s->norintsts & SDHC_NIS_REMOVE) && (s->wakcon & SDHC_WKUP_ON_RMV)))"
[can these two ever have different values?] and also attempting to
shortcut by manually updating slotint in codepaths which change only
parts of the state which this expression is testing. Why not just do
things the simple and straightforward way and get rid of slotint
completely?
-- PMM
- [Qemu-devel] [PATCH v5 0/4] Standard SD host controller model, Peter A. G. Crosthwaite, 2012/07/05
- [Qemu-devel] [PATCH v5 1/4] hw: introduce standard SD host controller, Peter A. G. Crosthwaite, 2012/07/05
- [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller model, Peter A. G. Crosthwaite, 2012/07/05
- Re: [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller model,
Peter Maydell <=
- Re: [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller model, Igor Mitsyanko, 2012/07/17
- Re: [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller model, Peter Maydell, 2012/07/17
- Re: [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller model, Igor Mitsyanko, 2012/07/17
- Re: [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller model, Peter Maydell, 2012/07/17
- Re: [Qemu-devel] [PATCH v5 2/4] exynos4210: Added SD host controller model, Peter Crosthwaite, 2012/07/18
[Qemu-devel] [PATCH v5 3/4] vl.c: allow for repeated -sd arguments, Peter A. G. Crosthwaite, 2012/07/05
[Qemu-devel] [PATCH v5 4/4] xilinx_zynq: Added SD controllers, Peter A. G. Crosthwaite, 2012/07/05