diff options
author | Christoph Hellwig <hch@lst.de> | 2024-02-28 05:37:41 -0800 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2024-03-06 08:27:00 -0700 |
commit | 0127a47f58c6bb7b54386960ee66864b937269eb (patch) | |
tree | 4a6ea92c3bb2bb92e52e0dd067ae97f8893cc1db /drivers/s390/block/dasd_int.h | |
parent | 41463f2dfde2824a817789d635be8111cff463f5 (diff) | |
download | linux-0127a47f58c6bb7b54386960ee66864b937269eb.tar.gz |
dasd: move queue setup to common code
Most of the code in setup_blk_queue is shared between all disciplines.
Move it to common code and leave a method to query the maximum number
of transferable blocks, and a flag to indicate discard support.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Stefan Haberland <sth@linux.ibm.com>
Link: https://lore.kernel.org/r/20240228133742.806274-3-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/s390/block/dasd_int.h')
-rw-r--r-- | drivers/s390/block/dasd_int.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/s390/block/dasd_int.h b/drivers/s390/block/dasd_int.h index a6c5f1fa2d8798..b56d683a991dfd 100644 --- a/drivers/s390/block/dasd_int.h +++ b/drivers/s390/block/dasd_int.h @@ -293,6 +293,7 @@ struct dasd_discipline { struct module *owner; char ebcname[8]; /* a name used for tagging and printks */ char name[8]; /* a name used for tagging and printks */ + bool has_discard; struct list_head list; /* used for list of disciplines */ @@ -331,10 +332,7 @@ struct dasd_discipline { int (*online_to_ready) (struct dasd_device *); int (*basic_to_known)(struct dasd_device *); - /* - * Initialize block layer request queue. - */ - void (*setup_blk_queue)(struct dasd_block *); + unsigned int (*max_sectors)(struct dasd_block *); /* (struct dasd_device *); * Device operation functions. build_cp creates a ccw chain for * a block device request, start_io starts the request and |