<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/block/null_blk, branch v6.3</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v6.3</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v6.3'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2023-03-15T12:50:24Z</updated>
<entry>
<title>block: null_blk: cleanup null_queue_rq()</title>
<updated>2023-03-15T12:50:24Z</updated>
<author>
<name>Damien Le Moal</name>
<email>damien.lemoal@opensource.wdc.com</email>
</author>
<published>2023-03-14T04:11:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b6402014cab0481bdfd1ffff3e1dad714e8e1205'/>
<id>urn:sha1:b6402014cab0481bdfd1ffff3e1dad714e8e1205</id>
<content type='text'>
Use a local struct request pointer variable to avoid having to
dereference struct blk_mq_queue_data multiple times. While at it, also
fix the function argument indentation and remove a useless "else" after
a return.

Signed-off-by: Damien Le Moal &lt;damien.lemoal@opensource.wdc.com&gt;
Reviewed-by: Johannes Thumshirn &lt;johannes.thumshirn@wdc.com&gt;
Reviewed-by: Pankaj Raghav &lt;p.raghav@samsung.com&gt;
Link: https://lore.kernel.org/r/20230314041106.19173-2-damien.lemoal@opensource.wdc.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>block: null_blk: Fix handling of fake timeout request</title>
<updated>2023-03-15T12:50:23Z</updated>
<author>
<name>Damien Le Moal</name>
<email>damien.lemoal@opensource.wdc.com</email>
</author>
<published>2023-03-14T04:11:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=63f886597085f346276e3b3c8974de0100d65f32'/>
<id>urn:sha1:63f886597085f346276e3b3c8974de0100d65f32</id>
<content type='text'>
When injecting a fake timeout into the null_blk driver using
fail_io_timeout, the request timeout handler does not execute
blk_mq_complete_request(), so the complete callback is never executed
for a timedout request.

The null_blk driver also has a driver-specific fake timeout mechanism
which does not have this problem. Fix the problem with fail_io_timeout
by using the same meachanism as null_blk internal timeout feature, using
the fake_timeout field of null_blk commands.

Reported-by: Akinobu Mita &lt;akinobu.mita@gmail.com&gt;
Fixes: de3510e52b0a ("null_blk: fix command timeout completion handling")
Signed-off-by: Damien Le Moal &lt;damien.lemoal@opensource.wdc.com&gt;
Reviewed-by: Johannes Thumshirn &lt;johannes.thumshirn@wdc.com&gt;
Link: https://lore.kernel.org/r/20230314041106.19173-2-damien.lemoal@opensource.wdc.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>block: make BLK_DEF_MAX_SECTORS unsigned</title>
<updated>2023-01-29T22:18:33Z</updated>
<author>
<name>Keith Busch</name>
<email>kbusch@kernel.org</email>
</author>
<published>2023-01-05T20:51:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0a26f327e46c203229e72c823dfec71a2b405ec5'/>
<id>urn:sha1:0a26f327e46c203229e72c823dfec71a2b405ec5</id>
<content type='text'>
This is used as an unsigned value, so define it that way to avoid
having to cast it.

Suggested-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Keith Busch &lt;kbusch@kernel.org&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Bart Van Assche &lt;bvanassche@acm.org&gt;
Reviewed-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
Link: https://lore.kernel.org/r/20230105205146.3610282-2-kbusch@meta.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>null_blk: support read-only and offline zone conditions</title>
<updated>2022-12-01T21:49:48Z</updated>
<author>
<name>Shin'ichiro Kawasaki</name>
<email>shinichiro.kawasaki@wdc.com</email>
</author>
<published>2022-12-01T06:10:36Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d3a5738849e03990618cbb12e10db4eb82dbfda0'/>
<id>urn:sha1:d3a5738849e03990618cbb12e10db4eb82dbfda0</id>
<content type='text'>
In zoned mode, zones with write pointers can have conditions "read-only"
or "offline". In read-only condition, zones can not be written. In
offline condition, the zones can be neither written nor read. These
conditions are intended for zones with media failures, then it is
difficult to set those conditions to zones on real devices.

To test handling of zones in the conditions, add a feature to null_blk
to set up zones in read-only or offline condition. Add new configuration
attributes "zone_readonly" and "zone_offline". Write a sector to the
attribute files to specify the target zone to set the zone conditions.
For example, following command lines do it:

   echo 0 &gt; nullb1/zone_readonly
   echo 524288 &gt; nullb1/zone_offline

When the specified zones are already in read-only or offline condition,
normal empty condition is restored to the zones. These condition changes
can be done only after the null_blk device get powered, since status
area of each zone is not yet allocated before power-on.

Also improve zone condition checks to inhibit all commands for zones in
offline conditions. In same manner, inhibit write and zone management
commands for zones in read-only condition.

Signed-off-by: Shin'ichiro Kawasaki &lt;shinichiro.kawasaki@wdc.com&gt;
Reviewed-by: Damien Le Moal &lt;damien.lemoal@opensource.wdc.com&gt;
Link: https://lore.kernel.org/r/20221201061036.2342206-1-shinichiro.kawasaki@wdc.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>block: Change the return type of blk_mq_map_queues() into void</title>
<updated>2022-08-22T16:07:53Z</updated>
<author>
<name>Bart Van Assche</name>
<email>bvanassche@acm.org</email>
</author>
<published>2022-08-15T17:00:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a4e1d0b76e7b32c0839e72679c530445172a2564'/>
<id>urn:sha1:a4e1d0b76e7b32c0839e72679c530445172a2564</id>
<content type='text'>
Since blk_mq_map_queues() and the .map_queues() callbacks always return 0,
change their return type into void. Most callers ignore the returned value
anyway.

Cc: Christoph Hellwig &lt;hch@lst.de&gt;
Cc: Jason Wang &lt;jasowang@redhat.com&gt;
Cc: Keith Busch &lt;kbusch@kernel.org&gt;
Cc: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
Cc: Doug Gilbert &lt;dgilbert@interlog.com&gt;
Cc: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Signed-off-by: Bart Van Assche &lt;bvanassche@acm.org&gt;
Reviewed-by: John Garry &lt;john.garry@huawei.com&gt;
Acked-by: Md Haris Iqbal &lt;haris.iqbal@ionos.com&gt;
Reviewed-by: Sagi Grimberg &lt;sagi@grimberg.me&gt;
Link: https://lore.kernel.org/r/20220815170043.19489-3-bvanassche@acm.org
[axboe: fold in fix from Bart]
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>null_blk: Modify the behavior of null_map_queues()</title>
<updated>2022-08-22T13:52:51Z</updated>
<author>
<name>Bart Van Assche</name>
<email>bvanassche@acm.org</email>
</author>
<published>2022-08-15T17:00:42Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=10b41ea15e81a5597bc5944a7900e9a790bd984a'/>
<id>urn:sha1:10b41ea15e81a5597bc5944a7900e9a790bd984a</id>
<content type='text'>
Instead of returning -EINVAL if an internal inconsistency is detected,
fall back to a single submission queue. This patch prepares for changing
the return value of the .map_queues() callbacks into void.

Cc: Christoph Hellwig &lt;hch@lst.de&gt;
Cc: Keith Busch &lt;kbusch@kernel.org&gt;
Signed-off-by: Bart Van Assche &lt;bvanassche@acm.org&gt;
Reviewed-by: Chaitanya Kulkarni &lt;kch@nvidia.com&gt;
Link: https://lore.kernel.org/r/20220815170043.19489-2-bvanassche@acm.org
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>null_blk: fix ida error handling in null_add_dev()</title>
<updated>2022-08-02T23:22:41Z</updated>
<author>
<name>Dan Carpenter</name>
<email>dan.carpenter@oracle.com</email>
</author>
<published>2022-07-15T08:12:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ee452a8d984f94fa8e894f003a52e776e4572881'/>
<id>urn:sha1:ee452a8d984f94fa8e894f003a52e776e4572881</id>
<content type='text'>
There needs to be some error checking if ida_simple_get() fails.
Also call ida_free() if there are errors later.

Fixes: 94bc02e30fb8 ("nullb: use ida to manage index")
Signed-off-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Link: https://lore.kernel.org/r/YtEhXsr6vJeoiYhd@kili
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>null_blk: add configfs variables for 2 options</title>
<updated>2022-08-02T23:15:02Z</updated>
<author>
<name>Vincent Fu</name>
<email>vincent.fu@samsung.com</email>
</author>
<published>2022-07-08T17:49:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7012eef520cb7cb12910fb799dfd4ad0ed256b77'/>
<id>urn:sha1:7012eef520cb7cb12910fb799dfd4ad0ed256b77</id>
<content type='text'>
Allow setting via configfs these two options:

no_sched
shared_tag_bitmap

Previously these could only be activated as module parameters.

Still missing are:

shared_tags
timeout
requeue
init_hctx

Signed-off-by: Vincent Fu &lt;vincent.fu@samsung.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Link: https://lore.kernel.org/r/20220708174943.87787-3-vincent.fu@samsung.com
[axboe: fold in nullb == NULL fix]
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>null_blk: add module parameters for 4 options</title>
<updated>2022-08-02T23:14:50Z</updated>
<author>
<name>Vincent Fu</name>
<email>vincent.fu@samsung.com</email>
</author>
<published>2022-07-08T17:49:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=058efe000b31ce9c63bca02a33b67780b0ef5b41'/>
<id>urn:sha1:058efe000b31ce9c63bca02a33b67780b0ef5b41</id>
<content type='text'>
Add as module parameters these options:

memory_backed
discard
mbps
cache_size

Previously these could only be set via configfs.

Still missing is bad_blocks.

The kernel test robot found a documentation formatting issue in v1 of
this patch.

Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Signed-off-by: Vincent Fu &lt;vincent.fu@samsung.com&gt;
Link: https://lore.kernel.org/r/20220708174943.87787-2-vincent.fu@samsung.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>block: null_blk: Use the bitmap API to allocate bitmaps</title>
<updated>2022-08-02T23:14:44Z</updated>
<author>
<name>Christophe JAILLET</name>
<email>christophe.jaillet@wanadoo.fr</email>
</author>
<published>2022-07-03T16:05:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=eb25ad80364bc4351ad3f96ecbe9805e8af2d8c0'/>
<id>urn:sha1:eb25ad80364bc4351ad3f96ecbe9805e8af2d8c0</id>
<content type='text'>
Use bitmap_zalloc()/bitmap_free() instead of hand-writing them.

It is less verbose and it improves the semantic.

Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Link: https://lore.kernel.org/r/7c4d3116ba843fc4a8ae557dd6176352a6cd0985.1656864320.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
</feed>
