[PATCH 04/21] kernel: export ptrace_may_access
Mika Kuoppala
mika.kuoppala at linux.intel.com
Wed Aug 21 11:46:32 UTC 2024
Andi Shyti <andi.shyti at linux.intel.com> writes:
> Hi Mika,
>
> On Fri, Jul 26, 2024 at 05:08:01PM +0300, Mika Kuoppala wrote:
>> We need to export ptrace_may_access to be able to
>> allow debugger connection to check for debuggee access and
>> at the same time allow xe.ko module build.
>>
>> CC: Lucas De Marchi <lucas.demarchi at intel.com>
>> Signed-off-by: Mika Kuoppala <mika.kuoppala at linux.intel.com>
>> CC: Andi Shyti <andi.shyti at intel.com>
>> CC: Maciej Patelczyk <maciej.patelczyk at linux.intel.com>
>> Signed-off-by: Jonathan Cavitt <jonathan.cavitt at intel.com>
>
> Just one note here: the tag order matters a little, the signature
> of from the sender should take the last place.
I will ping Jonathan to remove the sob as this might be residue
of splitting patches. He is credited on the actual application
of ptrace_may_access and the original EXPORT parts are mine.
>
>> ---
>> kernel/ptrace.c | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/kernel/ptrace.c b/kernel/ptrace.c
>> index d5f89f9ef29f..86be1805ebd8 100644
>> --- a/kernel/ptrace.c
>> +++ b/kernel/ptrace.c
>> @@ -354,6 +354,7 @@ bool ptrace_may_access(struct task_struct *task, unsigned int mode)
>> task_unlock(task);
>> return !err;
>> }
>> +EXPORT_SYMBOL_GPL(ptrace_may_access);
>
> I also believe, as suggested, that we should seek an ack from the
> maintainers here. Maybe we could have CC'ed just for this single
> patch. (You can add people in CC even after the '---' section not
> to pollute the commit log. This way you let git-send-email handle
> it).
I will move this patch to be first in series with ptrace author
and lkml included in cc.
>
> Nevertheless, same as I agreed earlier:
>
> Reviewed-by: Andi Shyti <andi.shyti at linux.intel.com>
Thanks,
-Mika
>
> Thanks,
> Andi
>
>> static int check_ptrace_options(unsigned long data)
>> {
>> --
>> 2.34.1
More information about the Intel-xe
mailing list