Hi Julien,

Julien Grall <jul...@xen.org> writes:

> Hi,
>
> Hi Volodymyr,
>
> On 22/11/2024 21:07, Volodymyr Babchuk wrote:
>> diff --git a/xen/include/xen/stack_protector.h 
>> b/xen/include/xen/stack_protector.h
>> new file mode 100644
>> index 0000000000..97f1eb5ac0
>> --- /dev/null
>> +++ b/xen/include/xen/stack_protector.h
>> @@ -0,0 +1,30 @@
>> +/* SPDX-License-Identifier: GPL-2.0-only */
>> +
>> +#ifndef XEN__STACK_PROTECTOR_H
>> +#define XEN__STACK_PROTECTOR_H
>> +
>> +#ifdef CONFIG_STACKPROTECTOR
>> +
>> +#ifndef CONFIG_X86
>> +extern unsigned long __stack_chk_guard;
>
> Is this variable meant to change after boot? If not, then can you tag
> it with __ro_after_init?
>

No, changing it after boot will lead to a random panic. So yes, it is good
idea to make it RO.

-- 
WBR, Volodymyr

Reply via email to