Skip to content

Commit a521fc3

Browse files
committed
Merge tag 'block-6.1-2022-10-13' of git://git.kernel.dk/linux
Pull more block updates from Jens Axboe: "Fixes that ended up landing later than the initial block pull request. Nothing really major in here: - NVMe pull request via Christoph: - add NVME_QUIRK_BOGUS_NID for Lexar NM760 (Abhijit) - add NVME_QUIRK_NO_DEEPEST_PS to avoid the deepest sleep state on ZHITAI TiPro5000 SSDs (Xi Ruoyao) - fix possible hang caused during ctrl deletion (Sagi Grimberg) - fix possible hang in live ns resize with ANA access (Sagi Grimberg) - Proactively avoid a sign extension issue with the queue flags (Brian) - Regression fix for hidden disks (Christoph) - Update OPAL maintainers entry (Jonathan) - blk-wbt regression initialization fix (Yu)" * tag 'block-6.1-2022-10-13' of git://git.kernel.dk/linux: nvme-multipath: fix possible hang in live ns resize with ANA access nvme-pci: avoid the deepest sleep state on ZHITAI TiPro5000 SSDs nvme-pci: add NVME_QUIRK_BOGUS_NID for Lexar NM760 nvme-tcp: fix possible hang caused during ctrl deletion nvme-rdma: fix possible hang caused during ctrl deletion block: fix leaking minors of hidden disks block: avoid sign extend problem with default queue flags mask blk-wbt: fix that 'rwb->wc' is always set to 1 in wbt_init() block: Remove the repeat word 'can' MAINTAINERS: Update SED-Opal Maintainers
2 parents c98c70e + 3bc429c commit a521fc3

File tree

9 files changed

+20
-10
lines changed

9 files changed

+20
-10
lines changed

MAINTAINERS

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18515,8 +18515,7 @@ S: Maintained
1851518515
F: drivers/mmc/host/sdhci-esdhc-imx.c
1851618516

1851718517
SECURE ENCRYPTING DEVICE (SED) OPAL DRIVER
18518-
M: Jonathan Derrick <[email protected]>
18519-
M: Revanth Rajashekar <[email protected]>
18518+
M: Jonathan Derrick <[email protected]>
1852018519
1852118520
S: Supported
1852218521
F: block/opal_proto.h

block/bio.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -567,7 +567,7 @@ EXPORT_SYMBOL(bio_alloc_bioset);
567567
* be reused by calling bio_uninit() before calling bio_init() again.
568568
*
569569
* Note that unlike bio_alloc() or bio_alloc_bioset() allocations from this
570-
* function are not backed by a mempool can can fail. Do not use this function
570+
* function are not backed by a mempool can fail. Do not use this function
571571
* for allocations in the file system I/O path.
572572
*
573573
* Returns: Pointer to new bio on success, NULL on failure.

block/blk-wbt.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -841,12 +841,11 @@ int wbt_init(struct request_queue *q)
841841
rwb->last_comp = rwb->last_issue = jiffies;
842842
rwb->win_nsec = RWB_WINDOW_NSEC;
843843
rwb->enable_state = WBT_STATE_ON_DEFAULT;
844-
rwb->wc = 1;
844+
rwb->wc = test_bit(QUEUE_FLAG_WC, &q->queue_flags);
845845
rwb->rq_depth.default_depth = RWB_DEF_DEPTH;
846846
rwb->min_lat_nsec = wbt_default_latency_nsec(q);
847847

848848
wbt_queue_depth_changed(&rwb->rqos);
849-
wbt_set_write_cache(q, test_bit(QUEUE_FLAG_WC, &q->queue_flags));
850849

851850
/*
852851
* Assign rwb and add the stats callback.

block/genhd.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -507,6 +507,13 @@ int __must_check device_add_disk(struct device *parent, struct gendisk *disk,
507507
*/
508508
dev_set_uevent_suppress(ddev, 0);
509509
disk_uevent(disk, KOBJ_ADD);
510+
} else {
511+
/*
512+
* Even if the block_device for a hidden gendisk is not
513+
* registered, it needs to have a valid bd_dev so that the
514+
* freeing of the dynamic major works.
515+
*/
516+
disk->part0->bd_dev = MKDEV(disk->major, disk->first_minor);
510517
}
511518

512519
disk_update_readahead(disk);

drivers/nvme/host/multipath.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,7 @@ void nvme_mpath_revalidate_paths(struct nvme_ns *ns)
182182

183183
for_each_node(node)
184184
rcu_assign_pointer(head->current_path[node], NULL);
185+
kblockd_schedule_work(&head->requeue_work);
185186
}
186187

187188
static bool nvme_path_is_disabled(struct nvme_ns *ns)

drivers/nvme/host/pci.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3521,12 +3521,16 @@ static const struct pci_device_id nvme_id_table[] = {
35213521
.driver_data = NVME_QUIRK_BOGUS_NID, },
35223522
{ PCI_DEVICE(0x1dbe, 0x5236), /* ADATA XPG GAMMIX S70 */
35233523
.driver_data = NVME_QUIRK_BOGUS_NID, },
3524+
{ PCI_DEVICE(0x1e49, 0x0021), /* ZHITAI TiPro5000 NVMe SSD */
3525+
.driver_data = NVME_QUIRK_NO_DEEPEST_PS, },
35243526
{ PCI_DEVICE(0x1e49, 0x0041), /* ZHITAI TiPro7000 NVMe SSD */
35253527
.driver_data = NVME_QUIRK_NO_DEEPEST_PS, },
35263528
{ PCI_DEVICE(0xc0a9, 0x540a), /* Crucial P2 */
35273529
.driver_data = NVME_QUIRK_BOGUS_NID, },
35283530
{ PCI_DEVICE(0x1d97, 0x2263), /* Lexar NM610 */
35293531
.driver_data = NVME_QUIRK_BOGUS_NID, },
3532+
{ PCI_DEVICE(0x1d97, 0x2269), /* Lexar NM760 */
3533+
.driver_data = NVME_QUIRK_BOGUS_NID, },
35303534
{ PCI_DEVICE(PCI_VENDOR_ID_AMAZON, 0x0061),
35313535
.driver_data = NVME_QUIRK_DMA_ADDRESS_BITS_48, },
35323536
{ PCI_DEVICE(PCI_VENDOR_ID_AMAZON, 0x0065),

drivers/nvme/host/rdma.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -996,7 +996,7 @@ static void nvme_rdma_stop_ctrl(struct nvme_ctrl *nctrl)
996996
{
997997
struct nvme_rdma_ctrl *ctrl = to_rdma_ctrl(nctrl);
998998

999-
cancel_work_sync(&ctrl->err_work);
999+
flush_work(&ctrl->err_work);
10001000
cancel_delayed_work_sync(&ctrl->reconnect_work);
10011001
}
10021002

drivers/nvme/host/tcp.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2181,7 +2181,7 @@ static void nvme_reset_ctrl_work(struct work_struct *work)
21812181

21822182
static void nvme_tcp_stop_ctrl(struct nvme_ctrl *ctrl)
21832183
{
2184-
cancel_work_sync(&to_tcp_ctrl(ctrl)->err_work);
2184+
flush_work(&to_tcp_ctrl(ctrl)->err_work);
21852185
cancel_delayed_work_sync(&to_tcp_ctrl(ctrl)->connect_work);
21862186
}
21872187

include/linux/blkdev.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -580,9 +580,9 @@ struct request_queue {
580580
#define QUEUE_FLAG_NOWAIT 29 /* device supports NOWAIT */
581581
#define QUEUE_FLAG_SQ_SCHED 30 /* single queue style io dispatch */
582582

583-
#define QUEUE_FLAG_MQ_DEFAULT ((1 << QUEUE_FLAG_IO_STAT) | \
584-
(1 << QUEUE_FLAG_SAME_COMP) | \
585-
(1 << QUEUE_FLAG_NOWAIT))
583+
#define QUEUE_FLAG_MQ_DEFAULT ((1UL << QUEUE_FLAG_IO_STAT) | \
584+
(1UL << QUEUE_FLAG_SAME_COMP) | \
585+
(1UL << QUEUE_FLAG_NOWAIT))
586586

587587
void blk_queue_flag_set(unsigned int flag, struct request_queue *q);
588588
void blk_queue_flag_clear(unsigned int flag, struct request_queue *q);

0 commit comments

Comments
 (0)