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: <20120413133226.GB26383@redhat.com>
Date:	Fri, 13 Apr 2012 09:32:26 -0400
From:	Vivek Goyal <vgoyal@...hat.com>
To:	Tejun Heo <tj@...nel.org>
Cc:	axboe@...nel.dk, ctalbott@...gle.com, rni@...gle.com,
	linux-kernel@...r.kernel.org, cgroups@...r.kernel.org,
	containers@...ts.linux-foundation.org
Subject: Re: [PATCH 1/8] blkcg: kill blkio_list and replace blkio_list_lock
 with a mutex

On Thu, Apr 12, 2012 at 04:29:33PM -0700, Tejun Heo wrote:

Hi Tejun,

> @@ -732,20 +732,21 @@ void blkio_policy_register(struct blkio_policy_type *blkiop)
>  {
>  	struct request_queue *q;
>  
> +	mutex_lock(&blkcg_pol_mutex);
> +
>  	blkcg_bypass_start();
> -	spin_lock(&blkio_list_lock);
>  
>  	BUG_ON(blkio_policy[blkiop->plid]);

A minor nit. It might be a good idea to check that blkiop->plid is not
greater than BLKIO_NR_POLICIES for both registration and unresitration
functions to avoid touching memory beyond blkio_policy[] array.

Thanks
Vivek
--
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