lkml.org 
[lkml]   [2022]   [Feb]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH v10 1/10] add basic task isolation prctl interface
On Sat, Jan 29, 2022 at 04:22:07AM +0000, 向 景亘 wrote:
> Hi,
>
> On Jan 28, 2022, at 1:30 AM, Marcelo Tosatti <mtosatti@redhat.com> wrote:
> >
> > Index: linux-2.6/include/linux/task_isolation.h
> > ===================================================================
> > --- /dev/null
> > +++ linux-2.6/include/linux/task_isolation.h
> > @@ -0,0 +1,91 @@
> > +/* SPDX-License-Identifier: GPL-2.0 */
> > +
> > +#ifndef __LINUX_TASK_ISOL_H
> > +#define __LINUX_TASK_ISOL_H
> > +
> > +#ifdef CONFIG_TASK_ISOLATION
> > +
> > +struct task_isol_info {
> > + /* Which features have been configured */
> > + u64 conf_mask;
> > + /* Which features are active */
> > + u64 active_mask;
> > + /* Quiesce mask */
> > + u64 quiesce_mask;
> > +
> > + /* Oneshot mask */
> > + u64 oneshot_mask;
> > +
> > + u8 inherit_mask;
> > +};
> > +
> > +extern void __task_isol_free(struct task_struct *tsk);
> > +
> > +static inline void task_isol_free(struct task_struct *tsk)
> > +{
> > + if (tsk->task_isol_info)
> > + __task_isol_free(tsk);
> > +}
> > +
> > +int prctl_task_isol_feat_get(unsigned long arg2, unsigned long arg3,
> > + unsigned long arg4, unsigned long arg5);
> > +int prctl_task_isol_cfg_get(unsigned long arg2, unsigned long arg3,
> > + unsigned long arg4, unsigned long arg5);
> > +int prctl_task_isol_cfg_set(unsigned long arg2, unsigned long arg3,
> > + unsigned long arg4, unsigned long arg5);
> > +int prctl_task_isol_activate_get(unsigned long arg2, unsigned long arg3,
> > + unsigned long arg4, unsigned long arg5);
> > +int prctl_task_isol_activate_set(unsigned long arg2, unsigned long arg3,
> > + unsigned long arg4, unsigned long arg5);
> > +
> > +int __copy_task_isol(struct task_struct *tsk);
> > +
> > +#else
> > +
> > +static inline void task_isol_free(struct task_struct *tsk)
> > +{
> > +}
> > +
> > +static inline int prctl_task_isol_feat_get(unsigned long arg2,
> > + unsigned long arg3,
> > + unsigned long arg4,
> > + unsigned long arg5)
> > +{
> > + return -EOPNOTSUPP;
> > +}
> > +
> > +static inline int prctl_task_isoln_cfg_get(unsigned long arg2,
> I think this line should be "prctl_task_isol_cfg_get".

Yes, fixed, thanks!

\
 
 \ /
  Last update: 2022-02-02 19:42    [W:0.077 / U:0.152 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site