From owner-freebsd-drivers@FreeBSD.ORG Mon Jul 21 18:32:30 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7A8C2106567C for ; Mon, 21 Jul 2008 18:32:30 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 381778FC1F for ; Mon, 21 Jul 2008 18:32:29 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id F40A51A9192 for ; Mon, 21 Jul 2008 11:12:37 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JtqhGJVYWhON for ; Mon, 21 Jul 2008 11:12:37 -0700 (PDT) Received: from iago.office.miralink.com (iago.office.miralink.com [10.0.0.40]) by plato.miralink.com (Postfix) with ESMTP id 909F21A918A for ; Mon, 21 Jul 2008 11:12:37 -0700 (PDT) Message-ID: <4884D1ED.5060205@miralink.com> Date: Mon, 21 Jul 2008 11:14:05 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.14 (X11/20080501) MIME-Version: 1.0 To: freebsd-drivers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: MII compile errors(RELENG_7) X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jul 2008 18:32:30 -0000 Anyone else getting this with GENERIC from this AM? ===> mii (all) cc -O2 -fno-strict-aliasing -pipe -D_KERNEL -DKLD_MODULE -std=c99 -nostdinc -DHAVE_KERNEL_OPTION_HEADERS -include /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/i386/compile/GENERIC/opt_global.h -I. -I@ -I@/contrib/altq -finline-limit=8000 --param inline-unit-growth=100 --param large-function-growth=1000 -fno-common -g -I/usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/i386/compile/GENERIC -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -ffreestanding -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -c /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c cc -O2 -fno-strict-aliasing -pipe -D_KERNEL -DKLD_MODULE -std=c99 -nostdinc -DHAVE_KERNEL_OPTION_HEADERS -include /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/i386/compile/GENERIC/opt_global.h -I. -I@ -I@/contrib/altq -finline-limit=8000 --param inline-unit-growth=100 --param large-function-growth=1000 -fno-common -g -I/usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/i386/compile/GENERIC -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -ffreestanding -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -c /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/truephy.c /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/truephy.c:78: error: 'MII_OUI_AGERE' undeclared here (not in a function) /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/truephy.c:78: error: 'MII_MODEL_AGERE_ET1011C' undeclared here (not in a function) /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/truephy.c:78: error: 'MII_STR_AGERE_ET1011C' undeclared here (not in a function) *** Error code 1 /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:88: error: 'MII_OUI_JMICRON' undeclared here (not in a function) /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:88: error: 'MII_MODEL_JMICRON_JMP202' undeclared here (not in a function) /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:88: error: 'MII_STR_JMICRON_JMP202' undeclared here (not in a function) /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:89: error: 'MII_MODEL_JMICRON_JMP211' undeclared here (not in a function) /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:89: error: 'MII_STR_JMICRON_JMP211' undeclared here (not in a function) *** Error code 1 2 errors *** Error code 2 1 error *** Error code 2 1 error -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com Yahoo: sean_bruno@yahoo.com From owner-freebsd-drivers@FreeBSD.ORG Mon Jul 21 18:33:44 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 12ACC1065674 for ; Mon, 21 Jul 2008 18:33:44 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id C8F558FC0C for ; Mon, 21 Jul 2008 18:33:43 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 3C8C91A9195 for ; Mon, 21 Jul 2008 11:32:15 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id nOGd5KqXk8tN for ; Mon, 21 Jul 2008 11:32:14 -0700 (PDT) Received: from iago.office.miralink.com (iago.office.miralink.com [10.0.0.40]) by plato.miralink.com (Postfix) with ESMTP id C73161A9192 for ; Mon, 21 Jul 2008 11:32:14 -0700 (PDT) Message-ID: <4884D686.2040706@miralink.com> Date: Mon, 21 Jul 2008 11:33:42 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.14 (X11/20080501) MIME-Version: 1.0 To: freebsd-drivers@freebsd.org References: <4884D1ED.5060205@miralink.com> In-Reply-To: <4884D1ED.5060205@miralink.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: MII compile errors(RELENG_7) X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jul 2008 18:33:44 -0000 Sean Bruno wrote: > Anyone else getting this with GENERIC from this AM? > > > ===> mii (all) > cc -O2 -fno-strict-aliasing -pipe -D_KERNEL -DKLD_MODULE -std=c99 > -nostdinc -DHAVE_KERNEL_OPTION_HEADERS -include > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/i386/compile/GENERIC/opt_global.h > -I. -I@ -I@/contrib/altq -finline-limit=8000 --param > inline-unit-growth=100 --param large-function-growth=1000 -fno-common > -g > -I/usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/i386/compile/GENERIC > -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx > -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -ffreestanding -Wall > -Wredundant-decls -Wnested-externs -Wstrict-prototypes > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef > -Wno-pointer-sign -fformat-extensions -c > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c > > cc -O2 -fno-strict-aliasing -pipe -D_KERNEL -DKLD_MODULE -std=c99 > -nostdinc -DHAVE_KERNEL_OPTION_HEADERS -include > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/i386/compile/GENERIC/opt_global.h > -I. -I@ -I@/contrib/altq -finline-limit=8000 --param > inline-unit-growth=100 --param large-function-growth=1000 -fno-common > -g > -I/usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/i386/compile/GENERIC > -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx > -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -ffreestanding -Wall > -Wredundant-decls -Wnested-externs -Wstrict-prototypes > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef > -Wno-pointer-sign -fformat-extensions -c > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/truephy.c > > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/truephy.c:78: > error: 'MII_OUI_AGERE' undeclared here (not in a function) > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/truephy.c:78: > error: 'MII_MODEL_AGERE_ET1011C' undeclared here (not in a function) > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/truephy.c:78: > error: 'MII_STR_AGERE_ET1011C' undeclared here (not in a function) > *** Error code 1 > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:88: > error: 'MII_OUI_JMICRON' undeclared here (not in a function) > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:88: > error: 'MII_MODEL_JMICRON_JMP202' undeclared here (not in a function) > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:88: > error: 'MII_STR_JMICRON_JMP202' undeclared here (not in a function) > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:89: > error: 'MII_MODEL_JMICRON_JMP211' undeclared here (not in a function) > /usr/home/sbruno/FreeBSD_RELENG_7_15APR08/src/sys/modules/mii/../../dev/mii/jmphy.c:89: > error: 'MII_STR_JMICRON_JMP211' undeclared here (not in a function) > *** Error code 1 > 2 errors > *** Error code 2 > 1 error > *** Error code 2 > 1 error > Hmmm....This looks like an artifact of compiling with -j flags. e.g. make -j 2 Excluding that make option, compile fine. -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com Yahoo: sean_bruno@yahoo.com From owner-freebsd-drivers@FreeBSD.ORG Fri Jul 25 10:12:50 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7BEAD106567A; Fri, 25 Jul 2008 10:12:50 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from smtp8.yandex.ru (smtp8.yandex.ru [213.180.200.213]) by mx1.freebsd.org (Postfix) with ESMTP id 7AF1D8FC21; Fri, 25 Jul 2008 10:12:49 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from mail.kirov.so-cdu.ru ([77.72.136.145]:14822 "EHLO [127.0.0.1]" smtp-auth: "bu7cher" TLS-CIPHER: "DHE-RSA-AES256-SHA keybits 256/256 version TLSv1/SSLv3" TLS-PEER-CN1: ) by mail.yandex.ru with ESMTP id S7455898AbYGYKMi (ORCPT + 1 other); Fri, 25 Jul 2008 14:12:38 +0400 X-Yandex-Spam: 1 X-Yandex-Front: smtp8 X-Yandex-TimeMark: 1216980758 X-MsgDayCount: 7 X-Comment: RFC 2476 MSA function at smtp8.yandex.ru logged sender identity as: bu7cher Message-ID: <4889A712.7090204@yandex.ru> Date: Fri, 25 Jul 2008 14:12:34 +0400 From: "Andrey V. Elsukov" User-Agent: Mozilla Thunderbird 1.5 (FreeBSD/20051231) MIME-Version: 1.0 To: Sean Bruno References: <4839F473.6070109@miralink.com> <4889A415.1060309@yandex.ru> In-Reply-To: <4889A415.1060309@yandex.ru> Content-Type: multipart/mixed; boundary="------------020408080206040205040404" Cc: freebsd-drivers@freebsd.org, =?UTF-8?B?U8O4cmVuIFNjaG1pZHQ=?= Subject: Re: ATA patch for RELENG_6 ... a patch looking for a good home X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jul 2008 10:12:50 -0000 This is a multi-part message in MIME format. --------------020408080206040205040404 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Andrey V. Elsukov wrote: > What you think about attached patch? > It can resolve your problem and shouldn't break anything. > With this patch you can set mode in /boot/device.hints, for > example: > hint.ad.0.mode="UDMA33" > hint.ad.1.mode="UDMA100" > > These limits work only on boot stage, after boot completed you can > change mode via atacontrol. Also, this is the same patch, but it doesn't allow override maximum mode in device.hints. I don't know which patch is preferable, I think second one. -- WBR, Andrey V. Elsukov --------------020408080206040205040404 Content-Type: text/plain; name="ata_limit_mode_from_device_hints2.diff.txt" Content-Transfer-Encoding: base64 Content-Disposition: inline; filename="ata_limit_mode_from_device_hints2.diff.txt" SW5kZXg6IHNyYy9zeXMvZGV2L2F0YS9hdGEtYWxsLmMKPT09PT09PT09PT09PT09PT09PT09 PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQpSQ1MgZmls ZTogL25jdnMvc3JjL3N5cy9kZXYvYXRhL2F0YS1hbGwuYyx2CnJldHJpZXZpbmcgcmV2aXNp b24gMS4yODkKZGlmZiAtdSAtYiAtcCAtcjEuMjg5IGF0YS1hbGwuYwotLS0gc3JjL3N5cy9k ZXYvYXRhL2F0YS1hbGwuYwkxMSBKdW4gMjAwOCAwNjo0NDo1OCAtMDAwMAkxLjI4OQorKysg c3JjL3N5cy9kZXYvYXRhL2F0YS1hbGwuYwkyNSBKdWwgMjAwOCAxMDowNjowMCAtMDAwMApA QCAtODg5LDYgKzg4OSwyOCBAQCBhdGFfbW9kZTJzdHIoaW50IG1vZGUpCiAgICAgfQogfQog CitzdGF0aWMgaW50CithdGFfc3RyMm1vZGUoY29uc3QgY2hhciAqc3RyKQoreworCWlmICgh c3RybmNhc2VjbXAoc3RyLCAiQklPU1BJTyIsIDcpKSByZXR1cm4gQVRBX1BJTzsKKwlpZiAo IXN0cm5jYXNlY21wKHN0ciwgIlBJTzAiLCA0KSkgcmV0dXJuIEFUQV9QSU8wOworCWlmICgh c3RybmNhc2VjbXAoc3RyLCAiUElPMSIsIDQpKSByZXR1cm4gQVRBX1BJTzE7CisJaWYgKCFz dHJuY2FzZWNtcChzdHIsICJQSU8yIiwgNCkpIHJldHVybiBBVEFfUElPMjsKKwlpZiAoIXN0 cm5jYXNlY21wKHN0ciwgIlBJTzMiLCA0KSkgcmV0dXJuIEFUQV9QSU8zOworCWlmICghc3Ry bmNhc2VjbXAoc3RyLCAiUElPNCIsIDQpKSByZXR1cm4gQVRBX1BJTzQ7CisJaWYgKCFzdHJu Y2FzZWNtcChz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ludCBtOworCisJaWYgKGRydiAmJiByZXNvdXJjZV9zdHJp bmdfdmFsdWUoZHJ2LT5uYW1lLCBhdGFkZXYtPnVuaXQsCisJCQkJIm1vZGUiLCAmc3RyKSA9 PSAwKSB7CisJICAgIG0gPSBhdGFfc3RyMm1vZGUoc3RyKTsKKwkgICAgaWYgKG0gPj0gQVRB X1BJTykKKwkJbW9kZSA9IG07CisJfQorICAgIH0KKwogICAgIGlmIChtYXhtb2RlICYmIG1v ZGUgPiBtYXhtb2RlKQogCW1vZGUgPSBtYXhtb2RlOwogCg== --------------020408080206040205040404-- From owner-freebsd-drivers@FreeBSD.ORG Fri Jul 25 10:46:46 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 584C81065672 for ; Fri, 25 Jul 2008 10:46:46 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from smtp2.yandex.ru (smtp2.yandex.ru [213.180.200.18]) by mx1.freebsd.org (Postfix) with ESMTP id 8B9B48FC16 for ; Fri, 25 Jul 2008 10:46:45 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from ns.kirov.so-cdu.ru ([77.72.136.145]:27127 "EHLO [127.0.0.1]" smtp-auth: "bu7cher" TLS-CIPHER: "DHE-RSA-AES256-SHA keybits 256/256 version TLSv1/SSLv3" TLS-PEER-CN1: ) by mail.yandex.ru with ESMTP id S4395399AbYGYJ7w (ORCPT ); Fri, 25 Jul 2008 13:59:52 +0400 X-Yandex-Spam: 1 X-Yandex-Front: smtp2 X-Yandex-TimeMark: 1216979992 X-MsgDayCount: 3 X-Comment: RFC 2476 MSA function at smtp2.yandex.ru logged sender identity as: bu7cher Message-ID: <4889A415.1060309@yandex.ru> Date: Fri, 25 Jul 2008 13:59:49 +0400 From: "Andrey V. Elsukov" User-Agent: Mozilla Thunderbird 1.5 (FreeBSD/20051231) MIME-Version: 1.0 To: Sean Bruno References: <4839F473.6070109@miralink.com> In-Reply-To: <4839F473.6070109@miralink.com> Content-Type: multipart/mixed; boundary="------------040205090903030903000307" Cc: freebsd-drivers@freebsd.org, =?UTF-8?B?U8O4cmVuIFNjaG1pZHQ=?= Subject: Re: ATA patch for RELENG_6 ... a patch looking for a good home X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jul 2008 10:46:46 -0000 This is a multi-part message in MIME format. --------------040205090903030903000307 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Sean Bruno wrote: > I got this patch a while ago and I don't see it appearing in RELENG_6 > yet. Can someone "sheperd" this along or point out why it's not > acceptable? > > This patch was generated by a failure to boot correctly off of a compact > flash IDE module from Transcend. > > Index: dev/ata/ata-chipset.c > =================================================================== > --- dev/ata/ata-chipset.c (.../FreeBSD_RELENG_6_13APR07/src/sys) > (revision 5436) > +++ dev/ata/ata-chipset.c (.../miralink.FreeBSD.6/src/sys) > (revision 5436) > @@ -2059,7 +2059,8 @@ > atadev->mode = ATA_SA150; > } > else { > - mode = ata_limit_mode(dev, mode, ATA_UDMA5); > + /*mode = ata_limit_mode(dev, mode, ATA_UDMA5);*/ > + mode = ata_check_80pin(dev, ATA_UDMA5); > if (!ata_controlcmd(dev, ATA_SETFEATURES, ATA_SF_SETXFER, 0, mode)) > atadev->mode = mode; > } Hi, Soren and Sean. What you think about attached patch? It can resolve your problem and shouldn't break anything. With this patch you can set mode in /boot/device.hints, for example: hint.ad.0.mode="UDMA33" hint.ad.1.mode="UDMA100" These limits work only on boot stage, after boot completed you can change mode via atacontrol. -- WBR, Andrey V. Elsukov --------------040205090903030903000307 Content-Type: text/plain; name="ata_limit_mode_from_device_hints.diff.txt" Content-Transfer-Encoding: base64 Content-Disposition: inline; filename="ata_limit_mode_from_device_hints.diff.txt" SW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GV2LT51bml0LAorCQkJCSJtb2RlIiwgJnN0cikgPT0gMCkg eworCSAgICBtID0gYXRhX3N0cjJtb2RlKHN0cik7CisJICAgIGlmIChtID49IEFUQV9QSU8p CisJCW1vZGUgPSBtOworCX0KKyAgICB9CisKICAgICBpZiAobW9kZSA+PSBBVEFfVURNQTAg JiYgYXRhX3Vtb2RlKCZhdGFkZXYtPnBhcmFtKSA+IDApCiAJcmV0dXJuIG1pbihtb2RlLCBh dGFfdW1vZGUoJmF0YWRldi0+cGFyYW0pKTsKIAo= --------------040205090903030903000307-- From owner-freebsd-drivers@FreeBSD.ORG Fri Jul 25 14:43:39 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F0736106567A for ; Fri, 25 Jul 2008 14:43:39 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id CDCEE8FC19 for ; Fri, 25 Jul 2008 14:43:39 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 05E8C1A90C4; Fri, 25 Jul 2008 07:41:22 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.272 X-Spam-Level: X-Spam-Status: No, score=-4.272 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, AWL=0.127, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hFkpG38k6beo; Fri, 25 Jul 2008 07:41:21 -0700 (PDT) Received: from [10.47.1.10] (vpn.office.miralink.com [10.0.0.5]) by plato.miralink.com (Postfix) with ESMTP id 782A61A90C2; Fri, 25 Jul 2008 07:41:21 -0700 (PDT) Message-ID: <4889E699.3050606@miralink.com> Date: Fri, 25 Jul 2008 07:43:37 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.14 (X11/20080501) MIME-Version: 1.0 To: "Andrey V. Elsukov" References: <4839F473.6070109@miralink.com> <4889A415.1060309@yandex.ru> <4889A712.7090204@yandex.ru> In-Reply-To: <4889A712.7090204@yandex.ru> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-drivers@freebsd.org, =?UTF-8?B?U8O4cmVuIFNjaG1pZHQ=?= Subject: Re: ATA patch for RELENG_6 ... a patch looking for a good home X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jul 2008 14:43:40 -0000 Andrey V. Elsukov wrote: > Andrey V. Elsukov wrote: >> What you think about attached patch? >> It can resolve your problem and shouldn't break anything. >> With this patch you can set mode in /boot/device.hints, for >> example: >> hint.ad.0.mode="UDMA33" >> hint.ad.1.mode="UDMA100" >> >> These limits work only on boot stage, after boot completed you can >> change mode via atacontrol. > My issue was that the boot device itself was the flash module from Transcend. Setting the speed via atacontrol after the system booted was not preferred as the root device _was_ the Transcend. Does that make sense? > Also, this is the same patch, but it doesn't allow override maximum > mode in device.hints. I don't know which patch is preferable, I think > second one. > I'll try both and get back to you. -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Cell 503-358-6832 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com From owner-freebsd-drivers@FreeBSD.ORG Sat Jul 26 05:25:10 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AC85B106564A; Sat, 26 Jul 2008 05:25:10 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from webmail3.yandex.ru (webmail3.yandex.ru [213.180.200.60]) by mx1.freebsd.org (Postfix) with ESMTP id 1ED738FC13; Sat, 26 Jul 2008 05:25:10 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from YAMAIL (webmail3) by mail.yandex.ru id S4603952AbYGZFY7 for (+ 1 other); Sat, 26 Jul 2008 09:24:59 +0400 X-Yandex-Spam: 1 Received: from [77.72.136.71] ([77.72.136.71]) by mail.yandex.ru with HTTP; Sat, 26 Jul 2008 09:24:58 +0400 From: "Andrey V. Elsukov" To: sbruno@miralink.com In-Reply-To: <4889E699.3050606@miralink.com> References: <4839F473.6070109@miralink.com> <4889A415.1060309@yandex.ru> <4889A712.7090204@yandex.ru> <4889E699.3050606@miralink.com> MIME-Version: 1.0 Message-Id: <147801217049898@webmail3.yandex.ru> Date: Sat, 26 Jul 2008 09:24:58 +0400 X-Mailer: Yamail [ http://yandex.ru ] 5.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain Cc: freebsd-drivers@freebsd.org, sos@freebsd.org Subject: Re: ATA patch for RELENG_6 ... a patch looking for a good home X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jul 2008 05:25:10 -0000 25.07.08, 18:43, "Sean Bruno" : > >> These limits work only on boot stage, after boot completed you can > >> change mode via atacontrol. > > > My issue was that the boot device itself was the flash module from > Transcend. Setting the speed via atacontrol after the system booted was > not preferred as the root device _was_ the Transcend. Does that make sense? Yes, I remember your problem. You don't need to change mode after boot. I wanted to say that it is possible to change mode and device.hints doesn't limit you to change mode after boot. > > Also, this is the same patch, but it doesn't allow override maximum > > mode in device.hints. I don't know which patch is preferable, I think > > second one. > > > I'll try both and get back to you. I think you may try only the last patch. -- WBR, Andrey V. Elsukov