Re: [PATCH] core_pattern: add CPU specifier

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

 



On 09/04, Andrew Morton wrote:
>
> On Sat,  3 Sep 2022 08:43:30 +0200 Oleksandr Natalenko <oleksandr@xxxxxxxxxx> wrote:
>
> > @@ -535,6 +539,7 @@ void do_coredump(const kernel_siginfo_t *siginfo)
> >  		 */
> >  		.mm_flags = mm->flags,
> >  		.vma_meta = NULL,
> > +		.cpu = raw_smp_processor_id(),
> >  	};
>
> Why use the "raw_" function here?

To avoid check_preemption_disabled() from debug_smp_processor_id().

We do not disable preemption because this is pointless, this is the
"racy snapshot" anyway. The coredumping task can migrate to another
CPU even before get_signal/do_coredump, right after exit-to-user
path enables irqs.

Oleg.




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux