NetBSD Problem Report #34452

From www@NetBSD.org  Sat Sep  2 12:43:43 2006
Return-Path: <www@NetBSD.org>
Received: by narn.NetBSD.org (Postfix, from userid 31301)
	id CF2FA63BA0A; Sat,  2 Sep 2006 12:43:43 +0000 (UTC)
Message-Id: <20060902124343.CF2FA63BA0A@narn.NetBSD.org>
Date: Sat,  2 Sep 2006 12:43:43 +0000 (UTC)
From: netbsd@precedence.co.uk
Reply-To: netbsd@precedence.co.uk
To: gnats-bugs@NetBSD.org
Subject: Freecom USB HDD which worked with 2.x doesn't work with 3.1_RC1, 4.0_BETA or 4.99.1
X-Send-Pr-Version: www-1.0

>Number:         34452
>Category:       kern
>Synopsis:       Freecom USB HDD which worked with 2.x doesn't work with 3.1_RC1, 4.0_BETA or 4.99.1
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Sep 02 12:45:01 +0000 2006
>Last-Modified:  Wed Oct 04 17:05:01 +0000 2006
>Originator:     Stephen Borrill
>Release:        3.0_STABLE, 3.1_RC1, 4.0_BETA, 4.99.1
>Organization:
Precedence Technologies Ltd
>Environment:
NetBSD netmanager 3.0_STABLE NetBSD 3.0_STABLE (NETMANRAID) #19: Mon Aug 21 16:17:42 BST 2006 root@devel:/root/netmanager3/work/obj/sys/arch/i386/compile/NETMANRAID i386
>Description:
Got a Freecom Classic 250GB USB drive which works fine on NetBSD 2.0_STABLE (and earlier):

ehci0 at pci0 dev 29 function 7: Intel 82801EB/ER USB EHCI Controller (rev. 0x0)
ehci0: interrupting at irq 11
ehci0: EHCI version 1.0
ehci0: companion controllers, 2 ports each: uhci0 uhci1 uhci2 uhci3
usb4 at ehci0: USB revision 2.0
uhub4 at usb4
[snip]
umass0 at uhub4 port 5 configuration 1 
interface 0
umass0: Freecom product 0xfccd, rev 2.00/4.06, addr 2
umass0: using SCSI over Bulk-Only
scsibus1 at umass0: 2 targets, 1 lun per target
sd0 at scsibus1 target 0 lun 0: <HDS72252, 5VLAT80, V36O> disk fixed
sd0: fabricating a geometry
sd0: 232 GB, 238475 cyl, 64 head, 32 sec, 512 bytes/sect x 488397169 sectors

However on NetBSD 3.0 and later (inc. 3.1_RC1 and 4.99.1) I get the 
following:
ehci0 at pci0 dev 29 function 7: Intel 82801GB/GR USB EHCI Controller (rev. 0x01)
ehci0: interrupting at irq 5
ehci0: BIOS has given up ownership
ehci0: EHCI version 1.0
ehci0: companion controllers, 2 ports each: uhci0 uhci1 uhci2
usb3 at ehci0: USB revision 2.0
uhub3 at usb3
uhub3: Intel EHCI root hub, class 9/0, rev 2.00/1.00, addr 1
uhub3: 6 ports with 6 removable, self powered
[snip]
umass0 at uhub3 port 2 configuration 1 interface 0
umass0: Freecom product 0xfccd, rev 2.00/4.06, addr 2
umass0: using SCSI over Bulk-Only
umass0: Get Max Lun failed: IOERROR
umass0: unable to get Max Lun: IOERROR

(Yes, these are different machines because of available hardware round the 
office, but it's reproducible even on the same hardware - it was first 
noticed during a 2.0 to 3.0 upgrade).

It would be good to solve this for 3.1 and 4.0 before they get released...
>How-To-Repeat:
Get a Freecom Classic 250GB USB2 HDD and connect to a machine running NetBSD 3.0 or later
>Fix:
Unknown. A cursory glance through umass.c suggests it hasn't altered in any pertinent way since 2.0, so I guess the problem lies elsewhere.

>Audit-Trail:
From: Stephen Borrill <netbsd@precedence.co.uk>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/34452: Freecom USB HDD which worked with 2.x doesn't work
 with 3.1_RC1, 4.0_BETA or 4.99.1
Date: Thu, 21 Sep 2006 18:22:18 +0100 (BST)

 Further info:

 On VIA chipsets (uhci), both 2.0.2 and 3.0_STABLE give BBB stalled, the 
 drive attaches, but is unusable.

 On SIS chipsets (ehci), 2.0 and 3.1_RC3 give Get Max Lun failed: TIMEOUT

 On Intel chipsets (the original being tested) (uhci), 2.0_STABLE and 3.0
 work, but 3.1_RC3 (and 3.0_STABLE) give Get Max Lun failed: TIMEOUT

 i.e. this drive does not work on VIA or SIS chipsets, but works fine on 
 3.0 and earlier on Intel chipsets.

 This narrows down the search, something along the path to 3.1 breaks it on
 Intel chipsets (having it working on VIA and SIS would be nice though :-) )

From: Stephen Borrill <netbsd@precedence.co.uk>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/34452: Freecom USB HDD which worked with 2.x doesn't work
 with 3.1_RC1, 4.0_BETA or 4.99.1
Date: Wed, 4 Oct 2006 18:00:02 +0100 (BST)

 More info:

 Revision 1.85 of dev/usb/ehci.c is the culprit. More specifically, it's 
 the top and bottom lines that alter sqh->qh.qh_qtd.qtd_status. Even with 
 the changes in 1.87 to preserve a few flags, it looks like perhaps some 
 other flags are being lost when qtd_status is restored at the end.

 The problem exhibits itself in very odd ways; the drive wll work in port 5 
 of uhub3, but not port 1 of the same uhub.

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.