From owner-freebsd-arch@freebsd.org Wed Apr 27 01:37:45 2016 Return-Path: Delivered-To: freebsd-arch@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A389DB1D754 for ; Wed, 27 Apr 2016 01:37:45 +0000 (UTC) (envelope-from csjp@sqrt.ca) Received: from mx01.sqrt.ca (i4hg.x.rootbsd.net [208.79.81.26]) by mx1.freebsd.org (Postfix) with ESMTP id 808BB1759 for ; Wed, 27 Apr 2016 01:37:45 +0000 (UTC) (envelope-from csjp@sqrt.ca) Received: by mx01.sqrt.ca (Postfix, from userid 58) id 495D2233802; Tue, 26 Apr 2016 21:30:41 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on ion X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=ALL_TRUSTED autolearn=ham autolearn_force=no version=3.4.1 Received: from xor.gateway.mts.net (wnpgmb1316w-ds01-111-250.dynamic.mtsallstream.net [142.161.111.250]) by mx01.sqrt.ca (Postfix) with ESMTPSA id 3F4AB233800; Tue, 26 Apr 2016 21:30:40 -0400 (EDT) Date: Tue, 26 Apr 2016 20:31:55 -0500 From: Christian Peron To: dayanidhi sreenivasan Cc: freebsd-arch@freebsd.org Subject: Re: FIONBIO support in freebsd for bpf Message-ID: <20160427013155.GA3880@xor.gateway.mts.net> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="OgqxwSJOaUobr8KG" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.6.0 (2016-04-01) X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Apr 2016 01:37:45 -0000 --OgqxwSJOaUobr8KG Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable It is supported. If you want to put the descriptor into non-blocking mode, = open it up with the device with the O_NONBLOCK flag specified. It probably wouldn't be too= difficult to implement this via ioctl(FIONBIO) but I would need to look at it. Not certain why it= can't be done using this method. Hope this helps. On Tue, Apr 26, 2016 at 07:22:20PM -0400, dayanidhi sreenivasan wrote: > Hi Guys, > Can somebody tell me why there is no support for non blocking IO for bpf = yet? >=20 > static int > bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, > struct thread *td) > { >=20 > ...... >=20 > case FIONBIO: /* Non-blocking I/O */ > break; >=20 > } >=20 > Thanks > Daya > _______________________________________________ > freebsd-arch@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" --OgqxwSJOaUobr8KG Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAlcgFosACgkQzHFpVAM/ozzrkACeO/qAWs9MDYW/nzOKDLdfEZuL LbkAnj/7A/Y2RmCCc20aJBaBycQ5mMwq =2oqO -----END PGP SIGNATURE----- --OgqxwSJOaUobr8KG--