From owner-freebsd-mobile@FreeBSD.ORG Sun Feb 1 04:10:18 2009 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 063DD1065785 for ; Sun, 1 Feb 2009 04:10:18 +0000 (UTC) (envelope-from henry.hu.sh@gmail.com) Received: from rv-out-0506.google.com (rv-out-0506.google.com [209.85.198.228]) by mx1.freebsd.org (Postfix) with ESMTP id CF2308FC1B for ; Sun, 1 Feb 2009 04:10:17 +0000 (UTC) (envelope-from henry.hu.sh@gmail.com) Received: by rv-out-0506.google.com with SMTP id b25so1076162rvf.43 for ; Sat, 31 Jan 2009 20:10:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:reply-to:date:message-id :subject:from:to:cc:content-type:content-transfer-encoding; bh=196076RuCP60jUFPe00PotANeahcvZnRtG4NtnJhvxc=; b=pn+UNXlzSbaOv8pLiFIJq+edFMyX/43UHbdQ3DmTnGDDrjQtNcetTcO90+Agr0ODE2 45KgmVUo0jqtpOQAE+6bBtbGl8NP3XdfRV6MvpK6y51NLgzbI/8mYPv/blnpO2pIpmSm hnFvp6P8Q2W0VZe4qCNx2XGfLD25Dm1CU/7/c= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:reply-to:date:message-id:subject:from:to:cc :content-type:content-transfer-encoding; b=rAcY+Oa0a3LWS2nqWsl2lFM1YWfZmjqVQoLZVFEx/aC39m0jIjmJA7Q7skIqR9wWqy BGNmaO3VwBT+6CgEkvwUigjUmZ9zm5Q+96hV4o9QRbxwSfE7Y01S1ODd3dtAcv/Y7Z8j JhiSoPKCXrjJfzWvfhyyB+S1Ni2d8toE4LjGk= MIME-Version: 1.0 Received: by 10.142.89.13 with SMTP id m13mr1215213wfb.50.1233460174440; Sat, 31 Jan 2009 19:49:34 -0800 (PST) Date: Sun, 1 Feb 2009 11:49:34 +0800 Message-ID: <53a1e0710901311949x3b853404oe89cf2ae9a0903f7@mail.gmail.com> From: Henry Hu To: freebsd-mobile@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Alexander Motin Subject: Problem about the new sdhci driver X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: hu.henry9@gmail.com List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Feb 2009 04:10:18 -0000 Hi, I'm using FreeBSD 7-STABLE, with sdhci driver sdhci.20081029.tgz mmc.20081029.tgz I've found that if I load sdhci driver with card inserted, everything works fine. But if I load sdhci driver first, and then insert card, the card is not detected.Additionally, there is no interrupt. After I've load sdhci driver without card, the controller seems to be in a problematic state. The register dump outputed when the driver loaded showed that Present is 0x01f20000 which is correct since the card is not inserted then. But cards is not detected. Even if I unload the driver and reload with card inserted, the card still cannot be detected, and there's no interrupt. But the Present register changed to 0x01fa0000 which is strange. So I guess there's something wrong with the driver when the card is not present. sdhci0: mem 0xf0401000-0xf04010ff irq 18 at device 9.1 on pci5 sdhci0-slot0: 33MHz 4bits 3.3V DMA sdhci0-slot0: ============== REGISTER DUMP ============== sdhci0-slot0: Sys addr: 0x00000000 | Version: 0x00000200 sdhci0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 sdhci0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 sdhci0-slot0: Present: 0x01f20000 | Host ctl: 0x00000000 sdhci0-slot0: Power: 0x00000000 | Blk gap: 0x00000000 sdhci0-slot0: Wake-up: 0x00000000 | Clock: 0x00000000 sdhci0-slot0: Timeout: 0x0000000c | Int stat: 0x00000000 sdhci0-slot0: Int enab: 0x01ff00fb | Sig enab: 0x01ff00fb sdhci0-slot0: AC12 err: 0x00000000 | Slot int: 0x00000000 sdhci0-slot0: Caps: 0x01c021a1 | Max curr: 0x00000040 sdhci0-slot0: =========================================== I'm using hw.pci.do_power_nodriver=3 Cheers, Henry From owner-freebsd-mobile@FreeBSD.ORG Sun Feb 1 10:07:59 2009 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 72DC31065673 for ; Sun, 1 Feb 2009 10:07:59 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from cmail.optima.ua (cmail.optima.ua [195.248.191.121]) by mx1.freebsd.org (Postfix) with ESMTP id ED0488FC12 for ; Sun, 1 Feb 2009 10:07:58 +0000 (UTC) (envelope-from mav@FreeBSD.org) X-Spam-Flag: SKIP X-Spam-Yversion: Spamooborona-2.1.0 Received: from [212.86.226.226] (account mav@alkar.net HELO mavbook.mavhome.dp.ua) by cmail.optima.ua (CommuniGate Pro SMTP 5.2.9) with ESMTPSA id 233108855; Sun, 01 Feb 2009 12:07:57 +0200 Message-ID: <49857482.5080508@FreeBSD.org> Date: Sun, 01 Feb 2009 12:08:02 +0200 From: Alexander Motin User-Agent: Thunderbird 2.0.0.19 (X11/20090118) MIME-Version: 1.0 To: hu.henry9@gmail.com References: <53a1e0710901311949x3b853404oe89cf2ae9a0903f7@mail.gmail.com> In-Reply-To: <53a1e0710901311949x3b853404oe89cf2ae9a0903f7@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-mobile@freebsd.org Subject: Re: Problem about the new sdhci driver X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Feb 2009 10:07:59 -0000 Henry Hu wrote: > I'm using FreeBSD 7-STABLE, with sdhci driver > sdhci.20081029.tgz > mmc.20081029.tgz > > I've found that if I load sdhci driver with card inserted, everything > works fine. > But if I load sdhci driver first, and then insert card, the card is > not detected.Additionally, there is no interrupt. > After I've load sdhci driver without card, the controller seems to be > in a problematic state. The register dump outputed when the driver > loaded showed that Present is 0x01f20000 which is correct since the > card is not inserted then. But cards is not detected. > Even if I unload the driver and reload with card inserted, the card > still cannot be detected, and there's no interrupt. But the Present > register changed to 0x01fa0000 which is strange. > > So I guess there's something wrong with the driver when the card is not present. > > sdhci0: mem 0xf0401000-0xf04010ff irq 18 at device 9.1 on pci5 > sdhci0-slot0: 33MHz 4bits 3.3V DMA > sdhci0-slot0: ============== REGISTER DUMP ============== > sdhci0-slot0: Sys addr: 0x00000000 | Version: 0x00000200 > sdhci0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 > sdhci0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 > sdhci0-slot0: Present: 0x01f20000 | Host ctl: 0x00000000 > sdhci0-slot0: Power: 0x00000000 | Blk gap: 0x00000000 > sdhci0-slot0: Wake-up: 0x00000000 | Clock: 0x00000000 > sdhci0-slot0: Timeout: 0x0000000c | Int stat: 0x00000000 > sdhci0-slot0: Int enab: 0x01ff00fb | Sig enab: 0x01ff00fb > sdhci0-slot0: AC12 err: 0x00000000 | Slot int: 0x00000000 > sdhci0-slot0: Caps: 0x01c021a1 | Max curr: 0x00000040 > sdhci0-slot0: =========================================== Try this patch please: --- sdhci.c.prev 2009-01-29 00:53:41.000000000 +0200 +++ sdhci.c 2009-02-01 11:58:42.000000000 +0200 @@ -82,7 +82,8 @@ static const struct sdhci_device { u_int quirks; } sdhci_devices[] = { { 0x08221180, 0xffff, "RICOH R5C822 SD", - SDHCI_QUIRK_FORCE_DMA }, + SDHCI_QUIRK_FORCE_DMA | + SDHCI_QUIRK_NO_CARD_NO_RESET }, { 0x8034104c, 0xffff, "TI XX21/XX11 SD", SDHCI_QUIRK_FORCE_DMA }, { 0x05501524, 0xffff, "ENE CB712 SD", Could everybody having this controller send me pciconf and Version register from their controller and report me is this bug present on their system? I would like to collect some statistics. -- Alexander Motin From owner-freebsd-mobile@FreeBSD.ORG Sun Feb 1 12:32:28 2009 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 240AE1065670; Sun, 1 Feb 2009 12:32:28 +0000 (UTC) (envelope-from henry.hu.sh@gmail.com) Received: from yx-out-2324.google.com (yx-out-2324.google.com [74.125.44.29]) by mx1.freebsd.org (Postfix) with ESMTP id BFE678FC1E; Sun, 1 Feb 2009 12:32:27 +0000 (UTC) (envelope-from henry.hu.sh@gmail.com) Received: by yx-out-2324.google.com with SMTP id 8so439321yxb.13 for ; Sun, 01 Feb 2009 04:32:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:reply-to:in-reply-to :references:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=4mTnP7Cs6mABe0O4j+v/alYG1kBA+AhSHe/CwIRfQog=; b=iuh8u0upcCAWH4gqwMmiSEDKbCACozyEGA2dnuyhZpFdBCEn34A7oWQN0GurmWgjVo IbCNRgqFbfpT7/2FZ98DWl78RGsnRPnT1Z62SY0y0PIxUHLMErbiT9B79W7dhPEl6+2o aVjimglf8iHm/LYPt/VyRNd6Fbj3jJwUILS/Q= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:reply-to:in-reply-to:references:date:message-id :subject:from:to:cc:content-type:content-transfer-encoding; b=NhVyt9By0FxXCOjFcIgkfFafGPd/flG7PcjOWC7LACd2GMnAZzGL1Jo8A7Srp51tWE oowhVxElGGvSN7dhqa8VgVw7i5ir+Ekx9AoFJ+A7n6rUsLcHpwxlSrubu5Loz2NtNVcU 3lzAghmJ6PhsV38BWHlKQfq5Ld0++27Riheos= MIME-Version: 1.0 Received: by 10.100.13.6 with SMTP id 6mr2187815anm.9.1233491546364; Sun, 01 Feb 2009 04:32:26 -0800 (PST) In-Reply-To: <49857482.5080508@FreeBSD.org> References: <53a1e0710901311949x3b853404oe89cf2ae9a0903f7@mail.gmail.com> <49857482.5080508@FreeBSD.org> Date: Sun, 1 Feb 2009 20:32:25 +0800 Message-ID: <53a1e0710902010432j49111ecey8d9a93acfbe3c64d@mail.gmail.com> From: Henry Hu To: Alexander Motin Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-mobile@freebsd.org Subject: Re: Problem about the new sdhci driver X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: hu.henry9@gmail.com List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Feb 2009 12:32:28 -0000 After doing more experiments, I found the cause: hw.pci.do_power_resume=3 If I set it to 0 and load the driver, it works well with and without the card. If I set it to 3 and load the driver, then 1. If the card is present, then it would detect the card and the disk shows up. If I remove the card and insert it again, it cannot detect it again. And if I unload the driver now and reload it with the card, it cannot detect the card and it cannot detect card insertion / removal. 2. If the card is not present, then it cannot detect the card, and if I remove the card and insert it again, nothing happens. The 0x01fa0000 state is normal: I found that the detection of write-protection is independent from card detection. If I pull the card out completely, the present register is 0x01f20000. If I pull the card out half-way, the present register is 0x01fa000, the write-protection bit is 1 and the card-present bit is 0... So the problem is about power states, not the driver, and no patch is needed. Since I rarely use the card reader when the laptop is using battery, I decided to remove it from sysctl .conf .... Thanks for the help. Good driver! Cheers, Henry On Sun, Feb 1, 2009 at 6:08 PM, Alexander Motin wrote: > Henry Hu wrote: >> >> I'm using FreeBSD 7-STABLE, with sdhci driver >> sdhci.20081029.tgz >> mmc.20081029.tgz >> >> I've found that if I load sdhci driver with card inserted, everything >> works fine. >> But if I load sdhci driver first, and then insert card, the card is >> not detected.Additionally, there is no interrupt. >> After I've load sdhci driver without card, the controller seems to be >> in a problematic state. The register dump outputed when the driver >> loaded showed that Present is 0x01f20000 which is correct since the >> card is not inserted then. But cards is not detected. >> Even if I unload the driver and reload with card inserted, the card >> still cannot be detected, and there's no interrupt. But the Present >> register changed to 0x01fa0000 which is strange. >> >> So I guess there's something wrong with the driver when the card is not >> present. >> >> sdhci0: mem 0xf0401000-0xf04010ff irq 18 at device 9.1 >> on pci5 >> sdhci0-slot0: 33MHz 4bits 3.3V DMA >> sdhci0-slot0: ============== REGISTER DUMP ============== >> sdhci0-slot0: Sys addr: 0x00000000 | Version: 0x00000200 >> sdhci0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 >> sdhci0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 >> sdhci0-slot0: Present: 0x01f20000 | Host ctl: 0x00000000 >> sdhci0-slot0: Power: 0x00000000 | Blk gap: 0x00000000 >> sdhci0-slot0: Wake-up: 0x00000000 | Clock: 0x00000000 >> sdhci0-slot0: Timeout: 0x0000000c | Int stat: 0x00000000 >> sdhci0-slot0: Int enab: 0x01ff00fb | Sig enab: 0x01ff00fb >> sdhci0-slot0: AC12 err: 0x00000000 | Slot int: 0x00000000 >> sdhci0-slot0: Caps: 0x01c021a1 | Max curr: 0x00000040 >> sdhci0-slot0: =========================================== > > Try this patch please: > --- sdhci.c.prev 2009-01-29 00:53:41.000000000 +0200 > +++ sdhci.c 2009-02-01 11:58:42.000000000 +0200 > @@ -82,7 +82,8 @@ static const struct sdhci_device { > u_int quirks; > } sdhci_devices[] = { > { 0x08221180, 0xffff, "RICOH R5C822 SD", > - SDHCI_QUIRK_FORCE_DMA }, > + SDHCI_QUIRK_FORCE_DMA | > + SDHCI_QUIRK_NO_CARD_NO_RESET }, > { 0x8034104c, 0xffff, "TI XX21/XX11 SD", > SDHCI_QUIRK_FORCE_DMA }, > { 0x05501524, 0xffff, "ENE CB712 SD", > > > Could everybody having this controller send me pciconf and Version register > from their controller and report me is this bug present on their system? I > would like to collect some statistics. > > -- > Alexander Motin > _______________________________________________ > freebsd-mobile@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-mobile > To unsubscribe, send any mail to "freebsd-mobile-unsubscribe@freebsd.org" > From owner-freebsd-mobile@FreeBSD.ORG Sun Feb 1 18:31:45 2009 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 19ACC106564A for ; Sun, 1 Feb 2009 18:31:45 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from cmail.optima.ua (cmail.optima.ua [195.248.191.121]) by mx1.freebsd.org (Postfix) with ESMTP id 6C2D98FC1B for ; Sun, 1 Feb 2009 18:31:44 +0000 (UTC) (envelope-from mav@FreeBSD.org) X-Spam-Flag: SKIP X-Spam-Yversion: Spamooborona-2.1.0 Received: from [212.86.226.226] (account mav@alkar.net HELO mavbook.mavhome.dp.ua) by cmail.optima.ua (CommuniGate Pro SMTP 5.2.9) with ESMTPSA id 233135558; Sun, 01 Feb 2009 20:31:43 +0200 Message-ID: <4985EA94.1090007@FreeBSD.org> Date: Sun, 01 Feb 2009 20:31:48 +0200 From: Alexander Motin User-Agent: Thunderbird 2.0.0.19 (X11/20090118) MIME-Version: 1.0 To: hu.henry9@gmail.com References: <53a1e0710901311949x3b853404oe89cf2ae9a0903f7@mail.gmail.com> <49857482.5080508@FreeBSD.org> <53a1e0710902010432j49111ecey8d9a93acfbe3c64d@mail.gmail.com> In-Reply-To: <53a1e0710902010432j49111ecey8d9a93acfbe3c64d@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-mobile@freebsd.org Subject: Re: Problem about the new sdhci driver X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Feb 2009 18:31:45 -0000 Henry Hu wrote: > After doing more experiments, I found the cause: > hw.pci.do_power_resume=3 > If I set it to 0 and load the driver, it works well with and without the card. > If I set it to 3 and load the driver, then > 1. If the card is present, then it would detect the card and the disk > shows up. If I remove the card and insert it again, it cannot detect > it again. And if I unload the driver now and reload it with the card, > it cannot detect the card and it cannot detect card insertion / > removal. > 2. If the card is not present, then it cannot detect the card, and if > I remove the card and insert it again, nothing happens. > The 0x01fa0000 state is normal: I found that the detection of > write-protection is independent from card detection. If I pull the > card out completely, the present register is 0x01f20000. If I pull the > card out half-way, the present register is 0x01fa000, the > write-protection bit is 1 and the card-present bit is 0... > > So the problem is about power states, not the driver, and no patch is > needed. Since I rarely use the card reader when the laptop is using > battery, I decided to remove it from sysctl .conf .... > Thanks for the help. Good driver! And still it would be good to try the patch. Some revisions of this controller known behave wrong if being reseted without card inserted. This patch enables special quirk to avoid that situation. I think power management can be not a reason of problem, but just a trigger. > On Sun, Feb 1, 2009 at 6:08 PM, Alexander Motin wrote: >> Henry Hu wrote: >>> I'm using FreeBSD 7-STABLE, with sdhci driver >>> sdhci.20081029.tgz >>> mmc.20081029.tgz >>> >>> I've found that if I load sdhci driver with card inserted, everything >>> works fine. >>> But if I load sdhci driver first, and then insert card, the card is >>> not detected.Additionally, there is no interrupt. >>> After I've load sdhci driver without card, the controller seems to be >>> in a problematic state. The register dump outputed when the driver >>> loaded showed that Present is 0x01f20000 which is correct since the >>> card is not inserted then. But cards is not detected. >>> Even if I unload the driver and reload with card inserted, the card >>> still cannot be detected, and there's no interrupt. But the Present >>> register changed to 0x01fa0000 which is strange. >>> >>> So I guess there's something wrong with the driver when the card is not >>> present. >>> >>> sdhci0: mem 0xf0401000-0xf04010ff irq 18 at device 9.1 >>> on pci5 >>> sdhci0-slot0: 33MHz 4bits 3.3V DMA >>> sdhci0-slot0: ============== REGISTER DUMP ============== >>> sdhci0-slot0: Sys addr: 0x00000000 | Version: 0x00000200 >>> sdhci0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 >>> sdhci0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 >>> sdhci0-slot0: Present: 0x01f20000 | Host ctl: 0x00000000 >>> sdhci0-slot0: Power: 0x00000000 | Blk gap: 0x00000000 >>> sdhci0-slot0: Wake-up: 0x00000000 | Clock: 0x00000000 >>> sdhci0-slot0: Timeout: 0x0000000c | Int stat: 0x00000000 >>> sdhci0-slot0: Int enab: 0x01ff00fb | Sig enab: 0x01ff00fb >>> sdhci0-slot0: AC12 err: 0x00000000 | Slot int: 0x00000000 >>> sdhci0-slot0: Caps: 0x01c021a1 | Max curr: 0x00000040 >>> sdhci0-slot0: =========================================== >> Try this patch please: >> --- sdhci.c.prev 2009-01-29 00:53:41.000000000 +0200 >> +++ sdhci.c 2009-02-01 11:58:42.000000000 +0200 >> @@ -82,7 +82,8 @@ static const struct sdhci_device { >> u_int quirks; >> } sdhci_devices[] = { >> { 0x08221180, 0xffff, "RICOH R5C822 SD", >> - SDHCI_QUIRK_FORCE_DMA }, >> + SDHCI_QUIRK_FORCE_DMA | >> + SDHCI_QUIRK_NO_CARD_NO_RESET }, >> { 0x8034104c, 0xffff, "TI XX21/XX11 SD", >> SDHCI_QUIRK_FORCE_DMA }, >> { 0x05501524, 0xffff, "ENE CB712 SD", >> >> >> Could everybody having this controller send me pciconf and Version register >> from their controller and report me is this bug present on their system? I >> would like to collect some statistics. >> >> -- >> Alexander Motin >> _______________________________________________ >> freebsd-mobile@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-mobile >> To unsubscribe, send any mail to "freebsd-mobile-unsubscribe@freebsd.org" >> -- Alexander Motin From owner-freebsd-mobile@FreeBSD.ORG Tue Feb 3 13:17:18 2009 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1E9EC106564A; Tue, 3 Feb 2009 13:17:18 +0000 (UTC) (envelope-from henry.hu.sh@gmail.com) Received: from rv-out-0506.google.com (rv-out-0506.google.com [209.85.198.233]) by mx1.freebsd.org (Postfix) with ESMTP id DF7BD8FC0C; Tue, 3 Feb 2009 13:17:17 +0000 (UTC) (envelope-from henry.hu.sh@gmail.com) Received: by rv-out-0506.google.com with SMTP id g9so1410800rvb.3 for ; Tue, 03 Feb 2009 05:17:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:reply-to:in-reply-to :references:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=DaUWjzTZslP/h8ql7C+PxX3K+QbAdsZbxL/ZLEYvizE=; b=ef9Rkvk2YC8O99n80qsFVTw6x5KHER18ySP04M2XWfsDOBx8hchve00OL7A+7CdOB8 LjyDA49UYwHeoW0jf0RqaGYABPT8tYpDeRC/bfGEAcJdpjeasn8UKgeUuFftOJvPj1OC WwTjn4H0GtobvYCdVnJZnjHqos4GibyIicx9g= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:reply-to:in-reply-to:references:date:message-id :subject:from:to:cc:content-type:content-transfer-encoding; b=GrLxapb+9QpwWdkvJXJZtmfR9TcKki77F+9cAQrkwk7CgfkFDxwzUbHcaaSp36rd+w idK5iMjV0UXk1Vqc1Ntbjg2Ud7A8V16a0UpWkUR4S8oQfV8RHlpf53YP+vXY9TspGNzS cWmuW4ZYB532IJgD3B1QbHU7g8SNJJ9vs9HI4= MIME-Version: 1.0 Received: by 10.142.136.16 with SMTP id j16mr2105446wfd.27.1233667037345; Tue, 03 Feb 2009 05:17:17 -0800 (PST) In-Reply-To: <4985EA94.1090007@FreeBSD.org> References: <53a1e0710901311949x3b853404oe89cf2ae9a0903f7@mail.gmail.com> <49857482.5080508@FreeBSD.org> <53a1e0710902010432j49111ecey8d9a93acfbe3c64d@mail.gmail.com> <4985EA94.1090007@FreeBSD.org> Date: Tue, 3 Feb 2009 21:17:17 +0800 Message-ID: <53a1e0710902030517y4fb692f2nf038c8f6799d58c7@mail.gmail.com> From: Henry Hu To: Alexander Motin Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-mobile@freebsd.org Subject: Re: Problem about the new sdhci driver X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: hu.henry9@gmail.com List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Feb 2009 13:17:18 -0000 I've tried patch with no good result. Everything works like before. On Mon, Feb 2, 2009 at 2:31 AM, Alexander Motin wrote: > Henry Hu wrote: >> >> After doing more experiments, I found the cause: >> hw.pci.do_power_resume=3 >> If I set it to 0 and load the driver, it works well with and without the >> card. >> If I set it to 3 and load the driver, then >> 1. If the card is present, then it would detect the card and the disk >> shows up. If I remove the card and insert it again, it cannot detect >> it again. And if I unload the driver now and reload it with the card, >> it cannot detect the card and it cannot detect card insertion / >> removal. >> 2. If the card is not present, then it cannot detect the card, and if >> I remove the card and insert it again, nothing happens. >> The 0x01fa0000 state is normal: I found that the detection of >> write-protection is independent from card detection. If I pull the >> card out completely, the present register is 0x01f20000. If I pull the >> card out half-way, the present register is 0x01fa000, the >> write-protection bit is 1 and the card-present bit is 0... >> >> So the problem is about power states, not the driver, and no patch is >> needed. Since I rarely use the card reader when the laptop is using >> battery, I decided to remove it from sysctl .conf .... >> Thanks for the help. Good driver! > > And still it would be good to try the patch. Some revisions of this > controller known behave wrong if being reseted without card inserted. This > patch enables special quirk to avoid that situation. I think power > management can be not a reason of problem, but just a trigger. > >> On Sun, Feb 1, 2009 at 6:08 PM, Alexander Motin wrote: >>> >>> Henry Hu wrote: >>>> >>>> I'm using FreeBSD 7-STABLE, with sdhci driver >>>> sdhci.20081029.tgz >>>> mmc.20081029.tgz >>>> >>>> I've found that if I load sdhci driver with card inserted, everything >>>> works fine. >>>> But if I load sdhci driver first, and then insert card, the card is >>>> not detected.Additionally, there is no interrupt. >>>> After I've load sdhci driver without card, the controller seems to be >>>> in a problematic state. The register dump outputed when the driver >>>> loaded showed that Present is 0x01f20000 which is correct since the >>>> card is not inserted then. But cards is not detected. >>>> Even if I unload the driver and reload with card inserted, the card >>>> still cannot be detected, and there's no interrupt. But the Present >>>> register changed to 0x01fa0000 which is strange. >>>> >>>> So I guess there's something wrong with the driver when the card is not >>>> present. >>>> >>>> sdhci0: mem 0xf0401000-0xf04010ff irq 18 at device 9.1 >>>> on pci5 >>>> sdhci0-slot0: 33MHz 4bits 3.3V DMA >>>> sdhci0-slot0: ============== REGISTER DUMP ============== >>>> sdhci0-slot0: Sys addr: 0x00000000 | Version: 0x00000200 >>>> sdhci0-slot0: Blk size: 0x00000000 | Blk cnt: 0x00000000 >>>> sdhci0-slot0: Argument: 0x00000000 | Trn mode: 0x00000000 >>>> sdhci0-slot0: Present: 0x01f20000 | Host ctl: 0x00000000 >>>> sdhci0-slot0: Power: 0x00000000 | Blk gap: 0x00000000 >>>> sdhci0-slot0: Wake-up: 0x00000000 | Clock: 0x00000000 >>>> sdhci0-slot0: Timeout: 0x0000000c | Int stat: 0x00000000 >>>> sdhci0-slot0: Int enab: 0x01ff00fb | Sig enab: 0x01ff00fb >>>> sdhci0-slot0: AC12 err: 0x00000000 | Slot int: 0x00000000 >>>> sdhci0-slot0: Caps: 0x01c021a1 | Max curr: 0x00000040 >>>> sdhci0-slot0: =========================================== >>> >>> Try this patch please: >>> --- sdhci.c.prev 2009-01-29 00:53:41.000000000 +0200 >>> +++ sdhci.c 2009-02-01 11:58:42.000000000 +0200 >>> @@ -82,7 +82,8 @@ static const struct sdhci_device { >>> u_int quirks; >>> } sdhci_devices[] = { >>> { 0x08221180, 0xffff, "RICOH R5C822 SD", >>> - SDHCI_QUIRK_FORCE_DMA }, >>> + SDHCI_QUIRK_FORCE_DMA | >>> + SDHCI_QUIRK_NO_CARD_NO_RESET }, >>> { 0x8034104c, 0xffff, "TI XX21/XX11 SD", >>> SDHCI_QUIRK_FORCE_DMA }, >>> { 0x05501524, 0xffff, "ENE CB712 SD", >>> >>> >>> Could everybody having this controller send me pciconf and Version >>> register >>> from their controller and report me is this bug present on their system? >>> I >>> would like to collect some statistics. >>> >>> -- >>> Alexander Motin >>> _______________________________________________ >>> freebsd-mobile@freebsd.org mailing list >>> http://lists.freebsd.org/mailman/listinfo/freebsd-mobile >>> To unsubscribe, send any mail to "freebsd-mobile-unsubscribe@freebsd.org" >>> > > > -- > Alexander Motin > _______________________________________________ > freebsd-mobile@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-mobile > To unsubscribe, send any mail to "freebsd-mobile-unsubscribe@freebsd.org" > From owner-freebsd-mobile@FreeBSD.ORG Wed Feb 4 10:21:12 2009 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EDC221065673 for ; Wed, 4 Feb 2009 10:21:12 +0000 (UTC) (envelope-from Matthias.Apitz@oclc.org) Received: from mail.pica.nl (mail.pica.nl [192.87.44.30]) by mx1.freebsd.org (Postfix) with ESMTP id 8B5258FC17 for ; Wed, 4 Feb 2009 10:21:12 +0000 (UTC) (envelope-from Matthias.Apitz@oclc.org) Received: from rebelion.Sisis.de ([10.0.1.29]) by mail.pica.nl with Microsoft SMTPSVC(6.0.3790.3959); Wed, 4 Feb 2009 11:21:09 +0100 Received: (from guru@localhost) by rebelion.Sisis.de (8.14.2/8.13.8/Submit) id n14AL8sb006212 for freebsd-mobile@freebsd.org; Wed, 4 Feb 2009 11:21:08 +0100 (CET) (envelope-from matthias.apitz@oclc.org) X-Authentication-Warning: rebelion.Sisis.de: guru set sender to matthias.apitz@oclc.org using -f Date: Wed, 4 Feb 2009 11:21:08 +0100 From: Matthias Apitz To: freebsd-mobile@freebsd.org Message-ID: <20090204102108.GA6027@rebelion.Sisis.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i X-Operating-System: FreeBSD 7.0-STABLE (i386) X-OriginalArrivalTime: 04 Feb 2009 10:21:09.0955 (UTC) FILETIME=[4C529130:01C986B2] Subject: EeePC 900 && UMTS X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Matthias Apitz List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Feb 2009 10:21:13 -0000 Hello, I'm thinking in buying a USB based UMTS modem to be online with my EeePC 900 while travelling around; in the past I've done tests with the Huawei E220 G3 Modem and it worked with my normal 7.0-STABLE based laptop. This is already a year ago, I think -- are there any other options nowadays? Thx matthias -- Matthias Apitz Manager Technical Support - OCLC GmbH Gruenwalder Weg 28g - 82041 Oberhaching - Germany t +49-89-61308 351 - f +49-89-61308 399 - m +49-170-4527211 e - w http://www.oclc.org/ http://www.UnixArea.de/ b http://gurucubano.blogspot.com/ From owner-freebsd-mobile@FreeBSD.ORG Wed Feb 4 12:16:30 2009 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D5914106564A for ; Wed, 4 Feb 2009 12:16:30 +0000 (UTC) (envelope-from vince@unsane.co.uk) Received: from unsane.co.uk (unsane-pt.tunnel.tserv5.lon1.ipv6.he.net [IPv6:2001:470:1f08:110::2]) by mx1.freebsd.org (Postfix) with ESMTP id 566758FC1F for ; Wed, 4 Feb 2009 12:16:30 +0000 (UTC) (envelope-from vince@unsane.co.uk) Received: from vhoffman.lon.namesco.net (126.117-84-212.staticip.namesco.net [212.84.117.126]) (authenticated bits=0) by unsane.co.uk (8.14.3/8.14.0) with ESMTP id n14CHiEP033268 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Wed, 4 Feb 2009 12:17:50 GMT (envelope-from vince@unsane.co.uk) Message-ID: <49898716.701@unsane.co.uk> Date: Wed, 04 Feb 2009 12:16:22 +0000 From: Vincent Hoffman User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-GB; rv:1.9.1b3pre) Gecko/20081204 Thunderbird/3.0b1 MIME-Version: 1.0 To: Alexander Motin References: <1233145383.00067348.1233133205@10.7.7.3> <49817333.8070708@mavhome.dp.ua> In-Reply-To: <49817333.8070708@mavhome.dp.ua> X-Enigmail-Version: 0.96a Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Jack Twilley , freebsd-mobile@freebsd.org Subject: Re: Tethering with HTC Touch Pro -- how? X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Feb 2009 12:16:31 -0000 On 29/1/09 09:13, Alexander Motin wrote: > Jack Twilley wrote: > >> I have enabled internet connection sharing on my HTC Touch Pro by >> modifying the registry. The phone works for tethering on my Vista box >> as expected. How do I make it work on FreeBSD? >> > > I am successfully using my Qtek S200 with WM6.1 as plain Bluetooth > GPRS/EDGE modem. BT PAN profile could be better for internet sharing; I > haven't seen it implemented, but there were some activity. Sharing via > USB cable requires RNDIS support, which is also not implemented, AFAIK > due to buggy and undocumented protocol. > > Just as a quick appendium, bluetooth PAN support got added to -CURRENT a couple of days ago. I'll try and dig out my old HTC Hermes and test it, will report back if I do. From owner-freebsd-mobile@FreeBSD.ORG Wed Feb 4 12:24:27 2009 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 68E7F106566B for ; Wed, 4 Feb 2009 12:24:27 +0000 (UTC) (envelope-from mav@mavhome.dp.ua) Received: from cmail.optima.ua (cmail.optima.ua [195.248.191.121]) by mx1.freebsd.org (Postfix) with ESMTP id DB9828FC12 for ; Wed, 4 Feb 2009 12:24:26 +0000 (UTC) (envelope-from mav@mavhome.dp.ua) X-Spam-Flag: SKIP X-Spam-Yversion: Spamooborona-2.1.0 Received: from orphanage.alkar.net (account mav@alkar.net [212.86.226.11] verified) by cmail.optima.ua (CommuniGate Pro SMTP 5.2.9) with ESMTPA id 233504497; Wed, 04 Feb 2009 14:24:25 +0200 Message-ID: <498988F9.40106@mavhome.dp.ua> Date: Wed, 04 Feb 2009 14:24:25 +0200 From: Alexander Motin User-Agent: Thunderbird 2.0.0.14 (X11/20080612) MIME-Version: 1.0 To: Vincent Hoffman References: <1233145383.00067348.1233133205@10.7.7.3> <49817333.8070708@mavhome.dp.ua> <49898716.701@unsane.co.uk> In-Reply-To: <49898716.701@unsane.co.uk> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Jack Twilley , freebsd-mobile@freebsd.org Subject: Re: Tethering with HTC Touch Pro -- how? X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Feb 2009 12:24:27 -0000 Vincent Hoffman wrote: > On 29/1/09 09:13, Alexander Motin wrote: >> Jack Twilley wrote: >> >>> I have enabled internet connection sharing on my HTC Touch Pro by >>> modifying the registry. The phone works for tethering on my Vista box >>> as expected. How do I make it work on FreeBSD? >>> >> I am successfully using my Qtek S200 with WM6.1 as plain Bluetooth >> GPRS/EDGE modem. BT PAN profile could be better for internet sharing; I >> haven't seen it implemented, but there were some activity. Sharing via >> USB cable requires RNDIS support, which is also not implemented, AFAIK >> due to buggy and undocumented protocol. >> > Just as a quick appendium, bluetooth PAN support got added to -CURRENT a > couple of days ago. > I'll try and dig out my old HTC Hermes and test it, will report back if > I do. I have even tested it already and replied on freebsd-bluetooth@. It works fine with my Qtek S200 with WM6.1. -- Alexander Motin