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: <95E22EAF20104309BF3938E7820F36D6@usish.com.cn>
Date:	Wed, 22 Feb 2012 12:58:08 +0800
From:	"Jack Wang" <jack_wang@...sh.com>
To:	"'Tejun Heo'" <tj@...nel.org>,
	"'Jun'ichi Nomura'" <j-nomura@...jp.nec.com>
Cc:	"'Jens Axboe'" <axboe@...nel.dk>, <linux-kernel@...r.kernel.org>,
	"'linux-scsi'" <linux-scsi@...r.kernel.org>,
	"'Naveen Goswamy'" <naveen.goswamy@...ymtl.ca>,
	"'James Bottomley'" <James.Bottomley@...senPartnership.com>,
	"'Stefan Richter'" <stefanr@...6.in-berlin.de>,
	"'Dave Jones'" <davej@...hat.com>, <sgruszka@...hat.com>,
	"'Huajun Li'" <huajun.li.lee@...il.com>
Subject: RE: [PATCH] Fix NULL pointer dereference in sd_revalidate_disk

Should this need pick up into stable too?

Jack
Re: [PATCH] Fix NULL pointer dereference in sd_revalidate_disk
> 
> On Wed, Feb 22, 2012 at 10:01:53AM +0900, Jun'ichi Nomura wrote:
> > Since 2.6.39 (1196f8b), when a driver returns -ENOMEDIUM for open(),
> > __blkdev_get() calls rescan_partitions() to remove
> > in-kernel partition structures and raise KOBJ_CHANGE uevent.
> >
> > However it ends up calling driver's revalidate_disk without open
> > and could cause oops.
> >
> > In the case of SCSI:
> >
> >   process A                  process B
> >   ----------------------------------------------
> >   sys_open
> >     __blkdev_get
> >       sd_open
> >         returns -ENOMEDIUM
> >                              scsi_remove_device
> >                                <scsi_device torn down>
> >       rescan_partitions
> >         sd_revalidate_disk
> >           <oops>
> >
> > Oopses are reported here:
> > http://marc.info/?l=linux-scsi&m=132388619710052
> >
> > This patch separates the partition invalidation from rescan_partitions()
> > and use it for -ENOMEDIUM case.
> >
> > Reported-by: Huajun Li <huajun.li.lee@...il.com>
> > Signed-off-by: Jun'ichi Nomura <j-nomura@...jp.nec.com>
> 
> Acked-by: Tejun Heo <tj@...nel.org>
> 
> Thank you!
> 
> --
> tejun
> --
> To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

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