Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma

Pull rdma fixes from Doug Ledford:
"We have 5 small fixes for this pull request. One is a performance
regression, so not necessarily strictly a fix, but it was small and
reasonable and claimed to avoid thrashing in the scheduler, so I took
it. The remaining are all legitimate fixes that match the "we take
fixes any time" criteria.

Summary:

- One performance regression for hfi1

- One kasan fix for hfi1

- A couple mlx5 fixes

- A core oops fix"

* tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma:
IB/core: Fix oops in netdev_next_upper_dev_rcu()
IB/mlx5: Block DEVX umem from the non applicable cases
IB/mlx5: Fix implicit ODP interrupted page fault
IB/hfi1: Fix an out-of-bounds access in get_hw_stats
IB/hfi1: Fix a latency issue for small messages

+22 -8
+3
drivers/infiniband/core/roce_gid_mgmt.c
··· 267 267 struct net_device *cookie_ndev = cookie; 268 268 bool match = false; 269 269 270 + if (!rdma_ndev) 271 + return false; 272 + 270 273 rcu_read_lock(); 271 274 if (netif_is_bond_master(cookie_ndev) && 272 275 rdma_is_upper_dev_rcu(rdma_ndev, cookie_ndev))
+2 -1
drivers/infiniband/hw/hfi1/chip.c
··· 12500 12500 } 12501 12501 12502 12502 /* allocate space for the counter values */ 12503 - dd->cntrs = kcalloc(dd->ndevcntrs, sizeof(u64), GFP_KERNEL); 12503 + dd->cntrs = kcalloc(dd->ndevcntrs + num_driver_cntrs, sizeof(u64), 12504 + GFP_KERNEL); 12504 12505 if (!dd->cntrs) 12505 12506 goto bail; 12506 12507
+2
drivers/infiniband/hw/hfi1/hfi.h
··· 155 155 extern struct hfi1_ib_stats hfi1_stats; 156 156 extern const struct pci_error_handlers hfi1_pci_err_handler; 157 157 158 + extern int num_driver_cntrs; 159 + 158 160 /* 159 161 * First-cut criterion for "device is active" is 160 162 * two thousand dwords combined Tx, Rx traffic per
+7
drivers/infiniband/hw/hfi1/qp.c
··· 340 340 default: 341 341 break; 342 342 } 343 + 344 + /* 345 + * System latency between send and schedule is large enough that 346 + * forcing call_send to true for piothreshold packets is necessary. 347 + */ 348 + if (wqe->length <= piothreshold) 349 + *call_send = true; 343 350 return 0; 344 351 } 345 352
+1 -1
drivers/infiniband/hw/hfi1/verbs.c
··· 1479 1479 static DEFINE_MUTEX(cntr_names_lock); /* protects the *_cntr_names bufers */ 1480 1480 static const char **dev_cntr_names; 1481 1481 static const char **port_cntr_names; 1482 - static int num_driver_cntrs = ARRAY_SIZE(driver_cntr_names); 1482 + int num_driver_cntrs = ARRAY_SIZE(driver_cntr_names); 1483 1483 static int num_dev_cntrs; 1484 1484 static int num_port_cntrs; 1485 1485 static int cntr_names_initialized;
+3 -1
drivers/infiniband/hw/mlx5/devx.c
··· 1066 1066 1067 1067 err = uverbs_get_flags32(&access, attrs, 1068 1068 MLX5_IB_ATTR_DEVX_UMEM_REG_ACCESS, 1069 - IB_ACCESS_SUPPORTED); 1069 + IB_ACCESS_LOCAL_WRITE | 1070 + IB_ACCESS_REMOTE_WRITE | 1071 + IB_ACCESS_REMOTE_READ); 1070 1072 if (err) 1071 1073 return err; 1072 1074
+4 -5
drivers/infiniband/hw/mlx5/odp.c
··· 506 506 static int pagefault_mr(struct mlx5_ib_dev *dev, struct mlx5_ib_mr *mr, 507 507 u64 io_virt, size_t bcnt, u32 *bytes_mapped) 508 508 { 509 + int npages = 0, current_seq, page_shift, ret, np; 510 + bool implicit = false; 509 511 struct ib_umem_odp *odp_mr = to_ib_umem_odp(mr->umem); 510 512 u64 access_mask = ODP_READ_ALLOWED_BIT; 511 - int npages = 0, page_shift, np; 512 513 u64 start_idx, page_mask; 513 514 struct ib_umem_odp *odp; 514 - int current_seq; 515 515 size_t size; 516 - int ret; 517 516 518 517 if (!odp_mr->page_list) { 519 518 odp = implicit_mr_get_data(mr, io_virt, bcnt); ··· 520 521 if (IS_ERR(odp)) 521 522 return PTR_ERR(odp); 522 523 mr = odp->private; 523 - 524 + implicit = true; 524 525 } else { 525 526 odp = odp_mr; 526 527 } ··· 599 600 600 601 out: 601 602 if (ret == -EAGAIN) { 602 - if (mr->parent || !odp->dying) { 603 + if (implicit || !odp->dying) { 603 604 unsigned long timeout = 604 605 msecs_to_jiffies(MMU_NOTIFIER_TIMEOUT); 605 606