From owner-freebsd-usb@FreeBSD.ORG Sun Jul 5 10:36:48 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 41E9A1065673; Sun, 5 Jul 2009 10:36:48 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe07.swip.net [212.247.154.193]) by mx1.freebsd.org (Postfix) with ESMTP id 44CE48FC12; Sun, 5 Jul 2009 10:36:46 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=Hrwt8fWgTlIA:10 a=MXw7gxVQKqGXY79tIT8aFQ==:17 a=dT19lrtdAAAA:8 a=MinmzMF1LL3qrF-msNAA:9 a=D_bpiQ21t--K_77gx9EA:7 a=h5JnGOmdAB9tnkmLPbytnJLNn9kA:4 Received: from [62.113.132.61] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe07.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 1269025837; Sun, 05 Jul 2009 12:36:45 +0200 From: Hans Petter Selasky To: Piotr =?iso-8859-2?q?Zi=EAcik?= Date: Sun, 5 Jul 2009 12:36:21 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-CURRENT; KDE/4.2.4; i386; ; ) References: <200906231035.43096.kosmo@semihalf.com> <200906301037.49367.kosmo@semihalf.com> <200906301128.26046.hselasky@c2i.net> In-Reply-To: <200906301128.26046.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200907051236.22783.hselasky@c2i.net> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, thompsa@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 05 Jul 2009 10:36:48 -0000 On Tuesday 30 June 2009 11:28:23 Hans Petter Selasky wrote: > On Tuesday 30 June 2009 10:37:48 Piotr Zi=EAcik wrote: > > Monday 29 June 2009 15:16:56 Hans Petter Selasky napisa=B3(a): > > > You want to change the flags passed to bus_dmamap_sync() so that the > > > flush/invalidate mapping gets right. I understand why your patch makes > > > it work. That's not the problem. > > > > > > In "src/sys/arm/arm/busdma_machdep.c" there is a function called > > > "_bus_dmamap_sync_bp()". If you look at that function you see that it > > > only triggers on the "BUS_DMASYNC_PREWRITE" and "BUS_DMASYNC_POSTREAD" > > > flags. After your patching only the PREXXXX flags are used, so if bou= ce > > > pages are used on ARM and x86 and amd64 +++, then only > > > BUS_DMASYNC_PREWRITE will do anything. This indicates that your patch > > > is not fully correct. > > Hi, > > > That is true. I have missed "bounce page" case. I can change flags pass= ed > > to bus_dmamap_sync() to fix this on ARM, but this will break MIPS. > > Right, so there is inconsistency among the platforms in how the BUSDMA is > implemented, which should be fixed. > > > This clearly shows the problem - using side effect of busdma to manage > > CPU cache. Current USB implementation relies of this side effect assumi= ng > > that bus_dmamap_sync() with given flags will do cpu cache > > flush/invalidation. This is not true even on i386 ! > > i386 handles this differently. > > > This thread is not about my patch. It is only a fast and dirty hack > > making USB working on platforms without hardware cache coherency > > and showing the problem. I see two proper solutions: > > Ok. > > > 1. Implement usb_pc_cpu_invalidate() / usb_pc_cpu_flush() with > > cpu_*() functions realizing requested operation. > > > > 2. Using busdma in proper way: > > [... prepare data to transfer ...] > > bus_dmamap_sync(..., PREREAD | PREWRITE); > > [... do transfer ...] > > bus_dmamap_sync(..., POSTREAD | POSTWRITE); > > [... check results ...] > > as manpage says: > > > > If read and write operations are not preceded and followed by the > > appropriate synchronization operations, behavior is undefined. > > > > Requirement cited above is currently not met in USB stack. Funtion > > shown in http://fxr.watson.org/fxr/source/dev/usb/controller/ehci.c#L12= 94 > > is just an example of improper usage of bus_dmamap_sync(), which is > > hidden under usb_pc_cpu_invalidate(). > > I'm not violating any rules in busdma. The busdma manual is silent about > doing multiple sync operations of the same kind in a row. If the sheeva > hardware you are using works differently, you have to fix it. > > > This thread started from my question about general usage of > > usb_pc_cpu_*() functions. So I am asking once again - why these functio= ns > > relies on side effect of busdma instead of simply doing cache > > flush/invalidation through cpu_*() functions ? > > Because busdma is the interface for doing these kinds of operations and n= ot > cpu_xxx(). The DMA memory is allocated using busdma and loaded using > busdma, and cpu_xxx() is not a part of the busdma interface. > > > > Grepping through the source code for ARM, I found a line like this: > > > (...) > > > You see that it only performs purge and no prior flush. This is what > > > needs fixing! If semihalf could go through the "arm/arm/cpufunc.c" fi= le > > > and fix those flush and invalidate functions then many people would > > > become happy! > > > > My developement platform is sheeva. CPU functions for this platform are > > implemented correctly. > > > > > Again, it is not a problem in USB firstly, it is a problem in > > > "arm/xxx". > > > > You are suggesting that the problem is in ARM busdma (and in MIPS busdm= a, > > as on this platform USB also does not work). Could you give me example = of > > platform _without_ hardware coherency where new USB stack simply works ? > > If I find time later today I will fix the cache sync operations for > AT91RM9200 which has a built in OHCI, which has been working fine with my > new USB stack. > > Can you please add some prints to the "bus_dmamap_sync_buf()" code on ARM, > and verify which cases the CPU is entering, without your patch and with > your patch. From my analysis your patch will just change the execution > path: > > With your patch it calls: > > cpu_dcache_wb_range((vm_offset_t)buf, len); > cpu_l2cache_wb_range((vm_offset_t)buf, len); > > Without your patch it calls: > > cpu_dcache_wbinv_range((vm_offset_t)buf, len); > cpu_l2cache_wbinv_range((vm_offset_t)buf, len); > > In my view these execution paths are equivalent with regard to clean or > cache flush. They should both perform a cache flush, which is what the USB > code wants to do, but obviously the latter case is not implemented > correctly, most likely because it doesn't flush the buffer like expected! > > Try adding: > > cpu_dcache_wb_range((vm_offset_t)buf, len); > cpu_l2cache_wb_range((vm_offset_t)buf, len); > > Before: > > cpu_dcache_wbinv_range((vm_offset_t)buf, len); > cpu_l2cache_wbinv_range((vm_offset_t)buf, len); > > In: sys/arm/arm/busdma_machdep.c > Hi, I did not find time yet to test on my AT91RM9200 board. I hope to do a test= =20 this week. Did you at semihalf find anything? =2D-HPS From owner-freebsd-usb@FreeBSD.ORG Sun Jul 5 18:50:28 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 88FAA106566C for ; Sun, 5 Jul 2009 18:50:28 +0000 (UTC) (envelope-from rj@shadowbots.com) Received: from mail-ew0-f213.google.com (mail-ew0-f213.google.com [209.85.219.213]) by mx1.freebsd.org (Postfix) with ESMTP id EDCEE8FC23 for ; Sun, 5 Jul 2009 18:50:27 +0000 (UTC) (envelope-from rj@shadowbots.com) Received: by ewy9 with SMTP id 9so3602123ewy.43 for ; Sun, 05 Jul 2009 11:50:26 -0700 (PDT) MIME-Version: 1.0 Received: by 10.210.81.9 with SMTP id e9mr3782128ebb.68.1246817924118; Sun, 05 Jul 2009 11:18:44 -0700 (PDT) From: Robert Jameson Date: Sun, 5 Jul 2009 14:18:24 -0400 Message-ID: <9072a4470907051118o6c14e19cs670981a500fc6375@mail.gmail.com> To: freebsd-usb@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: FreeBSD Kernel Panic during backup to USB external drive. X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 05 Jul 2009 18:50:29 -0000 Hello everyone, recently i've been experience kernel panics whenever attempting to run my backup to my usb external drive. Here is the information i have, whatever else is needed please reply, thank you. (02:11 PM):(root@cube)/var/crash$ kgdb /boot/kernel/kernel /var/crash/vmcore.1 GNU gdb 6.1.1 [FreeBSD] Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i386-marcel-freebsd"... Unread portion of the kernel message buffer: panic: ffs_clusteralloc: map mismatch cpuid = 1 Uptime: 4d10h42m10s Physical memory: 2546 MB Dumping 249 MB: 234 218 202 186 170 154 138 122 106 90 74 58 42 26 10 Reading symbols from /boot/kernel/acpi.ko...Reading symbols from /boot/kernel/acpi.ko.symbols...done. done. Loaded symbols for /boot/kernel/acpi.ko Reading symbols from /boot/kernel/pflog.ko...Reading symbols from /boot/kernel/pflog.ko.symbols...done. done. Loaded symbols for /boot/kernel/pflog.ko Reading symbols from /boot/kernel/pf.ko...Reading symbols from /boot/kernel/pf.ko.symbols...done. done. Loaded symbols for /boot/kernel/pf.ko Reading symbols from /boot/kernel/linux.ko...Reading symbols from /boot/kernel/linux.ko.symbols...done. done. Loaded symbols for /boot/kernel/linux.ko #0 doadump () at pcpu.h:196 196 pcpu.h: No such file or directory. in pcpu.h (kgdb) quit my backup script: #!/usr/local/bin/bash -x # # creates backups of essential files # DATA="/usr/home /root" CONFIG="/etc /usr/local/etc /var/lib /etc/namedb" LIST="/tmp/backlist_$$.txt" # mount /backup set $(date) # if test "$1" = "Sun" ; then # weekly a full backup of all data and config. settings: # tar cfz "/backup/data/data_full_$6-$2-$3.tgz" $DATA rm -f /backup/data/data_diff* # tar cfz "/backup/config/config_full_$6-$2-$3.tgz" $CONFIG rm -f /backup/config/config_diff* else # incremental backup: # find $DATA -depth -type f \( -ctime -1 -o -mtime -1 \) -print > $LIST tar cfzT "/backup/data/data_diff_$6-$2-$3.tgz" "$LIST" rm -f "$LIST" # find $CONFIG -depth -type f \( -ctime -1 -o -mtime -1 \) -print > $LIST tar cfzT "/backup/config/config_diff_$6-$2-$3.tgz" "$LIST" rm -f "$LIST" fi # # create sql dump of databases: mysqldump -u root --password=XXXXXXXXX --opt information_schema > "/backup/database/information_schema_$6-$2-$3.sql" gzip "/backup/database/information_schema_$6-$2-$3.sql" mysqldump -u root --password=XXXXXXXXX --opt denora > "/backup/database/denora_$6-$2-$3.sql" gzip "/backup/database/denora_$6-$2-$3.sql" mysqldump -u root --password=XXXXXXXXX --opt evilnet > "/backup/database/evilnet_$6-$2-$3.sql" gzip "/backup/database/evilnet_$6-$2-$3.sql" mysqldump -u root --password=XXXXXXXXX --opt mysql > "/backup/database/mysql_$6-$2-$3.sql" gzip "/backup/database/mysql_$6-$2-$3.sql" mysqldump -u root --password=XXXXXXXXX --opt quotes_db > "/backup/database/quotes_db_$6-$2-$3.sql" gzip "/backup/database/quotes_db_$6-$2-$3.sql" # umount /backup fstab: # Device Mountpoint FStype Options Dump Pass# /dev/ad0s1b none swap sw 0 0 /dev/ad0s1a / ufs rw 1 1 /dev/ad1s1d /usr/home ufs rw 1 1 /dev/acd0 /cdrom cd9660 ro,noauto 0 0 /dev/da0s1d /backup ufs rw,noauto 1 1 -- ---------------- Island Information Services Robert Jameson Cell: (843) 298-6648 E-Mail: rj@dawnshosting.com From owner-freebsd-usb@FreeBSD.ORG Sun Jul 5 21:30:36 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 77B8C1065670; Sun, 5 Jul 2009 21:30:36 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe15.tele2.se [212.247.155.193]) by mx1.freebsd.org (Postfix) with ESMTP id ACD7D8FC1A; Sun, 5 Jul 2009 21:30:35 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=eJ57vKNmtyAA:10 a=MXw7gxVQKqGXY79tIT8aFQ==:17 a=kctU5lBUWTds1dXsgIkA:9 a=IDspSqL6dOovD2ZrJlIA:7 a=zm9i5RoucayZCjo48cATZLmc46QA:4 Received: from [62.113.132.61] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe15.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 527435834; Sun, 05 Jul 2009 23:30:30 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org, freebsd-current@freebsd.org Date: Sun, 5 Jul 2009 23:30:06 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-CURRENT; KDE/4.2.4; i386; ; ) References: <9072a4470907051118o6c14e19cs670981a500fc6375@mail.gmail.com> In-Reply-To: <9072a4470907051118o6c14e19cs670981a500fc6375@mail.gmail.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907052330.07792.hselasky@c2i.net> Cc: Subject: Re: FreeBSD Kernel Panic during backup to USB external drive. X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 05 Jul 2009 21:30:36 -0000 On Sunday 05 July 2009 20:18:24 Robert Jameson wrote: > Hello everyone, recently i've been experience kernel panics whenever > attempting to run my backup to my usb external drive. > Here is the information i have, whatever else is needed please reply, thank > you. Hi, This issue doesn't look directly related to USB. I'm forwarding it to the freebsd-current e-mail list! Thanks for testing FreeBSD 8-current. --HPS > > > (02:11 PM):(root@cube)/var/crash$ kgdb /boot/kernel/kernel > /var/crash/vmcore.1 > GNU gdb 6.1.1 [FreeBSD] > Copyright 2004 Free Software Foundation, Inc. > GDB is free software, covered by the GNU General Public License, and you > are welcome to change it and/or distribute copies of it under certain > conditions. > Type "show copying" to see the conditions. > There is absolutely no warranty for GDB. Type "show warranty" for details. > This GDB was configured as "i386-marcel-freebsd"... > > Unread portion of the kernel message buffer: > panic: ffs_clusteralloc: map mismatch > cpuid = 1 > Uptime: 4d10h42m10s > Physical memory: 2546 MB > Dumping 249 MB: 234 218 202 186 170 154 138 122 106 90 74 58 42 26 10 > > Reading symbols from /boot/kernel/acpi.ko...Reading symbols from > /boot/kernel/acpi.ko.symbols...done. > done. > Loaded symbols for /boot/kernel/acpi.ko > Reading symbols from /boot/kernel/pflog.ko...Reading symbols from > /boot/kernel/pflog.ko.symbols...done. > done. > Loaded symbols for /boot/kernel/pflog.ko > Reading symbols from /boot/kernel/pf.ko...Reading symbols from > /boot/kernel/pf.ko.symbols...done. > done. > Loaded symbols for /boot/kernel/pf.ko > Reading symbols from /boot/kernel/linux.ko...Reading symbols from > /boot/kernel/linux.ko.symbols...done. > done. > Loaded symbols for /boot/kernel/linux.ko > #0 doadump () at pcpu.h:196 > 196 pcpu.h: No such file or directory. > in pcpu.h > (kgdb) quit > > > my backup script: > > #!/usr/local/bin/bash -x > # > # creates backups of essential files > # > DATA="/usr/home /root" > CONFIG="/etc /usr/local/etc /var/lib /etc/namedb" > LIST="/tmp/backlist_$$.txt" > # > mount /backup > set $(date) > # > if test "$1" = "Sun" ; then > # weekly a full backup of all data and config. settings: > # > tar cfz "/backup/data/data_full_$6-$2-$3.tgz" $DATA > rm -f /backup/data/data_diff* > # > tar cfz "/backup/config/config_full_$6-$2-$3.tgz" $CONFIG > rm -f /backup/config/config_diff* > else > # incremental backup: > # > find $DATA -depth -type f \( -ctime -1 -o -mtime -1 \) -print > > $LIST > tar cfzT "/backup/data/data_diff_$6-$2-$3.tgz" "$LIST" > rm -f "$LIST" > # > find $CONFIG -depth -type f \( -ctime -1 -o -mtime -1 \) -print > > $LIST > tar cfzT "/backup/config/config_diff_$6-$2-$3.tgz" "$LIST" > rm -f "$LIST" > fi > # > # create sql dump of databases: > mysqldump -u root --password=XXXXXXXXX --opt information_schema > > "/backup/database/information_schema_$6-$2-$3.sql" > gzip "/backup/database/information_schema_$6-$2-$3.sql" > mysqldump -u root --password=XXXXXXXXX --opt denora > > "/backup/database/denora_$6-$2-$3.sql" > gzip "/backup/database/denora_$6-$2-$3.sql" > mysqldump -u root --password=XXXXXXXXX --opt evilnet > > "/backup/database/evilnet_$6-$2-$3.sql" > gzip "/backup/database/evilnet_$6-$2-$3.sql" > mysqldump -u root --password=XXXXXXXXX --opt mysql > > "/backup/database/mysql_$6-$2-$3.sql" > gzip "/backup/database/mysql_$6-$2-$3.sql" > mysqldump -u root --password=XXXXXXXXX --opt quotes_db > > "/backup/database/quotes_db_$6-$2-$3.sql" > gzip "/backup/database/quotes_db_$6-$2-$3.sql" > > # > umount /backup > > > fstab: > > # Device Mountpoint FStype Options Dump > Pass# > /dev/ad0s1b none swap sw 0 0 > /dev/ad0s1a / ufs rw 1 1 > /dev/ad1s1d /usr/home ufs rw 1 1 > /dev/acd0 /cdrom cd9660 ro,noauto 0 0 > /dev/da0s1d /backup ufs rw,noauto 1 1 From owner-freebsd-usb@FreeBSD.ORG Mon Jul 6 11:07:09 2009 Return-Path: Delivered-To: freebsd-usb@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 290BB106566C for ; Mon, 6 Jul 2009 11:07:09 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 146958FC13 for ; Mon, 6 Jul 2009 11:07:09 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n66B79S1010970 for ; Mon, 6 Jul 2009 11:07:09 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n66B78it010966 for freebsd-usb@FreeBSD.org; Mon, 6 Jul 2009 11:07:08 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 6 Jul 2009 11:07:08 GMT Message-Id: <200907061107.n66B78it010966@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-usb@FreeBSD.org Cc: Subject: Current problem reports assigned to freebsd-usb@FreeBSD.org X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Jul 2009 11:07:09 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- o usb/135938 usb [aue] aue driver only passes traffic in promisc mode o usb/135857 usb RTL8187 Wireless Adapter o usb/135575 usb [usbdevs] [patch] Add HTC Wizard phone vid/pid informa o usb/135542 usb [keyboard] boot loader does not work with a usb keyboa o usb/135372 usb Quirk report for Teclast TL-C300 usb media player o usb/135348 usb [umass] USB Drive Hangs with ZFS (JMicron USB2/eSata) o usb/135206 usb machine reboots when inserted USB device o usb/135200 usb SAMSUNG i740 usb mass: Synchronize cache failed, statu o usb/135182 usb UMASS quirk - Olympus FE20 camera o usb/134950 usb Lowering DTR for USB-modem via ubsa is not possible o usb/134633 usb Add support for WILLCOM03(SHARP smart phone) o usb/134631 usb [usbdevs] [patch] WiSPY DBx support requires usb tweak o usb/134476 usb [usb2] [umass] [quirk] Add quirk for Cypress xx6830xx o usb/134299 usb Kernel Panic plugging in MF626 USB UMTS Stick u3g o usb/134193 usb System freeze on usb MP3 player insertion o usb/134117 usb [Patch] Add support for 'Option GlobeTrotter HSDPA Mod o usb/134085 usb [umass] Adding usb quirk for Sony USB flash drive o usb/133989 usb [newusb] [ukbd] USB keyboard dead at mountroot> prompt f usb/133545 usb [usb] [panic] Kernel crash in usb2_intr_schedule_adjus o usb/133390 usb umass crashes system in 7.1 when Olympus D-540 attache o usb/133296 usb rum driver not working properly in hostap mode p usb/132799 usb [usb][patch]GENESYS USB2IDE requires NO_SYNCHRONIZE_CA o usb/132785 usb [usb] [patch] Gemtech remote powersocket is classed as o usb/132594 usb USB subsystem causes page fault and crashes o usb/132312 usb Xorg 7.4 halts USB controller o usb/132080 usb [patch] [usb] Kernel panic after NOMEM caused by rum c o usb/132066 usb [ukbd] Keyboard failure USB keyboard DELL 760 o usb/132036 usb [panic] page fault when connecting Olympus C740 camera o usb/131912 usb [uslcom] [patch] New devices using Silicon Labs chips o usb/131900 usb [usbdevs] [patch] Additional product identification co o usb/131583 usb [umass] Failure when detaching umass Device o usb/131576 usb [aue] ADMtek USB To LAN Converter can't send data o usb/131521 usb Registering Belkin UPS to usb_quirks.c f usb/131123 usb [patch] re-add UQ_ASSUME_CM_OVER_DATA USB quirk o usb/131074 usb no run-time detection of usb devices plugged into exte o usb/130736 usb Page fault unplugging USB stick o usb/130325 usb [usb] [patch] fix tools/tools/usb/print-usb-if-vids.sh o usb/130230 usb Samsung Electronics YP-U3 does not attach in 7.1-RELEA o usb/130208 usb Boot process severely hampered by umass0 error o usb/130122 usb [newusb] DVD drive detects as 'da' device o docs/129962 usb [newusb] usbconfig(8) refers to non-existant usb2_core o usb/129945 usb [usbdevs] [patch] add u3g support for Longcheer WM66 U o usb/129766 usb [usb] plugging in usb modem HUAWEI E226 panics system o usb/129758 usb [uftdi] [patch] add Pyramid LCD usb support o usb/129673 usb [uhci] uhci (uhub) confused on replugging USB 1.1 scan o usb/129522 usb [ubsa] [patch] add support for ZTE AC8700 modem o usb/129500 usb [umass] [panic] FreeBSD Crashes when connecting SanDis o usb/129311 usb [usb] [panic] Instant crash with an USB card reader o usb/129251 usb [usbdevs] [patch] Liebert UPS being assigned uhid and o usb/129173 usb [uplcom] [patch] Add support for Corega CG-USBRS232R a s usb/128990 usb [usb] u3g does not handle RTS/CTS available on for exa o usb/128977 usb [usb] [patch] uaudio is not full duplex o usb/128803 usb [usbdevs] [patch] Quirk for I-Tuner Networks USBLCD4X2 o usb/128485 usb [umodem] [patch] Nokia N80 modem support o usb/128425 usb [umass] Cannot Connect Maxtor Onetouch 4 USB drive f usb/128418 usb [panic] [rum] loading if_rum causes panic, looks like o usb/128324 usb [uplcom] [patch] remove baud rate restriction for PL23 o usb/127980 usb [umass] [patch] Fix Samsung YP U2 MP3 player on 7.x an o usb/127926 usb [boot] USB Timeout during bootup s usb/127549 usb [umass] [patch] Meizu MiniPlayer M6 (SL) requires some s usb/127453 usb [request] ubsa, uark, ubser, uftdi, and friends should o usb/127423 usb [boot] BTX halted on Gigabyte GA-MA69VM-S2 / AMD Sempr o usb/127342 usb [boot] [panic] enabling usb keyboard and mouse support o usb/127248 usb [ucom] panic while uplcom devices attaach and detach o kern/127222 usb [ohci]: Regression in 7.0 usb storage generic driver o usb/126884 usb [ugen] [patch] Bug in buffer handling in ugen.c f usb/126848 usb [usb]: USB Keyboard hangs during Installation o usb/126740 usb [ulpt] doesn't work on 7.0-RELEASE, 10 second stall be o usb/126519 usb [usb] [panic] panic when plugging in an iphone o kern/126396 usb [panic] kernel panic after unplug USB Bluetooth device o usb/125736 usb [ukbd] [hang] system hangs after AT keyboard detect if o usb/125631 usb [ums] [panic] kernel panic during bootup while 'Logite o usb/125510 usb [panic] repeated plug and unplug of USB mass storage d o usb/125450 usb [panic] Removing USB flash card while being accessed c o usb/125264 usb [patch] sysctl for set usb mouse rate (very useful for o usb/125238 usb [ums] Habu Mouse turns off in X o usb/125088 usb [keyboard] Touchpad not detected on Adesso AKB-430UG U o usb/124980 usb [panic] kernel panic on detaching unmounted umass devi o kern/124777 usb [ucom] USB cua devices don't revert to tty devices whe o usb/124758 usb [rum] [panic] rum panics SMP kernel o usb/124708 usb [panic] Kernel panic on USB KVM reattach o usb/124604 usb [ums] Microsoft combo wireless mouse doesn't work o usb/123969 usb [usb] Supermicro H8SMi-2 usb problem: port reset faile o usb/123714 usb [usb] [panic] Panic when hald-storage-probe runs with o usb/123691 usb usbd(8): usbd hangs o usb/123690 usb [usb] [panic] Panic on USB device insertion when usb l o usb/123611 usb [usb] BBB reset failed, STALLED from Imation/Mitsumi U o usb/123509 usb [umass] continuous reset Samsung SGH-G600 phone o usb/123352 usb [usbdevs] [patch] Add Option GTMAX3.6/7.2 and Quallcom o usb/123351 usb [usbdevs] [patch] Add Reiner SCT cyberJack, Omnikey [2 o usb/122992 usb [umass] [patch] MotoROKR Z6 Phone not recognised by um o usb/122956 usb [ubsa] [patch] add support for Novatel Wireless XU870 o usb/122936 usb [ucom] [ubsa] Device does not receive interrupt o usb/122905 usb [ubsa] [patch] add Huawei E220 to ubsa o usb/122819 usb [usb] [patch] Patch to provide dynamic additions to th o usb/122813 usb [udbp] [request] udbp driver should be removed in favo o usb/122621 usb [new driver] [patch] New driver for Sierra Wireless 3G o usb/122547 usb [ehci] USB Printer not being recognized after reboot o usb/122539 usb [ohci] [panic] AnyDATA ADU-E1000D - kernel panic: ohci o usb/122483 usb [panic] [ulpt] Repeatable panic in 7.0-STABLE o usb/122119 usb [umass] umass device causes creation of daX but not da o usb/122025 usb [uscanner] [patch] uscanner does not attach to Epson R o usb/121755 usb [ohci] [patch] Fix panic after ohci/uhub cardbus devic o usb/121734 usb [ugen] ugen HP1022 printer device not working since up o usb/121708 usb [keyboard] nforce 650i mobo w/ usb keyboard infinite k o usb/121474 usb [cam] [patch] QUIRK: SAMSUNG HM250JI in LaCie usb hard o usb/121426 usb [patch] [uscanner] add HP ScanJet 3570C o usb/121275 usb [boot] [panic] FreeBSD fails to boot with usb legacy s o usb/121232 usb [usb] [panic] USB CardBus card removal causes reboot s p usb/121184 usb [uipaq] [patch] add ids from linux ipaq driver (plus a o usb/121169 usb [umass] Issues with usb mp3 player o usb/121045 usb [uftdi] [patch] Add support for PC-OP-RS1 and KURO-RS o usb/120786 usb [usb] [panic] Kernel panic when forced umount of a det o usb/120729 usb [panic] fault while in kernel mode with connecting USB o usb/120572 usb [umass] [patch] quirk to support ASUS P535 as umass (a o usb/120321 usb [hang] System hangs when transferring data to WD MyBoo o usb/120283 usb [panic] Automation reboot with wireless keyboard & mou o usb/120034 usb [hang] 6.2 & 6.3 hangs on boot at usb0: OHCI with 1.5 o usb/119981 usb [axe] [patch] add support for LOGITEC LAN-GTJ/U2 gigab o usb/119977 usb [ums] Mouse does not work in a Cherry-USB keyboard/mou o usb/119653 usb [cam] [patch] iriver s7 player sync cache error patch o usb/119633 usb [umass] umass0: BBB reset failed, IOERROR [regression] o usb/119513 usb [irq] inserting dlink dwl-g630 wireless card results i o usb/119509 usb [usb] USB flaky on Dell Optiplex 755 o usb/119481 usb [hang] FreeBSD not responding after connecting USB-Mas o usb/119389 usb [umass] Sony DSC-W1 CBI reset failed, STALLED [regress o usb/119227 usb [ubsa] [patch] ubsa buffer is too small; should be tun o usb/119201 usb [cam] [patch] Quirks for Olympus FE-210 camera, LG and o usb/118485 usb [usbdevs] [patch] Logitech Headset Workaround o usb/118480 usb [umass] Timeout in USB mass storage freezes vfs layer o usb/118353 usb [panic] [ppp] repeatable kernel panic during ppp(4) se o usb/118141 usb [ucom] usb serial and nokia phones ucomreadcb ucomread o usb/118140 usb [ucom] [patch] quick hack for ucom to get it behave wi o usb/118098 usb [umass] 6th gen iPod causes problems when disconnectin o usb/117955 usb [umass] [panic] inserting minolta dimage a2 crashes OS o usb/117946 usb [panic] D-Link DUB-E100 rev. B1 crashes FreeBSD 7.0-BE o usb/117938 usb [ums] [patch] Adding support for MS WL Natural and MS o usb/117911 usb [ums] [request] Mouse Gembird MUSWC not work o usb/117893 usb [umass] Lacie USB DVD writing failing o usb/117613 usb [uhci] [irq] uhci interrupt storm & USB leaked memory o usb/117598 usb [uaudio] [patch] Not possible to record with Plantroni o usb/117313 usb [umass] [panic] panic on usb camera insertion o usb/117200 usb [ugen] ugen0 prints strange string on attach if detach o usb/117183 usb [panic] USB/fusefs -- panic while transferring large a o usb/116947 usb [ukbd] [patch] [regression] enable boot protocol on th o usb/116699 usb [usbhid] USB HID devices do not initialize at system b o usb/116561 usb [umodem] [panic] RELENG_6 umodem panic "trying to slee o usb/116282 usb [ulpt] Cannot print on USB HP LJ1018 or LJ1300 o usb/115935 usb [usbdevs] [patch] kernel counterproductively attaches o usb/115933 usb [uftdi] [patch] RATOC REX-USB60F (usb serial converter o usb/115400 usb [ehci] Problem with EHCI on ASUS M2N4-SLI o usb/115298 usb [ulpt] [panic] Turning off USB printer panics kernel o usb/114916 usb [umass] [patch] USB Maxtor drive (L300RO) requires qui o kern/114780 usb [uplcom] [panic] Panics while stress testing the uplco o usb/114682 usb [umass] generic USB media-card reader unusable o usb/114310 usb [libusb] [patch] [panic] USB hub attachment panics ker o usb/114068 usb [umass] [patch] Problems with connection of the umass o conf/114013 usb [patch] WITHOUT_USB allow to compil a lot of USB stuff s usb/113977 usb [request] Need a way to set mode of USB disk's write c o usb/113672 usb [ehci] [panic] Kernel panic with AEWIN CB6971 s usb/113629 usb [ukbd] Dropped USB keyboard events on Dell Latitude D6 o usb/113432 usb [ucom] WARNING: attempt to net_add_domain(netgraph) af a usb/113060 usb [usbdevs] [patch] Samsung printer not working in bidir o usb/112944 usb [ulpt] [patch] Bi-directional access to HP LaserJet 10 o usb/112640 usb [usb] [hang] Kernel freezes when writing a file to an o usb/112631 usb [panic] Problem with SONY DSC-S80 camera on umount s usb/112568 usb [umass] [request] USB mode may wrong when mounting Pla o usb/112463 usb [umass] problem with Samsung USB DVD writer, libscg an o usb/112461 usb [ehci] [request] ehci USB 2.0 doesn't work on nforce4 o usb/111753 usb [uhid] [panic] Replicable system panic involving UHID o usb/110856 usb [ugen] [patch] interrupt in msgs are truncated when bu o usb/110197 usb [umass] Sony PSP umass device does not detach from EHC o usb/109397 usb [panic] on boot from USB flash o usb/109274 usb [usb] MCP55 USB Controller fails to attach in AMD64 Cu o usb/108513 usb [umass] Creative MuVo TX FM fails in 6.2-RELEASE [regr s usb/108344 usb [panic] kernel with atausb panics when unplugging USB o usb/108056 usb [ohci] Mouse gets powered off during device probe when o usb/107935 usb [uplcom] [panic] panic while accessing /dev/cuaU0 o usb/107924 usb [patch] usbd(8) does not call detach o usb/107848 usb [umass] [request] cannot access Samsung flash disk o usb/107827 usb [ohci] [panic] ohci_add_done addr not found o usb/107496 usb [uhub] USB device problem on RELENG_6_2 (SHORT_XFER) [ o usb/107388 usb [new driver] [patch] add utoppy device from NetBSD o usb/107248 usb [umass] [patch] scsi_da.c quirk for Cowon iAUDIO X5 MP o usb/107243 usb [cam] [patch] Apacer USB Flash Drive quirk o usb/106861 usb [usbdevs] [patch]: usbdevs update: Add product ACER Ze s usb/106832 usb [usb] USB HP printer is not detected by kernel when AC o usb/106648 usb [umass] [hang] USB Floppy on D1950 10 min Hang on Inse o usb/106621 usb [axe] [patch] DLINK DUB-E100 support broken o usb/106615 usb [uftdi] uftdi module does not automatically load with o usb/106041 usb [usb] [request] FreeBSD does not recognise Mustek Bear o usb/105361 usb [panic] Kernel panic during unmounting mass storage (C o usb/105186 usb [ehci] [panic] USB 2.0/ehci on FreeBSD 6.2-PRE/AMD64 c o usb/105065 usb [ata] [usb] SATA - USB Bridge o usb/104830 usb [umass] system crashes when copying data to umass devi o usb/104645 usb [umass] [request] Rave C-201 MP3 player does not commu o usb/104352 usb [ural] [patch] ural driver doesnt work o usb/104292 usb [umass] [hang] system lockup on forced umount of usb-s o usb/104290 usb [umass] [patch] quirk: TOSHIBA DVD-RAM drive (libretto o usb/103917 usb [uhub] USB driver reports "Addr 0 should never happen" o usb/103418 usb usbhidctl(1): [patch] [request] usbhidctl: add ability o usb/103289 usb [request] USB 2.0 problems on AMD LX-800 CPU and CS-55 o usb/103046 usb [ulpt] [patch] ulpt event driven I/O with select(2) an o usb/103025 usb [uhub] [panic] wrong detection of USB device for FreeB o usb/102976 usb [panic] Casio Exilim Digital Camera causes panic on in o usb/102678 usb [keyboard] Dell PowerEdge DRAC5 USB Keyboard does not o usb/102066 usb [ukbd] usb keyboard and multimedia keys don't work o usb/101775 usb [libusbhid] [patch] possible error in report descripto o usb/101761 usb [usb] [patch] [request] usb.h: increase maximal size o o usb/101752 usb [umass] [panic] 6.1-RELEASE kernel panic on usb device o usb/101448 usb [ohci] FBSD 6.1-STABLE/AMD64 crashes under heavy USB/O o usb/101096 usb [ural] [panic] USB WLAN occasionally causes kernel-pan o usb/100746 usb [keyboard] system does not boot due to USB keyboard pr o usb/99538 usb [keyboard] while using USB keyboard default params of o usb/99431 usb [keyboard] FreeBSD on MSI 6566E (Intel 845E motherboar o kern/99200 usb [bluetooth] SMP-Kernel crashes reliably when Bluetooth o usb/98343 usb [boot] BBB reset failed errors with Creative Muvo MP3 o usb/97472 usb [cam] [patch] add support for Olympus C150,D390 s usb/97286 usb [mouse] [request] MS Wireless Intellimouse Explorer 2. o usb/97175 usb [umass] [hang] USB cardreader hangs system o usb/96457 usb [umass] [panic] fatback on umass = reboot o usb/96381 usb [cam] [patch] add a quirk table entry for a flash ram o usb/96224 usb [usb] [msdosfs] mount_msdosfs cause page fault in sync s usb/96120 usb [ums] [request] USB mouse not always detected s usb/95636 usb [umass] [boot] 5 minute delay at boot when using VT620 o usb/95562 usb [umass] Write Stress in USB Mass drive causes "vinvalb s usb/95348 usb [keyboard] USB keyboard unplug causes noise on screen o usb/95037 usb [umass] USB disk not recognized on hot-plug. o usb/94897 usb [panic] Kernel Panic when cleanly unmounting USB disk o usb/94717 usb [ulpt] Reading from /dev/ulpt can break work of a UHCI o usb/94384 usb [panic] kernel panic with usb2 hardware o usb/93872 usb [cam] [patch] SCSI quirk required for ELTA 8061 OL USB o usb/93828 usb [ohci] [panic] ohci causes panic on boot (HP Pavillion o usb/93408 usb [mouse] hw.acpi.cpu.cx_lowest=C3 on AMD Turion causes o usb/93389 usb [umass] [patch] Digital Camera Pentax S60 don't work o usb/93155 usb [ulpt] /dev/ulpt0: device busy, USB printer does not w o usb/92852 usb [ums] [patch] Vertical scroll not working properly on o usb/92171 usb [panic] panic unplugging Vodafone Mobile Connect (UMTS o usb/92142 usb [uhub] SET_ADDR_FAILED and SHORT_XFER errors from usb o usb/92083 usb [ural] [panic] panic using WPA on ural NIC in 6.0-RELE o usb/92052 usb [ulpt] usbd causes defunct process with busy file-hand o usb/91906 usb [ehci] [hang] FreeBSD hangs while booting with USB leg o usb/91896 usb camcontrol(8): Serial Number of USB Memory Sticks is n o usb/91811 usb [umass] Compact Flash in HP Photosmart 2610 return " o usb/91629 usb [usb] usbd_abort_pipe() may result in infinite loop o usb/91546 usb [umodem] [patch] Nokia 6630 mobile phone does not work o usb/91538 usb [ulpt] [patch] Unable to print to EPSON CX3500 o usb/91283 usb [boot] [regression] booting very slow with usb devices o usb/91238 usb [umass] USB tape unit fails to write a second tape fil o usb/90700 usb [umass] [panic] Kernel panic on connect/mount/use umas o usb/89954 usb [umass] [panic] USB Disk driver race condition? s usb/89003 usb [request] LaCie Firewire drive not properly supported o usb/88743 usb [hang] [regression] USB makes kernel hang at boot (reg o usb/88408 usb [axe] axe0 read PHY failed o usb/87648 usb [mouse] Logitech USB-optical mouse problem. o usb/87224 usb [usb] Cannot mount USB Zip750 o usb/86767 usb [umass] [patch] bogus "slice starts beyond end of the o usb/86298 usb [mouse] Known good USB mouse won't work with correct s s usb/85067 usb [uscanner] Cannot attach ScanJet 4300C to usb device f usb/84750 usb [hang] 6-BETA2 reboot/shutdown with root_fs on externa s usb/84336 usb [usb] [reboot] instant system reboot when unmounting a o usb/84326 usb [umass] Panic trying to connect SCSI tape drive via US o usb/83977 usb [ucom] [panic] ucom1: open bulk out error (addr 2): IN o usb/83863 usb [ugen] Communication problem between opensc/openct via o usb/83756 usb [ums] [patch] Microsoft Intellimouse Explorer 4.0A doe o usb/83563 usb [umass] [panic] Page Fault while detaching Mpman Usb d o usb/83504 usb [kernel] [patch] SpeedTouch USB stop working on recent o usb/82660 usb [ehci] [panic] EHCI: I/O stuck in state 'physrd'/panic s usb/82569 usb [umass] [panic] USB mass storage plug/unplug causes sy o usb/82520 usb [udbp] [reboot] Reboot when USL101 connected o usb/82350 usb [ucom] [panic] null pointer dereference in USB stack o usb/81621 usb [ehci] [hang] external hd hangs under load on ehci o usb/80935 usb [uvisor] [patch] uvisor.c is not work with CLIE TH55. o usb/80862 usb [patch] USB locking issues: missing some Giant calls o usb/80854 usb [patch] [request] suggestion for new iface-no-probe me o usb/80829 usb [modules] [panic] possible panic when loading USB-modu s usb/80777 usb [request] usb_rem_task() should wait for callback to c s usb/80776 usb [udav] [request] UDAV device driver shouldn't use usb_ o usb/80774 usb [patch] have "usbd_find_desc" in line with the other " o usb/80361 usb [umass] [patch] mounting of Dell usb-stick fails o usb/80040 usb [hang] Use of sound mixer causes system freeze with ua o usb/79723 usb [usb] [request] prepare for high speed isochronous tra o usb/79722 usb [ehci] wrong alignments in ehci.h a usb/79656 usb [ehci] RHSC interrupts lost o usb/79524 usb [ulpt] printing to Minolta PagePro 1[23]xxW via USB fa o usb/79287 usb [uhci] [hang] UHCI hang after interrupt transfer o usb/79269 usb [ohci] USB ohci da0 plug/unplug causes crashes and loc o usb/78984 usb [umass] [patch] Creative MUVO umass failure o usb/77294 usb [ucom] [panic] ucom + ulpcom panic o usb/77184 usb [umass] [panic] kernel panic on USB device disconnect, o usb/76732 usb [ums] Mouse problems with USB KVM Switch o usb/76653 usb [umass] [patch] Problem with Asahi Optical usb device o usb/76461 usb [umass] disklabel of umass(4)-CAM(4)-da(4) not used by o usb/76395 usb [uhci] USB printer does not work, usbdevs says "addr 0 s usb/75928 usb [umass] [request] Cytronix SmartMedia card (SMC) reade o usb/75800 usb [ucom] ucom1: init failed STALLED error in time of syn o usb/75797 usb [sound] 5.3-STABLE(2005 1/4) detect USB headset, But c o usb/75764 usb [umass] [patch] "umass0: Phase Error" - no device for o usb/75705 usb [umass] [panic] da0 attach / Optio S4 (with backtrace) o usb/74771 usb [umass] [hang] mounting write-protected umass device a s usb/74453 usb [umass] [patch] Q-lity CD-RW USB ECW-043 (ScanLogic SL o usb/74211 usb [umass] USB flash drive causes CAM status 0x4 on 4.10R o usb/73307 usb [panic] Kernel panics on USB disconnect s usb/72733 usb [ucom] [request] Kyocera 7135 Palm OS connection probl o usb/71455 usb [umass] Slow USB umass performance of 5.3 o usb/71417 usb [ugen] Cryptoflex e-gate USB token (ugen0) communicati o usb/71416 usb [ugen] Cryptoflex e-gate USB token (ugen0) detach is n o usb/71280 usb [aue] aue0 device (linksys usb100tx) doesn't work in 1 o usb/71155 usb [ulpt] misbehaving usb-printer hangs processes, causes o usb/70523 usb [umct] [patch] umct sending/receiving wrong characters o usb/69006 usb [usbdevs] [patch] Apple Cinema Display hangs USB ports o usb/68232 usb [ugen] [patch] ugen(4) isochronous handling correction o usb/67301 usb [uftdi] [panic] RTS and system panic o usb/66547 usb [ucom] Palm Tungsten T USB does not initialize correct o usb/63621 usb [umass] [panic] USB MemoryStick Reader stalls/crashes s usb/62257 usb [umass] [request] card reader UCR-61S2B is only half-s o usb/59698 usb [keyboard] [patch] Rework of ukbd HID to AT code trans s bin/57255 usb [patch] usbd(8) and multi-function devices s usb/52026 usb [usb] [request] umass driver support for InSystem ISD2 s usb/51958 usb [urio] [patch] update for urio driver o i386/46371 usb USB controller cannot be initialized on IBM Netfinity o usb/40948 usb [umass] [request] USB HP CDW8200 does not work o usb/30929 usb [usb] [patch] use usbd to initialize USB ADSL modem 323 problems total. From owner-freebsd-usb@FreeBSD.ORG Tue Jul 7 13:50:31 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2E4D1106564A; Tue, 7 Jul 2009 13:50:31 +0000 (UTC) (envelope-from kosmo@semihalf.com) Received: from smtp.semihalf.com (smtp.semihalf.com [213.17.239.109]) by mx1.freebsd.org (Postfix) with ESMTP id D602C8FC24; Tue, 7 Jul 2009 13:50:29 +0000 (UTC) (envelope-from kosmo@semihalf.com) Received: from [10.0.0.5] (cardhu.semihalf.com [213.17.239.108]) by smtp.semihalf.com (Postfix) with ESMTPSA id 74FB5C4021; Tue, 7 Jul 2009 15:49:24 +0200 (CEST) From: Piotr =?iso-8859-2?q?Zi=EAcik?= Organization: Semihalf To: Hans Petter Selasky Date: Tue, 7 Jul 2009 15:50:28 +0200 User-Agent: PLD Linux KMail/1.9.10 References: <200906231035.43096.kosmo@semihalf.com> <200906301128.26046.hselasky@c2i.net> <200907051236.22783.hselasky@c2i.net> In-Reply-To: <200907051236.22783.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200907071550.28781.kosmo@semihalf.com> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, thompsa@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Jul 2009 13:50:31 -0000 > > I did not find time yet to test on my AT91RM9200 board. I hope to do a te= st > this week. Did you at semihalf find anything? > I had Checked USB behaviour on PowerPC without hardware cache coherency. The problem also exists here and patch helps. I also generated some logs which you asked for: =2D--- Original USB code ----- ugen0.1: at usbus0 uhub0: on usbus0 ugen1.1: at usbus1 uhub1: on usbus1 ugen2.1: at usbus2 uhub2: on usbus2 Root mount waiting for: usbus2 usbus1 usbus0 uhub0: 1 port with 1 removable, self powered uhub1: 1 port with 1 removable, self powered uhub2: 1 port with 1 removable, self powered =3D> bus_dmamap_sync(0xC3A9E780, 0xC3B6F540, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B9E168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E500, 0xC3AB8C40, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B9D168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E500, 0xC3AB8C00, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B9D170 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E500, 0xC3AB8C00, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B9D170 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B9C170 (size: 0x00000012) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B9C170 (size: 0x00000012) =3D> bus_dmamap_sync(0xC3A9E080, 0xC3B6F400, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B9B168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E080, 0xC3B6F280, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B9B170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E080, 0xC3B6F280, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B9B170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E080, 0xC3B6F400, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B9B168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E080, 0xC3B6F280, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B9B170 (size: 0x00000009) =3D> bus_dmamap_sync(0xC3A9E080, 0xC3B6F280, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B9B170 (size: 0x00000009) Root mount waiting for: usbus0 =3D> bus_dmamap_sync(0xC3A9E300, 0xC3AB8D00, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B9A168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E580, 0xC3AB8E40, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B99168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E580, 0xC3B6F380, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B99170 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E580, 0xC3B6F380, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B99170 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E800, 0xC3B6F480, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B98168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E800, 0xC3AB8E00, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B98170 (size: 0x00000012) =3D> bus_dmamap_sync(0xC3A9E800, 0xC3AB8E00, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B98170 (size: 0x00000012) =3D> bus_dmamap_sync(0xC35DC700, 0xC3AB8B40, [PREREAD PREWRITE ________=20 _________]) -> Writeback Invalidate 0xC3B97168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC35DC700, 0xC3B6F500, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B97170 (size: 0x00000009) =3D> bus_dmamap_sync(0xC35DC700, 0xC3B6F500, [_______ ________ POSTREAD=20 POSTWRITE]) -> Invalidate 0xC3B97170 (size: 0x00000009) usb_alloc_device:1729: Failure selecting configuration index 0: USB_ERR_INV= AL,=20 port 1, addr 2 (ignored) ugen0.2: at usbus0 =2D---- USB Stack with my patch ----- ugen0.1: at usbus0 uhub0: on usbus0 ugen1.1: at usbus1 uhub1: on usbus1 ugen2.1: at usbus2 uhub2: on usbus2 Root mount waiting for: usbus2 usbus1 usbus0 uhub0: 1 port with 1 removable, self powered uhub1: 1 port with 1 removable, self powered uhub2: 1 port with 1 removable, self powered =3D> bus_dmamap_sync(0xC3A9E780, 0xC3B6F540, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9E168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E500, 0xC3AB8C40, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9D168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E500, 0xC3AB8C00, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9D170 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E500, 0xC3AB8C00, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9D170 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000012) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000012) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000004) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000004) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000002) Root mount waiting for: usbus0 =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000022) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000022) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000002) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000022) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000022) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000009) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000009) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000020) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000020) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) ugen0.2: at usbus0 umass0: on usbus0 umass0: SCSI over Bulk-Only; quirks =3D 0x0000 =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F080, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3B9C168 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000001) =3D> bus_dmamap_sync(0xC3A9E280, 0xC3B6F140, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3B9C170 (size: 0x00000001) Root mount waiting for: usbus0 umass0:0:0:-1: Attached to scbus0 =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) Trying to mount root from nfs:10.0.0.201:/nfsroot/mv78100-4/ =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB6098 (size: 0x00000024) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB6098 (size: 0x00000024) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Invalidate 0xC3BC0500 (size: 0x00000100) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Invalidate 0xC3BC0500 (size: 0x00000100) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BBC0A0 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BBC0A0 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) da0 at umass-sim0 bus 0 target 0 lun 0 da0: Removable Direct Access SCSI-0 device da0: 40.000MB/s transfers da0: 1912MB (3915776 512 byte sectors: 255H 63S/T 243C) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) NFS ROOT: 10.0.0.201:/nfsroot/mv78100-4/ =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3AB9C80 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3AB9C80 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BBAC70 (size: 0x00000020) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BBAC70 (size: 0x00000020) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Invalidate 0xC3B6D800 (size: 0x00000200) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Invalidate 0xC3B6D800 (size: 0x00000200) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Invalidate 0xC3C2A000 (size: 0x00002000) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Invalidate 0xC3C2A000 (size: 0x00002000) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3AB9B50 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3AB9B50 (size: 0x00000008) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BBAC70 (size: 0x00000020) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB00C0, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BBAC70 (size: 0x00000020) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB0380, [_______ PREWRITE ________=20 _________]) -> Writeback 0xC3BB23A8 (size: 0x0000001F) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =3D> bus_dmamap_sync(0xC3A9E480, 0xC3BB8080, [PREREAD ________ ________=20 _________]) -> Writeback Invalidate 0xC3BB2770 (size: 0x0000000D) =2D-=20 Best regards, Piotr Zi=EAcik From owner-freebsd-usb@FreeBSD.ORG Tue Jul 7 16:47:07 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E9F7010656AB; Tue, 7 Jul 2009 16:47:07 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe01.swip.net [212.247.154.1]) by mx1.freebsd.org (Postfix) with ESMTP id D42048FC16; Tue, 7 Jul 2009 16:47:06 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=Hrwt8fWgTlIA:10 a=MXw7gxVQKqGXY79tIT8aFQ==:17 a=6ZsRMLCPI8ooBufYVQoA:9 a=0XZanadGUU8MJNL9l0V2CwABxxkA:4 Received: from [62.113.132.61] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe01.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 219319571; Tue, 07 Jul 2009 18:47:05 +0200 From: Hans Petter Selasky To: Piotr =?iso-8859-2?q?Zi=EAcik?= Date: Tue, 7 Jul 2009 18:46:39 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-CURRENT; KDE/4.2.4; i386; ; ) References: <200906231035.43096.kosmo@semihalf.com> <200907051236.22783.hselasky@c2i.net> <200907071550.28781.kosmo@semihalf.com> In-Reply-To: <200907071550.28781.kosmo@semihalf.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200907071846.42086.hselasky@c2i.net> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, thompsa@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Jul 2009 16:47:08 -0000 On Tuesday 07 July 2009 15:50:28 Piotr Zi=EAcik wrote: > > I did not find time yet to test on my AT91RM9200 board. I hope to do a > > test this week. Did you at semihalf find anything? > Hi, > I had Checked USB behaviour on PowerPC without hardware cache coherency. > The problem also exists here and patch helps. In my source code view the busdma sync function is empty for power-pc. Your= =20 patch should have no effect at all for sync operations? > > I also generated some logs which you asked for: Thanks. I will try to make a build for AT91RM9200 tonight. Did you test my suggested patch: > Try adding: > > cpu_dcache_wb_range((vm_offset_t)buf, len); > cpu_l2cache_wb_range((vm_offset_t)buf, len); > > Before: > > cpu_dcache_wbinv_range((vm_offset_t)buf, len); > cpu_l2cache_wbinv_range((vm_offset_t)buf, len); > > In: sys/arm/arm/busdma_machdep.c Or have you got any comments on that? =2D-HPS From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 07:32:50 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5C0BE1065670 for ; Wed, 8 Jul 2009 07:32:50 +0000 (UTC) (envelope-from sarumont@sigil.org) Received: from mail.sigil.org (mail.sigil.org [208.86.227.164]) by mx1.freebsd.org (Postfix) with ESMTP id 277AF8FC19 for ; Wed, 8 Jul 2009 07:32:50 +0000 (UTC) (envelope-from sarumont@sigil.org) Received: from localhost (localhost [127.0.0.1]) by mail.sigil.org (Postfix) with ESMTP id 81B99BF0C6 for ; Wed, 8 Jul 2009 02:13:08 -0500 (CDT) X-Virus-Scanned: amavisd-new at sigil.org Received: from mail.sigil.org ([127.0.0.1]) by localhost (mail.sigil.org [127.0.0.1]) (amavisd-new, port 10024) with LMTP id RxPstZdZ6tNW for ; Wed, 8 Jul 2009 02:13:07 -0500 (CDT) Received: from illusion.portal.sigil.org (ip72-202-157-83.ks.ks.cox.net [72.202.157.83]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sigil.org (Postfix) with ESMTPSA id 0EEC7BF0C5 for ; Wed, 8 Jul 2009 02:13:06 -0500 (CDT) Received: by illusion.portal.sigil.org (sSMTP sendmail emulation); Wed, 8 Jul 2009 02:13:48 -0500 From: "Richard Kolkovich" Date: Wed, 8 Jul 2009 02:13:48 -0500 To: freebsd-usb@freebsd.org Message-ID: <20090708071347.GB52577@magus.portal.sigil.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="cvVnyQ+4j833TQvp" Content-Disposition: inline X-OS: FreeBSD magus 7.2-PRERELEASE i386 X-Mailer: Mutt 1.5.20 (2009-06-14) X-Composed-With: vim X-PGP-Key: http://sarumont.sigil.org/pubkey.asc User-Agent: Mutt/1.5.20 (2009-06-14) Subject: uvideo status check X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 07:32:50 -0000 --cvVnyQ+4j833TQvp Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Looking into UVC support for FreeBSD, the last update I see is on 4/4/09 on= this list. I was wondering, first and foremost, if anyone was working on/planning to work on= porting the uvideo driver to FreeBSD. If so, has been any progress made? I'm willing to star= t porting/help=20 port/help test/whatever. =20 Thanks, --=20 Richard Kolkovich sarumont@sigil.org --cvVnyQ+4j833TQvp Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.12 (FreeBSD) iEYEARECAAYFAkpURysACgkQfXtD1KVAIbCXxACg74G3ictfertIDplKaasw5EYA UHEAmwenNVZmJjRfArjJQghSjKW/MFqL =lstj -----END PGP SIGNATURE----- --cvVnyQ+4j833TQvp-- From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 09:04:09 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 31CF9106568E; Wed, 8 Jul 2009 09:04:09 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe09.tele2.se [212.247.155.1]) by mx1.freebsd.org (Postfix) with ESMTP id 65F2D8FC22; Wed, 8 Jul 2009 09:04:08 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=Hrwt8fWgTlIA:10 a=gg2W7PyvkLb8p4ie143lBA==:17 a=qqY-37dCzyb6F8oYTQwA:9 a=wQ8DsXPsDZOwMyX6hxGZY5avNgEA:4 Received: from [194.248.135.20] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe09.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 928573831; Wed, 08 Jul 2009 11:04:06 +0200 From: Hans Petter Selasky To: Rafal Jaworowski Date: Wed, 8 Jul 2009 11:03:43 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: <200906231035.43096.kosmo@semihalf.com> <200907071846.42086.hselasky@c2i.net> <37C51279-42D8-49DE-8249-0DA386EBB062@semihalf.com> In-Reply-To: <37C51279-42D8-49DE-8249-0DA386EBB062@semihalf.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907081103.45388.hselasky@c2i.net> Cc: thompsa@freebsd.org, freebsd-arm@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 09:04:10 -0000 On Wednesday 08 July 2009 10:58:17 Rafal Jaworowski wrote: > On 2009-07-07, at 18:46, Hans Petter Selasky wrote: > >> I had Checked USB behaviour on PowerPC without hardware cache > >> coherency. > >> The problem also exists here and patch helps. > > > > In my source code view the busdma sync function is empty for power- > > pc. Your > > patch should have no effect at all for sync operations? > > This was about the PPC4xx PowerPC port, not committed to the tree yet. > Unlike most PowerPC this system has a de-coherent DMA and therefore > its busdma sync is non empty, but needs to enforce coherency by > software. > > The point is this is another platform on which USB stack (usb_pc_cpu_* > functions) shows similar issues as reported for ARM and MIPS. And what about my patch suggestion in my previous e-mail having the same subject. Does it work? Regarding my testing on the AT91RM9200 I was short of time yesterday and will try to get it done today. --HPS From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 09:14:27 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5A491106566C; Wed, 8 Jul 2009 09:14:27 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from smtp.semihalf.com (smtp.semihalf.com [213.17.239.109]) by mx1.freebsd.org (Postfix) with ESMTP id 0F3F28FC0A; Wed, 8 Jul 2009 09:14:26 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from [10.0.0.34] (cardhu.semihalf.com [213.17.239.108]) by smtp.semihalf.com (Postfix) with ESMTPSA id 5B4E9C3AAA; Wed, 8 Jul 2009 10:57:15 +0200 (CEST) Message-Id: <37C51279-42D8-49DE-8249-0DA386EBB062@semihalf.com> From: Rafal Jaworowski To: Hans Petter Selasky In-Reply-To: <200907071846.42086.hselasky@c2i.net> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v935.3) Date: Wed, 8 Jul 2009 10:58:17 +0200 References: <200906231035.43096.kosmo@semihalf.com> <200907051236.22783.hselasky@c2i.net> <200907071550.28781.kosmo@semihalf.com> <200907071846.42086.hselasky@c2i.net> X-Mailer: Apple Mail (2.935.3) Cc: thompsa@freebsd.org, freebsd-arm@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 09:14:27 -0000 On 2009-07-07, at 18:46, Hans Petter Selasky wrote: >> I had Checked USB behaviour on PowerPC without hardware cache >> coherency. >> The problem also exists here and patch helps. > > In my source code view the busdma sync function is empty for power- > pc. Your > patch should have no effect at all for sync operations? This was about the PPC4xx PowerPC port, not committed to the tree yet. Unlike most PowerPC this system has a de-coherent DMA and therefore its busdma sync is non empty, but needs to enforce coherency by software. The point is this is another platform on which USB stack (usb_pc_cpu_* functions) shows similar issues as reported for ARM and MIPS. Rafal From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 10:16:42 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6118E1065673; Wed, 8 Jul 2009 10:16:42 +0000 (UTC) (envelope-from kosmo@semihalf.com) Received: from smtp.semihalf.com (smtp.semihalf.com [213.17.239.109]) by mx1.freebsd.org (Postfix) with ESMTP id 065DA8FC1D; Wed, 8 Jul 2009 10:16:41 +0000 (UTC) (envelope-from kosmo@semihalf.com) Received: from [10.0.0.5] (cardhu.semihalf.com [213.17.239.108]) by smtp.semihalf.com (Postfix) with ESMTPSA id B1BBEC4021; Wed, 8 Jul 2009 12:15:37 +0200 (CEST) From: Piotr =?iso-8859-2?q?Zi=EAcik?= Organization: Semihalf To: Hans Petter Selasky Date: Wed, 8 Jul 2009 12:16:39 +0200 User-Agent: PLD Linux KMail/1.9.10 References: <200906231035.43096.kosmo@semihalf.com> <37C51279-42D8-49DE-8249-0DA386EBB062@semihalf.com> <200907081103.45388.hselasky@c2i.net> In-Reply-To: <200907081103.45388.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200907081216.40100.kosmo@semihalf.com> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, thompsa@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 10:16:43 -0000 Wednesday 08 July 2009 11:03:43 Hans Petter Selasky napisa=B3(a): > > And what about my patch suggestion in my previous e-mail having the same > subject. Does it work? > I have tested it and it does not work. By the way Writeback before Writebac= k=20 Invalidate did not change cache behaviour too much. Writeback invalidate=20 means flush all modified cache lines and then invalidate cache. However looking into logs which I have sent you yesterdat I see one differe= nce=20 which may be significant. My patch changes Invalidate into Writeback=20 Invalidate. In original code if driver write something to memory and then=20 invalidate cache, the write will be lost. With my patch after change will be written to memory and then cache will be invalidated. What do you think ? =2D-=20 Best Regards, Piotr Ziecik From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 10:30:50 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2DCA3106564A for ; Wed, 8 Jul 2009 10:30:50 +0000 (UTC) (envelope-from sebastian.huber@embedded-brains.de) Received: from mail.embedded-brains.de (host-82-135-62-35.customer.m-online.net [82.135.62.35]) by mx1.freebsd.org (Postfix) with ESMTP id A84428FC12 for ; Wed, 8 Jul 2009 10:30:49 +0000 (UTC) (envelope-from sebastian.huber@embedded-brains.de) Received: by mail.embedded-brains.de (Postfix, from userid 65534) id 8B4066F8260; Wed, 8 Jul 2009 12:30:47 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on fidibus X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.3 Received: from [192.168.96.31] (eb0011.eb.z [192.168.96.31]) by mail.embedded-brains.de (Postfix) with ESMTP id 5C83E6F825E; Wed, 8 Jul 2009 12:30:46 +0200 (CEST) Message-ID: <4A547556.4050801@embedded-brains.de> Date: Wed, 08 Jul 2009 12:30:46 +0200 From: Sebastian Huber User-Agent: Thunderbird 2.0.0.19 (X11/20081227) MIME-Version: 1.0 To: =?ISO-8859-2?Q?Piotr_Zi=EAcik?= References: <200906231035.43096.kosmo@semihalf.com> <37C51279-42D8-49DE-8249-0DA386EBB062@semihalf.com> <200907081103.45388.hselasky@c2i.net> <200907081216.40100.kosmo@semihalf.com> In-Reply-To: <200907081216.40100.kosmo@semihalf.com> Content-Type: text/plain; charset=ISO-8859-2 Content-Transfer-Encoding: 8bit Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, freebsd-usb@freebsd.org, thompsa@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 10:30:50 -0000 Hi! The general approach for systems with no hardware cache coherence protocol should be: Memory to device DMA transfer of a buffer: 1. write all modified cache lines of the buffer back to memory (cache flush for buffer) 2. start DMA transfer Device to memory DMA transfer of a buffer: 1. invalidate the cache of the buffer, here you have to make sure that this buffer does not share a cache line with other buffers (!) 2. start DMA transfer 3. all accesses to the buffer via the cache must wait until the DMA has finished CU -- Sebastian Huber, Embedded Brains GmbH Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany Phone : +49 89 18 90 80 79-6 Fax : +49 89 18 90 80 79-9 E-Mail : sebastian.huber@embedded-brains.de PGP : Public key available on request Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG. From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 10:51:22 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1CBB51065674; Wed, 8 Jul 2009 10:51:22 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe09.swipnet.se [212.247.155.1]) by mx1.freebsd.org (Postfix) with ESMTP id 3AFF98FC13; Wed, 8 Jul 2009 10:51:20 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=Hrwt8fWgTlIA:10 a=gg2W7PyvkLb8p4ie143lBA==:17 a=ge6c7HbqCLY6kjjTAcgA:9 a=-Zd0oq5pNAkYy4vOxvgA:7 a=wsCSXzGZHIBTtm1dGkqSUQLDJlkA:4 Received: from [194.248.135.20] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe09.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 928647965; Wed, 08 Jul 2009 12:51:19 +0200 From: Hans Petter Selasky To: Piotr =?iso-8859-2?q?Zi=EAcik?= Date: Wed, 8 Jul 2009 12:50:56 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: <200906231035.43096.kosmo@semihalf.com> <200907081103.45388.hselasky@c2i.net> <200907081216.40100.kosmo@semihalf.com> In-Reply-To: <200907081216.40100.kosmo@semihalf.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200907081250.58151.hselasky@c2i.net> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, thompsa@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 10:51:22 -0000 Hi, On Wednesday 08 July 2009 12:16:39 Piotr Zi=EAcik wrote: > Wednesday 08 July 2009 11:03:43 Hans Petter Selasky napisa=B3(a): > > And what about my patch suggestion in my previous e-mail having the same > > subject. Does it work? > > I have tested it and it does not work. By the way Writeback before > Writeback Invalidate did not change cache behaviour too much. Writeback > invalidate means flush all modified cache lines and then invalidate cache. By flush you mean write from CPU cache to RAM, right. And nothing else? You= =20 don't mean discard CPU cache by "flush" ??? > > However looking into logs which I have sent you yesterdat I see one > difference which may be significant. My patch changes Invalidate into > Writeback Invalidate. In original code if driver write something to memory > and then invalidate cache If that is the case I'm very surprised. Could you make another printout for= =20 me. Compile the kernel with KDB, and add a call to "kdb_backtrace()" in=20 bus_dmamap_sync() before printing out the writeback and/or invalidate, so t= hat=20 I can see the backtrace. > , the write will be lost. I'm aware about that. > With my patch after > change will be written to memory and then cache will be invalidated. What > do you think ? I still cannot see that I'm using the wrong flags when calling=20 bus_dmamap_sync(). You are absoultely sure that your USB code is indentical to the now stock 8- current USB code, and that there are no integration issues lurking? In the USB "usb_pc_cpu_flush()" is used after CPU write operations to flush= =20 the CPU cache to RAM. "usb_pc_cpu_invalidate()" is used before CPU read=20 operations. So far so good? You are arguing that: BUS_DMASYNC_POSTWRITE | BUS_DMASYNC_POSTREAD flags do not cause a CPU invalidate? Whilst the busdma manual is clear, that these flags are used after "an upda= te=20 of host memory by the device and prior to CPU access to host memory". BUS_DMASYNC_POSTREAD Perform any synchronization required af= ter an update of host memory by the device = and prior to CPU access to host memory. BUS_DMASYNC_POSTWRITE Perform any synchronization required af= ter device access to host memory. And that: BUS_DMASYNC_PREREAD Perform any synchronization required pr= ior to an update of host memory by the devi= ce. BUS_DMASYNC_PREWRITE Perform any synchronization required af= ter an update of host memory by the CPU and prior to device access to host memory. flags do not cause a CPU flush prior to device acccess. /*------------------------------------------------------------------------* * usb_pc_cpu_invalidate - invalidate CPU cache *------------------------------------------------------------------------*/ void usb_pc_cpu_invalidate(struct usb_page_cache *pc) { if (pc->page_offset_end =3D=3D pc->page_offset_buf) { /* nothing has been loaded into this page cache! */ return; } bus_dmamap_sync(pc->tag, pc->map, BUS_DMASYNC_POSTWRITE | BUS_DMASYNC_POSTREAD); } /*------------------------------------------------------------------------* * usb_pc_cpu_flush - flush CPU cache *------------------------------------------------------------------------*/ void usb_pc_cpu_flush(struct usb_page_cache *pc) { if (pc->page_offset_end =3D=3D pc->page_offset_buf) { /* nothing has been loaded into this page cache! */ return; } bus_dmamap_sync(pc->tag, pc->map, BUS_DMASYNC_PREWRITE | BUS_DMASYNC_PREREAD); } Thanks for being patient. If there is a bug, it will be fixed. =2D-HPS From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 14:29:25 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EC6881065676; Wed, 8 Jul 2009 14:29:25 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id A855F8FC15; Wed, 8 Jul 2009 14:29:25 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from localhost (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id n68EN5GH053804; Wed, 8 Jul 2009 08:23:06 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Wed, 08 Jul 2009 08:23:43 -0600 (MDT) Message-Id: <20090708.082343.-1343671115.imp@bsdimp.com> To: hselasky@c2i.net From: "M. Warner Losh" In-Reply-To: <200907081103.45388.hselasky@c2i.net> References: <200907071846.42086.hselasky@c2i.net> <37C51279-42D8-49DE-8249-0DA386EBB062@semihalf.com> <200907081103.45388.hselasky@c2i.net> X-Mailer: Mew version 5.2 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-usb@freebsd.org, raj@semihalf.com, freebsd-arm@freebsd.org, thompsa@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 14:29:26 -0000 In message: <200907081103.45388.hselasky@c2i.net> Hans Petter Selasky writes: : On Wednesday 08 July 2009 10:58:17 Rafal Jaworowski wrote: : > On 2009-07-07, at 18:46, Hans Petter Selasky wrote: : > >> I had Checked USB behaviour on PowerPC without hardware cache : > >> coherency. : > >> The problem also exists here and patch helps. : > > : > > In my source code view the busdma sync function is empty for power- : > > pc. Your : > > patch should have no effect at all for sync operations? : > : > This was about the PPC4xx PowerPC port, not committed to the tree yet. : > Unlike most PowerPC this system has a de-coherent DMA and therefore : > its busdma sync is non empty, but needs to enforce coherency by : > software. : > : > The point is this is another platform on which USB stack (usb_pc_cpu_* : > functions) shows similar issues as reported for ARM and MIPS. : : And what about my patch suggestion in my previous e-mail having the same : subject. Does it work? : : Regarding my testing on the AT91RM9200 I was short of time yesterday and will : try to get it done today. I think that the root cause of this issue is two fold. First, The 4 operations for busdma are being collapsed to only 2 operations. There are four for a reason (since you have to do different things for each case). Second, and I think this is more important, I think that we're seeing some cache-line poisoning. We're flushing the entire busdma tag rather than just one cache line since we don't have the API to do that. In addition, I don't think that the USB code is being careful enough to ensure that we don't have buffers that live in the same cache line that are simultaneously being used for read and write. The corruption we're seeing is a classic signal that this may be going on, although I must admit that I've not done the detailed analysis to prove it. Warner From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 18:38:26 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 22124106564A; Wed, 8 Jul 2009 18:38:26 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe05.swip.net [212.247.154.129]) by mx1.freebsd.org (Postfix) with ESMTP id 8294B8FC14; Wed, 8 Jul 2009 18:38:25 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=PfmQioeCagAA:10 a=MXw7gxVQKqGXY79tIT8aFQ==:17 a=uhKcqKgIUNSNzu5jDbcA:9 a=s3fHAes5VnVukIUNDrQA:7 a=mRLxUCAOtyrQO0ak-joQdkFdeHoA:4 Received: from [62.113.132.61] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe05.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 1174487107; Wed, 08 Jul 2009 20:38:23 +0200 From: Hans Petter Selasky To: freebsd-multimedia@freebsd.org, "Richard Kolkovich" , freebsd-usb@freebsd.org Date: Wed, 8 Jul 2009 20:38:01 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907082038.02682.hselasky@c2i.net> Cc: Ed Morgan Subject: Re: uvcvideo on Freebsd (uvideo status check) X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 18:38:26 -0000 On Wednesday 08 July 2009 19:11:05 Ed Morgan wrote: > Hi, > > Has anyone had any joy getting webcams that use the uvcvideo driver working > under FreeBSD? I'm looking at putting FreeBSD back on my laptop, and if the > webcam will work, that'll clinch it for me. Most of the results i've found > from trawling Google suggest that uvcvideo is basically not going to work, > but if anyone knows otherwise? > > Any advice would be greatly appreciated. > > Thanks very much. > > Ed There are several projects around, not finished yet, that are about porting V4L to BSD. See thread "USB webcam++ support for FreeBSD-8-current is soon here". --HPS From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 18:42:52 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3897D1065672 for ; Wed, 8 Jul 2009 18:42:52 +0000 (UTC) (envelope-from sarumont@sigil.org) Received: from mail.sigil.org (mail.sigil.org [208.86.227.164]) by mx1.freebsd.org (Postfix) with ESMTP id F29BA8FC0A for ; Wed, 8 Jul 2009 18:42:51 +0000 (UTC) (envelope-from sarumont@sigil.org) Received: from localhost (localhost [127.0.0.1]) by mail.sigil.org (Postfix) with ESMTP id 089FDBF0EB; Wed, 8 Jul 2009 13:42:09 -0500 (CDT) X-Virus-Scanned: amavisd-new at sigil.org Received: from mail.sigil.org ([127.0.0.1]) by localhost (mail.sigil.org [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Ysnv7kdx-VrW; Wed, 8 Jul 2009 13:42:08 -0500 (CDT) Received: from illusion.portal.sigil.org (ip72-202-157-83.ks.ks.cox.net [72.202.157.83]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sigil.org (Postfix) with ESMTPSA id A1F75BDCCE; Wed, 8 Jul 2009 13:42:07 -0500 (CDT) Received: by illusion.portal.sigil.org (sSMTP sendmail emulation); Wed, 8 Jul 2009 13:42:46 -0500 From: "Richard Kolkovich" Date: Wed, 8 Jul 2009 13:42:46 -0500 To: Hans Petter Selasky Message-ID: <20090708184246.GA29145@magus.portal.sigil.org> References: <200907082038.02682.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="AqsLC8rIMeq19msA" Content-Disposition: inline In-Reply-To: <200907082038.02682.hselasky@c2i.net> X-OS: FreeBSD magus 7.2-PRERELEASE i386 X-Mailer: Mutt 1.5.20 (2009-06-14) X-Composed-With: vim X-PGP-Key: http://sarumont.sigil.org/pubkey.asc User-Agent: Mutt/1.5.20 (2009-06-14) Cc: freebsd-multimedia@freebsd.org, Ed Morgan , freebsd-usb@freebsd.org Subject: Re: uvcvideo on Freebsd (uvideo status check) X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 18:42:52 -0000 --AqsLC8rIMeq19msA Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jul 08, 2009 at 08:38:01PM +0200, Hans Petter Selasky wrote: > On Wednesday 08 July 2009 19:11:05 Ed Morgan wrote: > > Hi, > > > > Has anyone had any joy getting webcams that use the uvcvideo driver wor= king > > under FreeBSD? I'm looking at putting FreeBSD back on my laptop, and if= the > > webcam will work, that'll clinch it for me. Most of the results i've fo= und > > from trawling Google suggest that uvcvideo is basically not going to wo= rk, > > but if anyone knows otherwise? > > > > Any advice would be greatly appreciated. > > > > Thanks very much. > > > > Ed >=20 > There are several projects around, not finished yet, that are about porti= ng=20 > V4L to BSD. >=20 > See thread "USB webcam++ support for FreeBSD-8-current is soon here". >=20 Thanks - I never came across that thread (or thought about checking -emulat= ion). > --HPS --=20 Richard Kolkovich sarumont@sigil.org --AqsLC8rIMeq19msA Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.12 (FreeBSD) iEYEARECAAYFAkpU6H4ACgkQfXtD1KVAIbBoJQCgmK1twuRe+fu/+gftSUo5dxBM RAcAnjGNQn7XICtoTAr25BAMSDDrDo8m =v6cC -----END PGP SIGNATURE----- --AqsLC8rIMeq19msA-- From owner-freebsd-usb@FreeBSD.ORG Wed Jul 8 19:09:23 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CFF2B106566C for ; Wed, 8 Jul 2009 19:09:23 +0000 (UTC) (envelope-from ejr.morgan@gmail.com) Received: from mail-ew0-f224.google.com (mail-ew0-f224.google.com [209.85.219.224]) by mx1.freebsd.org (Postfix) with ESMTP id 504958FC0C for ; Wed, 8 Jul 2009 19:09:23 +0000 (UTC) (envelope-from ejr.morgan@gmail.com) Received: by ewy24 with SMTP id 24so119765ewy.43 for ; Wed, 08 Jul 2009 12:09:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=48OE7JQU6F06R/Egq8TXXH4X2cmCpRwn/Imm6GuRpOU=; b=bwTCV5s6H7AhWacKAk4HJh4S4UAAEjJxz0GRIkPoNh3hBkcpZD6aVUyvIlKIHlkTM8 nlJmuQVcGrtk9XyM0euna+HvrS+fCcuClrBDiewxpfOOZxjrbgygW/pzN/+SMwax3cJ1 /enuA9d8S9ssj/nrcF2cDDI7RSnZecjshCip4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=SnQi9EJUw0dpDC8DqwbPGWQce57MOna2j5jqm9cI3UIM9WLGaJ6mPcmNdaudF6q7Oz gSaKFAC5Ke5ftW/czAU7Ts0fy/xENrPnMxb+d8rIUilDguVH/eDB1Qv5IuMQZ3ONx7uO /O9dpXTVftiSBR16sdqqIyAMIe4UcRUj75lZ0= MIME-Version: 1.0 Received: by 10.211.202.14 with SMTP id e14mr8380734ebq.42.1247078783457; Wed, 08 Jul 2009 11:46:23 -0700 (PDT) In-Reply-To: <200907082038.02682.hselasky@c2i.net> References: <200907082038.02682.hselasky@c2i.net> Date: Wed, 8 Jul 2009 14:46:23 -0400 Message-ID: From: Ed Morgan To: Hans Petter Selasky Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-multimedia@freebsd.org, freebsd-usb@freebsd.org Subject: Re: uvcvideo on Freebsd (uvideo status check) X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Jul 2009 19:09:24 -0000 Awesome, thanks very much. I'll subscribe to the list as well so I can keep up to date. Hopefully I can find some sort of resolution, though I can definately live without my cam for a bit. Thanks very much again. Ed 2009/7/8 Hans Petter Selasky > On Wednesday 08 July 2009 19:11:05 Ed Morgan wrote: > > Hi, > > > > Has anyone had any joy getting webcams that use the uvcvideo driver > working > > under FreeBSD? I'm looking at putting FreeBSD back on my laptop, and if > the > > webcam will work, that'll clinch it for me. Most of the results i've > found > > from trawling Google suggest that uvcvideo is basically not going to > work, > > but if anyone knows otherwise? > > > > Any advice would be greatly appreciated. > > > > Thanks very much. > > > > Ed > > There are several projects around, not finished yet, that are about porting > V4L to BSD. > > See thread "USB webcam++ support for FreeBSD-8-current is soon here". > > --HPS > -- Ed Morgan "Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats." - H. L. Mencken From owner-freebsd-usb@FreeBSD.ORG Thu Jul 9 15:21:02 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8E4B81065674; Thu, 9 Jul 2009 15:21:02 +0000 (UTC) (envelope-from kosmo@semihalf.com) Received: from smtp.semihalf.com (smtp.semihalf.com [213.17.239.109]) by mx1.freebsd.org (Postfix) with ESMTP id 40FC88FC1A; Thu, 9 Jul 2009 15:21:02 +0000 (UTC) (envelope-from kosmo@semihalf.com) Received: from [10.0.0.5] (cardhu.semihalf.com [213.17.239.108]) by smtp.semihalf.com (Postfix) with ESMTPSA id 92FACC3AAA; Thu, 9 Jul 2009 17:20:00 +0200 (CEST) From: Piotr =?iso-8859-2?q?Zi=EAcik?= Organization: Semihalf To: Hans Petter Selasky Date: Thu, 9 Jul 2009 17:21:00 +0200 User-Agent: PLD Linux KMail/1.9.10 References: <200906231035.43096.kosmo@semihalf.com> <200907081216.40100.kosmo@semihalf.com> <200907081250.58151.hselasky@c2i.net> In-Reply-To: <200907081250.58151.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200907091721.01272.kosmo@semihalf.com> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, thompsa@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 15:21:03 -0000 Wednesday 08 July 2009 12:50:56 Hans Petter Selasky napisa=B3(a): > By flush you mean write from CPU cache to RAM, right. And nothing else? Y= ou > don't mean discard CPU cache by "flush" ??? Yes. By flush I mean write all valid and modified cache lines to RAM. > > However looking into logs which I have sent you yesterdat I see one > > difference which may be significant. My patch changes Invalidate into > > Writeback Invalidate. In original code if driver write something to > > memory and then invalidate cache > > If that is the case I'm very surprised. Could you make another printout f= or > me. Compile the kernel with KDB, and add a call to "kdb_backtrace()" in > bus_dmamap_sync() before printing out the writeback and/or invalidate, so > that I can see the backtrace. > > > , the write will be lost. > > I'm aware about that. =46ull log with backtraces is here:=20 http://people.freebsd.org/~raj/logs/usb-cache.log > > With my patch after > > change will be written to memory and then cache will be invalidated. Wh= at > > do you think ? > > You are absoultely sure that your USB code is indentical to the now stock > 8- current USB code, and that there are no integration issues lurking? > I am using current from 2009.06.15. In later versions is bug in ARM pmap causing segmentation fault in ehci atatch code (for more details loot at http://www.nabble.com/pmap-problem-in-FreeBSD-current-td24352351.html). =2D-=20 Pozdrawiam. Piotr Zi=EAcik From owner-freebsd-usb@FreeBSD.ORG Thu Jul 9 15:23:14 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 36F9F106566C; Thu, 9 Jul 2009 15:23:14 +0000 (UTC) (envelope-from kosmo@semihalf.com) Received: from smtp.semihalf.com (smtp.semihalf.com [213.17.239.109]) by mx1.freebsd.org (Postfix) with ESMTP id E0BA48FC1D; Thu, 9 Jul 2009 15:23:13 +0000 (UTC) (envelope-from kosmo@semihalf.com) Received: from [10.0.0.5] (cardhu.semihalf.com [213.17.239.108]) by smtp.semihalf.com (Postfix) with ESMTPSA id 27497C3AAA; Thu, 9 Jul 2009 17:22:12 +0200 (CEST) From: Piotr =?iso-8859-2?q?Zi=EAcik?= Organization: Semihalf To: Sebastian Huber Date: Thu, 9 Jul 2009 17:23:12 +0200 User-Agent: PLD Linux KMail/1.9.10 References: <200906231035.43096.kosmo@semihalf.com> <200907081216.40100.kosmo@semihalf.com> <4A547556.4050801@embedded-brains.de> In-Reply-To: <4A547556.4050801@embedded-brains.de> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200907091723.13121.kosmo@semihalf.com> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, freebsd-usb@freebsd.org, thompsa@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 15:23:14 -0000 Wednesday 08 July 2009 12:30:46 Sebastian Huber napisa=B3(a): > Device to memory DMA transfer of a buffer: > (...) > 3. all accesses to the buffer via the cache must wait until the DMA has > finished And this is the problem in my oppinion - USB stack does not wait. =2D-=20 Best Regards. Piotr Zi=EAcik From owner-freebsd-usb@FreeBSD.ORG Thu Jul 9 15:35:38 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B845F1065680 for ; Thu, 9 Jul 2009 15:35:38 +0000 (UTC) (envelope-from nick@van-laarhoven.org) Received: from baranao.anywi.com (baranao.anywi.com [213.207.101.176]) by mx1.freebsd.org (Postfix) with ESMTP id 64C1C8FC17 for ; Thu, 9 Jul 2009 15:35:38 +0000 (UTC) (envelope-from nick@van-laarhoven.org) Received: from hind.van-laarhoven.org (ip51cfcfde.direct-adsl.nl [81.207.207.222]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by baranao.anywi.com (Postfix) with ESMTPSA id 1CACA3F41F for ; Thu, 9 Jul 2009 17:35:34 +0200 (CEST) From: Nick Hibma To: FreeBSD USB Mailing List Date: Thu, 9 Jul 2009 17:33:52 +0200 User-Agent: KMail/1.11.4 (FreeBSD/7.2-STABLE; KDE/4.2.4; i386; ; ) MIME-Version: 1.0 Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907091733.53664.nick@van-laarhoven.org> X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,UNPARSEABLE_RELAY autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on baranao.anywi.com Subject: ZTE devices X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 15:35:39 -0000 HPS, Not sure whether this is actually a problem, but you might want to have a look at the switch command for ZTE devices in the FBSD7 code base. it uses a ZTE specific command. The ZTE 636 device here switches properly using that command sequence. On another note, that device presents alternate interfaces, as in, interface 0 and 2 have alternates 1 and 3 resp. How does the new stack handle that? Can you set these alternates during attach? If so, you might want to do that for ZTE devices, as the alternates probably contain the additional serial ports. Below the descriptor dump for those devices. Nick DEVICE addr 2 DEVICE descriptor: bLength=18 bDescriptorType=device(1) bcdUSB=2.00 bDeviceClass=0 bDeviceSubClass=0 bDeviceProtocol=0 bMaxPacketSize=64 idVendor=0x19d2 idProduct=0x0031 bcdDevice=0 iManufacturer=2(ZTE, Incorporated) iProduct=1(ZTE CDMA Technologies MSM) iSerialNumber=3(1234567890ABCDEF) bNumConfigurations=1 CONFIGURATION descriptor 0: bLength=9 bDescriptorType=config(2) wTotalLength=256 bNumInterface=4 bConfigurationValue=1 iConfiguration=0() bmAttributes=a0 bMaxPower=500 mA INTERFACE descriptor 0: bLength=9 bDescriptorType=interface(4) bInterfaceNumber=0 bAlternateSetting=0 bNumEndpoints=0 bInterfaceClass=255 bInterfaceSubClass=255 bInterfaceProtocol=255 iInterface=0() Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=0 ... Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=21 ... Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=6 ... Unknown descriptor (class 255/255): bLength=21 bDescriptorType=36 bDescriptorSubtype=18 ... Unknown descriptor (class 255/255): bLength=6 bDescriptorType=36 bDescriptorSubtype=19 ... INTERFACE descriptor 1: bLength=9 bDescriptorType=interface(4) bInterfaceNumber=0 bAlternateSetting=1 bNumEndpoints=2 bInterfaceClass=255 bInterfaceSubClass=255 bInterfaceProtocol=255 iInterface=0() ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=1-in bmAttributes=bulk wMaxPacketSize=512 bInterval=32 ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=1-out bmAttributes=bulk wMaxPacketSize=512 bInterval=32 INTERFACE descriptor 2: bLength=9 bDescriptorType=interface(4) bInterfaceNumber=1 bAlternateSetting=0 bNumEndpoints=0 bInterfaceClass=255 bInterfaceSubClass=255 bInterfaceProtocol=255 iInterface=0() Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=0 ... Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=21 ... Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=6 ... Unknown descriptor (class 255/255): bLength=21 bDescriptorType=36 bDescriptorSubtype=18 ... Unknown descriptor (class 255/255): bLength=6 bDescriptorType=36 bDescriptorSubtype=19 ... INTERFACE descriptor 3: bLength=9 bDescriptorType=interface(4) bInterfaceNumber=1 bAlternateSetting=1 bNumEndpoints=2 bInterfaceClass=255 bInterfaceSubClass=255 bInterfaceProtocol=255 iInterface=0() ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=2-in bmAttributes=bulk wMaxPacketSize=512 bInterval=32 ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=2-out bmAttributes=bulk wMaxPacketSize=512 bInterval=32 INTERFACE descriptor 4: bLength=9 bDescriptorType=interface(4) bInterfaceNumber=2 bAlternateSetting=0 bNumEndpoints=2 bInterfaceClass=8 bInterfaceSubClass=6 bInterfaceProtocol=80 iInterface=0() ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=3-out bmAttributes=bulk wMaxPacketSize=512 bInterval=0 ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=3-in bmAttributes=bulk wMaxPacketSize=512 bInterval=0 INTERFACE descriptor 5: bLength=9 bDescriptorType=interface(4) bInterfaceNumber=3 bAlternateSetting=0 bNumEndpoints=3 bInterfaceClass=255 bInterfaceSubClass=255 bInterfaceProtocol=255 iInterface=0() Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=0 ... Unknown descriptor (class 255/255): bLength=4 bDescriptorType=36 bDescriptorSubtype=2 ... Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=1 ... Unknown descriptor (class 255/255): bLength=5 bDescriptorType=36 bDescriptorSubtype=6 ... Unknown descriptor (class 255/255): bLength=21 bDescriptorType=36 bDescriptorSubtype=18 ... Unknown descriptor (class 255/255): bLength=6 bDescriptorType=36 bDescriptorSubtype=19 ... ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=4-in bmAttributes=interrupt wMaxPacketSize=64 bInterval=5 ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=5-in bmAttributes=bulk wMaxPacketSize=512 bInterval=32 ENDPOINT descriptor: bLength=7 bDescriptorType=endpoint(5) bEndpointAddress=4-out bmAttributes=bulk wMaxPacketSize=512 bInterval=32 current configuration 1 ---------- From owner-freebsd-usb@FreeBSD.ORG Thu Jul 9 16:35:07 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A0E121065676; Thu, 9 Jul 2009 16:35:07 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe02.swip.net [212.247.154.33]) by mx1.freebsd.org (Postfix) with ESMTP id A70B58FC19; Thu, 9 Jul 2009 16:35:06 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=Hrwt8fWgTlIA:10 a=MXw7gxVQKqGXY79tIT8aFQ==:17 a=6I5d2MoRAAAA:8 a=9I5xiGouAAAA:8 a=3Fu2VmpGvCISSvz8iQMA:9 a=XGy9aEl_9vEWPm5gYIwA:7 a=LQzljaXy9EPa0d3N-Vp1QT03x7AA:4 Received: from [62.113.132.61] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe02.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 1283422939; Thu, 09 Jul 2009 18:35:04 +0200 From: Hans Petter Selasky To: Piotr =?iso-8859-2?q?Zi=EAcik?= Date: Thu, 9 Jul 2009 18:34:40 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: <200906231035.43096.kosmo@semihalf.com> <200907081250.58151.hselasky@c2i.net> <200907091721.01272.kosmo@semihalf.com> In-Reply-To: <200907091721.01272.kosmo@semihalf.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200907091834.42462.hselasky@c2i.net> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, thompsa@freebsd.org, freebsd-usb@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 16:35:08 -0000 Hi Piotr, On Thursday 09 July 2009 17:21:00 Piotr Zi=EAcik wrote: > Wednesday 08 July 2009 12:50:56 Hans Petter Selasky napisa=B3(a): > > By flush you mean write from CPU cache to RAM, right. And nothing else? > > You don't mean discard CPU cache by "flush" ??? > > Yes. By flush I mean write all valid and modified cache lines to RAM. > > > > However looking into logs which I have sent you yesterdat I see one > > > difference which may be significant. My patch changes Invalidate into > > > Writeback Invalidate. In original code if driver write something to > > > memory and then invalidate cache > > > > If that is the case I'm very surprised. Could you make another printout > > for me. Compile the kernel with KDB, and add a call to "kdb_backtrace()" > > in bus_dmamap_sync() before printing out the writeback and/or invalidat= e, > > so that I can see the backtrace. > > > > > , the write will be lost. > > > > I'm aware about that. > > Full log with backtraces is here: > http://people.freebsd.org/~raj/logs/usb-cache.log 1) My analysis: Only the data areas are being flushed/invalidated. No trans= fer=20 descriptors are flushed/invalidated. I see no cache operations happening on= =20 any DMA control structures, even though there are calls from EHCI to=20 xxx_pc_flush() and xxx_pc_invalidate(). One patch you can try is to add an additional unload call to=20 "usbd_transfer_setup_sub_malloc()": =3D=3D=3D=3D //depot/projects/usb/src/sys/dev/usb/usb_transfer.c#159 -=20 /home/hans_other/usb.p4/src/sys/dev/usb/usb_transfer.c =3D=3D=3D=3D @@ -268,6 +268,10 @@ pg, z, align)) { return (1); /* failure */ } + + bus_dmamap_unload(parm->dma_page_cache_ptr->tag, + parm->dma_page_cache_ptr->map); + /* Set beginning of current buffer */ buf =3D parm->dma_page_cache_ptr->buffer; /* Make room for one DMA page cache and one page */ This will avoid the same memory area being loaded twice. Not sure if there = is=20 still a bug in pmap about this! 2) You can also try to remove the "BUS_DMA_COHERENT" flag from "usb_busdma.= c". My time is limited today, because I have to work on libusb v1.0 support. Could you provide a new trace, showing an enumeration failure. In your=20 previous trace there was no error, because the printouts probably caused to= =20 CPU to flush out its cache. Debug details: /boot/loader.conf hw.usb.debug=3D15 hw.usb.ehci.debug=3D15 hw.usb.ohci.debug=3D15 hw.usb.uhci.debug=3D15 > I am using current from 2009.06.15. In later versions is bug in ARM pmap > causing segmentation fault in ehci atatch code (for more details loot at > http://www.nabble.com/pmap-problem-in-FreeBSD-current-td24352351.html). Ok. I have a feeling we will soon figure out the problem. =2D-HPS From owner-freebsd-usb@FreeBSD.ORG Thu Jul 9 16:39:50 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E94FC106567D for ; Thu, 9 Jul 2009 16:39:50 +0000 (UTC) (envelope-from bounces+305227.47129465.578549@icpbounce.com) Received: from smtp2.icpbounce.com (smtp2.icpbounce.com [216.27.93.124]) by mx1.freebsd.org (Postfix) with ESMTP id 887DD8FC2A for ; Thu, 9 Jul 2009 16:39:48 +0000 (UTC) (envelope-from bounces+305227.47129465.578549@icpbounce.com) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp2.icpbounce.com (Postfix) with ESMTP id 718B0F87DA for ; Thu, 9 Jul 2009 12:15:46 -0400 (EDT) Date: Thu, 9 Jul 2009 12:15:46 -0400 To: freebsd-usb@freebsd.org From: Global Access Travel Message-ID: X-Priority: 3 X-Mailer: PHPMailer [version 1.72] Errors-To: bounces+305227.47129465.578549@icpbounce.com X-List-Unsubscribe: X-Unsubscribe-Web: X-ICPINFO: X-Return-Path-Hint: bounces+305227.47129465.578549@icpbounce.com MIME-Version: 1.0 Content-Type: text/plain; charset = "utf-8" Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Fam Trip to TURKEY for $999 (Refundable) X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 16:39:52 -0000 [http://www.turkeycallingus.com/] Exclusive Boutique Enterprise Turkey FAM ISTANBUL - CAPPADOCIA - KONYA - ANTALYA - PAMUKKALE - KUSADASI 9 Nights / 11 Days $999 • 5 Continents • 150 Countries Worldwide • 100.000 Hotels • Instant Confirmation [http://www.turkeycallingus.com] [http://www.turkeycallingus.com/turkey-fam/TurkeyFam.htm] [http://www.turkeycallingus.com/turkey-fam/TurkeyFamItinerary.htm] [http://www.turkeycallingus.com/turkey-fam/TurkeyFamRates.htm] [http://www.turkeycallingus.com/turkey-fam/TurkeyFamServices.htm] [http://www.turkeycallingus.com/turkey-fam/TurkeyFamHotels.htm] Global Access proudly presents the biggest FAM Trip of the year, teaming with Turkish Airlines and Turkish Ministry of Tourism and Culture. As the host of ASTA IDE 2010 and European Capital of Culture 2010, Turkey is likely to be the one of the most popular destinations in 2010. Those who act early and get to know this beautiful country better will be able to give a better insight to their clients and secure more bookings. Our specially selected travel agents will stay in best hotels in each town, be escorted by professional, top tour guides, taste exceptionally good examples of Turkish Cuisine, and get to know Turkey in elegant way. Join us for a luxury FAM adventure and be our special guest in our beautiful country! COMBINE WITH World Travel Market! One of the biggest travel shows of Europe and the world, WTM, will be held in London between 9-12 November 2009. Combine your London trip with Turkey and benefit from great agent rates to see one of the most popular tourist destinations from USA and Canada. WE WILL REFUND YOUR MONEY BACK ! Upon booking your 20th passenger on a Global Access Travel Service, we will refund you the whole tour price that you’ve paid for the FAM Trip. If you book 20 or more people on a Global Access Travel Service before the FAM Trip starts, then you will travel for free! About Us Global Access Travel (GA) was founded in Turkey by a group of tourism professionals and marketing experts who recognized the needs to offer online services for accommodations, car rentals, and other travel related services to travel agencies. Through its sophisticated online reservation services, GA offers more than 100,000 hotels, motels, resorts, clubs and apartments all around the world. Other services of GA include car rentals, transfers, special tours, luxury services, city breaks, flight tickets and other services such as tailor made tour packages, exhibition organizations, incentives and other travel related services around the globe at competitive rates. [http://www.TurkeyCallingus.com] www.TurkeyCalling.us [http://www.turkeycallingus.com/turkey-calling-contact-us.htm] Global Access Travel Tel: +90 212 258 58 29 Fax: +90 212 258 34 47 E-mail : [mailto:incoming@gaturkey.com] incoming@gaturkey.com Website: [http://www.turkeycallingus.com/] www.TurkeyCalling.Us This message was sent by: FamTrit turkey, Nüzhetiye Cad., istanbul, besiktas 34357, Turkey To be removed click here: http://app.icontact.com/icp/mmail-mprofile.pl?r=47129465&l=82243&s=HQ2R&m=578549&c=305227 Forward to a friend: http://app.icontact.com/icp/sub/forward?m=578549&s=47129465&c=HQ2R&cid=305227 From owner-freebsd-usb@FreeBSD.ORG Thu Jul 9 16:46:03 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A06DE1065672; Thu, 9 Jul 2009 16:46:03 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe10.tele2.se [212.247.155.33]) by mx1.freebsd.org (Postfix) with ESMTP id D09278FC0A; Thu, 9 Jul 2009 16:46:02 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=Hrwt8fWgTlIA:10 a=MXw7gxVQKqGXY79tIT8aFQ==:17 a=6I5d2MoRAAAA:8 a=CB5tFlUBj5lX0kOYFHwA:9 a=lPvmI1w4oMshsF84DFMlSaN-tz0A:4 Received: from [62.113.132.61] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe10.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 1105609322; Thu, 09 Jul 2009 18:46:01 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org Date: Thu, 9 Jul 2009 18:45:39 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: <200906231035.43096.kosmo@semihalf.com> <200907091721.01272.kosmo@semihalf.com> <200907091834.42462.hselasky@c2i.net> In-Reply-To: <200907091834.42462.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-2" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907091845.40515.hselasky@c2i.net> Cc: Rafal Jaworowski , freebsd-arm@freebsd.org, thompsa@freebsd.org Subject: Re: CPU Cache and busdma usage in USB X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 16:46:04 -0000 On Thursday 09 July 2009 18:34:40 Hans Petter Selasky wrote: > > Full log with backtraces is here: > > http://people.freebsd.org/~raj/logs/usb-cache.log > > 1) My analysis: Only the data areas are being flushed/invalidated. I also see that the flushing/invalidating is being done correctly. --HPS From owner-freebsd-usb@FreeBSD.ORG Thu Jul 9 17:31:34 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C7C7D106566B for ; Thu, 9 Jul 2009 17:31:34 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe07.swip.net [212.247.154.193]) by mx1.freebsd.org (Postfix) with ESMTP id 5D7F58FC18 for ; Thu, 9 Jul 2009 17:31:34 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=MXw7gxVQKqGXY79tIT8aFQ==:17 a=kNKxU6IRFeM57lXOwdEA:9 a=q68oui0cBWMRklgh5RbQJOBqQ7oA:4 Received: from [62.113.132.61] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe07.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 1271482622; Thu, 09 Jul 2009 19:31:33 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org Date: Thu, 9 Jul 2009 19:31:09 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: <200907091733.53664.nick@van-laarhoven.org> In-Reply-To: <200907091733.53664.nick@van-laarhoven.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907091931.10975.hselasky@c2i.net> Cc: Subject: Re: ZTE devices X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 17:31:35 -0000 On Thursday 09 July 2009 17:33:52 Nick Hibma wrote: > HPS, > > Not sure whether this is actually a problem, but you might want to have a > look at the switch command for ZTE devices in the FBSD7 code base. it uses > a ZTE specific command. The ZTE 636 device here switches properly using > that command sequence. > > On another note, that device presents alternate interfaces, as in, > interface 0 and 2 have alternates 1 and 3 resp. How does the new stack > handle that? Can you set these alternates during attach? If so, you might > want to do that for ZTE devices, as the alternates probably contain the > additional serial ports. > > Below the descriptor dump for those devices. > > Nick > Hi, The 8-current u3g driver does not consider alternate settings. If that is a problem please suggest a patch. --HPS From owner-freebsd-usb@FreeBSD.ORG Thu Jul 9 23:59:17 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DF3EC106564A for ; Thu, 9 Jul 2009 23:59:16 +0000 (UTC) (envelope-from sent2400@respread.com) Received: from smtp20.respread.com (smtp20.respread.com [66.252.230.170]) by mx1.freebsd.org (Postfix) with ESMTP id 9057F8FC21 for ; Thu, 9 Jul 2009 23:59:16 +0000 (UTC) (envelope-from sent2400@respread.com) Received: from ds1183 ([204.10.77.183]) by smtp20.respread.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 9 Jul 2009 18:59:22 -0500 From: "WORLD CROWN ELECTRONICS LTD" To: "freebsd-usb@freebsd.org" Date: Thu, 09 Jul 2009 18:59:14 -0500 MIME-Version: 1.0 X-Mailer: aspNetEmail ver 3.6.0.67 X-Spread-CampaignId: 25823 X-Spread-SubscriberId: 7647985 X-Spread-SpreaderId: 2400 Message-ID: X-OriginalArrivalTime: 09 Jul 2009 23:59:22.0196 (UTC) FILETIME=[479B5140:01CA00F1] Content-Type: text/plain; charset="gb2312" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: USB Flash Drive 1GB at USD4.65 1K PCS FD262 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: sales@worldcrown.net List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 23:59:17 -0000 =0D=0D Promotional gift with YOUR OWN LOGO =0D=0D USB Flash Drive= 1GB at USD4=2E65 1K PCS FD262 =0D=0D ( http://rs-tr=2Ecom//t=2Easpx/sub= id/7647985/camid/25823/www=2Eworldcrown=2Enet/product_info=2Easp?id=3D529= ) ( http://rs-tr=2Ecom//t=2Easpx/subid/7647985/camid/25823/worldcrown=2E= net/product_info=2Easp?id=3D539 ) ( http://rs-tr=2Ecom//t=2Easpx/subid/76= 47985/camid/25823/httpsgjf34ewww=2Ereasonablespread=2Ecom/Management/Camp= aign/AddCampaignContent=2Easpx?campaign_id=3D15518 ) =09 ( http://rs-tr=2E= com//t=2Easpx/subid/7647985/camid/25823/worldcrown=2Enet/product_info=2Ea= sp?id=3D592 ) =09 ( http://rs-tr=2Ecom//t=2Easpx/subid/7647985/camid/2582= 3/www=2Eam730=2Ecom=2Ehk/ ) =0D=0DFD311 =09=0D=0DFD262 =09=0D=0DFD3= 06 =0D=0D=09 =09=0D=0D=09 FD306 =09 = FD309 =09=0D=0D FD308 =0D=0D= =09 =09=0D=0D=09 FD288 =09 FD10= 5 =09=0D=0D FD212A =0D=0DFor more product de= tails, please visit http://worldcrown=2Enet ( http://rs-tr=2Ecom//t=2Easp= x/subid/7647985/camid/25823/worldcrown=2Enet/ ) =0D=0DPlease tell me yo= ur MSN or Skype so we can discuss directly=2E My MSN is world=2Ecrown=40h= otmail=2Ecom ( ) and Skype is sales3_worldcrown=2Enet =0D=0DMs Li ______= ___________________ Direct Line: (852) 31870298 , Email: li=40worldcrown= =2Enet ( ), Skype: sales3_worldcrown=2Enet, MSN: world=2Ecrown=40hotmail= =2Ecom ( ) =0D=0DWORLD CROWN ELECTRONICS LTD =0D=0DHong Kong =0D=0DOff= ice =26 Showroom: Unit 371-374, 3/F=2E, Sino Industrial Plaza, 9 Kai Cheu= ng Road, Kowloon Bay, Kowloon, Hong Kong =0D=0DTel: (852) 3187 0228 (18 = Lines) Fax:(852) 2155 0985 (3 Lines) =0D=0DChina =0D=0DOffice Addres= s: Unit A516, Automobile Building, 45 Zhenhua Road, Futian District, Shen= zhen, China Factory Adddress: 6/F=2E, B7 Building, Xujingchang Industry = Park, Fuyuanyi Road, Xinhe Community, Fuyong Street, Bao An District, She= nzhen, China=2E =0D=0D=09 =09=09 =09=0D=0D=09 =09=09 =09=0D=0D=09 =09=09= =09=0D=0D=09 =09=09 =09=0D=0DThey trust and rely on us with their import= ant promotional projects=2E How about you? Please make your first step to= contact our sales department=2E You are ensured that your requirements w= ill be our first priority=2E =0D=0DForward this email ( http://rs-ar=2E= com/2400-25823/=2Enewsletter/USB_Flash_Drive_1GB_at_USD4=2E65_1K_PCS_FD26= 2/forward=2Easpx )=0D=0D=09 Update Email =26 Profile ( http://rs-sub=2Eco= m/SubscribeFormDetail=2Easpx?ens=3DsdUASjfpOA7IYYkm5rnZ6Q=3D=3D=26type=3D= profile ) =7C Unsubscribe ( http://rs-sub=2Ecom/Unsubscribe=2Easpx?sub=3D= 7647985=26user=3D2400=26campid=3D25823=26type=3Dp ) =09 ( http://rs-w=2E= com/about=2Easpx?subid=3D7647985=26campid=3D25823 ) From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 07:26:03 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8C541106564A for ; Fri, 10 Jul 2009 07:26:03 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) Received: from zivm-out1.uni-muenster.de (ZIVM-OUT1.UNI-MUENSTER.DE [128.176.192.8]) by mx1.freebsd.org (Postfix) with ESMTP id 249DF8FC17 for ; Fri, 10 Jul 2009 07:26:02 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) X-IronPort-AV: E=Sophos;i="4.42,377,1243807200"; d="scan'208";a="276829374" Received: from zivmaildisp2.uni-muenster.de (HELO ZIVMAILUSER05.UNI-MUENSTER.DE) ([128.176.188.143]) by zivm-relay1.uni-muenster.de with ESMTP; 10 Jul 2009 09:26:01 +0200 Received: by ZIVMAILUSER05.UNI-MUENSTER.DE (Postfix, from userid 149459) id 3FF5E1B07E4; Fri, 10 Jul 2009 09:26:01 +0200 (CEST) Date: Fri, 10 Jul 2009 09:26:00 +0200 (CEST) From: Alexander Best Sender: Organization: Westfaelische Wilhelms-Universitaet Muenster To: Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: settings usb mouse rate X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 07:26:03 -0000 i found this very cool PR http://www.freebsd.org/cgi/query-pr.cgi?pr=usb/125264 and wanted to ask if there's a way of changing the rate of usb mice with the new usb2 stack? what about the `moused` switches -r and -F? do they work with usb mice? alex From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 09:05:50 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AC2B01065677 for ; Fri, 10 Jul 2009 09:05:50 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) Received: from zivm-out3.uni-muenster.de (ZIVM-OUT3.UNI-MUENSTER.DE [128.176.192.18]) by mx1.freebsd.org (Postfix) with ESMTP id 43C328FC24 for ; Fri, 10 Jul 2009 09:05:50 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) X-IronPort-AV: E=Sophos;i="4.42,377,1243807200"; d="scan'208";a="8071598" Received: from zivmaildisp2.uni-muenster.de (HELO ZIVMAILUSER05.UNI-MUENSTER.DE) ([128.176.188.143]) by zivm-relay3.uni-muenster.de with ESMTP; 10 Jul 2009 11:05:48 +0200 Received: by ZIVMAILUSER05.UNI-MUENSTER.DE (Postfix, from userid 149459) id C92271B07E4; Fri, 10 Jul 2009 11:05:48 +0200 (CEST) Date: Fri, 10 Jul 2009 11:05:48 +0200 (CEST) From: Alexander Best Sender: Organization: Westfaelische Wilhelms-Universitaet Muenster To: Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: detaching usb device without unmounting it X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 09:05:50 -0000 since the usb2 stack allows one to detach a mounted usb device without the kernel panic'ing i'd like to know which steps are necessary to be taken after detaching a device? because i tried the following: 1. attach device 2. mount device 3. detach device when i tried to unmount the device i got the follwing error message: g_vfs_done():label/usb[WRITE(offset=19456, length=4096)]error = 6 and the console got locked up (ctr+c didn't work). so i tried to reboot using ctrl+alt+del. however after the message: "All buffers synced" there was no reboot. so i had to do a hard reset. however after the reset freebsd fsck'ed my harddrives. so they didn't unmount properly. should i have used `umount -f`? or just plug the device back in again? or isn't it possible to unmount a device that has already been detached? i'm running r195476 btw. alex From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 13:40:16 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 36560106566C for ; Fri, 10 Jul 2009 13:40:16 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe03.swip.net [212.247.154.65]) by mx1.freebsd.org (Postfix) with ESMTP id BCA3B8FC13 for ; Fri, 10 Jul 2009 13:40:15 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=gg2W7PyvkLb8p4ie143lBA==:17 a=6I5d2MoRAAAA:8 a=NE6UDB5IPtqui6qlAt4A:9 a=wNqKT02DMemIY_F0AjkA:7 a=Az21E67KWBFUsp-DLzpMGmW5dNkA:4 Received: from [194.248.135.20] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe03.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 1282713812; Fri, 10 Jul 2009 15:40:14 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org Date: Fri, 10 Jul 2009 15:39:53 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907101539.54682.hselasky@c2i.net> Cc: Alexander Best Subject: Re: settings usb mouse rate X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 13:40:16 -0000 On Friday 10 July 2009 09:26:00 Alexander Best wrote: > i found this very cool PR > http://www.freebsd.org/cgi/query-pr.cgi?pr=usb/125264 and wanted to ask if > there's a way of changing the rate of usb mice with the new usb2 stack? > > what about the `moused` switches -r and -F? do they work with usb mice? > I think this patch is not included in 8-current. I might put a modified patch in. Remind me about it next week and I'll see about getting it done! --HPS From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 13:41:38 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B24AF106564A; Fri, 10 Jul 2009 13:41:38 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe10.swip.net [212.247.155.33]) by mx1.freebsd.org (Postfix) with ESMTP id 197B88FC1D; Fri, 10 Jul 2009 13:41:37 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=W4yUWwPuJRMA:10 a=gg2W7PyvkLb8p4ie143lBA==:17 a=6I5d2MoRAAAA:8 a=CoTBo_Zjxy5KCONG29UA:9 a=w2JCi8v50dWtrkD0lxoA:7 a=SV94tEyFvL4lw_EyKiQKwkPS-NsA:4 a=SV7veod9ZcQA:10 Received: from [194.248.135.20] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe10.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 1106224194; Fri, 10 Jul 2009 15:41:36 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org, freebsd-current@freebsd.org Date: Fri, 10 Jul 2009 15:41:15 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907101541.16698.hselasky@c2i.net> Cc: Alexander Best Subject: Re: detaching usb device without unmounting it X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 13:41:39 -0000 This is not an USB issue. Try -current. --HPS On Friday 10 July 2009 11:05:48 Alexander Best wrote: > since the usb2 stack allows one to detach a mounted usb device without the > kernel panic'ing i'd like to know which steps are necessary to be taken > after detaching a device? because i tried the following: > > 1. attach device > 2. mount device > 3. detach device > > when i tried to unmount the device i got the follwing error message: > > g_vfs_done():label/usb[WRITE(offset=19456, length=4096)]error = 6 > > and the console got locked up (ctr+c didn't work). so i tried to reboot > using ctrl+alt+del. however after the message: "All buffers synced" there > was no reboot. so i had to do a hard reset. however after the reset freebsd > fsck'ed my harddrives. so they didn't unmount properly. > > should i have used `umount -f`? or just plug the device back in again? or > isn't it possible to unmount a device that has already been detached? > > i'm running r195476 btw. > > alex > _______________________________________________ > freebsd-usb@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-usb > To unsubscribe, send any mail to "freebsd-usb-unsubscribe@freebsd.org" From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 13:46:26 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CCB1A1065679; Fri, 10 Jul 2009 13:46:26 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) Received: from zivm-out1.uni-muenster.de (ZIVM-OUT1.UNI-MUENSTER.DE [128.176.192.8]) by mx1.freebsd.org (Postfix) with ESMTP id 3441B8FC26; Fri, 10 Jul 2009 13:46:25 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) X-IronPort-AV: E=Sophos;i="4.42,378,1243807200"; d="scan'208";a="276859850" Received: from zivmaildisp2.uni-muenster.de (HELO ZIVMAILUSER05.UNI-MUENSTER.DE) ([128.176.188.143]) by zivm-relay1.uni-muenster.de with ESMTP; 10 Jul 2009 15:46:24 +0200 Received: by ZIVMAILUSER05.UNI-MUENSTER.DE (Postfix, from userid 149459) id 5C4111B07E4; Fri, 10 Jul 2009 15:46:24 +0200 (CEST) Date: Fri, 10 Jul 2009 15:46:24 +0200 (CEST) From: Alexander Best Sender: Organization: Westfaelische Wilhelms-Universitaet Muenster To: Hans Petter Selasky , , Message-ID: In-Reply-To: <200907101541.16698.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: Subject: Re: detaching usb device without unmounting it X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 13:46:27 -0000 actually i'm running current: FreeBSD otaku 8.0-BETA1 FreeBSD 8.0-BETA1 #0 r195534: Fri Jul 10 11:52:48 CEST 2009 root@otaku:/usr/obj/usr/src/sys/ARUNDEL i386 updated my kernel sources a few hours ago. should i report this to the freebsd-current@ list then? alex Hans Petter Selasky schrieb am 2009-07-10: > This is not an USB issue. > Try -current. > --HPS > On Friday 10 July 2009 11:05:48 Alexander Best wrote: > > since the usb2 stack allows one to detach a mounted usb device > > without the > > kernel panic'ing i'd like to know which steps are necessary to be > > taken > > after detaching a device? because i tried the following: > > 1. attach device > > 2. mount device > > 3. detach device > > when i tried to unmount the device i got the follwing error > > message: > > g_vfs_done():label/usb[WRITE(offset=19456, length=4096)]error = 6 > > and the console got locked up (ctr+c didn't work). so i tried to > > reboot > > using ctrl+alt+del. however after the message: "All buffers synced" > > there > > was no reboot. so i had to do a hard reset. however after the reset > > freebsd > > fsck'ed my harddrives. so they didn't unmount properly. > > should i have used `umount -f`? or just plug the device back in > > again? or > > isn't it possible to unmount a device that has already been > > detached? > > i'm running r195476 btw. > > alex > > _______________________________________________ > > freebsd-usb@freebsd.org mailing list > > http://lists.freebsd.org/mailman/listinfo/freebsd-usb > > To unsubscribe, send any mail to > > "freebsd-usb-unsubscribe@freebsd.org" From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 13:48:02 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D1402106566C; Fri, 10 Jul 2009 13:48:02 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) Received: from zivm-out1.uni-muenster.de (ZIVM-OUT1.UNI-MUENSTER.DE [128.176.192.8]) by mx1.freebsd.org (Postfix) with ESMTP id 3B9228FC16; Fri, 10 Jul 2009 13:48:02 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) X-IronPort-AV: E=Sophos;i="4.42,378,1243807200"; d="scan'208";a="276859969" Received: from zivmaildisp2.uni-muenster.de (HELO ZIVMAILUSER05.UNI-MUENSTER.DE) ([128.176.188.143]) by zivm-relay1.uni-muenster.de with ESMTP; 10 Jul 2009 15:48:01 +0200 Received: by ZIVMAILUSER05.UNI-MUENSTER.DE (Postfix, from userid 149459) id 5555B1B07E4; Fri, 10 Jul 2009 15:48:01 +0200 (CEST) Date: Fri, 10 Jul 2009 15:48:01 +0200 (CEST) From: Alexander Best Sender: Organization: Westfaelische Wilhelms-Universitaet Muenster To: Hans Petter Selasky , , Message-ID: In-Reply-To: <200907101541.16698.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: Subject: Re: detaching usb device without unmounting it X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 13:48:03 -0000 oh. i just did. ;-) didn't see you put freebsd-current@ in the "To:" field. alex Hans Petter Selasky schrieb am 2009-07-10: > This is not an USB issue. > Try -current. > --HPS > On Friday 10 July 2009 11:05:48 Alexander Best wrote: > > since the usb2 stack allows one to detach a mounted usb device > > without the > > kernel panic'ing i'd like to know which steps are necessary to be > > taken > > after detaching a device? because i tried the following: > > 1. attach device > > 2. mount device > > 3. detach device > > when i tried to unmount the device i got the follwing error > > message: > > g_vfs_done():label/usb[WRITE(offset=19456, length=4096)]error = 6 > > and the console got locked up (ctr+c didn't work). so i tried to > > reboot > > using ctrl+alt+del. however after the message: "All buffers synced" > > there > > was no reboot. so i had to do a hard reset. however after the reset > > freebsd > > fsck'ed my harddrives. so they didn't unmount properly. > > should i have used `umount -f`? or just plug the device back in > > again? or > > isn't it possible to unmount a device that has already been > > detached? > > i'm running r195476 btw. > > alex > > _______________________________________________ > > freebsd-usb@freebsd.org mailing list > > http://lists.freebsd.org/mailman/listinfo/freebsd-usb > > To unsubscribe, send any mail to > > "freebsd-usb-unsubscribe@freebsd.org" From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 13:49:02 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AB2661065686 for ; Fri, 10 Jul 2009 13:49:02 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) Received: from zivm-out1.uni-muenster.de (ZIVM-OUT1.UNI-MUENSTER.DE [128.176.192.8]) by mx1.freebsd.org (Postfix) with ESMTP id 3D4938FC14 for ; Fri, 10 Jul 2009 13:49:01 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) X-IronPort-AV: E=Sophos;i="4.42,378,1243807200"; d="scan'208";a="276860036" Received: from zivmaildisp2.uni-muenster.de (HELO ZIVMAILUSER05.UNI-MUENSTER.DE) ([128.176.188.143]) by zivm-relay1.uni-muenster.de with ESMTP; 10 Jul 2009 15:48:49 +0200 Received: by ZIVMAILUSER05.UNI-MUENSTER.DE (Postfix, from userid 149459) id 34F381B07E4; Fri, 10 Jul 2009 15:48:49 +0200 (CEST) Date: Fri, 10 Jul 2009 15:48:49 +0200 (CEST) From: Alexander Best Sender: Organization: Westfaelische Wilhelms-Universitaet Muenster To: Hans Petter Selasky , Message-ID: In-Reply-To: <200907101539.54682.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: Subject: Re: settings usb mouse rate X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 13:49:03 -0000 ok. thanks. alex Hans Petter Selasky schrieb am 2009-07-10: > On Friday 10 July 2009 09:26:00 Alexander Best wrote: > > i found this very cool PR > > http://www.freebsd.org/cgi/query-pr.cgi?pr=usb/125264 and wanted to > > ask if > > there's a way of changing the rate of usb mice with the new usb2 > > stack? > > what about the `moused` switches -r and -F? do they work with usb > > mice? > I think this patch is not included in 8-current. I might put a > modified patch > in. Remind me about it next week and I'll see about getting it done! > --HPS From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 14:11:44 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6A8AE106566C for ; Fri, 10 Jul 2009 14:11:44 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 27FF78FC08 for ; Fri, 10 Jul 2009 14:11:44 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from localhost (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id n6AE8p9f093447; Fri, 10 Jul 2009 08:08:51 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Fri, 10 Jul 2009 08:09:32 -0600 (MDT) Message-Id: <20090710.080932.439672019.imp@bsdimp.com> To: alexbestms@math.uni-muenster.de From: "M. Warner Losh" In-Reply-To: References: X-Mailer: Mew version 5.2 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-usb@freebsd.org Subject: Re: detaching usb device without unmounting it X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 14:11:44 -0000 In message: Alexander Best writes: : since the usb2 stack allows one to detach a mounted usb device without the : kernel panic'ing usb1 allowed that too. the problem rarely was inside the usb stack (although there were some problems). The problem was at the higher levels of cam, the buffer cache and the file system. There were changes scattered throughout the rest of the system to allow devices to suddenly disappear. All usb2 did was fix a few edge cases in usb. : i'd like to know which steps are necessary to be taken after : detaching a device? because i tried the following: : : 1. attach device : 2. mount device : 3. detach device : : when i tried to unmount the device i got the follwing error message: : : g_vfs_done():label/usb[WRITE(offset=19456, length=4096)]error = 6 The proper action is limited to 'umount -f'. You can't reattach it, you can't really touch any files in the system (some cached files might be ok), you certainly can't write to it. : and the console got locked up (ctr+c didn't work). so i tried to reboot using : ctrl+alt+del. however after the message: "All buffers synced" there was no : reboot. so i had to do a hard reset. however after the reset freebsd fsck'ed : my harddrives. so they didn't unmount properly. : : should i have used `umount -f`? or just plug the device back in again? or : isn't it possible to unmount a device that has already been detached? You should have done an umount -f. You can't plug it back in again because we don't have support at the right levels (CAM(?), GEOM, buffer cache, fs) to allow previously orphaned resources to be reconnected to a new device. The device was destroyed, and data was destroyed with it... Warner From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 14:38:08 2009 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EF0B4106564A; Fri, 10 Jul 2009 14:38:08 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) Received: from zivm-out3.uni-muenster.de (ZIVM-OUT3.UNI-MUENSTER.DE [128.176.192.18]) by mx1.freebsd.org (Postfix) with ESMTP id 5607F8FC15; Fri, 10 Jul 2009 14:38:08 +0000 (UTC) (envelope-from a_best01@uni-muenster.de) X-IronPort-AV: E=Sophos;i="4.42,378,1243807200"; d="scan'208";a="8096947" Received: from zivmaildisp2.uni-muenster.de (HELO ZIVMAILUSER01.UNI-MUENSTER.DE) ([128.176.188.143]) by zivm-relay3.uni-muenster.de with ESMTP; 10 Jul 2009 16:38:06 +0200 Received: by ZIVMAILUSER01.UNI-MUENSTER.DE (Postfix, from userid 149459) id CD2751B0764; Fri, 10 Jul 2009 16:38:06 +0200 (CEST) Date: Fri, 10 Jul 2009 16:38:06 +0200 (CEST) From: Alexander Best Sender: Organization: Westfaelische Wilhelms-Universitaet Muenster To: "M. Warner Losh" Message-ID: In-Reply-To: <20090710.080932.439672019.imp@bsdimp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-current@freebsd.org, freebsd-usb@freebsd.org Subject: Re: detaching usb device without unmounting it X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 14:38:09 -0000 hmmm...i just tried that: 1. attach the device 2. mount the device @ mnt/umass 3. detach the device 4. do `umount -f /mnt/umass` i got the same error message i got when not using the f switch. also i forget to mention this lor: Jul 10 16:26:24 otaku kernel: lock order reversal: Jul 10 16:26:24 otaku kernel: 1st 0xc81569c0 ufs (ufs) @ /usr/src/sys/kern/vfs_mount.c:1199 Jul 10 16:26:24 otaku kernel: 2nd 0xc8dec9c0 devfs (devfs) @ /usr/src/sys/fs/msdosfs/msdosfs_vfsops.c:944 Jul 10 16:26:24 otaku kernel: KDB: stack backtrace: Jul 10 16:26:24 otaku kernel: db_trace_self_wrapper(c07d787b,ea61ca3c,c0609a25,c05fa4db,c07da81e,...) at db_trace_self_wrapper+0x26 Jul 10 16:26:24 otaku kernel: kdb_backtrace(c05fa4db,c07da81e,c78f0bc0,c78f0af0,ea61ca98,...) at kdb_backtrace+0x29 Jul 10 16:26:24 otaku kernel: _witness_debugger(c07da81e,c8dec9c0,c07c9650,c78f0af0,c07c9f08,...) at _witness_debugger+0x25 Jul 10 16:26:24 otaku kernel: witness_checkorder(c8dec9c0,9,c07c9f08,3b0,c8deca28,...) at witness_checkorder+0x839 Jul 10 16:26:24 otaku kernel: __lockmgr_args(c8dec9c0,80400,c8deca28,0,0,...) at __lockmgr_args+0x7b7 Jul 10 16:26:24 otaku kernel: vop_stdlock(ea61cba0,c09abbc8,c8a8ee24,80400,c8dec968,...) at vop_stdlock+0x68 Jul 10 16:26:24 otaku kernel: VOP_LOCK1_APV(c0820980,ea61cba0,ea61cbc0,c0853f80,c8dec968,...) at VOP_LOCK1_APV+0xb5 Jul 10 16:26:24 otaku kernel: _vn_lock(c8dec968,80400,c07c9f08,3b0,c7ea35a0,...) at _vn_lock+0x78 Jul 10 16:26:24 otaku kernel: msdosfs_sync(c7ea35a0,1,ea61cc38,4f4,80,...) at msdosfs_sync+0x29c Jul 10 16:26:24 otaku kernel: dounmount(c7ea35a0,8080000,c8a8ed80,479,1,...) at dounmount+0x44e Jul 10 16:26:24 otaku kernel: unmount(c8a8ed80,ea61ccf8,8,65,c,...) at unmount+0x2bf Jul 10 16:26:24 otaku kernel: syscall(ea61cd38) at syscall+0x2a6 Jul 10 16:26:24 otaku kernel: Xint0x80_syscall() at Xint0x80_syscall+0x20 Jul 10 16:26:24 otaku kernel: --- syscall (22, FreeBSD ELF32, unmount), eip = 0x280d730f, esp = 0xbfbfe4bc, ebp = 0xbfbfe588 --- again i can't get back to the shell using ctrl+c. switching to another console and issuing a reboot stalls at the very same point. alex M. Warner Losh schrieb am 2009-07-10: > In message: > > Alexander Best writes: > : since the usb2 stack allows one to detach a mounted usb device > without the > : kernel panic'ing > usb1 allowed that too. the problem rarely was inside the usb stack > (although there were some problems). The problem was at the higher > levels of cam, the buffer cache and the file system. There were > changes scattered throughout the rest of the system to allow devices > to suddenly disappear. All usb2 did was fix a few edge cases in usb. > : i'd like to know which steps are necessary to be taken after > : detaching a device? because i tried the following: > : > : 1. attach device > : 2. mount device > : 3. detach device > : > : when i tried to unmount the device i got the follwing error > message: > : > : g_vfs_done():label/usb[WRITE(offset=19456, length=4096)]error = 6 > The proper action is limited to 'umount -f'. You can't reattach it, > you can't really touch any files in the system (some cached files > might be ok), you certainly can't write to it. > : and the console got locked up (ctr+c didn't work). so i tried to > reboot using > : ctrl+alt+del. however after the message: "All buffers synced" there > was no > : reboot. so i had to do a hard reset. however after the reset > freebsd fsck'ed > : my harddrives. so they didn't unmount properly. > : > : should i have used `umount -f`? or just plug the device back in > again? or > : isn't it possible to unmount a device that has already been > detached? > You should have done an umount -f. You can't plug it back in again > because we don't have support at the right levels (CAM(?), GEOM, > buffer cache, fs) to allow previously orphaned resources to be > reconnected to a new device. The device was destroyed, and data was > destroyed with it... > Warner From owner-freebsd-usb@FreeBSD.ORG Fri Jul 10 17:49:36 2009 Return-Path: Delivered-To: usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BA72D106564A; Fri, 10 Jul 2009 17:49:36 +0000 (UTC) (envelope-from andy@fud.org.nz) Received: from mail-vw0-f172.google.com (mail-vw0-f172.google.com [209.85.212.172]) by mx1.freebsd.org (Postfix) with ESMTP id 6870E8FC18; Fri, 10 Jul 2009 17:49:36 +0000 (UTC) (envelope-from andy@fud.org.nz) Received: by vwj2 with SMTP id 2so864660vwj.3 for ; Fri, 10 Jul 2009 10:49:35 -0700 (PDT) MIME-Version: 1.0 Sender: andy@fud.org.nz Received: by 10.220.46.20 with SMTP id h20mr3236576vcf.78.1247246401210; Fri, 10 Jul 2009 10:20:01 -0700 (PDT) Date: Fri, 10 Jul 2009 10:20:01 -0700 X-Google-Sender-Auth: 2365364d915e1af8 Message-ID: <1280352d0907101020q69f494cdndb01ff14ecf7ea8c@mail.gmail.com> From: Andrew Thompson To: usb@freebsd.org, current Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Subject: USB polling X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2009 17:49:37 -0000 Hi, The one usb task that is still an issue for 8.0 is the polling support. The code needs to call into the host controller driver to check if the usb descriptor has been marked as done and call the completion callback. I am now traveling so cant look at it, if anyone wants to have a look it would be fantastic. This is needed for places where a usb keyboard is used and interrupts are disabled (root mount, DDB). regards, Andrew From owner-freebsd-usb@FreeBSD.ORG Sat Jul 11 15:10:42 2009 Return-Path: Delivered-To: usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9C20A106566B; Sat, 11 Jul 2009 15:10:42 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe08.swip.net [212.247.154.225]) by mx1.freebsd.org (Postfix) with ESMTP id CDA8F8FC12; Sat, 11 Jul 2009 15:10:41 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=MXw7gxVQKqGXY79tIT8aFQ==:17 a=vYXrHWlrNuCLr8PUXtYA:9 a=JS0FUPc30KwD7OHMkYvszT0tOGIA:4 Received: from [62.113.132.61] (account mc467741@c2i.net HELO laptop.adsl.tele2.no) by mailfe08.swip.net (CommuniGate Pro SMTP 5.2.13) with ESMTPA id 1275067602; Sat, 11 Jul 2009 17:10:40 +0200 From: Hans Petter Selasky To: freebsd-current@freebsd.org Date: Sat, 11 Jul 2009 17:10:16 +0200 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA1; KDE/4.2.4; i386; ; ) References: <1280352d0907101020q69f494cdndb01ff14ecf7ea8c@mail.gmail.com> In-Reply-To: <1280352d0907101020q69f494cdndb01ff14ecf7ea8c@mail.gmail.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200907111710.18843.hselasky@c2i.net> Cc: usb@freebsd.org, Andrew Thompson Subject: Re: USB polling X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Jul 2009 15:10:43 -0000 On Friday 10 July 2009 19:20:01 Andrew Thompson wrote: > Hi, > > The one usb task that is still an issue for 8.0 is the polling > support. The code needs to call into the host controller driver to > check if the usb descriptor has been marked as done and call the > completion callback. I am now traveling so cant look at it, if anyone > wants to have a look it would be fantastic. This is needed for places > where a usb keyboard is used and interrupts are disabled (root mount, > DDB). Hi, Probably we can implement USB polling with minimal transfer support. That basically means: - no timeouts - no automatic clear-stall Only support for ukbd and umass. Shouldn't be too hard. What is more hard, is that the sys/dev/usb/input/ukbd.c driver has to get away from using the Giant lock. Last time I looked at that it was impossible because the whole keyboard layer was under Giant. Has anything changed here? If not the USB keyboard will only work if kdb_enter() is called when Giant is locked! --HPS From owner-freebsd-usb@FreeBSD.ORG Sat Jul 11 19:17:29 2009 Return-Path: Delivered-To: usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BF4B81065672 for ; Sat, 11 Jul 2009 19:17:29 +0000 (UTC) (envelope-from andy@fud.org.nz) Received: from mail-vw0-f172.google.com (mail-vw0-f172.google.com [209.85.212.172]) by mx1.freebsd.org (Postfix) with ESMTP id 80E8C8FC13 for ; Sat, 11 Jul 2009 19:17:29 +0000 (UTC) (envelope-from andy@fud.org.nz) Received: by vwj2 with SMTP id 2so1284078vwj.3 for ; Sat, 11 Jul 2009 12:17:28 -0700 (PDT) MIME-Version: 1.0 Sender: andy@fud.org.nz Received: by 10.220.92.204 with SMTP id s12mr4827845vcm.30.1247339848376; Sat, 11 Jul 2009 12:17:28 -0700 (PDT) In-Reply-To: <200907111710.18843.hselasky@c2i.net> References: <1280352d0907101020q69f494cdndb01ff14ecf7ea8c@mail.gmail.com> <200907111710.18843.hselasky@c2i.net> Date: Sat, 11 Jul 2009 20:17:28 +0100 X-Google-Sender-Auth: b0072311eaa0d757 Message-ID: <1280352d0907111217r5c218cdctf158dbfc588da304@mail.gmail.com> From: Andrew Thompson To: Hans Petter Selasky Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: usb@freebsd.org, freebsd-current@freebsd.org Subject: Re: USB polling X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Jul 2009 19:17:30 -0000 2009/7/11 Hans Petter Selasky : > On Friday 10 July 2009 19:20:01 Andrew Thompson wrote: >> Hi, >> >> The one usb task that is still an issue for 8.0 is the polling >> support. The code needs to call into the host controller driver to >> check if the usb descriptor has been marked as done and call the >> completion callback. I am now traveling so cant look at it, if anyone >> wants to have a look it would be fantastic. This is needed for places >> where a usb keyboard is used and interrupts are disabled (root mount, >> DDB). > > Hi, > > Probably we can implement USB polling with minimal transfer support. That > basically means: > > - no timeouts > - no automatic clear-stall > > Only support for ukbd and umass. > > Shouldn't be too hard. Thats pretty much what we need, at least for 8.0. Andrew