Linux MultiMedia Card development
 help / color / mirror / Atom feed
From: Dan Carpenter <error27@gmail.com>
To: Jiasheng Jiang <jiasheng@iscas.ac.cn>
Cc: maximlevitsky@gmail.com, oakad@yahoo.com, ulf.hansson@linaro.org,
	christophe.jaillet@wanadoo.fr, axboe@kernel.dk, hare@suse.de,
	linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] memstick/ms_block: Add check for alloc_ordered_workqueue
Date: Sat, 26 Nov 2022 11:01:40 +0300	[thread overview]
Message-ID: <Y4HH5Ch1ABrRzN5/@kadam> (raw)
In-Reply-To: <20221126012558.34374-1-jiasheng@iscas.ac.cn>

On Sat, Nov 26, 2022 at 09:25:58AM +0800, Jiasheng Jiang wrote:
> As the alloc_ordered_workqueue may return NULL pointer,
> it should be better to add check for the return
> value.
> Moreover, the msb->io_queue should be freed if error occurs later.
> 
> Fixes: 0ab30494bc4f ("memstick: add support for legacy memorysticks")
> Signed-off-by: Jiasheng Jiang <jiasheng@iscas.ac.cn>
> ---
> Changelog:
> 
> v1 -> v2:
> 
> 1. Assign error number to rc if alloc_ordered_workqueue fails.
> 2. Free msb->io_queue if error occurs later.
> ---

My other question about this driver, not really directed to you but to
anyone on the list is where the final destroy_workqueue(msb->io_queue)
is when we unload the driver.

regards,
dan carpenter


  reply	other threads:[~2022-11-26  8:01 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-26  1:25 [PATCH v2] memstick/ms_block: Add check for alloc_ordered_workqueue Jiasheng Jiang
2022-11-26  8:01 ` Dan Carpenter [this message]
2022-11-28 14:45   ` Ulf Hansson
2022-11-29 12:54 ` Ulf Hansson

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=Y4HH5Ch1ABrRzN5/@kadam \
    --to=error27@gmail.com \
    --cc=axboe@kernel.dk \
    --cc=christophe.jaillet@wanadoo.fr \
    --cc=hare@suse.de \
    --cc=jiasheng@iscas.ac.cn \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=maximlevitsky@gmail.com \
    --cc=oakad@yahoo.com \
    --cc=ulf.hansson@linaro.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