From owner-freebsd-stable@FreeBSD.ORG Mon Feb 4 06:37:34 2008 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 66F0316A419 for ; Mon, 4 Feb 2008 06:37:34 +0000 (UTC) (envelope-from ganbold@micom.mng.net) Received: from publicd.ub.mng.net (publicd.ub.mng.net [202.179.0.88]) by mx1.freebsd.org (Postfix) with ESMTP id 173B213C448 for ; Mon, 4 Feb 2008 06:37:33 +0000 (UTC) (envelope-from ganbold@micom.mng.net) Received: from [202.179.0.164] (helo=daemon.micom.mng.net) by publicd.ub.mng.net with esmtpa (Exim 4.67 (FreeBSD)) (envelope-from ) id 1JLuxP-000KPq-OR; Mon, 04 Feb 2008 14:37:32 +0800 Message-ID: <47A6B2AB.2060308@micom.mng.net> Date: Mon, 04 Feb 2008 14:37:31 +0800 From: Ganbold User-Agent: Thunderbird 2.0.0.9 (X11/20071225) MIME-Version: 1.0 To: Jeremy Chadwick References: <47A69A66.2080109@micom.mng.net> <20080204063023.GA91789@eos.sc1.parodius.com> In-Reply-To: <20080204063023.GA91789@eos.sc1.parodius.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: FreeBSD Stable Mailing List Subject: Re: /dev/cuad0: Device busy X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Feb 2008 06:37:34 -0000 Jeremy Chadwick wrote: > On Mon, Feb 04, 2008 at 12:53:58PM +0800, Ganbold wrote: > >> Hi, >> >> I'm trying to use serial port but the system says device busy. >> >> daemon# cu -l /dev/cuad0 -s 9600 >> /dev/cuad0: Device busy >> link down >> > > Does the same happen if you do `cu -l ttyd0 -s 9600`? > It works and fstat shows: daemon# fstat /dev/cuad0 USER CMD PID FD MOUNT INUM MODE SZ|DV R/W NAME daemon# fstat /dev/ttyd0 USER CMD PID FD MOUNT INUM MODE SZ|DV R/W NAME root cu 5574 3 /dev 41 crw------- ttyd0 rw /dev/ttyd0 root cu 5573 3 /dev 41 crw------- ttyd0 rw /dev/ttyd0 daemon# Is it expected behaviour? thanks, Ganbold > >> How to check whether something is using serial port? >> Any idea? >> > > fstat should help here. > > -- Success is in the minds of Fools. -- William Wrenshaw, 1578