Re: [Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler
On Sat, Aug 18, 2018 at 04:46:29PM +0300, Marcel Apfelbaum wrote: > Hi Yuval, > > On 08/14/2018 01:00 PM, Yuval Shaia wrote: > > Function create_ah might return NULL, let's exit with an error. > > > > Signed-off-by: Yuval Shaia > > --- > > hw/rdma/rdma_backend.c | 4 > > 1 file changed, 4 insertions(+) > > > > diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma_backend.c > > index 35726bda2e..59d02eb567 100644 > > --- a/hw/rdma/rdma_backend.c > > +++ b/hw/rdma/rdma_backend.c > > @@ -402,6 +402,10 @@ void rdma_backend_post_send(RdmaBackendDev > > *backend_dev, > > if (qp_type == IBV_QPT_UD) { > > wr.wr.ud.ah = create_ah(backend_dev, qp->ibpd, > > backend_dev->backend_gid_idx, dgid); > > +if (!wr.wr.ud.ah) { > > +comp_handler(IBV_WC_GENERAL_ERR, VENDOR_ERR_FAIL_BACKEND, ctx, > > 0); > > comp_handler takes 3 arguments, but here you pass 4, so the compilation > fails. Right, please ignore this patch. I will send it with a different patch-set which is still under work. > > Thanks, > Marcel > > > +goto out_dealloc_cqe_ctx; > > +} > > wr.wr.ud.remote_qpn = dqpn; > > wr.wr.ud.remote_qkey = dqkey; > > } >
Re: [Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler
Hi Yuval, On 08/14/2018 01:00 PM, Yuval Shaia wrote: Function create_ah might return NULL, let's exit with an error. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_backend.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma_backend.c index 35726bda2e..59d02eb567 100644 --- a/hw/rdma/rdma_backend.c +++ b/hw/rdma/rdma_backend.c @@ -402,6 +402,10 @@ void rdma_backend_post_send(RdmaBackendDev *backend_dev, if (qp_type == IBV_QPT_UD) { wr.wr.ud.ah = create_ah(backend_dev, qp->ibpd, backend_dev->backend_gid_idx, dgid); +if (!wr.wr.ud.ah) { +comp_handler(IBV_WC_GENERAL_ERR, VENDOR_ERR_FAIL_BACKEND, ctx, 0); comp_handler takes 3 arguments, but here you pass 4, so the compilation fails. Thanks, Marcel +goto out_dealloc_cqe_ctx; +} wr.wr.ud.remote_qpn = dqpn; wr.wr.ud.remote_qkey = dqkey; }
Re: [Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler
Hi, This series failed docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 20180814100010.2546-1-yuval.sh...@oracle.com Subject: [Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler === TEST SCRIPT BEGIN === #!/bin/bash time make docker-test-quick@centos7 SHOW_ENV=1 J=8 === TEST SCRIPT END === Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384 Switched to a new branch 'test' 16008d3d0e hw/rdma: Abort send-op if fail to create addr handler === OUTPUT BEGIN === BUILD centos7 make[1]: Entering directory '/var/tmp/patchew-tester-tmp-fy5j5fbe/src' GEN /var/tmp/patchew-tester-tmp-fy5j5fbe/src/docker-src.2018-08-17-02.36.17.24673/qemu.tar Cloning into '/var/tmp/patchew-tester-tmp-fy5j5fbe/src/docker-src.2018-08-17-02.36.17.24673/qemu.tar.vroot'... done. Checking out files: 45% (2897/6322) Checking out files: 46% (2909/6322) Checking out files: 47% (2972/6322) Checking out files: 48% (3035/6322) Checking out files: 49% (3098/6322) Checking out files: 50% (3161/6322) Checking out files: 51% (3225/6322) Checking out files: 52% (3288/6322) Checking out files: 53% (3351/6322) Checking out files: 54% (3414/6322) Checking out files: 55% (3478/6322) Checking out files: 56% (3541/6322) Checking out files: 57% (3604/6322) Checking out files: 58% (3667/6322) Checking out files: 59% (3730/6322) Checking out files: 60% (3794/6322) Checking out files: 61% (3857/6322) Checking out files: 62% (3920/6322) Checking out files: 63% (3983/6322) Checking out files: 64% (4047/6322) Checking out files: 65% (4110/6322) Checking out files: 66% (4173/6322) Checking out files: 67% (4236/6322) Checking out files: 68% (4299/6322) Checking out files: 69% (4363/6322) Checking out files: 70% (4426/6322) Checking out files: 71% (4489/6322) Checking out files: 72% (4552/6322) Checking out files: 73% (4616/6322) Checking out files: 74% (4679/6322) Checking out files: 75% (4742/6322) Checking out files: 76% (4805/6322) Checking out files: 77% (4868/6322) Checking out files: 78% (4932/6322) Checking out files: 79% (4995/6322) Checking out files: 80% (5058/6322) Checking out files: 81% (5121/6322) Checking out files: 82% (5185/6322) Checking out files: 83% (5248/6322) Checking out files: 84% (5311/6322) Checking out files: 85% (5374/6322) Checking out files: 86% (5437/6322) Checking out files: 87% (5501/6322) Checking out files: 88% (5564/6322) Checking out files: 89% (5627/6322) Checking out files: 90% (5690/6322) Checking out files: 91% (5754/6322) Checking out files: 92% (5817/6322) Checking out files: 93% (5880/6322) Checking out files: 94% (5943/6322) Checking out files: 95% (6006/6322) Checking out files: 96% (6070/6322) Checking out files: 97% (6133/6322) Checking out files: 98% (6196/6322) Checking out files: 99% (6259/6322) Checking out files: 100% (6322/6322) Checking out files: 100% (6322/6322), done. Your branch is up-to-date with 'origin/test'. Submodule 'dtc' (git://git.qemu-project.org/dtc.git) registered for path 'dtc' Cloning into '/var/tmp/patchew-tester-tmp-fy5j5fbe/src/docker-src.2018-08-17-02.36.17.24673/qemu.tar.vroot/dtc'... Submodule path 'dtc': checked out 'e54388015af1fb4bf04d0bca99caba1074d9cc42' Submodule 'ui/keycodemapdb' (git://git.qemu.org/keycodemapdb.git) registered for path 'ui/keycodemapdb' Cloning into '/var/tmp/patchew-tester-tmp-fy5j5fbe/src/docker-src.2018-08-17-02.36.17.24673/qemu.tar.vroot/ui/keycodemapdb'... Submodule path 'ui/keycodemapdb': checked out '6b3d716e2b6472eb7189d3220552280ef3d832ce' COPYRUNNER RUN test-quick in qemu:centos7 Packages installed: SDL-devel-1.2.15-14.el7.x86_64 bison-3.0.4-1.el7.x86_64 bzip2-1.0.6-13.el7.x86_64 bzip2-devel-1.0.6-13.el7.x86_64 ccache-3.3.4-1.el7.x86_64 csnappy-devel-0-6.20150729gitd7bc683.el7.x86_64 flex-2.5.37-3.el7.x86_64 gcc-4.8.5-28.el7_5.1.x86_64 gettext-0.19.8.1-2.el7.x86_64 git-1.8.3.1-14.el7_5.x86_64 glib2-devel-2.54.2-2.el7.x86_64 libaio-devel-0.3.109-13.el7.x86_64 libepoxy-devel-1.3.1-2.el7_5.x86_64 libfdt-devel-1.4.6-1.el7.x86_64 lzo-devel-2.06-8.el7.x86_64 make-3.82-23.el7.x86_64 mesa-libEGL-devel-17.2.3-8.20171019.el7.x86_64 mesa-libgbm-devel-17.2.3-8.20171019.el7.x86_64 nettle-devel-2.7.1-8.el7.x86_64 package g++ is not installed package librdmacm-devel is not installed pixman-devel-0.34.0-1.el7.x86_64 spice-glib-devel-0.34-3.el7_5.1.x86_64 spice-server-devel-0.14.0-2.el7_5.4.x86_64 tar-1.26-34.el7.x86_64 vte-devel-0.28.2-10.el7.x86_64 xen-devel-4.6.6-12.el7.x86_64 zlib-devel-1.2.7-17.el7.x86_64 Environment va
Re: [Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler
On Tue, Aug 14, 2018 at 01:00:10PM +0300, Yuval Shaia wrote: > Function create_ah might return NULL, let's exit with an error. > > Signed-off-by: Yuval Shaia > --- > hw/rdma/rdma_backend.c | 4 > 1 file changed, 4 insertions(+) > > diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma_backend.c > index 35726bda2e..59d02eb567 100644 > --- a/hw/rdma/rdma_backend.c > +++ b/hw/rdma/rdma_backend.c > @@ -402,6 +402,10 @@ void rdma_backend_post_send(RdmaBackendDev *backend_dev, > if (qp_type == IBV_QPT_UD) { > wr.wr.ud.ah = create_ah(backend_dev, qp->ibpd, > backend_dev->backend_gid_idx, dgid); > +if (!wr.wr.ud.ah) { > +comp_handler(IBV_WC_GENERAL_ERR, VENDOR_ERR_FAIL_BACKEND, ctx, > 0); This change is based on a patch i sent at Aug 5, "Misc fixes for pvrdma device", without it build fails. I will re-post this patch as soon as the patch-set will be pulled. > +goto out_dealloc_cqe_ctx; > +} > wr.wr.ud.remote_qpn = dqpn; > wr.wr.ud.remote_qkey = dqkey; > } > -- > 2.17.1 >
Re: [Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler
On 08/14/2018 01:00 PM, Yuval Shaia wrote: Function create_ah might return NULL, let's exit with an error. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_backend.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma_backend.c index 35726bda2e..59d02eb567 100644 --- a/hw/rdma/rdma_backend.c +++ b/hw/rdma/rdma_backend.c @@ -402,6 +402,10 @@ void rdma_backend_post_send(RdmaBackendDev *backend_dev, if (qp_type == IBV_QPT_UD) { wr.wr.ud.ah = create_ah(backend_dev, qp->ibpd, backend_dev->backend_gid_idx, dgid); +if (!wr.wr.ud.ah) { +comp_handler(IBV_WC_GENERAL_ERR, VENDOR_ERR_FAIL_BACKEND, ctx, 0); +goto out_dealloc_cqe_ctx; +} wr.wr.ud.remote_qpn = dqpn; wr.wr.ud.remote_qkey = dqkey; } The path did not compile because it depends on a series that was not yet merged. Reviewed-by: Marcel Apfelbaum Thanks, Marcel
Re: [Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler
Hi, This series failed docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 20180814100010.2546-1-yuval.sh...@oracle.com Subject: [Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler === TEST SCRIPT BEGIN === #!/bin/bash time make docker-test-quick@centos7 SHOW_ENV=1 J=8 === TEST SCRIPT END === Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384 Switched to a new branch 'test' 8bf637b1a9 hw/rdma: Abort send-op if fail to create addr handler === OUTPUT BEGIN === BUILD centos7 make[1]: Entering directory '/var/tmp/patchew-tester-tmp-2780scpd/src' GEN /var/tmp/patchew-tester-tmp-2780scpd/src/docker-src.2018-08-16-02.27.09.11924/qemu.tar Cloning into '/var/tmp/patchew-tester-tmp-2780scpd/src/docker-src.2018-08-16-02.27.09.11924/qemu.tar.vroot'... done. Your branch is up-to-date with 'origin/test'. Submodule 'dtc' (git://git.qemu-project.org/dtc.git) registered for path 'dtc' Cloning into '/var/tmp/patchew-tester-tmp-2780scpd/src/docker-src.2018-08-16-02.27.09.11924/qemu.tar.vroot/dtc'... Submodule path 'dtc': checked out 'e54388015af1fb4bf04d0bca99caba1074d9cc42' Submodule 'ui/keycodemapdb' (git://git.qemu.org/keycodemapdb.git) registered for path 'ui/keycodemapdb' Cloning into '/var/tmp/patchew-tester-tmp-2780scpd/src/docker-src.2018-08-16-02.27.09.11924/qemu.tar.vroot/ui/keycodemapdb'... Submodule path 'ui/keycodemapdb': checked out '6b3d716e2b6472eb7189d3220552280ef3d832ce' COPYRUNNER RUN test-quick in qemu:centos7 Packages installed: SDL-devel-1.2.15-14.el7.x86_64 bison-3.0.4-1.el7.x86_64 bzip2-devel-1.0.6-13.el7.x86_64 ccache-3.3.4-1.el7.x86_64 csnappy-devel-0-6.20150729gitd7bc683.el7.x86_64 flex-2.5.37-3.el7.x86_64 gcc-4.8.5-16.el7_4.2.x86_64 gettext-0.19.8.1-2.el7.x86_64 git-1.8.3.1-12.el7_4.x86_64 glib2-devel-2.50.3-3.el7.x86_64 libepoxy-devel-1.3.1-1.el7.x86_64 libfdt-devel-1.4.6-1.el7.x86_64 lzo-devel-2.06-8.el7.x86_64 make-3.82-23.el7.x86_64 mesa-libEGL-devel-17.0.1-6.20170307.el7.x86_64 mesa-libgbm-devel-17.0.1-6.20170307.el7.x86_64 package g++ is not installed package librdmacm-devel is not installed pixman-devel-0.34.0-1.el7.x86_64 spice-glib-devel-0.33-6.el7_4.1.x86_64 spice-server-devel-0.12.8-2.el7.1.x86_64 tar-1.26-32.el7.x86_64 vte-devel-0.28.2-10.el7.x86_64 xen-devel-4.6.6-10.el7.x86_64 zlib-devel-1.2.7-17.el7.x86_64 Environment variables: PACKAGES=bison bzip2-devel ccache csnappy-devel flex g++ gcc gettext git glib2-devel libepoxy-devel libfdt-devel librdmacm-devel lzo-devel make mesa-libEGL-devel mesa-libgbm-devel pixman-devel SDL-devel spice-glib-devel spice-server-devel tar vte-devel xen-devel zlib-devel HOSTNAME=f3b76565b023 MAKEFLAGS= -j8 J=8 CCACHE_DIR=/var/tmp/ccache EXTRA_CONFIGURE_OPTS= V= SHOW_ENV=1 PATH=/usr/lib/ccache:/usr/lib64/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PWD=/ TARGET_LIST= SHLVL=1 HOME=/home/patchew TEST_DIR=/tmp/qemu-test FEATURES= dtc DEBUG= _=/usr/bin/env Configure options: --enable-werror --target-list=x86_64-softmmu,aarch64-softmmu --prefix=/tmp/qemu-test/install No C++ compiler available; disabling C++ specific optional code Install prefix/tmp/qemu-test/install BIOS directory/tmp/qemu-test/install/share/qemu firmware path /tmp/qemu-test/install/share/qemu-firmware binary directory /tmp/qemu-test/install/bin library directory /tmp/qemu-test/install/lib module directory /tmp/qemu-test/install/lib/qemu libexec directory /tmp/qemu-test/install/libexec include directory /tmp/qemu-test/install/include config directory /tmp/qemu-test/install/etc local state directory /tmp/qemu-test/install/var Manual directory /tmp/qemu-test/install/share/man ELF interp prefix /usr/gnemul/qemu-%M Source path /tmp/qemu-test/src GIT binarygit GIT submodules C compilercc Host C compiler cc C++ compiler Objective-C compiler cc ARFLAGS rv CFLAGS-O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -g QEMU_CFLAGS -I/usr/include/pixman-1-Werror -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -fPIE -DPIE -m64 -mcx16 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wall -Wundef -Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -fno-common -fwrapv -Wendif-labels -Wno-missing-include-dirs -Wempty-body -Wnested-externs -Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers -Wold-style-declaration -Wold-style-definition -Wtype-limits -fstack-protector-strong -Wno-missing-braces -I/usr/include/libpng15 -I/usr/include/spice-server -I/usr/include/cacard -I/usr/include/glib-2.0 -I/
[Qemu-devel] [PATCH] hw/rdma: Abort send-op if fail to create addr handler
Function create_ah might return NULL, let's exit with an error. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_backend.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma_backend.c index 35726bda2e..59d02eb567 100644 --- a/hw/rdma/rdma_backend.c +++ b/hw/rdma/rdma_backend.c @@ -402,6 +402,10 @@ void rdma_backend_post_send(RdmaBackendDev *backend_dev, if (qp_type == IBV_QPT_UD) { wr.wr.ud.ah = create_ah(backend_dev, qp->ibpd, backend_dev->backend_gid_idx, dgid); +if (!wr.wr.ud.ah) { +comp_handler(IBV_WC_GENERAL_ERR, VENDOR_ERR_FAIL_BACKEND, ctx, 0); +goto out_dealloc_cqe_ctx; +} wr.wr.ud.remote_qpn = dqpn; wr.wr.ud.remote_qkey = dqkey; } -- 2.17.1