Message ID | 1490352343-20075-27-git-send-email-jinpu.wangl@profitbricks.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Hi Jack, [auto build test WARNING on linus/master] [also build test WARNING on v4.11-rc3 next-20170324] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Jack-Wang/INFINIBAND-NETWORK-BLOCK-DEVICE-IBNBD/20170325-101629 config: i386-allyesconfig (attached as .config) compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901 reproduce: # save the attached .config to linux build tree make ARCH=i386 All warnings (new ones prefixed by >>): drivers/block/ibnbd_server/ibnbd_srv.c: In function 'ibnbd_srv_revalidate_sess_dev': >> drivers/block/ibnbd_server/ibnbd_srv.c:994:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'size_t {aka unsigned int}' [-Wformat=] INFO(sess_dev, "notified client about device size change" ^~~~~~ drivers/block/ibnbd_server/ibnbd_srv.c:994:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 5 has type 'size_t {aka unsigned int}' [-Wformat=] -- drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c: In function 'ibnbd_validate_msg_sess_info': >> drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:54:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=] ERR_NP("Sess info message with unexpected length received" ^~~~~~ >> drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:54:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=] drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c: In function 'ibnbd_validate_msg_sess_info_rsp': drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:67:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=] ERR_NP("Sess info message with unexpected length received" ^~~~~~ drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:67:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=] drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c: In function 'ibnbd_validate_msg_open_resp': drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:82:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=] ERR_NP("Open Response msg received with unexpected length" ^~~~~~ drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c: In function 'ibnbd_validate_msg_revalidate': drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:114:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=] ERR_NP("Device resize message with unexpected length received" ^~~~~~ drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:114:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=] drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c: In function 'ibnbd_validate_msg_open': drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:126:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=] ERR_NP("Open msg received with unexpected length" ^~~~~~ drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c: In function 'ibnbd_validate_msg_close': drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:151:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=] ERR_NP("Close msg received with unexpected length %lu instead" ^~~~~~ drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:151:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=] drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c: In function 'ibnbd_validate_msg_close_rsp': drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:163:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=] ERR_NP("Close_rsp msg received with unexpected length %lu" ^~~~~~ drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.c:163:10: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=] warning: __mcount_loc already exists: drivers/block/ibnbd_server/../ibnbd_lib/ibnbd-proto.o vim +994 drivers/block/ibnbd_server/ibnbd_srv.c 346428ec Jack Wang 2017-03-24 978 msg.nsectors = nsectors; 346428ec Jack Wang 2017-03-24 979 346428ec Jack Wang 2017-03-24 980 if (unlikely(sess_dev->sess->state == SESS_STATE_DISCONNECTED)) 346428ec Jack Wang 2017-03-24 981 return -ENODEV; 346428ec Jack Wang 2017-03-24 982 346428ec Jack Wang 2017-03-24 983 if (!sess_dev->is_visible) { 346428ec Jack Wang 2017-03-24 984 INFO(sess_dev, "revalidate device failed, wait for sending " 346428ec Jack Wang 2017-03-24 985 "open reply first\n"); 346428ec Jack Wang 2017-03-24 986 return -EAGAIN; 346428ec Jack Wang 2017-03-24 987 } 346428ec Jack Wang 2017-03-24 988 346428ec Jack Wang 2017-03-24 989 ret = ibtrs_srv_send(sess_dev->sess->ibtrs_sess, &vec, 1); 346428ec Jack Wang 2017-03-24 990 if (unlikely(ret)) { 346428ec Jack Wang 2017-03-24 991 ERR(sess_dev, "revalidate: Sending new device size" 346428ec Jack Wang 2017-03-24 992 " to client failed, errno: %d\n", ret); 346428ec Jack Wang 2017-03-24 993 } else { 346428ec Jack Wang 2017-03-24 @994 INFO(sess_dev, "notified client about device size change" 346428ec Jack Wang 2017-03-24 995 " (old nsectors: %lu, new nsectors: %lu)\n", 346428ec Jack Wang 2017-03-24 996 sess_dev->nsectors, nsectors); 346428ec Jack Wang 2017-03-24 997 sess_dev->nsectors = nsectors; 346428ec Jack Wang 2017-03-24 998 } 346428ec Jack Wang 2017-03-24 999 346428ec Jack Wang 2017-03-24 1000 return ret; 346428ec Jack Wang 2017-03-24 1001 } 346428ec Jack Wang 2017-03-24 1002 :::::: The code at line 994 was first introduced by commit :::::: 346428ec19d9ec225850f10b7fc26d98051d5f58 ibnbd_srv: add main functionality :::::: TO: Jack Wang <jinpu.wang@profitbricks.com> :::::: CC: 0day robot <fengguang.wu@intel.com> --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation
diff --git a/drivers/block/Kconfig b/drivers/block/Kconfig index c309e57..e4823c4 100644 --- a/drivers/block/Kconfig +++ b/drivers/block/Kconfig @@ -276,6 +276,7 @@ config BLK_DEV_CRYPTOLOOP source "drivers/block/drbd/Kconfig" source "drivers/block/ibnbd_client/Kconfig" +source "drivers/block/ibnbd_server/Kconfig" config BLK_DEV_NBD tristate "Network block device support" diff --git a/drivers/block/Makefile b/drivers/block/Makefile index 7da1813..cd20888 100644 --- a/drivers/block/Makefile +++ b/drivers/block/Makefile @@ -35,6 +35,7 @@ obj-$(CONFIG_BLK_DEV_HD) += hd.o obj-$(CONFIG_XEN_BLKDEV_FRONTEND) += xen-blkfront.o obj-$(CONFIG_XEN_BLKDEV_BACKEND) += xen-blkback/ obj-$(CONFIG_BLK_DEV_IBNBD_CLT) += ibnbd_client/ +obj-$(CONFIG_BLK_DEV_IBNBD_SRV) += ibnbd_server/ obj-$(CONFIG_BLK_DEV_DRBD) += drbd/ obj-$(CONFIG_BLK_DEV_RBD) += rbd.o obj-$(CONFIG_BLK_DEV_PCIESSD_MTIP32XX) += mtip32xx/ diff --git a/drivers/block/ibnbd_server/Kconfig b/drivers/block/ibnbd_server/Kconfig new file mode 100644 index 0000000..943e1b2 --- /dev/null +++ b/drivers/block/ibnbd_server/Kconfig @@ -0,0 +1,16 @@ +config BLK_DEV_IBNBD_SRV + tristate "Network block device over Infiniband server support" + depends on INFINIBAND_IBTRS_SRV + ---help--- + Saying Y here will allow your computer to be a server for network + block devices over Infiniband, i.e. it will be able to use block + devices exported by servers (mount file systems on them etc.). + Communication between client and server works over Infiniband + networking, but to the client program this is hidden: + it looks like a regular local file access to a block device + special file such as /dev/ibnbd0. + + To compile this driver as a module, choose M here: the + module will be called ibnbd_client. + + If unsure, say N. diff --git a/drivers/block/ibnbd_server/Makefile b/drivers/block/ibnbd_server/Makefile new file mode 100644 index 0000000..e66860f --- /dev/null +++ b/drivers/block/ibnbd_server/Makefile @@ -0,0 +1,3 @@ +obj-$(CONFIG_BLK_DEV_IBNBD_SRV) += ibnbd_server.o +ibnbd_server-objs := ibnbd_srv.o ibnbd_srv_sysfs.o ibnbd_dev.o \ + ../ibnbd_lib/ibnbd.o ../ibnbd_lib/ibnbd-proto.o