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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4C926303.9090206@kernel.dk>
Date:	Thu, 16 Sep 2010 20:33:39 +0200
From:	Jens Axboe <axboe@...nel.dk>
To:	Jan Kara <jack@...e.cz>
CC:	linux-kernel@...r.kernel.org, tj@...nel.org
Subject: Re: [PATCH] block: Fix race during disk initialization

On 2010-09-16 20:20, Jan Kara wrote:
> When a new disk is being discovered, add_disk() first ties the bdev to gendisk
> (via register_disk()->blkdev_get()) and only after that calls
> bdi_register_bdev(). Because register_disk() also creates disk's kobject, it
> can happen that userspace manages to open and modify the device's data (or
> inode) before its BDI is properly initialized leading to a warning in
> __mark_inode_dirty().
> 
> Fix the problem by registering BDI early enough.
> 
> This patch addresses https://bugzilla.kernel.org/show_bug.cgi?id=16312
> 
> Reported-by: Larry Finger <Larry.Finger@...inger.net>
> Signed-off-by: Jan Kara <jack@...e.cz>
> ---
>  block/genhd.c |    6 ++++--
>  1 files changed, 4 insertions(+), 2 deletions(-)
> 
>  Jens, would you consider merging this fix? The kernel boots with it but
> I'm not too familiar with this area of kernel so there can be something subtle
> I've missed. So please review. Thanks.

It looks sane. How about we add it to the .37 lineup and mark it for
stable backport?

-- 
Jens Axboe

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