From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 2 22:13:50 2008 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C51451065673 for ; Tue, 2 Dec 2008 22:13:50 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: from palm.hoeg.nl (mx0.hoeg.nl [IPv6:2001:7b8:613:100::211]) by mx1.freebsd.org (Postfix) with ESMTP id 649108FC1B for ; Tue, 2 Dec 2008 22:13:50 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: by palm.hoeg.nl (Postfix, from userid 1000) id 4E9CA1CE1F; Tue, 2 Dec 2008 23:13:49 +0100 (CET) Date: Tue, 2 Dec 2008 23:13:49 +0100 From: Ed Schouten To: Arjan van der Velde Message-ID: <20081202221349.GT64969@hoeg.nl> References: <54A75E03-AE64-4DD9-8D15-7A7499E73D43@xs4all.nl> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="3a/Z8KDuKqDOIvAo" Content-Disposition: inline In-Reply-To: <54A75E03-AE64-4DD9-8D15-7A7499E73D43@xs4all.nl> User-Agent: Mutt/1.5.18 (2008-05-17) Cc: FreeBSD Hackers Subject: Re: TCSBRK not implemented in linux compat X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Dec 2008 22:13:50 -0000 --3a/Z8KDuKqDOIvAo Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hello Arjan, * Arjan van der Velde wrote: > While trying to get a linux binary running on FreeBSD I encountered the= =20 > following problem during serial port I/O. > > Dec 1 22:22:34 soekris kernel: linux: pid 7239 (linuxbinary): ioctl =20 > fd=3D0, cmd=3D0x5409 ('T',9) is not implemented > > 0x5409 turns out to be TCSBRK, which is not implemented (yet?). Can =20 > anyone give me some clues where / how to start implementing this? It =20 > seems like the linux way of handling it is to call tcdrain(), but I'm =20 > not sure as to how this translates to the FreeBSD compat layer. I think you could just make it call TIOCDRAIN directly. Unfortunately that's not correct if the argument is 0, because then we have to call TIOCSBRK and TIOCCBRK with a 250 msec interval. I guess adding some kind of printf() there should be good enough for now. I can't look into it right now, because I have to get up at 6:15 tomorrow. Sorry! :-/ --=20 Ed Schouten WWW: http://80386.nl/ --3a/Z8KDuKqDOIvAo Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkk1sx0ACgkQ52SDGA2eCwX3rgCeMSbiBpZmzb0E6354tdD1dUlf BhQAnicrS/svQDk/Gp2muraPDS7WlZ04 =o/mh -----END PGP SIGNATURE----- --3a/Z8KDuKqDOIvAo--