public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: catboat@texas.net
To: David Woodhouse <dwmw2@infradead.org>
Cc: catboat@texas.net, linux-mtd@lists.infradead.org
Subject: Re: dynamic mtd_blktrans_dev not fully init'd under UBI?
Date: Sat, 01 Dec 2007 11:00:23 -0600	[thread overview]
Message-ID: <1196528423.475193277199d@www.webmail.texas.net> (raw)
In-Reply-To: <1196501291.13978.77.camel@pmac.infradead.org>



Thanks David. 




Quoting David Woodhouse <dwmw2@infradead.org>:

> On Fri, 2007-11-30 at 14:58 -0600, catboat@texas.net wrote:
> > In the newest git, I see a mutex named "lock" instead, but 
> > I don't think it's initialized either. See the function 
> > mtdblock_add_mtd() in drivers/mtd/mtdblock.c. The struct
> > mtd_blktrans_dev is just kzalloc'd leaving the mutex lock
> > all zeroes. 
> 
> diff --git a/drivers/mtd/mtd_blkdevs.c b/drivers/mtd/mtd_blkdevs.c
> index 74d9d30..839eed8 100644
> --- a/drivers/mtd/mtd_blkdevs.c
> +++ b/drivers/mtd/mtd_blkdevs.c
> @@ -248,9 +248,9 @@ int add_mtd_blktrans_dev(struct mtd_blktrans_dev *new)
>  		return -EBUSY;
>  	}
>  
> -	mutex_init(&new->lock);
>  	list_add_tail(&new->list, &tr->devs);
>   added:
> +	mutex_init(&new->lock);
>  	if (!tr->writesect)
>  		new->readonly = 1;
>  
> 
> -- 
> dwmw2
> 
> 
> 

      reply	other threads:[~2007-12-01 17:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-30 20:58 dynamic mtd_blktrans_dev not fully init'd under UBI? catboat
2007-12-01  9:28 ` David Woodhouse
2007-12-01 17:00   ` catboat [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1196528423.475193277199d@www.webmail.texas.net \
    --to=catboat@texas.net \
    --cc=dwmw2@infradead.org \
    --cc=linux-mtd@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox