IB/hns: include linux/module.h
Subsystems (2)
PATCH 1/1 IB/hns: include linux/module.h
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.
--- drivers/infiniband/hw/hns/hns_roce_main.c | 1 + 1 file changed, 1 insertion(+)
drivers/infiniband/hw/hns/hns_roce_main.c +1 -0
@@ -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>
Signature · 6 lines
2.9.0 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Doug Ledford
AppliedQuoted 15 lines · Arnd Bergmann
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]
Quoted 4 lines
Including the
module.hmakes it build again.Fixes 9a4435375cd1 ("IB/hns: Add driver files for hns RoCE driver")Signed-off-by Arnd Bergmann <[email protected]>
Thanks, applied.
Signature · 4 lines
Doug Ledford <[email protected]> GPG KeyID: B826A3330E572FDD Key fingerprint = AE6B 1BDA 122B 23B4 265B 1274 B826 A333 0E57 2FDD