Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1583486 > unrolled thread

[PATCH] IB/hns: include linux/module.h

Started byArnd Bergmann <arnd@arndb.de>
First post2017-02-17 15:50 +0100
Last post2017-02-19 15:00 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] IB/hns: include linux/module.h Arnd Bergmann <arnd@arndb.de> - 2017-02-17 15:50 +0100
    Re: [PATCH] IB/hns: include linux/module.h Doug Ledford <dledford@redhat.com> - 2017-02-19 15:00 +0100

#1583486 — [PATCH] IB/hns: include linux/module.h

FromArnd Bergmann <arnd@arndb.de>
Date2017-02-17 15:50 +0100
Subject[PATCH] IB/hns: include linux/module.h
Message-ID<tbS1b-5xl-11@gated-at.bofh.it>
I ran into a build error on arm64 randconfig testing:

infiniband/hw/hns/hns_roce_main.c:539:1: error: data definition has no type or storage class [-Werror]
infiniband/hw/hns/hns_roce_main.c:539:1: error: type defaults to 'int' in declaration of 'MODULE_DEVICE_TABLE' [-Werror=implicit-int]
infiniband/hw/hns/hns_roce_main.c:539:1: error: parameter names (without types) in function declaration [-Werror]
infiniband/hw/hns/hns_roce_main.c:979:226: error: data definition has no type or storage class [-Werror]
infiniband/hw/hns/hns_roce_main.c:979:226: error: type defaults to 'int' in declaration of 'module_init' [-Werror=implicit-int]
infiniband/hw/hns/hns_roce_main.c:979:1: error: parameter names (without types) in function declaration [-Werror]

Including the module.h makes it build again.

Fixes: 9a4435375cd1 ("IB/hns: Add driver files for hns RoCE driver")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/infiniband/hw/hns/hns_roce_main.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/infiniband/hw/hns/hns_roce_main.c b/drivers/infiniband/hw/hns/hns_roce_main.c
index 4953d9cb83a7..cf14679664ca 100644
--- a/drivers/infiniband/hw/hns/hns_roce_main.c
+++ b/drivers/infiniband/hw/hns/hns_roce_main.c
@@ -32,6 +32,7 @@
  */
 #include <linux/acpi.h>
 #include <linux/of_platform.h>
+#include <linux/module.h>
 #include <rdma/ib_addr.h>
 #include <rdma/ib_smi.h>
 #include <rdma/ib_user_verbs.h>
-- 
2.9.0

[toc] | [next] | [standalone]


#1584146

FromDoug Ledford <dledford@redhat.com>
Date2017-02-19 15:00 +0100
Message-ID<tcAbT-83c-9@gated-at.bofh.it>
In reply to#1583486

[Multipart message — attachments visible in raw view] — view raw

On Fri, 2017-02-17 at 15:38 +0100, Arnd Bergmann wrote:
> I ran into a build error on arm64 randconfig testing:
> 
> infiniband/hw/hns/hns_roce_main.c:539:1: error: data definition has
> no type or storage class [-Werror]
> infiniband/hw/hns/hns_roce_main.c:539:1: error: type defaults to
> 'int' in declaration of 'MODULE_DEVICE_TABLE' [-Werror=implicit-int]
> infiniband/hw/hns/hns_roce_main.c:539:1: error: parameter names
> (without types) in function declaration [-Werror]
> infiniband/hw/hns/hns_roce_main.c:979:226: error: data definition has
> no type or storage class [-Werror]
> infiniband/hw/hns/hns_roce_main.c:979:226: error: type defaults to
> 'int' in declaration of 'module_init' [-Werror=implicit-int]
> infiniband/hw/hns/hns_roce_main.c:979:1: error: parameter names
> (without types) in function declaration [-Werror]
> 
> Including the module.h makes it build again.
> 
> Fixes: 9a4435375cd1 ("IB/hns: Add driver files for hns RoCE driver")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Thanks, applied.

-- 
Doug Ledford <dledford@redhat.com>
    GPG KeyID: B826A3330E572FDD
   
Key fingerprint = AE6B 1BDA 122B 23B4 265B  1274 B826 A333 0E57 2FDD

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web