From: Jared Holzman <jholzman@nvidia.com>
To: Ming Lei <ming.lei@redhat.com>
Cc: "linux-block@vger.kernel.org" <linux-block@vger.kernel.org>,
Jens Axboe <axboe@kernel.dk>,
csander@purestorage.com
Subject: Re: [PATCH v4]: ublk: Add UBLK_U_CMD_UPDATE_SIZE
Date: Mon, 21 Apr 2025 14:03:48 +0300 [thread overview]
Message-ID: <cf8b1de5-e60b-4ead-bbba-a4db4bb32cd5@nvidia.com> (raw)
In-Reply-To: <aAWyy9qFlURHabHM@fedora>
On 21/04/2025 5:51, Ming Lei wrote:
> On Sun, Apr 20, 2025 at 11:06:17AM +0300, Jared Holzman wrote:
>>
>>
>> On 18/04/2025 2:35, Ming Lei wrote:
>>> On Wed, Apr 16, 2025 at 01:07:47PM +0300, Jared Holzman wrote:
>>>> Currently ublk only allows the size of the ublkb block device to be
>>>> set via UBLK_CMD_SET_PARAMS before UBLK_CMD_START_DEV is triggered.
>>>>
>>>> This does not provide support for extendable user-space block devices
>>>> without having to stop and restart the underlying ublkb block device
>>>> causing IO interruption.
>>>>
>>>> This patch adds a new ublk command UBLK_U_CMD_UPDATE_SIZE to allow the
>>>> ublk block device to be resized on-the-fly.
>>>>
>>>> Feature flag UBLK_F_UPDATE_SIZE is also added to indicate support for this
>>>> command.
>>>>
>>>> Signed-off-by: Omri Mann <omri@nvidia.com>
>>>> ---
>>>> drivers/block/ublk_drv.c | 18 +++++++++++++++++-
>>>> include/uapi/linux/ublk_cmd.h | 7 +++++++
>>>> 2 files changed, 24 insertions(+), 1 deletion(-)
>>>>
>>>> diff --git a/drivers/block/ublk_drv.c b/drivers/block/ublk_drv.c
>>>> index cdb1543fa4a9..128f094efbad 100644
>>>> --- a/drivers/block/ublk_drv.c
>>>> +++ b/drivers/block/ublk_drv.c
>>>> @@ -64,7 +64,8 @@
>>>> | UBLK_F_CMD_IOCTL_ENCODE \
>>>> | UBLK_F_USER_COPY \
>>>> | UBLK_F_ZONED \
>>>> - | UBLK_F_USER_RECOVERY_FAIL_IO)
>>>> + | UBLK_F_USER_RECOVERY_FAIL_IO \
>>>> + | UBLK_F_UPDATE_SIZE)
>>>>
>>>> #define UBLK_F_ALL_RECOVERY_FLAGS (UBLK_F_USER_RECOVERY \
>>>> | UBLK_F_USER_RECOVERY_REISSUE \
>>>> @@ -3067,6 +3068,16 @@ static int ublk_ctrl_get_features(const struct
>>>> ublksrv_ctrl_cmd *header)
>>>
>>> I try to apply this patch downloaded from both lore or patchwork, and 'git
>>> am' always complains the patch is broken:
>>
>> I think this is because of my workflow. I cannot send email outside of our
>> network using git send-mail so I've been copy-pasting the patch into
>> Thunderbird.
>
> oops, copy-paste usually breaks patch style, probably `xclip` can help you
> if copy-paste can't be avoided.
Apparently Thunderbird also breaks patch style by default. I had to change some settings.
>
> You probably need to find one email client to support importing patch plain
> text from file or sending patch directly, such as mutt/msmtp,...
Should be good now. Please see v6 of the patch I just sent. I already tried downloading and applying it myself and it works.
Apologies for the noise.
>
> Thanks,
> Ming
>
prev parent reply other threads:[~2025-04-21 11:03 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-16 10:07 [PATCH v4]: ublk: Add UBLK_U_CMD_UPDATE_SIZE Jared Holzman
2025-04-17 18:23 ` Uday Shankar
2025-04-17 21:05 ` Jared Holzman
2025-04-17 23:35 ` Ming Lei
2025-04-20 8:06 ` Jared Holzman
2025-04-21 2:51 ` Ming Lei
2025-04-21 11:03 ` Jared Holzman [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=cf8b1de5-e60b-4ead-bbba-a4db4bb32cd5@nvidia.com \
--to=jholzman@nvidia.com \
--cc=axboe@kernel.dk \
--cc=csander@purestorage.com \
--cc=linux-block@vger.kernel.org \
--cc=ming.lei@redhat.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