On 31.05.19 17:05, Richard Henderson wrote: > On 5/31/19 9:56 AM, David Hildenbrand wrote: >> @@ -678,7 +678,7 @@ uint32_t HELPER(stfle)(CPUS390XState *env, uint64_t addr) >> >> prepare_stfl(); >> max_bytes = ROUND_UP(used_stfl_bytes, 8); >> - for (i = 0; i < count_bytes; ++i) { >> + for (i = 0; i < MIN(count_bytes, max_bytes); ++i) { > > Before the loop, please put something like > > /* > * The PoP says that doublewords beyond the highest-numbered > * facility bit may or may not be stored. However, existing > * hardware appears to not store the words, and existing > * software appears to depend on that. > */ > > with that, > Reviewed-by: Richard Henderson <richard.hender...@linaro.org> >
Makes sense, thanks for the ultra-fast review! (have a great weekend!) -- Thanks, David / dhildenb