PDA

View Full Version : USB2 backport from 2.4.27 to 2.4.4/2.4.18/2.4.20



Jamie
09-29-2004, 01:35 PM
*************************************************************************************
The latest package is here (http://www.dealdatabase.com/forum/showthread.php?p=289690#post289690).
Previous versions are: here (http://www.dealdatabase.com/forum/showthread.php?p=279211#post279211), here (http://www.dealdatabase.com/forum/showthread.php?p=262633#post262633), here (http://www.dealdatabase.com/forum/showthread.php?p=243964#post243964), here (http://www.dealdatabase.com/forum/showthread.php?p=234846#post234846), here (http://www.dealdatabase.com/forum/showthread.php?p=226712#post226712) and here (http://www.dealdatabase.com/forum/showthread.php?p=187485#post187485).
Support thread: here (http://www.dealdatabase.com/forum/showthread.php?t=44114).
*************************************************************************************

As I mentioned in this (http://www.dealdatabase.com/forum/showpost.php?p=186317&postcount=67) thread, I've had some success backporting the linux 2.4.27 usb subsystem to 2.4.18 for TiVo software 4.0.

Here's the source as a patch to the kernel tree in TiVo-4.0-linux.2.4.tar.gz. The patch can be applied with "patch -p1 <usb2-2.4.18.patch" from within the linux-2.4 directory.

The patch is big since I moved the whole drivers/usb subtree in from 2.4.27. I barely got it in under the 1MB attachment limit. If you want to see my changes, it's probably easiest to apply the patch, then diff the drivers/usb subtree against a clean linux-2.4.27 source tree.

Caveats:

I compiled with a gcc3.0 tool chain.

The only thing I tested was the usbnet module with a linksys usb200m.

I didn't configure all usb devices, so the devices I didn't configure may not even compile if turned on.

I don't claim to have a full understanding of urb's, sk_buff's, pci_set_mwi, or a variety of other things in the code I changed, so I may have botched things. All I can say is, works for me with the usb200m.

Improvements would be welcome.

[Edit 2004/10/08: Please continue reading the thread. Later posts contain newer versions.]

TheWickedPriest
09-29-2004, 04:52 PM
So, what improvements does this give?

Jamie
09-29-2004, 06:26 PM
So, what improvements does this give?

You should probably go read the referenced support thread to understand the motivation for this backport.

Summary: Usb2 at "hi-speed" is faster than usb1.1 (480Mb/sec verses 12Mb/sec). The MuscleNerd compiled usb2 modules available here (http://www.dealdatabase.com/forum/showpost.php?p=180483&postcount=13) wedged my network when MRV was used to transfer programs. It didn't just hang my tivo, it hung the whole network. That's what drove me to look for an alternative. Others experienced similar problems, though some people are using the MN modules without problem. I can't explain why they work for some, but not for others. Different switches? Riley described "network oddities using various switches" here (http://www.dealdatabase.com/forum/showpost.php?p=183382&postcount=54).

The 2.4.27 drivers also support additional devices. For example, the usbnet driver is supposed to support IP over usb2 with host-to-host USB cables (no intermediate ethernet). This might be faster than using an ethernet connection. I haven't tried it. The cables are cheap ($15 or so at newegg (http://www.newegg.com/app/ViewProductDesc.asp?description=12-116-125&depa=0)), so I might pick one up and give it a shot next time they are in stock. In practice, I see that netcat is using 100% of the CPU during my performance tests. So there might not be a lot of room for improvement unless the driver overhead can be reduced, e.g. with a larger MTU.

alldeadhomiez
10-06-2004, 01:08 PM
Changes from your code to 20041006 code (see later posts for information on the newer revisions attached to this post):

First, I added kernel 2.4.20 support, to address the USB babble issues seen on 5.1.1b (and maybe fix some of the network lockup issues on the HD units). The babble issue is identical on 4.x and 5.x, but on my SD-H400 it was particularly frequent using the stock 2.4.20 USB and ax8817x drivers.

I also changed the structs in usb.h so that (depending on the kernel you're building for) the USB core and host controller drivers use the same ABI as what the TiVo-supplied drivers expect. This allows us to use existing, working drivers, particularly the closed-source Atmel WLAN drivers, with your 2.4.27 USB subsystem backport. In my testing, using the new 2.4.27 USB subsystem with any version of the ax8817x driver still produces babble problems, but switching to usbnet resolves the problem.

In this archive, usbcore and ehci-hcd have been merged into a single module, which detects whether your box supports USB 2.0 based on the BORD code. Idea being, you can install these new modules as follows:

- back up /lib/modules to somewhere safe
- delete ax8817x.o, usbcore.o, usb-ohci.o, and (if it exists) ehci-hcd.o
- copy in the new modules: usbcore.o, usb-ohci.o, and usbnet.o
- symlink usbnet.o to ax8817x.o

Using this method, no scripts will need to be changed to gain the benefit of the new modules on 4.x or 5.x, and you can test different chipsets with little or no driver reconfiguration.

---

Note to heroes: these drivers are experimental! Do not include them in any installation tool, and do not link directly to the attachments (link to the thread instead).

Latest version: 20050104
Last known good version: 20041024
usbsrc = source code, usbobj = binary objects

Jamie
10-06-2004, 01:31 PM
I made a few changes to the code you posted.
...
Great. Thanks! I'll give them a try and will use this as a base for any future motifications.

I'm trying to get ALI M5632 based host-to-host support in usbnet working for someone (backported from 2.6.8) but the debugging cycle is a bit long since I don't have the hardware. I'm also waiting for feedback from someone trying out the usb-storage.o module.

bcc
10-06-2004, 02:57 PM
Have you been able to see any performance improvements out of the new driver with ax8817x based ethernet dongles or in host-to-host mode?

Jamie
10-06-2004, 03:35 PM
Have you been able to see any performance improvements out of the new driver with ax8817x based ethernet dongles or in host-to-host mode?
See the support thread for what little performance data has been reported. Summary: the drivers in the original post did about 3MB/sec on a quiescient system on a netcat </dev/zero >/devnull test. I haven't tried the ADH modified drivers yet. I don't have a usb2 host-to-host cable, and I haven't heard from anyone that has one working yet.

alldeadhomiez
10-06-2004, 04:25 PM
usbnet, pc->tivo, kernel 2.4.20, Xterasys generic ax8817x (0x7b8/0x420a)
134217728 bytes transferred in 34.687189 seconds (3869375 bytes/sec)
134217728 bytes transferred in 34.625633 seconds (3876253 bytes/sec)
134217728 bytes transferred in 34.836329 seconds (3852809 bytes/sec)

usbnet, tivo->pc, kernel 2.4.20, Xterasys generic ax8817x (0x7b8/0x420a)
134217728 bytes transferred in 62.285 seconds (2154896 bytes/sec)
134217728 bytes transferred in 62.269 seconds (2155450 bytes/sec)
134217728 bytes transferred in 64.578 seconds (2078382 bytes/sec)

ax8817x, pc->tivo, kernel 2.4.20, Xterasys generic ax8817x (0x7b8/0x420a)
134217728 bytes transferred in 33.659399 seconds (3987526 bytes/sec)
134217728 bytes transferred in 33.507143 seconds (4005645 bytes/sec)
134217728 bytes transferred in 33.906486 seconds (3958468 bytes/sec)

ax8817x, tivo->pc, kernel 2.4.20, Xterasys generic ax8817x (0x7b8/0x420a)
134217728 bytes transferred in 65.580 seconds (2046626 bytes/sec)
134217728 bytes transferred in 64.858 seconds (2069409 bytes/sec)
134217728 bytes transferred in 63.798 seconds (2103792 bytes/sec)

bcc
10-06-2004, 04:35 PM
Darn, no better than what I've seen with the old driver for tivo->pc transfers. That's what I was afraid of...

Jamie
10-06-2004, 05:06 PM
Darn, no better than what I've seen with the old driver for tivo->pc transfers. That's what I was afraid of...
I've been wondering if adapting the scatter/gather style transfers from the usb-storage module would help reduce CPU load and increase performance. I've been waiting for some performance data from someone trying the usb-storage driver to see if it does any better than the eth drivers on the tivo. Not sure I have the time and energy to attack such a project, but it's an idea.

Jamie
10-06-2004, 11:35 PM
Here's some more data.

I cross compiled netperf. This is a generally accepted tool for network performance benchmarking.

Bottom line: you gain about 20% in throughput by running a kernel that has CONFIG_NET_FILTER and CONFIG_FILTER turned off. I guess even with empty chains, there is still some extra code each packet has to go through. {edit: turning CONFIG_FILTER breaks dhcp, and doesn't affect TCP performance anyway. Turn only CONFIG_NET_FILTER off for the performance gain.}

One thing that's strange: netperf shows better performance sending from the tivo than receiving. This is the reverse of what we all see with dd|netcat style tests.



------------------------------------------------------------------------
ADH drivers; tivo 4.0.1b standard kernel

pc->tivo
% netperf -t TCP_STREAM -H tivo-bedroom -l 60
TCP STREAM TEST to tivo-bedroom
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec

43689 16384 16384 60.01 18.76

tivo->pc
bash-2.02# netperf -t TCP_STREAM -H 192.168.1.100 -l 60
TCP STREAM TEST to 192.168.1.100
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec

87380 16384 16384 60.00 25.57

------------------------------------------------------------------------
ADH drivers; 2.4.18 kernel without netfilter

pc->tivo
% netperf -t TCP_STREAM -H tivo-bedroom -l 60
TCP STREAM TEST to tivo-bedroom
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec

43689 16384 16384 60.01 22.24

tivo->pc
bash-2.02# netperf -t TCP_STREAM -H 192.168.1.100 -l 60
TCP STREAM TEST to 192.168.1.100
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec

87380 16384 16384 60.00 31.09

alldeadhomiez
10-07-2004, 09:55 PM
I have attached a new revision above (20041007) which includes 2.4.4 support and extra drivers included in the old 2.4.4 USB package (http://www.dealdatabase.com/forum/showthread.php?t=24626). This package is intended to supercede the 2.4.20->2.4.4 backport in that thread.

For 2.4.4 users, this package offers the following improvements over the package I posted last year:
- fixes unaligned access nags
- more recent, less buggy driver and core versions
- replaces ax8817x.o with usbnet.o
- supports more devices by adding "newly" discovered device IDs
- cleaner build system
- usbdevfs/usbfs now works correctly
- supports the 2.4.4 ABI, so the core works with many other 2.4.4 drivers supplied by TiVo or third parties

For 2.4.18 and 2.4.20 users, the benefits over the 20041006 release are:
- adds support for pegasus, kaweth, rtl8150, and at76c503 adapters (in case the TiVo supplied drivers do not work)
- slight improvements in logging initialization status of the integrated EHCI driver

I have run several tests against the modules included in this package:


Tests on 2004/10/07 drivers:

PASS: 2.4.20, usbfs works
PASS: 2.4.20, kaweth, 3com 3c19250 (0x506/0x3e8)
notes: assertion failures on device removal
PASS: 2.4.20, usbnet, Xterasys ax8817x adapter (0x7b8/0x420a)
PASS: 2.4.20, pegasus, Linksys USB100TX (0x66b/0x2203)
PASS: 2.4.20, TiVo pegasus, Linksys USB100TX (0x66b/0x2203)
FAIL: 2.4.20, TiVo kaweth, 3com 3c19250 (0x506/0x3e8)
FAIL: 2.4.20, TiVo kaweth w/TiVo usbcore, 3com 3c19250 (0x506/0x3e8)
notes: unaligned accesses, no network connectivity, system lockup
PASS: 2.4.20, at76c503-rfmd, Belkin F5D6050 (0xd5c/0xa002)

PASS: 2.4.18, usbnet, Xterasys ax8817x adapter (0x7b8/0x420a)

PASS: 2.4.4, usbfs works
PASS: 2.4.4, usbnet, Xterasys ax8817x adapter (0x7b8/0x420a)
PASS: 2.4.4, kaweth, 3com 3c19250 (0x506/0x3e8)
notes: assertion failures on device removal
PASS: 2.4.4, pegasus, Linksys USB100TX (0x66b/0x2203)
FAIL: 2.4.4, TiVo pegasus, Linksys USB100TX (0x66b/0x2203)
FAIL: 2.4.4, TiVo pegasus w/TiVo usbcore, Linksys USB100TX (0x66b/0x2203)
PASS: 2.4.4, at76c503-rfmd, Belkin F5D6050 (0xd5c/0xa002)

Unless noted as "TiVo," all drivers and usbcore/usb-ohci/(ehci-hcd) are from
this package.

MRV was not tested, but so far the usbnet driver has appeared to fix the
babble issue associated with EHCI 2.4.20 + ax8817x.o.

Future work:
- Merge in the linux-wlan-ng stuff
- Add other useful/updated USB drivers: printer, scanner, usb-storage, serial, etc.
- Update to the latest at76c503 drivers

Woody Allen
10-10-2004, 02:05 AM
I'm trying to get ALI M5632 based host-to-host support in usbnet working for someone (backported from 2.6.8)

Here are the results. All credit goes to Jamie!



tivo:/usr/local/test$ ./test3
100000+0 records in
100000+0 records out

real 0m24.640s
user 0m1.190s
sys 0m19.630s
tivo:/usr/local/test$
tivo:/usr/local/test$ cat test3
#!/bin/sh
time dd if=/dev/zero bs=1024 count=100000 | netcat 192.168.1.1 10000 -w 1

tivo:/usr/local/test$ /usr/local/busybox/ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:4 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:312 (312.0 B) TX bytes:312 (312.0 B)

usb0 Link encap:Ethernet HWaddr 36:D2:9F:6B:BE:AB
inet addr:192.168.1.2 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:15000 Metric:1
RX packets:22486 errors:0 dropped:0 overruns:0 frame:0
TX packets:33867 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:1169304 (1.1 MiB) TX bytes:332020734 (316.6 MiB)



tivo(/dev/zero)->pc(/dev/null) 4 MBS
pc(/dev/zero)->tivo(/dev/null) 6.2 MBS

These results are still very experimental in that they have not been tested for side effects and actual file transfers

Increasing the MTU to greater than 15000 causes the tivo to become unstable - hangs and/or kevent messages.

Jamie
10-10-2004, 12:42 PM
[b]Here are the results....
Thanks for doing the testing and reporting results.

I believe the dropped kevents are due to EVENT_RX_MEMORY. Basically the driver is unable to allocate kernel memory, causing it to defer some of its work to a kevent. Turns out it can queue up only one of these defered kevents. If it tries a second time while the first is pending, it gets this warning.

The driver is currently allocating 60 transmit and receive buffers internally. That's probably too much for the poor TiVo when the MTU is large. 2*60*15000 works out to about 2MB. It should be possible to take the MTU into account when deciding how much queueing to do. Larger MTUs should require less queueing, so the number should be smaller. I tweaked with the queueing in the backport to adopt the larger queues from the 2.6.8 code rather than what the 2.4.27 code original had (which, as I recall, was a queue length of 1). Preliminary testing indicated that the larger queues helped when the MTU was the ethernet standard of 1500. But it did tickle this kevent warning occasionally.

I'm not sure that the txqueuelen has any effect, but if it means txqueuelen*MTU bytes are being allocated, 2000 is way too large.

I'll post netperf. I'm not sure that the dd|netcat measurement approach is capturing just the network performance. There are some extra data copies involved, and the context switching between processes when you run a dd|netcat pipeline.

Ultimately what we care about though is MRV and mfs_ftp transfer performance, so some final end-to-end performance numbers would be useful too once we get the network parameters tuned. I was hoping the host-to-host cables could break 10MB/sec.

alldeadhomiez
10-13-2004, 01:58 PM
Release 20041013 has been posted (above), with the following changes:


2004/10/12 Jamie

- Added ALI M5632 support to usbnet

2004/10/11 alldeadhomiez

- Added usb-storage.o, scanner.o, and printer.o from 2.4.27
- Changed directory layout (back)
- Added precompiled SCSI modules for all three kernels
- Added new ifconfig binary per EvilJack

2004/10/08 alldeadhomiez

- Added ehci-dummy.o (keeps a "real" ehci-hcd module from loading, when
renamed)

Please acquaint yourself with the contents of the README file before you proceed.

burbinator
10-18-2004, 03:32 AM
On the suggestion of alldeadhomiez I put together a script that compiles the linux-wlan-ng modules within the 2.4.27 backport framework. I have successfully compiled wlan-ng with respect to all 3 kernel versions, and have further confirmed that the newly compiled 2.4.4 modules do work in my dtivo running 3.1.1b. A copy of this script is included with the message, and it pretty much operates on the same assumptions about cross-compilers and kernel source locations as the 2.4.27 usb code.

Note that while wlan-ng only creates 2 kernel modules (p80211.o and prism_usb.o), it also creates a number of binaries, scripts, and user-modifiable configuration files in order to support the prism chipset wireless communcations process. More info on this concept of operations can be found in the documentation for linux-wlan-ng and in the README files accompanying the original prism drivers that I originally posted on these forums.

I do not plan on posting any binaries of these modules or new tpm distributions of the full linux-wlan-ng due to the experimental nature of these latest drivers.

10/21/2004: I re-uploaded the script to correct a bug that was dumping 2.4.4 modules into 2.4.18 and 2.4.20 dirs.

burbinator
10-21-2004, 11:10 PM
I had to re-upload the previous script because it was copying 2.4.4 modules into the 2.4.18 and 2.4.20 dirs. Be sure to perform a ``strings'' and fgrep for '2.4' to confirm that the versions are as expected. Sorry for not catching the bug sooner.

alldeadhomiez
10-24-2004, 08:50 PM
20041024 version now posted:


2004/10/24 burbinator

- Merged in linux-wlan-ng v0.2.1pre22 prism2 drivers
- Created test/setup_wlan.sh script to build linux-wlan-ng in this tree

2004/10/24 alldeadhomiez

- Updated at76c503 driver to the latest CVS version from berlios.de
- Changed interface name from wlan%d to eth%d
- Fixed an unaligned access nag

Notes:


tested with at76c503-rfmd and at76c503-i3861 adapters under 2.4.20
possible intermittent kernel panic on i3861 device initialization? I can't recreate this.
prism2 stuff is untested (but presumably the same as the 0.2.1pre22 objects burbinator has posted)
2.4.4 and 2.4.18 are untested, but nothing really changed
usbdfu has changed its name to at76_usbdfu
archive is now two .tar.bz2's because the .zip got too big
looking into ways to provide iw* utilities that work with all three WIRELESS_EXT versions (11, 12, and 14). Unfortunately CONFIG_NET_RADIO is a bool so linux/net/core/wireless.c is compiled into the kernel.

ronnythunder
10-30-2004, 12:10 PM
Bottom line: you gain about 20% in throughput by running a kernel that has CONFIG_NET_FILTER and CONFIG_FILTER turned off.good find, jamie. i can confirm about a 25% increase while pulling from an hd tivo to pc (both tserver and mfs_ftp have similar increases) with these turned off.

quite handy when the show you're extracting is almost 16gb :eek:

ronny

alldeadhomiez
01-04-2005, 07:36 PM
Changes in 20050104:


2005/01/04 alldeadhomiez

- Added Series2.5/Gen04/Uma2c support
- Changed obj/ layout to accommodate Series2.0 and Series2.5 host drivers
- Stripped ifconfig binary

Also, a few new sections have been added to the README; please familiarize yourself with them.

Here are my Series2.5 benchmarks, performed on a Humax DRT800:

ax8817x, drt800, netfilter disabled, stock ohci drivers, pc->tivo, kernel 2.4.20, Xterasys generic ax8817x (0x7b8/0x420a)


# netperf -t TCP_STREAM -H humax -l 60
TCP STREAM TEST to humax
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec

87380 16384 16384 60.02 7.54

ax8817x, drt800, netfilter disabled, stock ohci drivers, tivo->pc, kernel 2.4.20, Xterasys generic ax8817x (0x7b8/0x420a)


# netperf -t TCP_STREAM -H peecee -l 60
TCP STREAM TEST to peecee
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec

87380 16384 16384 60.12 5.94

usbnet, drt800, netfilter disabled, new ehci drivers, pc->tivo, kernel 2.4.20, Xterasys generic ax8817x (0x7b8/0x420a)


# netperf -t TCP_STREAM -H humax -l 60
TCP STREAM TEST to humax
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec

87380 16384 16384 60.01 29.73

usbnet, drt800, netfilter disabled, new ehci drivers, tivo->pc, kernel 2.4.20, Xterasys generic ax8817x (0x7b8/0x420a)


# netperf -t TCP_STREAM -H peecee -l 60
TCP STREAM TEST to peecee
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec

87380 16384 16384 59.99 10.43

The kernel I am running is posted here (http://www.dealdatabase.com/forum/showthread.php?p=200649#post200649).

titusmex
01-10-2005, 12:58 AM
Thanks Jamie & ADH & NUTKASE et all @ DD

(WAF skyrocketed with these transfer speeds) - Hardware & Drilling for new gigabit network approved!!!!


TCP STREAM TEST to 192.168.1.100
Recv Send Send Utilization Service Demand
Socket Socket Message Elapsed Send Recv Send Recv
Size Size Size Time Throughput local remote local remote
bytes bytes bytes secs. 10^6bits/s % S % N us/KB us/KB

65536 131070 131070 10.00 36.98 98.60 16.12 218.395 71.394
tivo:/var/hack$


USB 200M - Tivo SA 2 4.01b - ptvlb48 Kernel - superpatch 7.0.1

rc3105
01-12-2005, 04:20 PM
Please excuse me if this reply is a duplicate, I know I wrote a reply to this last night but I was unable to find it on this forum. Maybe I screwed up when pressing the submit reply button...

well, at least you're polite. it was deleted because (drum roll please)

this is a development thread, ask those type of questions in the support thread (http://www.dealdatabase.com/forum/showpost.php?p=186317&postcount=67)

kaneisgr
01-18-2005, 10:48 PM
I'd like to report the following -in case someone has ever run or runs over the same problem-.

Using the 2.4.18 backported modules for usb2 on my tivo SA Series 2 (running 4.0.1b) with a linksys usb200m doesn't work... :confused: To be more precise:

I boot the machine (without loading any usb modules):


$lsmod
Module Size Used by Not tainted
brcmdrv-rb 769328 24
therm 1488 0
fan 2096 0
ideturbo 5232 0 (unused)
router 66864 24
kfirm 104320 0 (unused)
tvinput 10640 0 (unused)
irblast 4112 0
ircatch 16944 1
modemtty 4672 1
fpga 1904 0
tivoconfig 960 0 (unused)
i2c 11888 1 [therm fan tvinput]


once I insmod usbcore.o everything looks good:


usb.c: starting integrated EHCI driver
ehci_hcd 00:0d.2: PCI device 1033:00e0
ehci_hcd 00:0d.2: irq 6, pci mem b4002000
usb.c: new USB bus registered, assigned bus number 1
ehci_hcd 00:0d.2: USB 2.0 enabled, EHCI 0.95, driver 2003-Dec-29/2.4
hub.c: USB hub found
hub.c: 5 ports detected
usb.c: EHCI initialization succeeded

then, :mad: if the usb200m is plugged in (or as soon as I plug it in) I get:


hub.c: new USB device 00:0d.2-2, assigned address 2
usb_control/bulk_msg: timeout
usb.c: USB device not accepting new address=2 (error=-145)
hub.c: new USB device 00:0d.2-2, assigned address 3
usb_control/bulk_msg: timeout
usb.c: USB device not accepting new address=3 (error=-145)


It doesn't matter if the usbnet module is loaded or not. The same stands for the usb-ohci module (which is required only for usb1.1 devices anyway).

I know that my SA2 has a EHCI capable usb controller (some very early versions don't), see bold text below:


$ cat /proc/pci
PCI devices found:
Bus 0, device 13, function 0:
Class 0c03: PCI device 1033:0035 (rev 65).
IRQ 5.
Master Capable. Latency=40. Min Gnt=1.Max Lat=42.
Non-prefetchable 32 bit memory at 0x14000000 [0x14000fff].
Bus 0, device 13, function 1:
Class 0c03: PCI device 1033:0035 (rev 65).
IRQ 3.
Master Capable. Latency=40. Min Gnt=1.Max Lat=42.
Non-prefetchable 32 bit memory at 0x14001000 [0x14001fff].
Bus 0, device 13, function 2:
Class 0c03: PCI device 1033:00e0 (rev 2).
IRQ 6.
Master Capable. Latency=64. Min Gnt=16.Max Lat=34.
Non-prefetchable 32 bit memory at 0x14002000 [0x140020ff].
Bus 0, device 14, function 0:
Class ff00: PCI device 1741:0000 (rev 128).
IRQ 2.
Master Capable. Latency=64.
Non-prefetchable 32 bit memory at 0x14100000 [0x141fffff].
Bus 0, device 15, function 0:
Class 0480: PCI device 141f:9000 (rev 0).
IRQ 40.
Master Capable. Latency=64.
Non-prefetchable 32 bit memory at 0x14200000 [0x14200fff].
Non-prefetchable 32 bit memory at 0x14220000 [0x1423ffff].
Prefetchable 32 bit memory at 0x14240000 [0x1425ffff].
Non-prefetchable 32 bit memory at 0x14260000 [0x1427ffff].


The strange thing is that there are no triggered interrupts on irq 6:


$ cat /proc/interrupts
2: 0 + cascade
4: 239054 + cascade, + brcm
6: 0 ehci_hcd
7: 34 + counter
22: 184462 + timer
23: 0 + illegal cycle
39: 0 + cascade
48: 0 + pci error
49: 0 + pci error
50: 0 + pci error
51: 0 + pci error
52: 0 + pci error
53: 0 + pci error
57: 10759 + ide0
70: 1 + irsuper
73: 10 + irsuper
81: 12533 serial
82: 175399 + i2c
83: 0 + i2c
84: 0 + cascade
85: 0 + cascade
86: 0 + cascade
87: 58976 + ide0
88: 0 + ide0
89: 0 + ide0
96: 0 + i2c
97: 0 + i2c
98: 0 + i2c
99: 0 + i2c
133: 13 parallel modem


usb1.1 devices (like my logitech mouse or the sennheiser headphones) are
recognised just fine with the backported usb2 modules (through usb-ohci).
(Of course there are no modules for those specific devices, but there are no problems assigning addresses to them!)

I've used both the stock 2.4.18 kernel and the one found in:

http://www.dealdatabase.com/forum/showthread.php?p=202967#post202967


The linksys usb200m works perfectly fine with the usb1.1 modules....

Unfortunately I don't have access to any other usb2 devices....
Any ideas/hints?

Best Regards!

alldeadhomiez
01-18-2005, 11:02 PM
The linksys usb200m works perfectly fine with the usb1.1 modules....

Did you try this usbcore with the parameter: use_ehci=0 ?

Also, what is the vend/prod when you pop it in a PC?

kaneisgr
01-19-2005, 12:11 AM
Did you try this usbcore with the parameter: use_ehci=0 ?

Also, what is the vend/prod when you pop it in a PC?

The vend/prod is 0x77b/0x2226.

with use_ehci=0 (and usb-ohci) it works :cool: :


usb.c: registered new driver usbdevfs
usb.c: registered new driver hub
usb-ohci.c: USB OHCI at membase 0xb4000000, IRQ 5
usb-ohci.c: usb-00:0d.0, PCI device 1033:0035
usb.c: new USB bus registered, assigned bus number 1
hub.c: USB hub found
hub.c: 3 ports detected
usb-ohci.c: USB OHCI at membase 0xb4001000, IRQ 3
usb-ohci.c: usb-00:0d.1, PCI device 1033:0035
usb.c: new USB bus registered, assigned bus number 2
hub.c: USB hub found
hub.c: 2 ports detected
hub.c: new USB device 00:0d.1-1, assigned address 2
usb.c: USB device 2 (vend/prod 0x77b/0x2226) is not claimed by any active driver
usb.c: registered new driver usbnet
eth0: register usbnet usb-00:0d.1-1, ASIX AX8817x USB 2.0 Ethernet
eth0: open: enable queueing (rx 4, tx 4) mtu 1500 raw framing

With no EHCI , however, is it really in USB 2.0 (as the log says)?

Thanks

Jamie
01-19-2005, 12:25 AM
With no EHCI , however, is it really in USB 2.0 (as the log says)?nope. The short queue length's reported by usbnet.o are one clue.

I very occasionally got the "not accepting new address" error with a usb host-to-host cable when I was plugging and unplugging it frequently. A reboot always helped, but nothing else did, including unloading and reloading all the usb modules.

kaneisgr
01-19-2005, 12:05 PM
nope. The short queue length's reported by usbnet.o are one clue.

I very occasionally got the "not accepting new address" error with a usb host-to-host cable when I was plugging and unplugging it frequently. A reboot always helped, but nothing else did, including unloading and reloading all the usb modules.

I tried rebooting tivo numerous times, but nothing changed... Always the same "not accepting new address" error(!).

Jamie
02-14-2005, 10:39 PM
Here's a delta against the 20050104 build from alldeadhomiez. This should make it into the next build, but I'm putting it out now for earlier adopters to try. It contains only a source patch, usbcore.o and usbnet.o for each architecture. The changes are:
2005/02/08 Jamie

- Added ax8817x_reset to usbnet that sets the medium_mode bits.
- Added usbnet module options to adjust the medium_mode, force half duplex,
and control tx and rx queue sizes.
- Set the default value for log2_irq_thresh to 4.The first change (the medium_mode bits) are the most interesting. Turns out that 802.3x has an optional hardware flow control mechanism for full duplex called "PAUSE" frames. A receiver can send PAUSE frames to tell a sender to slow down so it can keep up. The linux usbnet driver wasn't enabling it. This version of the driver does. I see ~ double the full duplex receive throughput with this enabled (both on x86 and tivo mips). It doesn't seem to help send performance though, and it may even be slightly worse than without flow control. YMMV: it may depend on the switch and/or the adapter on the other end. I'm interested in feedback; please use the "Soapbox derby" thread (http://www.dealdatabase.com/forum/showthread.php?p=209025#post209025).

EvilJack
06-13-2005, 08:58 PM
Is this needed with 6.2? If I'm using tytools to transfer video, it only runs at like .48 k/s? It takes like an hour to do a 2 hour show.

Not needed.... (as you said it works) but makes things go
faster if you use them. You'd want the 2.4.20 version of
the modules.

jack

Jamie
06-19-2005, 07:18 PM
Here's a new build with usbnet support for dongles built around the ASIX ax88178 and ax88772 chips. These are available in devices made by airlink-101 (AGIGAUSB (http://www.airlink101.com/products/agigausb.html) , ASOHOUSB (http://www.airlink101.com/products/asohousb.html)) and sold by Fry's/Outpost (http://shop4.outpost.com/search?search_type=regular&sqxts=1&query_string=airlink+usb+ethernet). The AGIGAUSB is a GigE device and supports jumbo frames.

Here's some performance data:
device chip speed jumbo? TXmbps RXmbps
usb200m 88172 100 n 45 60
ASOHOUSB 88772 " " 43 50
AGIGAUSB 88178 1000 " 43 46
" " " y 95 78Observation: GigE is only worth while if you can enable jumbo frames (mtu 9000). This means your switches and PC network adapters also have to support jumbo frames. I use smc (http://www.newegg.com/Product/Product.asp?Item=N82E16833129012) switches and intel (http://www.newegg.com/Product/Product.asp?Item=N82E16833106105) network adapters. If you can enable jumbo frames, the performance improvement is noticable. I routinely get 5-6MBsec in mfs_ftp extractions now.

If you want to change the mtu, you need to take the interface down and bring it back up. For example,
ifconfig eth0 down; ifconfig eth0 mtu 9000; ifconfig eth0 up If you do it all on one line, you can do it from a telnet session without losing your connection.

I'm seeing an occasional framing error. I'm writing this off to running GigE over long cat5 runs (not cat5e or cat6), although it could be a problem in the driver.
{Edit: it looks like at least some of the errors I'm seeing are due to usb "babble" (-EOVERFLOW urb status values). Still investigating.}

Thanks to EvilJack and pjin for sending me the dongles. Thanks to Jeff D for driver code from ASIX. I didn't actually use it. The new code is based on the ax88772 support in the 2.6.12-rc6-mm1 tree with some tweaks to the AX framing code to improve performance and fixes for mips byte order/alignment issues.

The usual caveats apply. I've only tested the 2.4.20 versions of the modules on tivo software version 7.1b.

gpontis
06-26-2005, 01:46 PM
Here's a new build with usbnet support for dongles built around the ASIX ax88178 and ax88172 chips.
...
The usual caveats apply. I've only tested the 2.4.20 versions of the modules on tivo software version 7.1b.

Wow, that was fast Jamie.

But I had no luck getting connection with the Airlink GigE adapter on a DTivo with 6.2. The system recognizes the device when plugged in. I can configure the interface without errors using ifconfig, but it does not send or receive packets. Everything comes up perfectly with the USB200M plugged back in.

Boot log is attached.

Jamie
06-26-2005, 02:18 PM
Wow, that was fast Jamie.

But I had no luck getting connection with the Airlink GigE adapter on a DTivo with 6.2. The system recognizes the device when plugged in. I can configure the interface without errors using ifconfig, but it does not send or receive packets. Everything comes up perfectly with the USB200M plugged back in.

Boot log is attached.I know at least one person (EvilJack) is using it with 6.2, so it can work.

Boot log stuff that looks relevant:
eth0: register usbnet usb-00:0d.2-1, ASIX AX88178 USB 2.0 GIGE EthernetThis is good. It means the driver is loaded and the dongle recognized.
Bringing up eth0...

Internet Software Consortium DHCP Client 2.0

Copyright 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium.

All rights reserved.



Please contribute if you find this software useful.

For info, please visit http://www.isc.org/dhcp-contrib.html



/proc/net/dev: No such file or directory

exiting.This is bad. It seems to indicate dhclient is failing. /proc/net/dev exists for me. Not sure why yours isn't seeing it.

I would suggest you manually install the module and configure the network. Works for me. I haven't tried using dhcp. See this (http://www.dealdatabase.com/forum/showthread.php?p=227101#post227101) thread for other thoughts. I'd get it working first from a serial console session before I worried about editing the startup scripts.

gpontis
06-26-2005, 10:06 PM
I didn't touch the startup scripts at first, since I was already networking with the USB200M. I just installed the new objects and rebooted with the GigE adapter instead of the USB200M.

For diagnostic purposes I tried loading usbnet.o manually, then manually doing the ifconfig. No dice. ifconfig shows that packets are being transmitted but the activity light on the adapter does not blink when I try to ping something. I am attaching the console output when I went through these steps.

George

Jamie
06-27-2005, 01:07 AM
I didn't touch the startup scripts at first, since I was already networking with the USB200M.Let's take this to the new support thread here (http://www.dealdatabase.com/forum/showthread.php?t=44114).

Jamie
09-16-2005, 09:30 PM
2005/09/15 Jamie

- Added prod/vendor for linksys usb200m v2 (an ax88772 based device)
- Minor bug fixes in ax framing code

--------------------

Only usbnet.{c,o} has changed.

Here's the info for /etc/hotplug/usb.map:
product 0b95 7720 Airlink ASOHOUSB
product 0b95 1780 Airlink AGIGAUSB
product 13b1 0018 Linksys USB200MV2This goes in the usbnet device section for 7.x, and the ax8817x section for older tivo software versions.

This is a development thread. Support issues go here (http://www.dealdatabase.com/forum/showthread.php?t=44114).

Jamie
09-19-2005, 05:03 PM
The latest drivers left me without Internet connection at all...This is not a support thread. Moderators: please delete or move to the appropriate thread (link (http://www.dealdatabase.com/forum/showthread.php?t=44114)).

My answer is here (http://www.dealdatabase.com/forum/showthread.php?p=235108#post235108).

dsumorok
09-21-2005, 09:42 PM
I would like to thank you for the Ax8817x driver as well as for the work on getting the Ax88772 working. I am working on a GPL Mac OS X driver for the Ax8817x and Ax88772. I know you are the experts... but I would be happy to post our code so far if anyone is interested. We release the driver at (http://www.sustworks.com/site/news_usb_ethernet.html) in .dmg format but would be happy to create a source archive in a more linux-friendly format if anyone is interested. I have an Airlink ASOHOUSB which I am testing out. I needed to set the phy address to 0xf0 in order to read the MII registers (set the 4 high "reserverd" bits to 1) on the Ax88772. Did you have any issues with phy address? I would also like to thank you for the info on the framing... I couldn't figure that out from the data sheet. Finally, of course, thanks for the info on the how to set the GPIO bits.

-Dan

Jamie
09-22-2005, 12:49 PM
I would like to thank you for the Ax8817x driver as well as for the work on getting the Ax88772 working. I am working on a GPL Mac OS X driver for the Ax8817x and Ax88772. I know you are the experts... but I would be happy to post our code so far if anyone is interested. We release the driver at (http://www.sustworks.com/site/news_usb_ethernet.html) in .dmg format but would be happy to create a source archive in a more linux-friendly format if anyone is interested. I have an Airlink ASOHOUSB which I am testing out. I needed to set the phy address to 0xf0 in order to read the MII registers (set the 4 high "reserverd" bits to 1) on the Ax88772. Did you have any issues with phy address? I would also like to thank you for the info on the framing... I couldn't figure that out from the data sheet. Finally, of course, thanks for the info on the how to set the GPIO bits.The ax88772 support was largely backported from the linux 2.6.12 usbnet.c source. I did have to make some byte order fixes. I also added the AX88178 support, which is very similar. The 2.6.13 usbnet is now modularized, so asix support is in its own source file, asix.c.

I don't recall anything special about the PHY. It's an internal PHY, as I recall. I did correspond with an OpenBSD developer who was working on ax88178 support in the OpenBSD axe driver:

http://www.openbsd.org/cgi-bin/cvsweb/src/sys/dev/usb/if_axe.c
http://www.openbsd.org/cgi-bin/cvsweb/src/sys/dev/usb/if_axereg.h


He was having PHY problems too, and found that the delays during initial setup were important. Try increasing the delays if you are still having problems.

I don't know the state of the world in OSX drivers. Perhaps you can leverage the BSD drivers?

PM or email me if you want to discuss further offline.

Blorton
10-12-2005, 09:38 PM
Just a quick head's up that Fry's currently has the AGIGAUSB on sale for $7.99. I bought the limit of two from the Atlanta location today and they had plenty left.

Cheers!
Dan

tivo24me
12-05-2005, 01:31 PM
If this sounds right, I upgraded my SD-DVR40 to 4.0.1b, 2.4.18 and have a USB200Mv2 that is not working. I am assuming it's because I have the V2 adapter. I have downloaded the usbobj2.4.27-20050916.tar.bz2 file from this thread and would like to know what files I should replace on my Tivo hard drive. Looks like my drivers are in /lib/modules.

Should I just backup my current files:
/lib/modules/usbcore.o
/lib/modules/usb-ohci.o
/lib/modules/usbnet.o

And copy in these 3 files from the 2.4.18 directories of the tar file I downloaded from this thread to my /lib/modules?

I also assume that I do not need to insmod any of these because 4.0.1b should load them automatically. Is that right?

Any help would be great :)

Jamie
12-05-2005, 01:37 PM
Any help would be great :)This is a development thread, and posts here should be discussions related to development. If you want help, go back to the first post in this thread and follow the link to the support thread.

Moderators: If possible, please delete this post and the two that preceed it, as they don't belong here.

santa8claws
12-12-2005, 05:56 PM
Hi, I have been interested in the wifi drivers development for the Zydas 1211 chipset:
http://www.zydas.com.tw/product/ZD1211.asp
http://www.zydas.com.tw/downloads/download-1211.asp

There is active development for linux drivers at sourceforge:
http://sourceforge.net/projects/zd1211/

So my question is what would be involved in order to build/backport this to work with the stock Tivo kernel version?

-- S8C

Jamie
12-12-2005, 06:13 PM
So my question is what would be involved in order to build/backport this to work with the stock Tivo kernel version?Do you have the hardware? If so, the first step I'd take is to get it running on an x86 linux box. Once that's done, integrate it into the usb-2.4.27 tree here. From the readme, it looks like it works with 2.4.22 and later, so there's a pretty good chance it will drop into the 2.4.27 tree easily. If noone has ever tested it with a big-endian processor, you may have to make some byte order fixes.

santa8claws
12-14-2005, 11:19 PM
I have a Trendnet USB2.0 wifi adapter which uses the chipset, so that's my reason to pursue a driver. It seems that integrating the driver is more advanced than just cross-compiling against a configured tivo kernel. I'll have to read up on this some more :(
Thanks for your thoughts!
-- s8c

Jamie
12-15-2005, 12:44 AM
I have a Trendnet USB2.0 wifi adapter which uses the chipset, so that's my reason to pursue a driver. It seems that integrating the driver is more advanced than just cross-compiling against a configured tivo kernel. I'll have to read up on this some more :(
Thanks for your thoughts!
-- s8cIntegration shouldn't be hard since it already works with a 2.4.2x kernel. There might be a few byte order changes to get it working on a mips processor. PM me if you give it a shot and get stuck on something and need help.

Jamie
12-26-2005, 02:57 PM
2005/12/26 Jamie

- Fix usbnet hard_header optimization -- it was messing up dhcp packets

Only usbnet.{c,o} changed.

This should fix the dhcp problems with ax88178 and ax88772 devices.

dsumorok
02-15-2006, 11:55 PM
Just in case you didn't know (I was not able to download the source), the Linksys USB 1000 appears to have an ax88178 chip inside (it reportedly works with the mac os x Ax88178 driver). The product id is 0x0039, and the vendor id is 0x1737.

Jamie
02-16-2006, 12:26 AM
Just in case you didn't know (I was not able to download the source), the Linksys USB 1000 appears to have an ax88178 chip inside (it reportedly works with the mac os x Ax88178 driver). The product id is 0x0039, and the vendor id is 0x1737.Thanks. I'll add that prodid/vendorid in the next release, though I don't have one so it won't be tested. Seem kind of pricey (~ $60) compared to the airlink devices.

mffattoum
02-27-2006, 01:22 PM
where can i get source code of kernel 2.4.18-14

Jamie
02-27-2006, 01:37 PM
where can i get source code of kernel 2.4.18-14This is the wrong forum for "where can I get..." questions -- try the Newbie forum.

TiVo linux kernel sources can be found here (www.tivo.com/linux). Generic linux kernel sources are here (http://www.kernel.org).

Jamie
09-04-2006, 06:12 PM
New release 2006/09/02 to support additional hardware. From the ChangeLog:
2006/09/02 Jamie

- usbnet

- Add support for the Linksys usb1000 gige adapter (AX88178)

- Add support for the D-Link DUB-E100 revision B (AX88772)

- Use a status interrupt to detect link changes and adjust registers
appropriately. This code was adapted from the current linux 2.6
usbnet. This may fix problems that some people have had with link
partners that are slow to negotiate. It also allows moving back
and forth between hubs & switches with different link speeds.

- Gen04 usbcore

- ehci works now with 7.x kernels on S2.5 hardware.
I borrowed bcm-usb.h from the 7.3 kernel sources and this seems to
provide the additional initialization required with 7.x kernels.

- pegasus
Adopt the 7.3.1 pegasus.[ch] code for the backport.
It seems to be newer than what we had in the backport, and works
with my Belkin F5D5500, while the old backport code didn't.

I can't get attachments to work, so here's links to copies on sourceforge:

usbobj2.4.27-20060906.tar.bz2 (http://prdownloads.sourceforge.net/mfs-utils/usbobj2.4.27-20060906.tar.bz2?download)
usbsrc2.4.27-20060906.tar.bz2 (http://prdownloads.sourceforge.net/mfs-utils/usbsrc2.4.27-20060906.tar.bz2?download)

[edit: the 20060902 version had problems with some devices. 20060906 should be better.]

labbie48
09-05-2006, 11:17 AM
Deleted moved to support thread

rbautch
10-26-2006, 01:32 PM
Jamie,
In the usb.map.additions included with the distribution, it shows this
# ax88178
product 0b95 1780 Airlink AGIGAUSB
product 1737 0039 Linksys usb1000In my 7.3 usb.map, the heading is actually AX88172. Not sure if this is just a typo or if it actually changed.

Jamie
10-26-2006, 01:51 PM
Jamie,
In the usb.map.additions included with the distribution, it shows this
# ax88178
product 0b95 1780 Airlink AGIGAUSB
product 1737 0039 Linksys usb1000In my 7.3 usb.map, the heading is actually AX88172. Not sure if this is just a typo or if it actually changed.The gige ASIX part is ax88178. See here (http://www.asix.com.tw/products.php?op=ProductList&PLine=71), for example. The ax88172 is the old 100mbps part (e.g. FA120, usb200m v1, etc). The ax88772 is the "new" 100mbps part (e.g. usb200m v2, DUB-E100 B1, etc.)

It's just a comment, so if it is wrong, it doesn't really mater.

PTVupgrade
01-03-2007, 02:55 PM
I have been attempting to compile a module for a USB 2.0 Ethernet adapter I stumbled across which uses a Davicom chipset (DM9601 - 0a46:9601).

I've been attempting to compile the 2.4.20 drivers and have gotten far enough to get what I thought would be a working .o file, but when I attempt to insmod it, I get errors like this:



Warning: loading dm9601.o will taint the kernel: no license
See http://www.tux.org/lkml/#export-tainted for information about tainted modu
les


and depending on the flags I use when compiling, I can also get a lot of these:



m9601.o: dm9601.o: Relocation overflow of type 4 for printk
dm9601.o: dm9601.o: Relocation overflow of type 4 for __wake_up
dm9601.o: dm9601.o: Relocation overflow of type 4 for interruptible_sleep_on
dm9601.o: dm9601.o: Relocation overflow of type 4 for add_wait_queue
dm9601.o: dm9601.o: Relocation overflow of type 4 for schedule
dm9601.o: dm9601.o: Relocation overflow of type 4 for remove_wait_queue
dm9601.o: dm9601.o: Relocation overflow of type 4 for printk
dm9601.o: dm9601.o: Relocation overflow of type 4 for interruptible_sleep_on
dm9601.o: dm9601.o: Relocation overflow of type 4 for add_wait_queue
dm9601.o: dm9601.o: Relocation overflow of type 4 for printk
dm9601.o: dm9601.o: Relocation overflow of type 4 for schedule
dm9601.o: dm9601.o: Relocation overflow of type 4 for remove_wait_queue
...


But no love.

I've done quite a bit of digging, but am running into dead ends. Any thoughts on the direction to take?

Jamie
01-03-2007, 03:32 PM
....


Warning: loading dm9601.o will taint the kernel: no license
See http://www.tux.org/lkml/#export-tainted for information about tainted modules

Sounds like you don't have a MODULE_LICENSE directive in the module indicating that it is GPL code. The link in the error message explains it. It's not fatal, but it just tells the kernel developers that the kernel is "tainted" with a non-GPL module, and in general you won't get any support from them if you run with non-GPL'd modules. Since most of the tivo modules are not GPL'd, this isn't really an issue in the tivo world since we are always tainted.

Check out usbnet.c, for example, to see how to label a mdoule as GPL to avoid the warning (if it really is GPL).


....
and depending on the flags I use when compiling, I can also get a lot of these:



m9601.o: dm9601.o: Relocation overflow of type 4 for printk
dm9601.o: dm9601.o: Relocation overflow of type 4 for __wake_up
...


Sounds like you aren't compiling the module with exactly the same gcc flags used when compling the kernel: link (http://www.linux-mips.org/wiki/Modules). You really need a clean kernel compile tree before you start building modules. See this (http://www.dealdatabase.com/forum/showthread.php?t=46361).

There's a pretty good chance that any module that's only been developed and tested on x86 machines is going to need some byte order cleanup to get it to work properly on mips.

If you want to port modules, I'd suggest you first make sure you can build a working mips kernel and the usb-2.4.27 backport modules. Once you have that framework working, you can drop new modules into it and adjust them as necessary to get them to compile/work on the mips-tivo platform.

Given that the dm9601 is a usb1.1 device, it isn't clear to me it's worth spending much time trying to support it.

PTVupgrade
01-03-2007, 03:51 PM
Thanks for the insights. I will have to look into that further.

But the last thing you said stunned me. I thought this was a USB 2.0 module; at least that is what the box says.

I definitely have some more digging to do. Perhaps I downloaded the wrong driver?

Jamie
01-03-2007, 04:00 PM
But the last thing you said stunned me. I thought this was a USB 2.0 module; at least that is what the box says. I just basing my assesment on a quick google on dm9601, which yielded this (http://www.davicom.com.tw/eng/products/dm9601.htm) product page at davicom. Seems to clearly state USB1.1 support only.

PTVupgrade
01-03-2007, 04:08 PM
I just basing my assesment on a quick google on dm9601, which yielded this (http://www.davicom.com.tw/eng/products/dm9601.htm) product page at davicom. Seems to clearly state USB1.1 support only.

Hmmm - right you are. We'll, I'd have to assume that is correct and its likely that this (http://tekgems.com/Products/la-lc05.htm) is incorrect. I had to do some sleuthing to figure out that this adapter was based upon this chipset, and I'm pretty sure I'm correct in that assessment, so my only guess at this point is that our friends in China may have pulled a fast one?

Bizarre.

Jamie
01-03-2007, 04:21 PM
Hmmm - right you are. We'll, I'd have to assume that is correct and its likely that this (http://tekgems.com/Products/la-lc05.htm) is incorrect. I had to do some sleuthing to figure out that this adapter was based upon this chipset, and I'm pretty sure I'm correct in that assessment, so my only guess at this point is that our friends in China may have pulled a fast one?

Bizarre.You really have to be careful when reading usb speed specs. A 12mbps usb 1.1 device can be labelled as "usb 2.0 fullspeed" but not "usb 2.0 hi-speed': link (http://arstechnica.com/news.ars/post/20031003-2927.html). The nomenclature seems to be designed to confuse. If you don't see the "hi-speed" logo and/or a 480mbps spec, it probably isn't.

mchipser
01-04-2007, 12:31 AM
is there a full current change log???

I am curious if the SMC2208USB is reconized as a USB 2.0 device or still a USB 1.0 device

Thanks

Myk3

drez
01-04-2007, 01:22 AM
The backport drivers don't magically turn a USB 1.0 device (like your SMC2208) into a USB 2.0 device.

If you're going to use the backport drivers, I recommend this $12 USB 2.0 ethernet adapter (http://www.outpost.com/product/4415686).

mchipser
01-04-2007, 08:31 AM
sorry about that.. for some reason i thought the smc was a usb 2 device.. i purchased a linksys 200m v2 and it works with the new drivers

thanks

myk3

gfb107
02-11-2007, 06:38 PM
I thought I did all my homework to make sure I could do jumbo frames.

HDVR2 & HR10-250
Airlink101 AGIGAUSB adapters

Switch
Switch: Netgear GS605 v2 5 port 10/100/1000 Switch (which claims Jumbo Frame Support (9,000) on the website and on the box)

PC NIC
Intel(R) PRO/1000 GT Desktop Adapter w/ Jumbo Frame support set to 9014 bytes in Device Manager -> Advanced. The choices are 16128 bytes 4088 bytes 9014 bytes disabled

When I telnet into my DTiVo and run

ifconfig eth0 down; ifconfig eth0 mtu 9000; ifconfig eth0 up
The command succeeds, and I can run a plain ifconfig to verify the new setting, but if I run the ps command the telnet session locks up.

I've tried setting the mtu using ifconfig as low as 2000, and that also locks up the telnet session with any command that returns more than a screen of data.

Anybody have any ideas?

Jamie
02-11-2007, 06:57 PM
I thought I did all my homework to make sure I could do jumbo frames.

HDVR2 & HR10-250
Airlink101 AGIGAUSB adapters

Switch
Switch: Netgear GS605 v2 5 port 10/100/1000 Switch (which claims Jumbo Frame Support (9,000) on the website and on the box)

PC NIC
Intel(R) PRO/1000 GT Desktop Adapter w/ Jumbo Frame support set to 9014 bytes in Device Manager -> Advanced. The choices are 16128 bytes 4088 bytes 9014 bytes disabled

When I telnet into my DTiVo and run

ifconfig eth0 down; ifconfig eth0 mtu 9000; ifconfig eth0 up
The command succeeds, and I can run a plain ifconfig to verify the new setting, but if I run the ps command the telnet session locks up.

I've tried setting the mtu using ifconfig as low as 2000, and that also locks up the telnet session with any command that returns more than a screen of data.

Anybody have any ideas?You might look at the suggestions and tools in this (http://www.dealdatabase.com/forum/showthread.php?t=52699&highlight=tracepath) thread. It sounds to me like it is an mtu problem, and, as always, I'm suspicious of the PC side :) Firewall and VPN software are known to cause problems.

gfb107
02-12-2007, 09:45 PM
Thanks for the help Jamie.

As it turns out, my problem was in my cables. I hadn't noticed that the status lights on the GS605 switch showed only a 100Mb/s connection to the AGIGAUSB adapters attached to my HR10-250 and HDVR2-1. Apparently jumbo frames don't work at 100Mb/s. Simply switching out those cables resolved my problems.

Here's my netperf results:
PC to HR10-250:
C:\netperf>netclient -H hr10-250 -C -c -- -S 65536 -s 65536
TCP STREAM TEST to hr10-250
Recv Send Send Utilization Service Demand
Socket Socket Message Elapsed Send Recv Send Recv
Size Size Size Time Throughput local remote local remote
bytes bytes bytes secs. 10^6bits/s % L % ? us/KB us/KB

131070 65536 65536 10.00 25.22 -0.39 69.37 -1.259 225.347
HR10-250 to PC:
HighDef-TiVo# netperf -H 192.168.1.115 -C -c -- -S 65536 -s 65536
TCP STREAM TEST to 192.168.1.115
Recv Send Send Utilization Service Demand
Socket Socket Message Elapsed Send Recv Send Recv
Size Size Size Time Throughput local remote local remote
bytes bytes bytes secs. 10^6bits/s % S % L us/KB us/KB

65536 131070 131070 10.02 49.94 99.90 3.59 163.876 5.892

PC to HDVR2:

C:\netperf>netclient -H hdvr2-1 -C -c -- -S 65536 -s 65536
TCP STREAM TEST to hdvr2-1
Recv Send Send Utilization Service Demand
Socket Socket Message Elapsed Send Recv Send Recv
Size Size Size Time Throughput local remote local remote
bytes bytes bytes secs. 10^6bits/s % L % ? us/KB us/KB

131070 65536 65536 10.00 19.56 2.06 70.60 8.620 295.747

HDVR2 to PC:

Family-TiVo# netperf -H 192.168.1.115 -C -c -- -S 65536 -s 65536
TCP STREAM TEST to 192.168.1.115
Recv Send Send Utilization Service Demand
Socket Socket Message Elapsed Send Recv Send Recv
Size Size Size Time Throughput local remote local remote
bytes bytes bytes secs. 10^6bits/s % S % L us/KB us/KB

65536 131070 131070 10.02 47.51 99.90 3.67 172.251 6.325


C:\mturoute>mturoute hr10-250
* ICMP Fragmentation is not permitted. *
* Maximum payload is 10000 bytes. *
+ ICMP payload of 5046 bytes succeeded.
+ ICMP payload of 7523 bytes succeeded.
+ ICMP payload of 8761 bytes succeeded.
- ICMP payload of 9380 bytes failed..
- ICMP payload of 9070 bytes failed..
+ ICMP payload of 8915 bytes succeeded.
- ICMP payload of 8992 bytes failed..
+ ICMP payload of 8953 bytes succeeded.
+ ICMP payload of 8972 bytes succeeded.
- ICMP payload of 8982 bytes failed..
- ICMP payload of 8977 bytes failed..
- ICMP payload of 8974 bytes failed..
- ICMP payload of 8973 bytes failed..
+ ICMP payload of 8972 bytes succeeded.
+ ICMP payload of 8972 bytes succeeded.
Path MTU: 9000 bytes.


C:\mturoute>mturoute hdvr2-1
* ICMP Fragmentation is not permitted. *
* Maximum payload is 10000 bytes. *
+ ICMP payload of 5046 bytes succeeded.
+ ICMP payload of 7523 bytes succeeded.
+ ICMP payload of 8761 bytes succeeded.
- ICMP payload of 9380 bytes failed..
- ICMP payload of 9070 bytes failed..
+ ICMP payload of 8915 bytes succeeded.
- ICMP payload of 8992 bytes failed..
+ ICMP payload of 8953 bytes succeeded.
+ ICMP payload of 8972 bytes succeeded.
- ICMP payload of 8982 bytes failed..
- ICMP payload of 8977 bytes failed..
- ICMP payload of 8974 bytes failed..
- ICMP payload of 8973 bytes failed..
+ ICMP payload of 8972 bytes succeeded.
+ ICMP payload of 8972 bytes succeeded.
Path MTU: 9000 bytes.

xcross
02-25-2007, 10:36 AM
Newbie question here. I've got a linksys wusb54gc that I would like to try to make work. Apparently its not well supported even under recent 2.6 kernels but I have found a "beta" driver for its rt2570 chipset. What is involved at a high level to backport a particular driver to be compatible with this package?

(And in case I get lazy and just want to watch TV on my Tivo, what's an easy to find adapter with the at76c503 chipset I see in your readme? My wife is holding her tongue about the ethernet cable snaking across the living room and up the entertainment center but that won't last forever...)

BTW, I finally did turn off the TV and haul out the screwdriver and follow the steps to get to where I can telnet to the Tivo and do lsmod. Kudos to Jaimie and this crew for making that possible.

thanks,
chris

Jamie
02-28-2007, 06:30 PM
Newbie question here. I've got a linksys wusb54gc that I would like to try to make work. Apparently its not well supported even under recent 2.6 kernels but I have found a "beta" driver for its rt2570 chipset. What is involved at a high level to backport a particular driver to be compatible with this package?It's generally a fair bit of work. A lot of data structures have changed between 2.4 and 2.6, so you are really writing 2.4 code from scratch using the 2.6 driver for general concepts and approaches.
(And in case I get lazy and just want to watch TV on my Tivo, what's an easy to find adapter with the at76c503 chipset I see in your readme? My wife is holding her tongue about the ethernet cable snaking across the living room and up the entertainment center but that won't last forever...)I don't do wireless and don't test the backport drivers with wireless devices, so generally I'm reluctant to suggest anything.

cyklfreak
03-01-2007, 05:02 PM
Hey Jamie,

would you consider looking at this adapter and seeing if it can be used??

I have the drivers if needed.. it's a wired cables unlimited brand

thanks!!

Jamie
03-01-2007, 05:31 PM
Hey Jamie,

would you consider looking at this adapter and seeing if it can be used??

I have the drivers if needed.. it's a wired cables unlimited brand

thanks!!What are the usb vendor/product codes? 07a6/8515? It looks it is a pegasus II chip and newer versions of the pegasus linux driver support it. As far as I can tell, all the older pegasus supported adapters where usb1.1, so it might take some overhauling of the code to get decent performance out of a usb2 device.

The first step would be to add the vender/prod codes to pegasus.h to see if it just works. Here's what comes from the linux-2.6 tree:

PEGASUS_DEV( "ADMtek ADM8515 \"Pegasus II\" USB-2.0 Ethernet",
VENDOR_ADMTEK, 0x8515,
DEFAULT_GPIO_RESET | PEGASUS_II )

cyklfreak
03-01-2007, 05:56 PM
i'm not an expert but this is what is in the ini file

[Manufacturer]
%ADMtek% = ADMtek

[ControlFlags]
ExcludeFromSelect = USB\VID_07A6&PID_8513

[ADMtek]
%ADM851X.DeviceDesc% = ADM8515.Ndi,USB\VID_07A6&PID_8515
%ADM851X.DeviceDesc% = ADM8511.Ndi,USB\VID_07A6&PID_8511
%ADM851X.DeviceDesc% = ADM8511.Ndi,USB\VID_07A6&PID_0986
%ADM851X.DeviceDesc% = ADM8513.Ndi,USB\VID_07A6&PID_8513


i'll try what you said and see


thnks

cyklfreak
03-01-2007, 06:42 PM
is there a certain place the pegasus.h file is or is pegasus.o what I am looking for??

sorry but I've looked and am lost!!

thanks

ScanMan
03-01-2007, 07:27 PM
is there a certain place the pegasus.h file is or is pegasus.o what I am looking for??

sorry but I've looked and am lost!!
No, it's pegasus.h that you're looking for. You won't find it on your tivo because it's a header file. So get the backport source file and you'll find pegasus.h in there. Jamie pretty much gave you the piece to copy in. Look around, you'll see similar sections. Then you'll have to recompile the 'pegasus.o' from the .c and .h files and copy that into your tivo. If you don't have a clue, I'd suggest you buy a compatible adapter...they're pretty cheap. This level of discussion really doesn't belong in the development thread.

Jamie
03-28-2007, 12:24 PM
2007/03/28 Jamie

- Add Gen05 (Series3) and TGC01 (SA DT) support for the host modules

- Provide network drivers compatible with 8.x TiVo kernels.

obj/drivers/2.4.20 -- compatible with older kernels (3.1.5, 6.x, 7.x, etc)
obj/drivers/2.4.20-8 -- compatible with 8.x kernels (8.1, 8.1.1)

- Add ADMTEK 8515 Pegasus II USB-2.0 support to the pegasus driver

Jamie
10-26-2007, 12:36 AM
2007/10/23 Jamie

Added Gen06 versions of the hosts modules, for the TiVoHD.

2.4.20-8 modules are also compatible with 9.x kernels.

forrestw
01-23-2008, 10:43 AM
Do you know if the usbnet.c in your kit has ever been ported into a linus-tree
recent 2.4 kernel? I need to support the 88772 chipset usb dongles on
x86 architecture and am trying to resolve your backport from 2.6 into
2.4.32.

thanks!

Jamie
01-23-2008, 11:22 AM
Do you know if the usbnet.c in your kit has ever been ported into a linus-tree
recent 2.4 kernel? I need to support the 88772 chipset usb dongles on
x86 architecture and am trying to resolve your backport from 2.6 into
2.4.32.This driver evolved in parallel with the 2.6 usbnet driver. I adopted some things from the 2.6 driver, and some of my changes made their way into the 2.6 kernel tree. I think the usbnet.c in the officially maintained 2.4 is pretty stagnant and hasn't been updated in a while.

I used to test changes on a linux 2.4 x86 system before porting to the tivo linux kernel source tree, but I haven't done that in quite a while. Still, I would think it wouldn't be too hard to get it to work with a current 2.4 tree on x86.

forrestw
01-23-2008, 02:23 PM
Yup, I've got it passing packets at least, just hit a kernel Oops so I've got some debugging to do.

I also have to implement the mii interface and that's not working as yet (we need to detect link on the interface) so I'll be going over the code to see if I can't figure out these issues.

when I get it all working I'll submit back to the 2.4 maint. tree.

Thanks, if you've got any tips on MII/PHY that'd be appreciated. I think your code has moved around some functionality and I need to work with the normal mii.o and ehci-hcd.o modules.

Jamie
01-23-2008, 02:43 PM
Yup, I've got it passing packets at least, just hit a kernel Oops so I've got some debugging to do.

I also have to implement the mii interface and that's not working as yet (we need to detect link on the interface) so I'll be going over the code to see if I can't figure out these issues.

when I get it all working I'll submit back to the 2.4 maint. tree.

Thanks, if you've got any tips on MII/PHY that'd be appreciated. I think your code has moved around some functionality and I need to work with the normal mii.o and ehci-hcd.o modules.Sounds good. Feel free to PM me if you have any questions.