]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
scsi: target: Rename target_configure_unmap_from_queue()
authorMike Christie <michael.christie@oracle.com>
Mon, 20 Oct 2025 10:38:14 +0000 (10:38 +0000)
committerMartin K. Petersen <martin.petersen@oracle.com>
Mon, 3 Nov 2025 02:40:01 +0000 (21:40 -0500)
Rename target_configure_unmap_from_queue() to
target_configure_unmap_from_bdev() since it now takes a bdev.

Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: John Garry <john.g.garry@oracle.com>
Reviewed-by: John Garry <john.g.garry@oracle.com>
Link: https://patch.msgid.link/20251020103820.2917593-2-john.g.garry@oracle.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/target/target_core_device.c
drivers/target/target_core_file.c
drivers/target/target_core_iblock.c
include/target/target_core_backend.h

index 7bb711b24c0d72d487600fde0b25addaf1d41dfb..83fe3d9a9681cd9821203c710709a6896f559053 100644 (file)
@@ -844,8 +844,8 @@ free_device:
  * Check if the underlying struct block_device supports discard and if yes
  * configure the UNMAP parameters.
  */
-bool target_configure_unmap_from_queue(struct se_dev_attrib *attrib,
-                                      struct block_device *bdev)
+bool target_configure_unmap_from_bdev(struct se_dev_attrib *attrib,
+                                     struct block_device *bdev)
 {
        int block_size = bdev_logical_block_size(bdev);
 
@@ -863,7 +863,7 @@ bool target_configure_unmap_from_queue(struct se_dev_attrib *attrib,
                bdev_discard_alignment(bdev) / block_size;
        return true;
 }
-EXPORT_SYMBOL(target_configure_unmap_from_queue);
+EXPORT_SYMBOL(target_configure_unmap_from_bdev);
 
 /*
  * Convert from blocksize advertised to the initiator to the 512 byte
index 2d78ef74633c8b17116be2a6393a14929a8093cd..b2610073e8ccab7b1e68007a4a802536ba4161e3 100644 (file)
@@ -92,8 +92,8 @@ static bool fd_configure_unmap(struct se_device *dev)
        struct inode *inode = file->f_mapping->host;
 
        if (S_ISBLK(inode->i_mode))
-               return target_configure_unmap_from_queue(&dev->dev_attrib,
-                                                        I_BDEV(inode));
+               return target_configure_unmap_from_bdev(&dev->dev_attrib,
+                                                       I_BDEV(inode));
 
        /* Limit UNMAP emulation to 8k Number of LBAs (NoLB) */
        dev->dev_attrib.max_unmap_lba_count = 0x2000;
index 66c292b7d74bc65bebde76ea6d935561123942e8..281612b9830f8640c705902ea526f14ac1f6e5a4 100644 (file)
@@ -84,8 +84,8 @@ static bool iblock_configure_unmap(struct se_device *dev)
 {
        struct iblock_dev *ib_dev = IBLOCK_DEV(dev);
 
-       return target_configure_unmap_from_queue(&dev->dev_attrib,
-                                                ib_dev->ibd_bd);
+       return target_configure_unmap_from_bdev(&dev->dev_attrib,
+                                               ib_dev->ibd_bd);
 }
 
 static int iblock_configure_device(struct se_device *dev)
index 4063a701081b4403bed86b186d5510fd3578ff57..d394306f8f490035ea382efc5375c5e52dad717c 100644 (file)
@@ -121,8 +121,8 @@ sense_reason_t passthrough_parse_cdb(struct se_cmd *cmd,
 
 bool target_sense_desc_format(struct se_device *dev);
 sector_t target_to_linux_sector(struct se_device *dev, sector_t lb);
-bool target_configure_unmap_from_queue(struct se_dev_attrib *attrib,
-                                      struct block_device *bdev);
+bool target_configure_unmap_from_bdev(struct se_dev_attrib *attrib,
+                                     struct block_device *bdev);
 
 static inline bool target_dev_configured(struct se_device *se_dev)
 {