<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/target/loopback/tcm_loop.c, branch v5.14</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=v5.14</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v5.14'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2021-06-01T02:48:21Z</updated>
<entry>
<title>scsi: core: Kill DRIVER_SENSE</title>
<updated>2021-06-01T02:48:21Z</updated>
<author>
<name>Hannes Reinecke</name>
<email>hare@suse.de</email>
</author>
<published>2021-04-27T08:30:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=464a00c9e0ad45e3f42ff6ea705491a356df818e'/>
<id>urn:sha1:464a00c9e0ad45e3f42ff6ea705491a356df818e</id>
<content type='text'>
Replace the check for DRIVER_SENSE with a check for
scsi_status_is_check_condition().

Audit all callsites to ensure the SAM status is set correctly. For
backwards compability move the DRIVER_SENSE definition to sg.h, and update
sg, bsg, and scsi_ioctl to set the DRIVER_SENSE driver_status whenever
SAM_STAT_CHECK_CONDITION is present.

[mkp: fix zeroday srp warning]

Link: https://lore.kernel.org/r/20210427083046.31620-10-hare@suse.de
Signed-off-by: Hannes Reinecke &lt;hare@suse.de&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;

fix
</content>
</entry>
<entry>
<title>scsi: target: tcm_loop: Use LIO wq cmd submission helper</title>
<updated>2021-03-04T22:37:02Z</updated>
<author>
<name>Mike Christie</name>
<email>michael.christie@oracle.com</email>
</author>
<published>2021-02-27T17:00:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=1130b499b4a74baa8248002a4fd4275bf137b7f4'/>
<id>urn:sha1:1130b499b4a74baa8248002a4fd4275bf137b7f4</id>
<content type='text'>
Convert loop to use the LIO wq cmd submission helper.

Link: https://lore.kernel.org/r/20210227170006.5077-20-michael.christie@oracle.com
Tested-by: Laurence Oberman &lt;loberman@redhat.com&gt;
Reviewed-by: Bodo Stroesser &lt;bostroesser@gmail.com&gt;
Signed-off-by: Mike Christie &lt;michael.christie@oracle.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: target: tcm_loop: Use block cmd allocator for se_cmds</title>
<updated>2021-03-04T22:37:02Z</updated>
<author>
<name>Mike Christie</name>
<email>michael.christie@oracle.com</email>
</author>
<published>2021-02-27T16:59:59Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e0eb5d38b732b011cd9ed5b1bf9f59b83c2500d3'/>
<id>urn:sha1:e0eb5d38b732b011cd9ed5b1bf9f59b83c2500d3</id>
<content type='text'>
Make tcm_loop use the block layer cmd allocator for se_cmds instead of
using the tcm_loop_cmd_cache. In the future when we can use the host tags
for internal requests like TMFs we can completely kill the
tcm_loop_cmd_cache.

Link: https://lore.kernel.org/r/20210227170006.5077-19-michael.christie@oracle.com
Tested-by: Laurence Oberman &lt;loberman@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Mike Christie &lt;michael.christie@oracle.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: target: core: Add gfp_t arg to target_cmd_init_cdb()</title>
<updated>2021-03-04T22:37:02Z</updated>
<author>
<name>Mike Christie</name>
<email>michael.christie@oracle.com</email>
</author>
<published>2021-02-27T16:59:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=08694199477da412baf1852c6d1bf5fedbd40c7e'/>
<id>urn:sha1:08694199477da412baf1852c6d1bf5fedbd40c7e</id>
<content type='text'>
tcm_loop could be used like a normal block device, so we can't use
GFP_KERNEL and should use GFP_NOIO. This adds a gfp_t arg to
target_cmd_init_cdb() and converts the users. For every driver but loop
GFP_KERNEL is kept.

This will also be useful in subsequent patches where loop needs to do
target_submit_prep() from interrupt context to get a ref to the se_device,
and so it will need to use GFP_ATOMIC.

Link: https://lore.kernel.org/r/20210227170006.5077-16-michael.christie@oracle.com
Tested-by: Laurence Oberman &lt;loberman@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Mike Christie &lt;michael.christie@oracle.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: target: tcm_loop: Convert to new submission API</title>
<updated>2021-03-04T22:37:01Z</updated>
<author>
<name>Mike Christie</name>
<email>michael.christie@oracle.com</email>
</author>
<published>2021-02-27T16:59:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=17ae18a6efed92ce1bb1a61fa9e7360d3d8fd5b9'/>
<id>urn:sha1:17ae18a6efed92ce1bb1a61fa9e7360d3d8fd5b9</id>
<content type='text'>
target_submit_cmd_map_sgls() is being removed, so convert loop to
the new submission API.

Even though loop does its own shutdown sync, this has loop use
target_init_cmd()/target_submit_prep()/target_submit() since it needed to
map sgls and in the next patches it will use the API to use LIO's
workqueue.

Link: https://lore.kernel.org/r/20210227170006.5077-9-michael.christie@oracle.com
Tested-by: Laurence Oberman &lt;loberman@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Mike Christie &lt;michael.christie@oracle.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: tcm_loop: Allow queues, can_queue and cmd_per_lun to be settable</title>
<updated>2020-11-05T03:39:38Z</updated>
<author>
<name>Mike Christie</name>
<email>michael.christie@oracle.com</email>
</author>
<published>2020-11-01T18:59:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=94a0dfcf7d33ea96bf3eb0c33e4239942a4ff087'/>
<id>urn:sha1:94a0dfcf7d33ea96bf3eb0c33e4239942a4ff087</id>
<content type='text'>
Make can_queue, nr_hw_queues and cmd_per_lun settable by the user instead
of hard coding them.

Link: https://lore.kernel.org/r/1604257174-4524-9-git-send-email-michael.christie@oracle.com
Reviewed-by: Himanshu Madhani &lt;himanshu.madhani@oracle.com&gt;
Signed-off-by: Mike Christie &lt;michael.christie@oracle.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: target: loopback: Fix READ with data and sensebytes</title>
<updated>2020-05-12T02:20:19Z</updated>
<author>
<name>Bodo Stroesser</name>
<email>bstroesser@ts.fujitsu.com</email>
</author>
<published>2020-04-28T18:26:17Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c68a56736c129f5dd1632856956f9c3e04bae200'/>
<id>urn:sha1:c68a56736c129f5dd1632856956f9c3e04bae200</id>
<content type='text'>
We use tcm_loop with tape emulations running on tcmu.

In case application reads a short tape block with a longer READ, or a long
tape block with a short READ, according to SCC spec data has to be
tranferred _and_ sensebytes with ILI set and information field containing
the residual count. Similar problem also exists when using fixed block
size in READ.

Up to now tcm_loop is not prepared to handle sensebytes if input data is
provided, as in tcm_loop_queue_data_in() it only sets SAM_STAT_GOOD and, if
necessary, the residual count.

To fix the bug, the same handling for sensebytes as present in
tcm_loop_queue_status() must be done in tcm_loop_queue_data_in() also.

After adding this handling, the two function now are nearly identical, so I
created a single function with two wrappers.

Link: https://lore.kernel.org/r/20200428182617.32726-1-bstroesser@ts.fujitsu.com
Signed-off-by: Bodo Stroesser &lt;bstroesser@ts.fujitsu.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: remove bidirectional command support</title>
<updated>2019-02-06T02:29:21Z</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2019-01-29T08:33:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ae3d56d81507c33024ba7c1eae2ef433aa9bc0d5'/>
<id>urn:sha1:ae3d56d81507c33024ba7c1eae2ef433aa9bc0d5</id>
<content type='text'>
No real need for bidi support once the OSD code is gone.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Jens Axboe &lt;axboe@kernel.dk&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: target/core: Remove the write_pending_status() callback function</title>
<updated>2019-02-05T02:23:59Z</updated>
<author>
<name>Bart Van Assche</name>
<email>bvanassche@acm.org</email>
</author>
<published>2019-01-25T18:34:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f80d2f0846b7b9ceb1f2a5951229ee4391edaebd'/>
<id>urn:sha1:f80d2f0846b7b9ceb1f2a5951229ee4391edaebd</id>
<content type='text'>
Due to the patch that makes TMF handling synchronous the
write_pending_status() callback function is no longer called.  Hence remove
it.

Acked-by: Felipe Balbi &lt;balbi@ti.com&gt;
Reviewed-by: Sagi Grimberg &lt;sagig@mellanox.com&gt;
Reviewed-by: Andy Grover &lt;agrover@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Hannes Reinecke &lt;hare@suse.com&gt;
Reviewed-by: Bryant G. Ly &lt;bryantly@linux.vnet.ibm.com&gt;
Cc: Nicholas Bellinger &lt;nab@linux-iscsi.org&gt;
Cc: Mike Christie &lt;mchristi@redhat.com&gt;
Cc: Himanshu Madhani &lt;himanshu.madhani@qlogic.com&gt;
Cc: Quinn Tran &lt;quinn.tran@qlogic.com&gt;
Cc: Saurav Kashyap &lt;saurav.kashyap@qlogic.com&gt;
Cc: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Cc: Juergen Gross &lt;jgross@suse.com&gt;
Signed-off-by: Bart Van Assche &lt;bvanassche@acm.org&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: remove the use_clustering flag</title>
<updated>2018-12-19T04:19:21Z</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2018-12-13T15:17:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4af14d113bcf95c12d1462ba623b7e7117bd3fb3'/>
<id>urn:sha1:4af14d113bcf95c12d1462ba623b7e7117bd3fb3</id>
<content type='text'>
The same effects can be achieved by setting the dma_boundary to
PAGE_SIZE - 1 and the max_segment_size to PAGE_SIZE, so shift those
settings into the drivers.  Note that in many cases the setting might
be bogus, but this keeps the status quo.

[mkp: fix myrs and myrb]

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
</feed>
