From: Muhammad Usama Anjum <musamaanjum@gmail.com>
To: Colin King <colin.king@canonical.com>,
Jens Axboe <axboe@kernel.dk>,
Dan Schatzberg <schatzberg.dan@gmail.com>,
linux-block@vger.kernel.org
Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] loop: Fix missing max_active argument in alloc_workqueue call
Date: Fri, 19 Mar 2021 00:18:25 +0500 [thread overview]
Message-ID: <2f7b725b755350136b0ba8cedd3e342f8234834c.camel@gmail.com> (raw)
In-Reply-To: <20210318151626.17442-1-colin.king@canonical.com>
On Thu, 2021-03-18 at 15:16 +0000, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> The 3rd argument to alloc_workqueue should be the max_active count,
> however currently it is the lo->lo_number that is intended for the
> loop%d number. Fix this by adding in the missing max_active count.
>
> Addresses-Coverity: ("Missing argument to printf")
> Fixes: 08ad7f822739 ("loop: Use worker per cgroup instead of kworker")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> drivers/block/loop.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/block/loop.c b/drivers/block/loop.c
> index f2f9e4127847..ee2a6c1bc093 100644
> --- a/drivers/block/loop.c
> +++ b/drivers/block/loop.c
> @@ -1192,7 +1192,7 @@ static int loop_configure(struct loop_device *lo, fmode_t mode,
> lo->workqueue = alloc_workqueue("loop%d",
> WQ_UNBOUND | WQ_FREEZABLE |
> WQ_MEM_RECLAIM,
> - lo->lo_number);
> + 1, lo->lo_number);
> if (!lo->workqueue) {
> error = -ENOMEM;
> goto out_unlock;
Nice catch.
Reviewed-by: Muhammad Usama Anjum <musamaanjum@gmail.com>
next prev parent reply other threads:[~2021-03-18 19:19 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-18 15:16 Colin King
2021-03-18 19:18 ` Muhammad Usama Anjum [this message]
2021-03-18 20:12 ` Jens Axboe
2021-03-18 20:24 ` Colin Ian King
2021-03-18 20:42 ` Jens Axboe
2021-03-19 9:47 ` Dan Carpenter
2021-03-19 10:03 ` Krzysztof Kozlowski
2021-03-19 13:02 ` Jens Axboe
2021-03-19 9:59 ` Krzysztof Kozlowski
2021-03-19 13:05 ` Jens Axboe
2021-03-19 15:51 ` Dan Schatzberg
2021-03-19 15:54 ` Dan Schatzberg
2021-03-19 15:56 ` Colin Ian King
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=2f7b725b755350136b0ba8cedd3e342f8234834c.camel@gmail.com \
--to=musamaanjum@gmail.com \
--cc=axboe@kernel.dk \
--cc=colin.king@canonical.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=schatzberg.dan@gmail.com \
/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
all inboxes | Powered by JetHome®