Date: Wed, 17 Aug 2016 11:30:49 +0200 From: Hans Petter Selasky <hps@selasky.org> To: KrishnamRaju ErapaRaju <Krishna2@chelsio.com>, Alex Bowden <alex.bowden@outlook.com>, "freebsd-infiniband@freebsd.org" <freebsd-infiniband@freebsd.org> Subject: Re: Set non blocking on /dev/rdma_cm Message-ID: <516f3566-33f0-c1d6-ab2d-997290a16ae5@selasky.org> In-Reply-To: <BN4PR12MB081885693F06A5B5666629D494140@BN4PR12MB0818.namprd12.prod.outlook.com> References: <DM2PR05MB75118A2E53E97548A432608F7130@DM2PR05MB751.namprd05.prod.outlook.com> <BN4PR12MB081885693F06A5B5666629D494140@BN4PR12MB0818.namprd12.prod.outlook.com>
next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format. --------------000922E94DAC204296CB83A8 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit On 08/17/16 09:03, KrishnamRaju ErapaRaju wrote: > Hi Alex, > > > I too faced the same issue earlier. But could not look into it/report it due to other priorities. > > Hans, if you have root caused it please point me to the patch, few of my apps uses O_NONBLOCK. > Hi Alex, Can you try the attached patch? cd /usr/src cat ibcore_fionbio.diff | patch -p1 --HPS --------------000922E94DAC204296CB83A8 Content-Type: text/x-patch; name="ibcore_fionbio.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="ibcore_fionbio.diff" diff --git a/sys/ofed/drivers/infiniband/core/ucma.c b/sys/ofed/drivers/infiniband/core/ucma.c index 56f8786..2c87db1 100644 --- a/sys/ofed/drivers/infiniband/core/ucma.c +++ b/sys/ofed/drivers/infiniband/core/ucma.c @@ -49,6 +49,8 @@ #include <rdma/ib_addr.h> #include <rdma/ib.h> +#include <sys/filio.h> + /* RDMA Userspace Connection Manager Access */ static unsigned int max_backlog = 1024; @@ -1825,11 +1827,24 @@ static int ucma_close(struct inode *inode, struct file *filp) return 0; } +static long +ucma_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) +{ + + switch (cmd) { + case FIONBIO: + return (0); + default: + return (-ENOTTY); + } +} + static const struct file_operations ucma_fops = { .owner = THIS_MODULE, .open = ucma_open, .release = ucma_close, .write = ucma_write, + .unlocked_ioctl = ucma_ioctl, .poll = ucma_poll, .llseek = no_llseek, }; --------------000922E94DAC204296CB83A8--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?516f3566-33f0-c1d6-ab2d-997290a16ae5>