qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v3 27/32] s390x/tcg: Provide probe_write_access


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH v3 27/32] s390x/tcg: Provide probe_write_access helper
Date: Thu, 7 Mar 2019 06:10:27 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0

On 3/7/19 4:15 AM, David Hildenbrand wrote:
> +void probe_write_access(CPUS390XState *env, uint64_t addr, uint64_t len,
> +                        uintptr_t ra)
> +{
> +#ifdef CONFIG_USER_ONLY
> +    if (!h2g_valid(addr) || !h2g_valid(addr + len - 1)) {
> +        s390_program_interrupt(env, PGM_ADDRESSING, ILEN_AUTO, ra);
> +    }

You need

  || page_check_range(addr, len, PAGE_WRITE) < 0

as well.


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]