From owner-cvs-all Tue Nov 5 23:34:52 2002 Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A892137B401; Tue, 5 Nov 2002 23:34:50 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id D7BF343E77; Tue, 5 Nov 2002 23:34:49 -0800 (PST) (envelope-from phk@critter.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.6/8.12.6) with ESMTP id gA67Yd9d092876; Wed, 6 Nov 2002 08:34:39 +0100 (CET) (envelope-from phk@critter.freebsd.dk) To: "Daniel O'Connor" Cc: Robert Watson , cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/sys/conf majors In-Reply-To: Your message of "06 Nov 2002 17:54:27 +1030." <1036567467.55376.95.camel@chowder.localdomain> Date: Wed, 06 Nov 2002 08:34:39 +0100 Message-ID: <92875.1036568079@critter.freebsd.dk> From: Poul-Henning Kamp Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <1036567467.55376.95.camel@chowder.localdomain>, "Daniel O'Connor" w rites: >On Wed, 2002-11-06 at 17:49, Poul-Henning Kamp wrote: >> >If you run multidrop where the parity bit is used as an address marker >> >(to make coding microprocessor firmware easier) then you need to be able >> >to set the parity bit at will. >> >> This is, IMO, a very bad reason to write an entirely new driver. >> >> You should instead write a new line-discipline. > >There is another reason which I meant to put into my original email - >there are quite a number of cards or dongles which don't have the >ability to change the data direction automatically, so you have to flip >one of the serial control lines to do it. The mdsio driver can do that >for you. That is still not a reason for cloning the driver. If you did it right with a linedisc, it would also work on sparc64 which uses a siemens chips, on multiport cards which use their own chips and on any future serial port worth its salt. If you continue to clone the sio driver, you will get a driver which conflicts with the sio driver, making life difficult for people who want to mix and match normal serial and RS485. Trust me on this, I've cleaned up more "I'll just make a copy and modify" code in the kernel than anybody else in this project. Please do it right, don't hack it. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message