From owner-freebsd-questions@FreeBSD.ORG Tue Mar 8 13:34:37 2005 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2C46516A4CE for ; Tue, 8 Mar 2005 13:34:37 +0000 (GMT) Received: from relay.pair.com (relay00.pair.com [209.68.1.20]) by mx1.FreeBSD.org (Postfix) with SMTP id 888C243D31 for ; Tue, 8 Mar 2005 13:34:36 +0000 (GMT) (envelope-from alejandro@varnet.biz) Received: (qmail 58476 invoked from network); 8 Mar 2005 13:34:35 -0000 Received: from unknown (HELO ale.varnet.bsd) (unknown) by unknown with SMTP; 8 Mar 2005 13:34:35 -0000 X-pair-Authenticated: 200.115.214.28 Date: Tue, 8 Mar 2005 10:35:16 -0300 From: Alejandro Pulver To: Benjamin Keating Message-ID: <20050308103516.4b0b7698@ale.varnet.bsd> In-Reply-To: <781e2bc0050307150012c172a0@mail.gmail.com> References: <781e2bc0050307150012c172a0@mail.gmail.com> X-Mailer: Sylpheed-Claws 0.9.12b (GTK+ 1.2.10; i386-portbld-freebsd5.3) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit cc: freebsd-questions@freebsd.org Subject: Re: Recompiling the Kernel for better ATA support X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Mar 2005 13:34:37 -0000 On Mon, 7 Mar 2005 15:00:24 -0800 Benjamin Keating wrote: > I'm having a problem with my drives and found a promising solution > (http://lists.freebsd.org/pipermail/freebsd-hackers/2004-October/0088 > 21.html) It looks like i need to modify > /usr/src/sys/dev/ata/ata-lowlevel.c with the following, but im unsure > how to read it. Some pointers about how to understand this would be > awesome. > > %< -------------------------------------- > > --- ata-lowlevel.c.orig Fri Oct 29 12:06:09 2004 > +++ ata-lowlevel.c Fri Oct 29 12:05:38 2004 > @@ -700,7 +700,7 @@ > ATA_IDX_OUTB(atadev->channel, ATA_ALTSTAT, ATA_A_4BIT); > > /* only use 48bit addressing if needed (avoid bugs and overhead) > */ > - if ((lba > 268435455 || count > 256) && atadev->param && > + if ((lba > 268435454 || count > 256) && atadev->param && > atadev->param->support.command2 & ATA_SUPPORT_ADDRESS48) { > > >% -------------------------------------- > It is just a patch (a file generated by diff(1) that outputs the difference between two files, generally the original file, and the modified file). It just changes the value "268435455" to "268435454". For more information see diff(1) and patch(1). > After modifying this file, do I simply recompile my kernel? Here is > how i go about recompiling mine (open to suggestions): > > # cd /usr/src/sys/i386/conf > # cp GENERIC MYKERNEL > # vi MYKERNEL > # config MYKERNEL > # cd /usr/src > # make buildkernel KERNCONF=MYKERNEL > # make installkernel KERNCONF=MYKERNEL > You have to patch the file '/usr/src/sys/dev/ata/ata-lowlevel.c' with: # patch /usr/src/sys/dev/ata/ata-lowlevel.c And then recompile your kernel. Personally I use the "traditional" way (procedure 1) for just compiling the kernel. > Im new to kernel compiling and never patched files in the source > before. > > Keep up the good work guys! I love this OS. > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to > "freebsd-questions-unsubscribe@freebsd.org" Best Regards, Ale