lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 7 Apr 2011 16:40:25 +0300
From:	Alexey Dobriyan <adobriyan@...il.com>
To:	Lai Jiangshan <laijs@...fujitsu.com>
Cc:	paulmck@...ux.vnet.ibm.com, "H. Peter Anvin" <hpa@...ux.intel.com>,
	Peter Zijlstra <peterz@...radead.org>,
	Michal Marek <mmarek@...e.cz>,
	Jan Beulich <JBeulich@...ell.com>, Ingo Molnar <mingo@...e.hu>,
	Alexander van Heukelum <heukelum@...tmail.fm>,
	Dipankar Sarma <dipankar@...ibm.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Sam Ravnborg <sam@...nborg.org>,
	David Howells <dhowells@...hat.com>,
	Oleg Nesterov <oleg@...hat.com>,
	Roland McGrath <roland@...hat.com>,
	linux-kernel@...r.kernel.org, Thomas Gleixner <tglx@...utronix.de>,
	Steven Rostedt <rostedt@...dmis.org>
Subject: Re: [PATCH 3/4] rcu: introduce task_rcu_struct and move task's RCU
 code to rcupdate_defs.h

On Thu, Apr 7, 2011 at 10:07 AM, Lai Jiangshan <laijs@...fujitsu.com> wrote:
> Add struct task_rcu_struct to make code clearer and move
> them to rcupdate_defs.h which help us for code maitainment.

> --- a/include/linux/sched.h
> +++ b/include/linux/sched.h
> @@ -1232,17 +1232,7 @@ struct task_struct {
>        unsigned int policy;
>        cpumask_t cpus_allowed;
>
> -#ifdef CONFIG_PREEMPT_RCU
> -       int rcu_read_lock_nesting;
> -       char rcu_read_unlock_special;
> -       struct list_head rcu_node_entry;
> -#endif /* #ifdef CONFIG_PREEMPT_RCU */
> -#ifdef CONFIG_TREE_PREEMPT_RCU
> -       struct rcu_node *rcu_blocked_node;
> -#endif /* #ifdef CONFIG_TREE_PREEMPT_RCU */
> -#ifdef CONFIG_RCU_BOOST
> -       struct rt_mutex *rcu_boost_mutex;
> -#endif /* #ifdef CONFIG_RCU_BOOST */
> +       struct task_rcu_struct task_rcu_struct;

Oh, wow, all these movements are for this.

You could do

    struct task_rcu {
        ...
    } rcu;

inside sched.h, drop pointless 1:1 current_() et al wrappers and
avoid all this mess.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ