1. 15 3月, 2022 1 次提交
  2. 23 2月, 2022 1 次提交
  3. 27 10月, 2021 1 次提交
  4. 29 9月, 2021 1 次提交
  5. 24 8月, 2021 2 次提交
  6. 12 8月, 2021 3 次提交
  7. 27 7月, 2021 5 次提交
  8. 23 6月, 2021 1 次提交
  9. 01 6月, 2021 1 次提交
  10. 16 4月, 2021 1 次提交
    • R
      scsi: qla2xxx: Reserve extra IRQ vectors · f02d4086
      Roman Bolshakov 提交于
      Commit a6dcfe08 ("scsi: qla2xxx: Limit interrupt vectors to number of
      CPUs") lowers the number of allocated MSI-X vectors to the number of CPUs.
      
      That breaks vector allocation assumptions in qla83xx_iospace_config(),
      qla24xx_enable_msix() and qla2x00_iospace_config(). Either of the functions
      computes maximum number of qpairs as:
      
        ha->max_qpairs = ha->msix_count - 1 (MB interrupt) - 1 (default
                         response queue) - 1 (ATIO, in dual or pure target mode)
      
      max_qpairs is set to zero in case of two CPUs and initiator mode. The
      number is then used to allocate ha->queue_pair_map inside
      qla2x00_alloc_queues(). No allocation happens and ha->queue_pair_map is
      left NULL but the driver thinks there are queue pairs available.
      
      qla2xxx_queuecommand() tries to find a qpair in the map and crashes:
      
        if (ha->mqenable) {
                uint32_t tag;
                uint16_t hwq;
                struct qla_qpair *qpair = NULL;
      
                tag = blk_mq_unique_tag(cmd->request);
                hwq = blk_mq_unique_tag_to_hwq(tag);
                qpair = ha->queue_pair_map[hwq]; # <- HERE
      
                if (qpair)
                        return qla2xxx_mqueuecommand(host, cmd, qpair);
        }
      
        BUG: kernel NULL pointer dereference, address: 0000000000000000
        #PF: supervisor read access in kernel mode
        #PF: error_code(0x0000) - not-present page
        PGD 0 P4D 0
        Oops: 0000 [#1] SMP PTI
        CPU: 0 PID: 72 Comm: kworker/u4:3 Tainted: G        W         5.10.0-rc1+ #25
        Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.0.0-prebuilt.qemu-project.org 04/01/2014
        Workqueue: scsi_wq_7 fc_scsi_scan_rport [scsi_transport_fc]
        RIP: 0010:qla2xxx_queuecommand+0x16b/0x3f0 [qla2xxx]
        Call Trace:
         scsi_queue_rq+0x58c/0xa60
         blk_mq_dispatch_rq_list+0x2b7/0x6f0
         ? __sbitmap_get_word+0x2a/0x80
         __blk_mq_sched_dispatch_requests+0xb8/0x170
         blk_mq_sched_dispatch_requests+0x2b/0x50
         __blk_mq_run_hw_queue+0x49/0xb0
         __blk_mq_delay_run_hw_queue+0xfb/0x150
         blk_mq_sched_insert_request+0xbe/0x110
         blk_execute_rq+0x45/0x70
         __scsi_execute+0x10e/0x250
         scsi_probe_and_add_lun+0x228/0xda0
         __scsi_scan_target+0xf4/0x620
         ? __pm_runtime_resume+0x4f/0x70
         scsi_scan_target+0x100/0x110
         fc_scsi_scan_rport+0xa1/0xb0 [scsi_transport_fc]
         process_one_work+0x1ea/0x3b0
         worker_thread+0x28/0x3b0
         ? process_one_work+0x3b0/0x3b0
         kthread+0x112/0x130
         ? kthread_park+0x80/0x80
         ret_from_fork+0x22/0x30
      
      The driver should allocate enough vectors to provide every CPU it's own HW
      queue and still handle reserved (MB, RSP, ATIO) interrupts.
      
      The change fixes the crash on dual core VM and prevents unbalanced QP
      allocation where nr_hw_queues is two less than the number of CPUs.
      
      Link: https://lore.kernel.org/r/20210412165740.39318-1-r.bolshakov@yadro.com
      Fixes: a6dcfe08 ("scsi: qla2xxx: Limit interrupt vectors to number of CPUs")
      Cc: Daniel Wagner <daniel.wagner@suse.com>
      Cc: Himanshu Madhani <himanshu.madhani@oracle.com>
      Cc: Quinn Tran <qutran@marvell.com>
      Cc: Nilesh Javali <njavali@marvell.com>
      Cc: Martin K. Petersen <martin.petersen@oracle.com>
      Cc: stable@vger.kernel.org # 5.11+
      Reported-by: NAleksandr Volkov <a.y.volkov@yadro.com>
      Reported-by: NAleksandr Miloserdov <a.miloserdov@yadro.com>
      Reviewed-by: NDaniel Wagner <dwagner@suse.de>
      Reviewed-by: NHimanshu Madhani <himanshu.madhani@oracle.com>
      Signed-off-by: NRoman Bolshakov <r.bolshakov@yadro.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      f02d4086
  11. 30 3月, 2021 1 次提交
    • Q
      scsi: qla2xxx: Fix crash in PCIe error handling · f7a0ed47
      Quinn Tran 提交于
      BUG: unable to handle kernel NULL pointer dereference at (null)
      IP: qla2x00_abort_isp+0x21/0x6b0 [qla2xxx] PGD 0 P4D 0
      Oops: 0000 [#1] SMP PTI
      CPU: 0 PID: 1715 Comm: kworker/0:2
      Tainted: GOE 4.12.14-122.37-default #1 SLE12-SP5
      Hardware name: HPE Superdome Flex/Superdome Flex, BIOS
      Bundle:3.30.100 SFW:IP147.007.004.017.000.2009211957 09/21/2020
      Workqueue: events aer_recover_work_func
      task: ffff9e399c14ca80 task.stack: ffffc1c58e4ac000
      RIP: 0010:qla2x00_abort_isp+0x21/0x6b0 [qla2xxx]
      RSP: 0018:ffffc1c58e4afd50 EFLAGS: 00010282
      RAX: 0000000000000000 RBX: ffff9e419cdef480 RCX: 0000000000000000
      RDX: ffff9e399c14ca80 RSI: 0000000000000246 RDI: ffff9e419bbc27b8
      RBP: ffff9e419bbc27b8 R08: 0000000000000004 R09: 00000000a0440000
      R10: 0000000000000000 R11: ffff9e399416d1a0 R12: ffff9e419cdef000
      R13: ffff9e3a7cfae800 R14: ffff9e3a7cfae800 R15: 00000000000000c0
      FS:  0000000000000000(0000) GS:ffff9e39a0000000(0000) knlGS:0000000000000000
      CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      CR2: 0000000000000000 CR3: 00000006cd00a005 CR4: 00000000007606f0
      DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
      DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
      PKRU: 55555554
      Call Trace:
        qla2xxx_pci_slot_reset+0x141/0x160 [qla2xxx]
        report_slot_reset+0x41/0x80
        ? merge_result.part.4+0x30/0x30
        pci_walk_bus+0x70/0x90
        pcie_do_recovery+0x1db/0x2e0
        aer_recover_work_func+0xc2/0xf0
        process_one_work+0x14c/0x390
      
      Disable board_disable logic where driver resources are freed while OS is in
      the process of recovering the adapter.
      
      Link: https://lore.kernel.org/r/20210329085229.4367-9-njavali@marvell.comTested-by: NLaurence Oberman <loberman@redhat.com>
      Signed-off-by: NQuinn Tran <qutran@marvell.com>
      Signed-off-by: NNilesh Javali <njavali@marvell.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      f7a0ed47
  12. 25 3月, 2021 1 次提交
  13. 23 1月, 2021 1 次提交
  14. 13 1月, 2021 3 次提交
  15. 10 12月, 2020 2 次提交
  16. 08 10月, 2020 1 次提交
  17. 30 9月, 2020 1 次提交
  18. 23 9月, 2020 3 次提交
  19. 16 9月, 2020 1 次提交
  20. 10 9月, 2020 3 次提交
  21. 24 8月, 2020 1 次提交
  22. 18 8月, 2020 1 次提交
  23. 16 7月, 2020 1 次提交
  24. 02 7月, 2020 2 次提交
  25. 20 5月, 2020 1 次提交