From patchwork Mon Jul 6 07:54:15 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kamal Heib X-Patchwork-Id: 11645137 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 30163912 for ; Mon, 6 Jul 2020 07:54:31 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 175B92070C for ; Mon, 6 Jul 2020 07:54:31 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="kkezu5Kk" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728911AbgGFHya (ORCPT ); Mon, 6 Jul 2020 03:54:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51240 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728248AbgGFHya (ORCPT ); Mon, 6 Jul 2020 03:54:30 -0400 Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DC881C061794 for ; Mon, 6 Jul 2020 00:54:29 -0700 (PDT) Received: by mail-wm1-x344.google.com with SMTP id f18so40839627wml.3 for ; Mon, 06 Jul 2020 00:54:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=obqxZdmR/t8xL2rXeSpVqMlK6yXRRmMUtovmoH9E5NE=; b=kkezu5KkJsC3VHWCPzlu3h8h5g/j/2iCyi+Ofcb90ZNxLXJTLXqK2bmKmRxz6WdFld Ueof0tXzlLlai8vvQi2T1jQp7uAMT5v6Ymhj4lCk633o7bOK0A2Y05g7BP0/MYS0mOjI PvTAiyok/RsFMmpd6/PPBAb6spTMV97555JrFwgKmD0B9bu1sR1+1bDtF37SPUJ8HBaB MP5sI69bzrHgouPSoFkbuhMyYoxkjF3wuLBinP2AfClckfG8y92DVHWwQEYVnFzg5sOW xYspJUct/yD4i+TdmUgZKITUj5LahgbjU2noyqD0Z4dYanMN5oNVtDf1NuO7h9duxybf vx0w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=obqxZdmR/t8xL2rXeSpVqMlK6yXRRmMUtovmoH9E5NE=; b=ju4csJhes4ItyjnnFJs8UjQokDs5yJGO+UYv/Q9WNR+Lx671o7Ym3MBRO9RoeLLUiJ erACAriCCveE+w2F7/1DFVe9f19OhXmnVC6DIE1EQRdyrXPCGMPsdcvhYMEBe3Qt4KN1 Bw1OUt6tAzJzqxxfoyBlIcXJ9eo6Or7hz9VduxYXS2BHTrsBg5mOTzKDpBSioIKQlJhd 5mjV2pnV1EHVQozOpG4HVH/AAThToPnWfge0WsSFlgvDCL1T8la/IptMbvSqTjuecfTC Xrl0b0S4oKIGehY7faMH1Wu/HJUL+hGz6DUTbYvLIy5Kf3l+XeMLMv6d9N/HfEanmwfo UK5g== X-Gm-Message-State: AOAM533iunmTJ+irfVXtUkh9Dlu4fn5jccAQPr9dpQC50l8IdgwCnp9c okIGq6TolHylxBZpTQ0PxWtgyOadrJo= X-Google-Smtp-Source: ABdhPJzWqSeFWvKooLiJxGsd1c4zBuY0WHxH3MUrIcrn4BeBN0b75n3COTqHjxCEGi2HQ+qSlWBltw== X-Received: by 2002:a05:600c:2154:: with SMTP id v20mr52034151wml.185.1594022068475; Mon, 06 Jul 2020 00:54:28 -0700 (PDT) Received: from kheib-workstation.redhat.com ([37.142.6.100]) by smtp.gmail.com with ESMTPSA id g145sm15028147wmg.23.2020.07.06.00.54.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jul 2020 00:54:27 -0700 (PDT) From: Kamal Heib To: linux-rdma@vger.kernel.org Cc: Jason Gunthorpe , Doug Ledford , Kamal Heib , Bernard Metzler Subject: [PATCH for-next 1/5] RDMA/siw: Set max_pkeys attribute Date: Mon, 6 Jul 2020 10:54:15 +0300 Message-Id: <20200706075419.361484-2-kamalheib1@gmail.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200706075419.361484-1-kamalheib1@gmail.com> References: <20200706075419.361484-1-kamalheib1@gmail.com> MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org Make sure to set the max_pkeys attribute to indicate the maximum number of partitions supported by the siw device. Fixes: 303ae1cdfdf7 ("rdma/siw: application interface") Signed-off-by: Kamal Heib Cc: Bernard Metzler --- drivers/infiniband/sw/siw/siw_verbs.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/infiniband/sw/siw/siw_verbs.c b/drivers/infiniband/sw/siw/siw_verbs.c index 987e2ba05dbc..bef35d566aee 100644 --- a/drivers/infiniband/sw/siw/siw_verbs.c +++ b/drivers/infiniband/sw/siw/siw_verbs.c @@ -151,6 +151,7 @@ int siw_query_device(struct ib_device *base_dev, struct ib_device_attr *attr, attr->max_srq = sdev->attrs.max_srq; attr->max_srq_sge = sdev->attrs.max_srq_sge; attr->max_srq_wr = sdev->attrs.max_srq_wr; + attr->max_pkeys = 1; attr->page_size_cap = PAGE_SIZE; attr->vendor_id = SIW_VENDOR_ID; attr->vendor_part_id = sdev->vendor_part_id; From patchwork Mon Jul 6 07:54:16 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kamal Heib X-Patchwork-Id: 11645139 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 7536060D for ; Mon, 6 Jul 2020 07:54:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5D4872070C for ; Mon, 6 Jul 2020 07:54:32 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="ryq9UCHX" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728917AbgGFHyb (ORCPT ); Mon, 6 Jul 2020 03:54:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51248 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728248AbgGFHyb (ORCPT ); Mon, 6 Jul 2020 03:54:31 -0400 Received: from mail-wr1-x443.google.com (mail-wr1-x443.google.com [IPv6:2a00:1450:4864:20::443]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3A727C061794 for ; Mon, 6 Jul 2020 00:54:31 -0700 (PDT) Received: by mail-wr1-x443.google.com with SMTP id r12so39664695wrj.13 for ; Mon, 06 Jul 2020 00:54:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=bDiCsTKJYT1dBvgYvF0oPh5E3DjsarKR+VvD0dD7xPY=; b=ryq9UCHXxVmVhcCSxrAsRiMkH5TeEONo732oloGdXzutVjAiIL4skL8NwfIUA7To2t PoURnbsKFqQK4yDVyxKVKqZMTBK/Zd2lebL6SaCsZpKjDGA3J8aKSMDZv96BB1j1iVVw 5Apc+W/w2iYCzXJnv/hLxRvJ06hNYRLmQqb5xqcIuUxLlOEZoMzNt5jYetXbFTr9RS6T X7sY2LgOGyBqRmuORhMpHMZ5Yy93ffvwm4iQln1VJkoD8hw5T/2S+SdJnZlp/Nxqx/8b eG7jFI3Y8F8ISijzzfuX8JYhemqjtUdZV4vEOUnhy6I1UL1kg6UY1cxq9XwDREzAAkVp rr/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=bDiCsTKJYT1dBvgYvF0oPh5E3DjsarKR+VvD0dD7xPY=; b=RBFCuo/cyOa4dhOP/HAUz0uRvPBYBKbu9u0N2PgwlL3XpUaRb/yhZ5DLYajAImP3pL 7ZEEP/xLgus+s30ol3au8U0w62Qzg6LygxY7ODJwQt0D18eL5twc0xpcbJRs/SZQvuuG BJ/YqXARUNvSsaH2Z5Hzlru+7T/0rNMSGju6tsm5yOIfyJIVVGVYcfvM02luJtzX+HDM Qn93QY3EPqRR7ECD8Z7pWBSj7eyFKRaAtnUiiOSFIPvXu2bn1eawOl0kOCixiONLstvb QjUtQTC2s8Gx5tc9EZC2W0vN2Na81fsSBLFdpUWZtxxW1DmNz+2jHL7iqK6oIsZf2j/j AY2Q== X-Gm-Message-State: AOAM530Aa2XxvfY0nBWLhBah3nqumeHRNAw1Y43D+qKik1amnA0CMr4L IFI/qMamNshjUCUy3QWHsT1i9iP3BNs= X-Google-Smtp-Source: ABdhPJyeljPh4NsiGIawG97hd/NnmNEVaB+bKo6iDZR+RgW+JHje0XcGoBDDCVgIjpmZr+oJxorOtA== X-Received: by 2002:adf:84e2:: with SMTP id 89mr49361415wrg.139.1594022069774; Mon, 06 Jul 2020 00:54:29 -0700 (PDT) Received: from kheib-workstation.redhat.com ([37.142.6.100]) by smtp.gmail.com with ESMTPSA id g145sm15028147wmg.23.2020.07.06.00.54.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jul 2020 00:54:29 -0700 (PDT) From: Kamal Heib To: linux-rdma@vger.kernel.org Cc: Jason Gunthorpe , Doug Ledford , Kamal Heib , Gal Pressman Subject: [PATCH for-next 2/5] RDMA/efa: Set max_pkeys attribute Date: Mon, 6 Jul 2020 10:54:16 +0300 Message-Id: <20200706075419.361484-3-kamalheib1@gmail.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200706075419.361484-1-kamalheib1@gmail.com> References: <20200706075419.361484-1-kamalheib1@gmail.com> MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org Make sure to set the max_pkeys attribute to indicate the maximum number of partitions supported by the efa device. Fixes: 40909f664d27 ("RDMA/efa: Add EFA verbs implementation") Signed-off-by: Kamal Heib Cc: Gal Pressman --- drivers/infiniband/hw/efa/efa_verbs.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/infiniband/hw/efa/efa_verbs.c b/drivers/infiniband/hw/efa/efa_verbs.c index 08313f7c73bc..7dd082441333 100644 --- a/drivers/infiniband/hw/efa/efa_verbs.c +++ b/drivers/infiniband/hw/efa/efa_verbs.c @@ -212,6 +212,7 @@ int efa_query_device(struct ib_device *ibdev, props->max_send_sge = dev_attr->max_sq_sge; props->max_recv_sge = dev_attr->max_rq_sge; props->max_sge_rd = dev_attr->max_wr_rdma_sge; + props->max_pkeys = 1; if (udata && udata->outlen) { resp.max_sq_sge = dev_attr->max_sq_sge; From patchwork Mon Jul 6 07:54:17 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kamal Heib X-Patchwork-Id: 11645141 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B8A7B60D for ; Mon, 6 Jul 2020 07:54:33 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 9F9AE2070C for ; Mon, 6 Jul 2020 07:54:33 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="IUe3TFA5" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728923AbgGFHyd (ORCPT ); Mon, 6 Jul 2020 03:54:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51250 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728248AbgGFHyc (ORCPT ); Mon, 6 Jul 2020 03:54:32 -0400 Received: from mail-wr1-x444.google.com (mail-wr1-x444.google.com [IPv6:2a00:1450:4864:20::444]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7D4C4C061794 for ; Mon, 6 Jul 2020 00:54:32 -0700 (PDT) Received: by mail-wr1-x444.google.com with SMTP id r12so39664761wrj.13 for ; Mon, 06 Jul 2020 00:54:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=UrUOSYUSIjSV0j+I0GgzPG+VjdWB+FhZMQ6SV5deoPo=; b=IUe3TFA59C36cVENHn59cr+SAmgPOsQ9khgIFsduFRsDFof5HibM7FeHFEcL2SJaE1 T6Rk4n1P3pQDIEwhrxabATrAuPjNsZ5p50z2r9ZkMgd+FW9wM5GpJZfHBMKGxWXtae3C LDA8uUT39aUpugLJZCxu5UXMXGBt04hDAe7HqgRLOggV7DNMqjkNC/8RbQ8EYl+W4Tou 62k7bRGlbR1DpbPvDE4nG9pBjGQw5V7JQTp0+MTqlTmtnwGBwcjGwYmVzTfcz9k/HbxW GfAdI5TUlSONhHiYCZ7e3FLBWJAVTMSwuqTXNpdnMYcgMN2SiRt7RgHahguonuix7Nxe 19Xg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=UrUOSYUSIjSV0j+I0GgzPG+VjdWB+FhZMQ6SV5deoPo=; b=M+Q7OhwWTUpnggRwcv4A5JCJS9x30ET0Gh4eF9RaYVafpyyH3/w/lIBcUGAm7HzWXs 8s3TAJncvexpAfLG3ECXK+XR8pkhQK8SqOlTA1kBSuyXioLP5MDEHIs8ZwPB5LB86s7t 3NlzFgWkR2+kdm0pTmzW6TbIEYRUI9a2elvzSb0MMrzJK/oxMRuRLPqBYT4gXfwUHHFj c4GiWu0tFAKEh3SjoG8SDnWZl5kAOXaYJp+nyRV2WsMtS43dwDO8TnRAMCqNxMeXUM3Y 3bz4R5F1BPmd0lXUr3XxECI2fSAHDAfLsAkOU1eI+V9XoVQH5VdZ3Yx2lTLpbwaI3FUX tq9Q== X-Gm-Message-State: AOAM531fpuinhrB0FJa+NDqAQ4/+Vt+7i4ps0GE+FqBr47BIQAoMZscg yWKx0ppekCDVa9RAP+KeQ2wZ6PDax8s= X-Google-Smtp-Source: ABdhPJzDwYoht7SVWaxEcop9RSJSOVa0h0/PgrJtH0XaLXE0DvxP8busictM5aeLMq35ISLIFuYVmA== X-Received: by 2002:adf:edc6:: with SMTP id v6mr47791315wro.413.1594022071128; Mon, 06 Jul 2020 00:54:31 -0700 (PDT) Received: from kheib-workstation.redhat.com ([37.142.6.100]) by smtp.gmail.com with ESMTPSA id g145sm15028147wmg.23.2020.07.06.00.54.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jul 2020 00:54:30 -0700 (PDT) From: Kamal Heib To: linux-rdma@vger.kernel.org Cc: Jason Gunthorpe , Doug Ledford , Kamal Heib , Potnuri Bharat Teja Subject: [PATCH for-next 3/5] RDMA/cxgb4: Set max_pkeys attribute Date: Mon, 6 Jul 2020 10:54:17 +0300 Message-Id: <20200706075419.361484-4-kamalheib1@gmail.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200706075419.361484-1-kamalheib1@gmail.com> References: <20200706075419.361484-1-kamalheib1@gmail.com> MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org Make sure to set the max_pkeys attribute to indicate the maximum number of partitions supported by the cxgb4 device. Fixes: cfdda9d76436 ("RDMA/cxgb4: Add driver for Chelsio T4 RNIC") Signed-off-by: Kamal Heib Cc: Potnuri Bharat Teja --- drivers/infiniband/hw/cxgb4/provider.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/infiniband/hw/cxgb4/provider.c b/drivers/infiniband/hw/cxgb4/provider.c index 1d3ff59e4060..275b77234a22 100644 --- a/drivers/infiniband/hw/cxgb4/provider.c +++ b/drivers/infiniband/hw/cxgb4/provider.c @@ -298,6 +298,7 @@ static int c4iw_query_device(struct ib_device *ibdev, struct ib_device_attr *pro props->local_ca_ack_delay = 0; props->max_fast_reg_page_list_len = t4_max_fr_depth(dev->rdev.lldi.ulptx_memwrite_dsgl && use_dsgl); + props->max_pkeys = 1; return 0; } From patchwork Mon Jul 6 07:54:18 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kamal Heib X-Patchwork-Id: 11645143 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id E905A912 for ; Mon, 6 Jul 2020 07:54:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D13322073E for ; Mon, 6 Jul 2020 07:54:35 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Gc7M6W7X" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728925AbgGFHyf (ORCPT ); Mon, 6 Jul 2020 03:54:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51258 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728248AbgGFHye (ORCPT ); Mon, 6 Jul 2020 03:54:34 -0400 Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A28CFC061794 for ; Mon, 6 Jul 2020 00:54:34 -0700 (PDT) Received: by mail-wr1-x441.google.com with SMTP id f7so36721875wrw.1 for ; Mon, 06 Jul 2020 00:54:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=K6mLL7tLM934/zbxauAezYq+UQ9iy2rbr+FRjTdUcOU=; b=Gc7M6W7XiDxH2/x+ZRr/LEHHMeNt9DHvA04L8BAwfyxaNPfashMvv60OvrdhmOUDq6 GVGSKbkD79i2XiOV29doB/Pw3MnPbEs5PjWdv48DA8TXQ0ESbe8Phg683vleQMvQqRP+ kgcqrqXsejrDv3KTPhJfFsf5FF469SxxM0B3NDemtHihxe3CUSHjik5hOykgU+ttI0dx yGU9kw4p3tR3/q3yf3nl1rlki2aQwTFyDVTV67M9CZ28Tslh4jixSmOHNdKqY0R2yC/M f97NYlDPJ9p3ll0LpY6wJSazGJCDDiRMoijVJE+ZWOivVGFRezshGSpzmox95KKsl9iU GkOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=K6mLL7tLM934/zbxauAezYq+UQ9iy2rbr+FRjTdUcOU=; b=cJod2nwXN234NK69eJJlluw01n167UcC/tMM375b4WAOSPCniSgOyal+XDswsstQmh OUBDH9rfmtcn5mMTHQGOEMQZn9XUleeYmwK6VrWePnMXgCNvq9hfMJfqmu9+G69DV2jB hLd76tmebHZTseS0GbAEylAnhAH6GNrDfhCptQMdDGOgch8YNYCtr+cW11EPaON5uKh0 hRjmBeFxAYb/zWQgQEjELenkyAFCvFUHKn2dysS3HT8c+CYlZMOZY+SKBAUNamULGDKe Qw7d0kkg8uwmQlRdf58WgtN9sH/Z/BU16BNwLxC0nKPIqeNLfoK6VYgBQlBsoGsx/oCU rlkw== X-Gm-Message-State: AOAM531sPOpoHkJ7XMh+swBPKaeFxwbDgNIWC6GkmoWXMupt3wAZcZt5 ekAzFDbcnWG867Ag1VzPmqnu5oCQr10= X-Google-Smtp-Source: ABdhPJy/G5Ik8SJddKzQ0oGJfwYdLmYPOYMIsLBcqgzYmpMM3Orcwk5995Ed2xJFM0sI8DCR0nEmgQ== X-Received: by 2002:adf:d084:: with SMTP id y4mr46416483wrh.161.1594022073266; Mon, 06 Jul 2020 00:54:33 -0700 (PDT) Received: from kheib-workstation.redhat.com ([37.142.6.100]) by smtp.gmail.com with ESMTPSA id g145sm15028147wmg.23.2020.07.06.00.54.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jul 2020 00:54:31 -0700 (PDT) From: Kamal Heib To: linux-rdma@vger.kernel.org Cc: Jason Gunthorpe , Doug Ledford , Kamal Heib , Shiraz Saleem Subject: [PATCH for-next 4/5] RDMA/i40iw: Set max_pkeys attribute Date: Mon, 6 Jul 2020 10:54:18 +0300 Message-Id: <20200706075419.361484-5-kamalheib1@gmail.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200706075419.361484-1-kamalheib1@gmail.com> References: <20200706075419.361484-1-kamalheib1@gmail.com> MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org Make sure to set the max_pkeys attribute to indicate the maximum number of partitions supported by the i40iw device. Fixes: d37498417947 ("i40iw: add files for iwarp interface") Signed-off-by: Kamal Heib Cc: Shiraz Saleem --- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/infiniband/hw/i40iw/i40iw_verbs.c b/drivers/infiniband/hw/i40iw/i40iw_verbs.c index 19af29a48c55..ef624fa5f07b 100644 --- a/drivers/infiniband/hw/i40iw/i40iw_verbs.c +++ b/drivers/infiniband/hw/i40iw/i40iw_verbs.c @@ -84,6 +84,7 @@ static int i40iw_query_device(struct ib_device *ibdev, props->max_qp_init_rd_atom = props->max_qp_rd_atom; props->atomic_cap = IB_ATOMIC_NONE; props->max_fast_reg_page_list_len = I40IW_MAX_PAGES_PER_FMR; + props->max_pkeys = 1; return 0; } From patchwork Mon Jul 6 07:54:19 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kamal Heib X-Patchwork-Id: 11645145 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 267AF60D for ; Mon, 6 Jul 2020 07:54:37 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 0D59D2070C for ; Mon, 6 Jul 2020 07:54:37 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="NccZojx6" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728930AbgGFHyg (ORCPT ); Mon, 6 Jul 2020 03:54:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51264 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728248AbgGFHyg (ORCPT ); Mon, 6 Jul 2020 03:54:36 -0400 Received: from mail-wr1-x443.google.com (mail-wr1-x443.google.com [IPv6:2a00:1450:4864:20::443]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C5EB7C061794 for ; Mon, 6 Jul 2020 00:54:35 -0700 (PDT) Received: by mail-wr1-x443.google.com with SMTP id o11so39753787wrv.9 for ; Mon, 06 Jul 2020 00:54:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=nFhKU1c8QJZQ3rQsIyMuD/WuH/oGWV1Tm3foNGD2v2k=; b=NccZojx6VS5SLPD0LCm6xJPuhmngP4m2JasFKYcjEh51pG9kJRXznDN25mNaQEPrek XDhvUOy8P43VZUp2vqRrmh/HdhGlbrYCSQY/QdrU1+1CuLy8ipgNJx7jiGNhIAV4jlax /nREGBn9vIUvGJhwImYtzRCekJLMw1uUn+sWcSJi0ZjunOGG/YEGCPTi+pmfh384RGBT A7OWLUpu+kYD1v+UwerVkmz3d5RqR82iKx203ylWCgyrcasQfX0K7SQ0lU+RFSzhXvc5 3L5781tBoZgZxHjSoBATXT3k06UXvOnXiPriCMhaV4bin+4ZBanW38ygADumbwNgk81E zQWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=nFhKU1c8QJZQ3rQsIyMuD/WuH/oGWV1Tm3foNGD2v2k=; b=bKS/qFLkXltfJzjfgn+0Ecp2WFF5voVVC3RhntTncQ+4C7PCRHzdE0/4rVE8bUVhtX /w1VYTJScXlkiCHYKKrgHZ787jPSCu3QTxuqPIeaNvspRE6K7jlda2CIAoPfQ+UnMOyg YH29k5+TJ6IRloioDqemf1GkXKbTbmniAVXSmLGw1vZlmVCBIHvdhHilIQWoL4fBLaWs XOQDFHNeOz8RYRLKCMtJfsAMFlHu0CJHaTuUUiJu65e/y1/tPtzOqp7yMcu5TJbY9eLv F5gjPLBbeKLROJr//MgIt9LE2nXqVjMUmFJ6Iie7YQhWpHgkk0uHjwjRY/4NvFkon0iX 3YwA== X-Gm-Message-State: AOAM530IYW4n6Yx/RwnX9nulNnpgjh6EvaSZtLDTrm/OT8wrRuUucFxT 2GvKV/Bpl7/PHvc6iRDbKbK0FCPkQB0= X-Google-Smtp-Source: ABdhPJyA9no0jQk4GZGg41UlO5wkyozjfrOb5lHSzJAD2hrioJiTYYI4yqk7d9vWLXIy9pHz6BQxPg== X-Received: by 2002:a5d:4b4f:: with SMTP id w15mr46311555wrs.84.1594022074424; Mon, 06 Jul 2020 00:54:34 -0700 (PDT) Received: from kheib-workstation.redhat.com ([37.142.6.100]) by smtp.gmail.com with ESMTPSA id g145sm15028147wmg.23.2020.07.06.00.54.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jul 2020 00:54:34 -0700 (PDT) From: Kamal Heib To: linux-rdma@vger.kernel.org Cc: Jason Gunthorpe , Doug Ledford , Kamal Heib , Christian Benvenuti Subject: [PATCH for-next 5/5] RDMA/usnic: Fix reported max_pkeys attribute Date: Mon, 6 Jul 2020 10:54:19 +0300 Message-Id: <20200706075419.361484-6-kamalheib1@gmail.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200706075419.361484-1-kamalheib1@gmail.com> References: <20200706075419.361484-1-kamalheib1@gmail.com> MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org Make sure to report the right max_pkeys attribute value to indicate the maximum number of partitions supported by the usnic device. Fixes: e3cf00d0a87f ("IB/usnic: Add Cisco VIC low-level hardware driver") Signed-off-by: Kamal Heib Cc: Christian Benvenuti --- drivers/infiniband/hw/usnic/usnic_ib_verbs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/infiniband/hw/usnic/usnic_ib_verbs.c b/drivers/infiniband/hw/usnic/usnic_ib_verbs.c index b8a77ce11590..0cb2a73d46ee 100644 --- a/drivers/infiniband/hw/usnic/usnic_ib_verbs.c +++ b/drivers/infiniband/hw/usnic/usnic_ib_verbs.c @@ -309,7 +309,7 @@ int usnic_ib_query_device(struct ib_device *ibdev, props->max_pd = USNIC_UIOM_MAX_PD_CNT; props->max_mr = USNIC_UIOM_MAX_MR_CNT; props->local_ca_ack_delay = 0; - props->max_pkeys = 0; + props->max_pkeys = 1; props->atomic_cap = IB_ATOMIC_NONE; props->masked_atomic_cap = props->atomic_cap; props->max_qp_rd_atom = 0;