Buffalo TeraStation WS-WVL/R1

From Leo's Notes
Last edited on 22 March 2022, at 05:37.

The Buffalo TeraStation WS-WVL/R1 is a two disk consumer network attached storage (NAS) unit manufactured by Buffalo Technology. It is very similar to the Buffalo TeraStation TS5400 but appears to be using a generation older CPU and memory.

This unit was first made available from around 2012.

CPU Intel Atom D510 1.66GHz (Dual Core)
RAM 1x 2GB DDR2 800MHz SODIMM
Chipset Intel ICH9
Disk 2x SATA II, AHCI
Network 2x Marvell Technology Group Ltd. Yukon Optima 88E8059
USB 2x USB 2.0, and 2x USB 3.0
Serial 1 rear serial port
Video 1 VGA output

I ordered this unit from Ebay for $55 including shipping. This unit is somewhat different from the TS4500. The main motherboard looks almost identical to the one in the TS4500 but resides on the bottom of the unit rather than on the side.

Linux Drivers

Network

The network adapter does not work 'out of the box' with CentOS 8. After some head scratching, you need to install the sky2 kernel module.

lspci shows the following devices:

00:00.0 Host bridge [0600]: Intel Corporation Atom Processor D4xx/D5xx/N4xx/N5xx DMI Bridge [8086:a000] (rev 02)
00:02.0 VGA compatible controller [0300]: Intel Corporation Atom Processor D4xx/D5xx/N4xx/N5xx Integrated Graphics Controller [8086:a001] (rev 02)
00:02.1 Display controller [0380]: Intel Corporation Atom Processor D4xx/D5xx/N4xx/N5xx Integrated Graphics Controller [8086:a002] (rev 02)
00:1c.0 PCI bridge [0604]: Intel Corporation 82801I (ICH9 Family) PCI Express Port 1 [8086:2940] (rev 02)
00:1c.4 PCI bridge [0604]: Intel Corporation 82801I (ICH9 Family) PCI Express Port 5 [8086:2948] (rev 02)
00:1c.5 PCI bridge [0604]: Intel Corporation 82801I (ICH9 Family) PCI Express Port 6 [8086:294a] (rev 02)
00:1d.0 USB controller [0c03]: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #1 [8086:2934] (rev 02)
00:1d.1 USB controller [0c03]: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #2 [8086:2935] (rev 02)
00:1d.2 USB controller [0c03]: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #3 [8086:2936] (rev 02)
00:1d.7 USB controller [0c03]: Intel Corporation 82801I (ICH9 Family) USB2 EHCI Controller #1 [8086:293a] (rev 02)
00:1e.0 PCI bridge [0604]: Intel Corporation 82801 PCI Bridge [8086:244e] (rev 92)
00:1f.0 ISA bridge [0601]: Intel Corporation 82801IR (ICH9R) LPC Interface Controller [8086:2916] (rev 02)
00:1f.2 SATA controller [0106]: Intel Corporation 82801IR/IO/IH (ICH9R/DO/DH) 6 port SATA Controller [AHCI mode] [8086:2922] (rev 02)
02:00.0 Ethernet controller [0200]: Marvell Technology Group Ltd. Yukon Optima 88E8059 [PCIe Gigabit Ethernet Controller with AVB] [11ab:4381] (rev 11)
03:00.0 Ethernet controller [0200]: Marvell Technology Group Ltd. Yukon Optima 88E8059 [PCIe Gigabit Ethernet Controller with AVB] [11ab:4381] (rev 11)
04:00.0 USB controller [0c03]: NEC Corporation uPD720200 USB 3.0 Host Controller [1033:0194] (rev 03)

Searching around showed that around 10 years ago, the sk98lin driver that was provided by Marvell was used. In fact, according to ElRepo's DeviceID page, the PCI device 11AB:4381 which this NAS has uses kmod-sk98lin. This driver was only available up to EL6 and targeted the 2.6 kernel and was never brought forward (or so I thought). I tried compiling it on the 4.18 kernel but the net_devices struct changed which couldn't be worked around.

After digging around some more, it looks like this driver was rewritten as sky2. ElRepo has a kmod-sky2 package for EL8 at http://elrepo.reloumirrors.net/elrepo/el8/x86_64/RPMS/. After installing this package, and rebooting the machine, the two interfaces came up.

LAN1 showed up as enp2s0 and LAN2 as enp3s0.

Addendum: Sky2 errors

The sky2 driver works for the most part but it generates a lot of errors especially under load. In dmesg, the sky2 driver will constantly spew the following:

[15011.700130] sky2 0000:02:00.0: error interrupt status=0x40000008
[15011.701243] sky2 0000:02:00.0 enp2s0: rx error, status 0x7ffc0001 length 820
[15015.121232] sky2 0000:02:00.0: error interrupt status=0x40000008
[15015.131694] sky2 0000:02:00.0 enp2s0: rx error, status 0x7ffc0001 length 996
[15015.186430] sky2 0000:02:00.0: error interrupt status=0x40000008
[15015.187119] sky2 0000:02:00.0 enp2s0: rx error, status 0x7ffc0001 length 996
[15016.402909] sky2 0000:02:00.0: error interrupt status=0x40000008
[15016.409942] sky2 0000:02:00.0 enp2s0: rx error, status 0x7ffc0001 length 996
[15017.344621] sky2 0000:02:00.0: error interrupt status=0x40000008
[15017.345388] sky2 0000:02:00.0 enp2s0: rx error, status 0x7ffc0001 length 996

The length values range from as low as 76 to as high as 1510 with the majority of them being 996. Out of the 4570 records in dmesg, these were the frequency of each length I found:

4098 996
168 908
122 716
36 916
15 628
11 820
9 668
7 844
7 436
6 836
5 156
4 804

Looking through the source, there is a note which blames the Yukon NIC hardware for misbehaving and generating invalid statuses. More info on this issue in the Linux mailing list. The hacky code targets the Yukon-2 FE+ network adapter but not the Yukon Optima that this device is using. Perhaps the driver can be patched so this NIC uses the hacky code that circumvents these errors from being reported?

USB 3.0

The USB controller is a NEC Corporation uPD720200 USB 3.0. When using an external hard drive with either of the two USB 3.0 ports, I am experiencing that reads from the disk are fine (I get about 130MB/s) but writes fail. When writing to an external drive connected to the USB 3.0 port, the external disk appears to hang. The same disk connected to the USB 2.0 port works just fine, but limited to the 2.0 speed (35MB/s).

Kernel logs show the following set of messages over and over as it tries to reset the device to no avail.

[Mon Nov 23 15:57:09 2020] sd 7:0:0:0: [sdd] tag#28 uas_eh_abort_handler 0 uas-tag 2 inflight: CMD
[Mon Nov 23 15:57:09 2020] sd 7:0:0:0: [sdd] tag#28 CDB: Write(10) 2a 00 00 03 84 00 00 04 00 00
[Mon Nov 23 15:57:09 2020] sd 7:0:0:0: [sdd] tag#27 uas_eh_abort_handler 0 uas-tag 21 inflight: CMD OUT
[Mon Nov 23 15:57:09 2020] sd 7:0:0:0: [sdd] tag#27 CDB: Write(10) 2a 00 00 03 d4 00 00 04 00 00
[Mon Nov 23 15:57:09 2020] sd 7:0:0:0: [sdd] tag#26 uas_eh_abort_handler 0 uas-tag 20 inflight: CMD OUT
[Mon Nov 23 15:57:09 2020] sd 7:0:0:0: [sdd] tag#26 CDB: Write(10) 2a 00 00 03 d0 00 00 04 00 00
[Mon Nov 23 15:57:09 2020] usb 6-1: stat urb: no pending cmd for uas-tag 2
[Mon Nov 23 15:57:09 2020] sd 7:0:0:0: [sdd] tag#25 uas_eh_abort_handler 0 uas-tag 19 inflight: CMD OUT
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#25 CDB: Write(10) 2a 00 00 03 cc 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#24 uas_eh_abort_handler 0 uas-tag 18 inflight: CMD OUT
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#24 CDB: Write(10) 2a 00 00 03 c8 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#23 uas_eh_abort_handler 0 uas-tag 17 inflight: CMD OUT
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#23 CDB: Write(10) 2a 00 00 03 c4 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#22 uas_eh_abort_handler 0 uas-tag 16 inflight: CMD OUT
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#22 CDB: Write(10) 2a 00 00 03 c0 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#21 uas_eh_abort_handler 0 uas-tag 15 inflight: CMD OUT
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#21 CDB: Write(10) 2a 00 00 03 bc 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#20 uas_eh_abort_handler 0 uas-tag 14 inflight: CMD OUT
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#20 CDB: Write(10) 2a 00 00 03 b8 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] usb 6-1: stat urb: no pending cmd for uas-tag 14
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#19 uas_eh_abort_handler 0 uas-tag 13 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#19 CDB: Write(10) 2a 00 00 03 b4 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#18 uas_eh_abort_handler 0 uas-tag 12 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#18 CDB: Write(10) 2a 00 00 03 b0 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#17 uas_eh_abort_handler 0 uas-tag 11 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#17 CDB: Write(10) 2a 00 00 03 ac 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#16 uas_eh_abort_handler 0 uas-tag 10 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#16 CDB: Write(10) 2a 00 00 03 a8 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#15 uas_eh_abort_handler 0 uas-tag 9 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#15 CDB: Write(10) 2a 00 00 03 a0 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#14 uas_eh_abort_handler 0 uas-tag 8 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#14 CDB: Write(10) 2a 00 00 03 9c 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#13 uas_eh_abort_handler 0 uas-tag 7 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#13 CDB: Write(10) 2a 00 00 03 98 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#12 uas_eh_abort_handler 0 uas-tag 6 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#12 CDB: Write(10) 2a 00 00 03 94 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#11 uas_eh_abort_handler 0 uas-tag 5 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#11 CDB: Write(10) 2a 00 00 03 90 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#10 uas_eh_abort_handler 0 uas-tag 4 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#10 CDB: Write(10) 2a 00 00 03 8c 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#9 uas_eh_abort_handler 0 uas-tag 3 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#9 CDB: Write(10) 2a 00 00 03 88 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#8 uas_eh_abort_handler 0 uas-tag 1 inflight:
[Mon Nov 23 15:57:10 2020] sd 7:0:0:0: [sdd] tag#8 CDB: Write(10) 2a 00 00 03 a4 00 00 04 00 00
[Mon Nov 23 15:57:10 2020] scsi host7: uas_eh_device_reset_handler start
[Mon Nov 23 15:57:10 2020] usb 6-1: reset SuperSpeed Gen 1 USB device number 7 using xhci_hcd
[Mon Nov 23 15:57:10 2020] scsi host7: uas_eh_device_reset_handler success

This is most likely due to a misbehaving UAS device. This was resolved after disabling UAS. Once UAS is disabled, you should see "UAS is blacklisted for this device, using usb-storage instead" in dmesg when the system boots or when the device is plugged in.

Sensors and Fan

The fan was on full blast from the moment it turned on. It is very audible.

lm_sensors detected the following temperatures and voltages. Temp 1 & 2 appears to be the CPU temperature while temp3 appears to be the ambient temperature.

coretemp-isa-0000
Adapter: ISA adapter
Core 0:       +42.0°C  (crit = +100.0°C)
Core 1:       +45.0°C  (crit = +100.0°C)

it8721-isa-0a10
Adapter: ISA adapter
in0:          +2.93 V  (min =  +0.97 V, max =  +1.02 V)  ALARM
in1:          +2.75 V  (min =  +1.66 V, max =  +2.93 V)
in2:          +1.98 V  (min =  +0.79 V, max =  +0.01 V)  ALARM
+3.3V:        +3.26 V  (min =  +2.02 V, max =  +1.54 V)  ALARM
in4:          +1.07 V  (min =  +1.25 V, max =  +1.63 V)  ALARM
in5:          +2.22 V  (min =  +2.20 V, max =  +0.30 V)  ALARM
in6:          +1.79 V  (min =  +0.01 V, max =  +0.55 V)  ALARM
3VSB:         +3.24 V  (min =  +1.39 V, max =  +1.58 V)  ALARM
Vbat:         +2.98 V
fan1:           0 RPM  (min =   12 RPM)  ALARM
fan2:           0 RPM  (min =  293 RPM)  ALARM
fan3:           0 RPM  (min =   21 RPM)  ALARM
temp1:        +58.0°C  (low  = +36.0°C, high = +49.0°C)  ALARM  sensor = thermal diode
temp2:        +57.0°C  (low  = +66.0°C, high = +32.0°C)  ALARM  sensor = thermal diode
temp3:        +25.0°C  (low  =  +9.0°C, high =  +1.0°C)  ALARM  sensor = thermal diode
intrusion0:  ALARM

The fan speed to PWM correlation shows that the fan on this unit is really all or nothing which explains why it is on full.

PWM 255 FAN 1928
PWM 240 FAN 1934
PWM 225 FAN 1934
PWM 210 FAN 1934
PWM 195 FAN 1928
PWM 180 FAN 1928
PWM 165 FAN 1928
PWM 150 FAN 1923
PWM 135 FAN 1917
PWM 120 FAN 1912
PWM 105 FAN 1906
PWM 90 FAN 1906
PWM 75 FAN 1896
PWM 60 FAN 1890
PWM 45 FAN 1885
PWM 30 FAN 1869
PWM 28 FAN 1869
PWM 26 FAN 1869
PWM 24 FAN 1869
PWM 22 FAN 1864
PWM 20 FAN 1869
PWM 18 FAN 1864
PWM 16 FAN 1864
PWM 14 FAN 1859
PWM 12 FAN 1864
PWM 10 FAN 1854
PWM 8 FAN 1854
PWM 6 FAN 1859
PWM 4 FAN 1859
PWM 2 FAN 1854
PWM 0 FAN 0
Fan Stopped at PWM = 0

I can only get some quiet after setting the MINPWM to 0 and MINSTART to 1 in /etc/fancontrol.


See Also