lkml.org 
[lkml]   [2008]   [Sep]   [5]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
SubjectRE: mmc/card/block.c : mmc_blk_open readonly mount bug?
DateFri, 5 Sep 2008 13:36:06 +0800
From<>
Guess nobody tests with readonly?  We had a socket on our board that
flipped the write protect signal, and the rest you know :-)

-----Original Message-----
From: Pierre Ossman [mailto:drzeus-list@drzeus.cx] 
Sent: Friday, September 05, 2008 1:07 PM
To: Andrew Morton
Cc: Sasi Nair; linux-kernel@vger.kernel.org
Subject: Re: mmc/card/block.c : mmc_blk_open readonly mount bug?

On Thu, 4 Sep 2008 16:08:08 -0700
Andrew Morton <akpm@linux-foundation.org> wrote:

> From: Andrew Morton <akpm@linux-foundation.org>
> 
> mmc_block_open() increments md->usage although it returns with -EROFS
when
> default mounting a MMC/SD card with write protect switch on.  This
> reference counting bug prevents /dev/mmcblkX from being released on
card
> removal, and situation worsen with reinsertion until the minor number
> range runs out.
> 
> Reported-by: <sasin@solomon-systech.com>
> Cc: Pierre Ossman <drzeus-list@drzeus.cx>
> Cc: <stable@kernel.org>		[2.6.25.x, 2.6.26.x]
> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
> ---

I wonder how that bug has been able to go unnoticed for so long...

Acked-by: Pierre Ossman <drzeus@drzeus.cx>

-- 
     -- Pierre Ossman

  Linux kernel, MMC maintainer        http://www.kernel.org
  rdesktop, core developer          http://www.rdesktop.org

  WARNING: This correspondence is being monitored by the
  Swedish government. Make sure your server uses encryption
  for SMTP traffic and consider using PGP for end-to-end
  encryption.


\
 
 \ /
  Last update: 2008-09-05 07:37    [from the cache]
©2003-2008