From: Jens Axboe Date: Mon, 20 Jul 2020 21:38:27 +0000 (-0600) Subject: Merge branch 'for-5.9/drivers' into for-5.9/block-merge X-Git-Tag: Ubuntu-5.13.0-19.19~5384^2~4 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=4f43d648078a754aefe6a4de233ebb6e4d192aa6;p=mirror_ubuntu-jammy-kernel.git Merge branch 'for-5.9/drivers' into for-5.9/block-merge * for-5.9/drivers: (38 commits) block: add max_active_zones to blk-sysfs block: add max_open_zones to blk-sysfs s390/dasd: Use struct_size() helper s390/dasd: fix inability to use DASD with DIAG driver md-cluster: fix wild pointer of unlock_all_bitmaps() md/raid5-cache: clear MD_SB_CHANGE_PENDING before flushing stripes md: fix deadlock causing by sysfs_notify md: improve io stats accounting md: raid0/linear: fix dereference before null check on pointer mddev rsxx: switch from 'pci_free_consistent()' to 'dma_free_coherent()' nvme: remove ns->disk checks nvme-pci: use standard block status symbolic names nvme-pci: use the consistent return type of nvme_pci_iod_alloc_size() nvme-pci: add a blank line after declarations nvme-pci: fix some comments issues nvme-pci: remove redundant segment validation nvme: document quirked Intel models nvme: expose reconnect_delay and ctrl_loss_tmo via sysfs nvme: support for zoned namespaces nvme: support for multiple Command Sets Supported and Effects log pages ... --- 4f43d648078a754aefe6a4de233ebb6e4d192aa6 diff --cc drivers/nvme/host/nvme.h index 26099eaf1b1c,13ca90bcd352..e536dd919073 --- a/drivers/nvme/host/nvme.h +++ b/drivers/nvme/host/nvme.h @@@ -692,11 -700,38 +710,41 @@@ static inline void nvme_mpath_wait_free static inline void nvme_mpath_start_freeze(struct nvme_subsystem *subsys) { } +static inline void nvme_mpath_update_disk_size(struct gendisk *disk) +{ +} #endif /* CONFIG_NVME_MULTIPATH */ + #ifdef CONFIG_BLK_DEV_ZONED + int nvme_update_zone_info(struct gendisk *disk, struct nvme_ns *ns, + unsigned lbaf); + + int nvme_report_zones(struct gendisk *disk, sector_t sector, + unsigned int nr_zones, report_zones_cb cb, void *data); + + blk_status_t nvme_setup_zone_mgmt_send(struct nvme_ns *ns, struct request *req, + struct nvme_command *cmnd, + enum nvme_zone_mgmt_action action); + #else + #define nvme_report_zones NULL + + static inline blk_status_t nvme_setup_zone_mgmt_send(struct nvme_ns *ns, + struct request *req, struct nvme_command *cmnd, + enum nvme_zone_mgmt_action action) + { + return BLK_STS_NOTSUPP; + } + + static inline int nvme_update_zone_info(struct gendisk *disk, + struct nvme_ns *ns, + unsigned lbaf) + { + dev_warn(ns->ctrl->device, + "Please enable CONFIG_BLK_DEV_ZONED to support ZNS devices\n"); + return -EPROTONOSUPPORT; + } + #endif + #ifdef CONFIG_NVM int nvme_nvm_register(struct nvme_ns *ns, char *disk_name, int node); void nvme_nvm_unregister(struct nvme_ns *ns);