On 02.09.2026 13:47, Orzel, Michal wrote:
> On 02-Sep-26 08:32, Jan Beulich wrote:
>> We want to patch the original call site, which memory-wise is unrelated
>> to the struct alt_instr * that we start from.
>>
>> No functional change intended.
>>
>> Signed-off-by: Jan Beulich <[email protected]>
>>
>> --- a/xen/arch/arm/alternative.c
>> +++ b/xen/arch/arm/alternative.c
>> @@ -134,7 +134,7 @@ static int __apply_alternatives(const st
>>              BUG_ON(alt->repl_len != alt->orig_len);
>>  
>>          origptr = ALT_ORIG_PTR(alt);
>> -        updptr = (void *)origptr + update_offset;
>> +        updptr = (void *)(long)origptr + update_offset;
> NIT: Why long and not unsigned long like other places in this file?

Hmm, that was inherited from "x86/altcall: hide casting away of const",
yet apparently wrongly so: update_offset is of unsigned type here. I've
switched locally.

> Reviewed-by: Michal Orzel <[email protected]>

Thanks.

Jan

Reply via email to