From patchwork Wed Sep 26 19:36:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 147660 Delivered-To: patch@linaro.org Received: by 2002:a2e:8595:0:0:0:0:0 with SMTP id b21-v6csp1121232lji; Wed, 26 Sep 2018 12:37:34 -0700 (PDT) X-Google-Smtp-Source: ACcGV61tqnYwCgVVPXRPUq/otzFjBdOEIxXY1YOHc0maLpThrPUg3xY8/dRwaMyrzESSmFje7UyM X-Received: by 2002:a62:5343:: with SMTP id h64-v6mr7717565pfb.226.1537990654742; Wed, 26 Sep 2018 12:37:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537990654; cv=none; d=google.com; s=arc-20160816; b=EpLtR0bmS5ZwEWIT6pq6874kYJmOccl82trdrLERqmE4vQqsDusDwaVACHJaalE1XW Bz4AqRUXLrus670r4dnxx8D2fygXAHQ6g0ojOctsX/IFBK3+LTmO6QjGvBl7isK3vCn1 8hzJS9lp5ymk7fEgj+1USH9jba5+lwwhITiOO6S2ifAVgp6yY3+yhjq7ew3j9vAodJC4 bW8p0SXu752301YnKscvvN4hHpMyja/n6cw1zbHETfn6p2iCk4GMAMfs3/QEBUxPDwWw OlU69efc4s0Bg4Att2K4a1F0vucMg9dfYrfqMlW2aih1iu6VQc8wvyoLc2D1LSD3WWOm W14Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=+sesT+41RZ6rPUYuxZ8E5bJTYILdcysYWnzRg+bR28o=; b=hkmNM1xDb5kreVjD1DiF5lp+Poc+6/vo+dlfzxMGCKSlSE47WVYseEitb8IxotTkfI 3X2EJpfD3G9ZKZqQgqBDMEkFlR8HXr/TOrxlaUrg+Vckw776blW0voSo7qEfeKEn4EbD VhlHJuVx8y2HsdCkmmFCQsEnNP8zzj1l1GhU2Gj7ycTfYiPGcPePoU6xjCY7Kn9jum2D WCSnog3CcKpSHRg1Tcm3+zlQG+1po/SZ2Vm3ICdlNWDO95YyyFgtA4NyKcbJ000X6XF/ MSoCckPpSx0bZuNo22EN7jDiYOuS0NpzyNUYBSldQB+2Z4bE2vCqPgYTiO6caSDHWGTo gAGg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s26-v6si6036227pge.339.2018.09.26.12.37.34; Wed, 26 Sep 2018 12:37:34 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726781AbeI0BwC (ORCPT + 32 others); Wed, 26 Sep 2018 21:52:02 -0400 Received: from mout.kundenserver.de ([212.227.17.24]:51181 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726032AbeI0BwB (ORCPT ); Wed, 26 Sep 2018 21:52:01 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue109 [212.227.15.145]) with ESMTPA (Nemesis) id 1MKbc2-1gLfTj32M8-00KyOQ; Wed, 26 Sep 2018 21:37:07 +0200 From: Arnd Bergmann To: Lijun Ou , "Wei Hu(Xavier)" , Doug Ledford , Jason Gunthorpe , Yishai Hadas Cc: Arnd Bergmann , Shaobo Xu , linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] RDMA: fix dependencies for rdma_user_mmap_io Date: Wed, 26 Sep 2018 21:36:52 +0200 Message-Id: <20180926193706.2447532-1-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 X-Provags-ID: V03:K1:+vRyNR1nIKmd26OTzp2PhY+zAVub2P5w/v0nK8D5aalyoPp0GMe 0HhYVPRbs8RMWMYegoAJ+p2Fk9wGUqwTKTFO9cz6Dc7pxbEAB+Vp9gim7l3ZN/Rimw/2clD QIhSLZy7MRoGxfavDD2G0xCvMIS9G0L7KEAgXVLwdlCuI95+iDnpx6c9AlK87/6+LIpxUdW Y62gROiE9kytXUv05SiiQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:4XvGftH8zU8=:VWRaC7XUo4RLRKWYyPcWAB Jhfzu0CaAvaDWXnRm+Sk3O4wtZZVS/+BP21ltKY25Ym9lBlHOMadGPjaeH6UgEVD9a9bcnJYK NulcqRhYng4tYIQU1OedLZLpCRm7ZG5vUdmhiQdkjHt8qCNloIk46H9FgOJcnFoHYszc2WkGb zB+4jb2tf/Wyfxwn9F+JfpaPHtTIv4WXeViWCw5NMDlqRxexcDNODbgpKR0u/c51Y++uvGUJd VS7YdrPk2MdluE/MbL1rfq5CyI6gjKPbHANIM3TsPBiyZMyjxdT5dSp4tyqv5zHQ56juIisBW Pgp2bk13/PkaLY7mSy50Ps4wyP8gy7KGzSvYCVK3Nva8tfQHKkFHSmLNnDE3td1H8MEQwNTFi beHv8vntcDlB+2YW5KPVVPFZr0wrHIyPRtiB+Tf3XcArmzkf8iG4O6ZiEz3J/TwpNWmhBcEuw y09r01uhyNSGyHNAyBnjXbtURPqanRQZUjmN3eD8qSEzMaTeUDplmgpwOHxT2Jp9jnz8JlvTx DGJ5oyNza+YAElTMIU85ePcQBpfIRf8YU5s/c8w0l7/STpmDj59RW8o5/7/V/Khdt2pQaHOQj /VnzVW/JviRn+Lj7z0DrgcEEhNp28r5ejmwl/3e16H3hOOpK43QKI1gfQW1Go7GerdJsmov/M c+1eLsrvav5sFJzVmx8eURkOyYqAfwpdNYmhBlwXNspWx89HLsKgSuBowUqPkv6SK734= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The mlx4 driver produces a link error when it is configured as built-in while CONFIG_INFINIBAND_USER_ACCESS is set to =m: drivers/infiniband/hw/mlx4/main.o: In function `mlx4_ib_mmap': main.c:(.text+0x1af4): undefined reference to `rdma_user_mmap_io' The same function is called from mlx5, which already has a dependency to ensure we can call it, and from hns, which appears to suffer from the same problem. This adds the same dependency that mlx5 uses to the other two. Fixes: 6745d356ab39 ("RDMA/hns: Use rdma_user_mmap_io") Fixes: c282da4109e4 ("RDMA/mlx4: Use rdma_user_mmap_io") Signed-off-by: Arnd Bergmann --- drivers/infiniband/hw/hns/Kconfig | 1 + drivers/infiniband/hw/mlx4/Kconfig | 1 + 2 files changed, 2 insertions(+) -- 2.18.0 diff --git a/drivers/infiniband/hw/hns/Kconfig b/drivers/infiniband/hw/hns/Kconfig index fddb5fdf92de..21c2100b2ea9 100644 --- a/drivers/infiniband/hw/hns/Kconfig +++ b/drivers/infiniband/hw/hns/Kconfig @@ -1,6 +1,7 @@ config INFINIBAND_HNS tristate "HNS RoCE Driver" depends on NET_VENDOR_HISILICON + depends on INFINIBAND_USER_ACCESS || !INFINIBAND_USER_ACCESS depends on ARM64 || (COMPILE_TEST && 64BIT) ---help--- This is a RoCE/RDMA driver for the Hisilicon RoCE engine. The engine diff --git a/drivers/infiniband/hw/mlx4/Kconfig b/drivers/infiniband/hw/mlx4/Kconfig index db4aa13ebae0..d1de3285fd88 100644 --- a/drivers/infiniband/hw/mlx4/Kconfig +++ b/drivers/infiniband/hw/mlx4/Kconfig @@ -1,6 +1,7 @@ config MLX4_INFINIBAND tristate "Mellanox ConnectX HCA support" depends on NETDEVICES && ETHERNET && PCI && INET + depends on INFINIBAND_USER_ACCESS || !INFINIBAND_USER_ACCESS depends on MAY_USE_DEVLINK select NET_VENDOR_MELLANOX select MLX4_CORE