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]
Message-Id: <200903190023.56929.dmitry.torokhov@gmail.com>
Date:	Thu, 19 Mar 2009 00:23:56 -0700
From:	Dmitry Torokhov <dmitry.torokhov@...il.com>
To:	Arjan van de Ven <arjan@...radead.org>
Cc:	linux-input@...r.kernel.org, dipankar@...ibm.com,
	linux-kernel@...r.kernel.org
Subject: Re: Question about usage of RCU in the input layer

Hi Arjan,

On Wednesday 18 March 2009 21:58:12 Arjan van de Ven wrote:
> Hi,
>
> the input layer does a "synchronize_rcu()" after a list_add_tail_rcu(),
> which is costing me 1 second of boot time.....
> And based on my understanding of the RCU concept, you only need to
> synchronize on delete, not on addition... so I think the synchronize is
> entirely redundant here...


It is there to guarantee that once we registered the handle all
subsequent input events will be delivered through it.
 
>
> Can I have my second of boot time back please ?
>

Not like this I'm afraid but I will see what I can do.

>
>
> diff --git a/drivers/input/input.c b/drivers/input/input.c
> index 1730d73..d69ec56 100644
> --- a/drivers/input/input.c
> +++ b/drivers/input/input.c
> @@ -1544,7 +1544,6 @@ int input_register_handle(struct input_handle
> *handle) return error;
>  	list_add_tail_rcu(&handle->d_node, &dev->h_list);
>  	mutex_unlock(&dev->mutex);
> -	synchronize_rcu();
>
>  	/*
>  	 * Since we are supposed to be called from ->connect()

-- 
Dmitry
--
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