[Bug 213713] xhci and ehci interrupt storms

2016-10-22 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=213713

Bug ID: 213713
   Summary: xhci and ehci interrupt storms
   Product: Base System
   Version: CURRENT
  Hardware: amd64
OS: Any
Status: New
  Severity: Affects Only Me
  Priority: ---
 Component: usb
  Assignee: freebsd-usb@FreeBSD.org
  Reporter: jailb...@fdf.net
CC: freebsd-am...@freebsd.org
CC: freebsd-am...@freebsd.org

Created attachment 176069
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=176069=edit
output from dmesg, vmstat -i, usbconfig, and debug sysctls

I have 2 Lenovo ThinkServer RD450 machines that are pretty much identical:

Intel Haswell Xeon E5-2630 CPUs
2 SD cards in internal SD/USB adapters in a ZFS mirror for booting
6 4TB Hitachi SAS drives (ZFS "RAID-10")
2 200GB Seagate SAS SSDs (1 SLOG, 1 L2ARCH)

These used to work perfectly probably around 10 months ago using then -CURRENT
(which was 11.x before the first BETAs/RCs).  Since then they've pretty much
been powered off and I'm trying to revive them.  So far I've tried both
11-STABLE and 12-CURRENT. Under both of them, sometimes booting dies as the USB
bus the SD adapters are on time out, which keeps the kernel from finding the
boot devices.  Other times everything works, however both the xhci0 and ehci0
interrupts receive over ~250k interrupts/second.  If I disable XHCI in the UEFI
firmware, the xhci0 interrupts obviously stop, but the ehci0 ones are
unchanged.  As I said, I don't recall this happening before, so it's either a
change that happened in the kernel, or it's something introduced by an UEFI
update (I'm on the latest that was released about a month ago).

UEFI settings that might be relevant:

PCI/PCIE Settings

SR-IOV Tech Support - Enabled
ARI Support - Enabled
Above 4GB Decoding - Enabled
ASPM Support - Auto

USB Settings

Legacy USB Support - Disabled
Port 60/64 Emulation - Disabled
XHCI - Enabled

Miscellaneous Settings

X2APIC - Enabled (toggling this doesn't seem to change the issue)

dmesg, 'vmstat -i', usbconfig, and output from setting hw.usb.debug,
hw.usb.ehci.debug, and hw.usb.xhci.debug are attached.

I got this all off of the 11-STABLE host booted off LiveUSB, so it will have an
extra device listed.  The 12-CURRENT host *NOT* booted off of LiveUSB (so
without the extra device) has the same issues.

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
freebsd-usb@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Facing serious problems after hardware upgrade with FreeBSD 10.3

2016-10-22 Thread Steven Hartland

TBH sounds like you may have some bad / incompatible hardware.

For the ata errors first thing I'd do is check cabling.

Is the disk fine if you remove the scanner from the equation (disconnect 
it)?


On 22/10/2016 19:08, Manish Jain wrote:

Hi,

I am running FreeBSD 10.3 amd64.

Over the last couple of months, I have made a major upgrade of my
computer - an upgrade which has knocked out virtually everything except
the CPU (AMD Athlon X2 270).

In phase 1 (about 2 months ago), I moved the motherboard to a new
Gigabyte SB970 based board (paired with the the old Athlon CPU) and the
hard disk to a Samsung EVO 850 SSD

In phase 2 (yesterday), I upgraded other components (new components
listed) : PSU (Corsair RM650x), RAM (Kingston HyperX, 8 GB, single
piece), DVD drive (Asus DRW-24D5MT), cabinet (Circle 821).

The USB peripherals remain the same ; mouse, keyboard, printer, scanner.

The USB scanner (Canon MG 2470 Pixma; multi-function device serving
purely as scanner) is the one that is of most interest.

After phase 2 of the upgrade was over, I have been facing this situation
(since yesterday) :

If I run 'scanimage -L' as root on the console at ttyv4 (no X), most of
the times it returns with a listing of the Canon scanner. At the same
time, on ttyv0, I also get the following diagnostics :

ata0: FAILURE - odd-sized DMA transfer attempt 5 % 2
ata0: setting up DMA failed

Once in about 2-3 tries, the command actually gets totally stuck. Not
even Control-C wakes it up. In such cases, the system usually has to be
rebooted - sometimes forcibly by hard-pressing the switch on the cabinet.

Further, at the time I boot, I sometimes also see the following
diagnostics on ttyv0 :

(ada0:ata0:0:1:0): READ_DMA48. ACB: 25 00 df ea ff 40 33 00 00 00 01 00
(ada0:ata0:0:1:0): CAM status: Command timeout
(ada0:ata0:0:1:0): Retrying command

The last time I spotted the above error ("CAM status: Command timeout")
was in a single user shell running fsck after an unclean shutdown. No
other command except fsck and reboot was given to the system during that
session.

I am trying to determine whether the errors I am facing are a problem
with the hardware; with the kernel; or with the USB code. The only other
thing notable I can add is the USB scanner works seamlessly under
Windows XP (which serves as my second OS on my dual-boot machine).

If anybody can help me determine what is wrong with the system, I shall
be highly grateful - I feel practically paralysed after investing so
much time, money and energy upgrading the hardware, only to be feeling
as if now I am stuck in no man's land.


Thanks
Manish Jain
___
freebsd-usb@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


___
freebsd-usb@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Facing serious problems after hardware upgrade with FreeBSD 10.3

2016-10-22 Thread Hans Petter Selasky

On 10/22/16 20:08, Manish Jain wrote:


Hi,

I am running FreeBSD 10.3 amd64.

Over the last couple of months, I have made a major upgrade of my
computer - an upgrade which has knocked out virtually everything except
the CPU (AMD Athlon X2 270).

In phase 1 (about 2 months ago), I moved the motherboard to a new
Gigabyte SB970 based board (paired with the the old Athlon CPU) and the
hard disk to a Samsung EVO 850 SSD

In phase 2 (yesterday), I upgraded other components (new components
listed) : PSU (Corsair RM650x), RAM (Kingston HyperX, 8 GB, single
piece), DVD drive (Asus DRW-24D5MT), cabinet (Circle 821).

The USB peripherals remain the same ; mouse, keyboard, printer, scanner.

The USB scanner (Canon MG 2470 Pixma; multi-function device serving
purely as scanner) is the one that is of most interest.

After phase 2 of the upgrade was over, I have been facing this situation
(since yesterday) :

If I run 'scanimage -L' as root on the console at ttyv4 (no X), most of
the times it returns with a listing of the Canon scanner. At the same
time, on ttyv0, I also get the following diagnostics :

ata0: FAILURE - odd-sized DMA transfer attempt 5 % 2
ata0: setting up DMA failed

Once in about 2-3 tries, the command actually gets totally stuck. Not
even Control-C wakes it up. In such cases, the system usually has to be
rebooted - sometimes forcibly by hard-pressing the switch on the cabinet.

Further, at the time I boot, I sometimes also see the following
diagnostics on ttyv0 :

(ada0:ata0:0:1:0): READ_DMA48. ACB: 25 00 df ea ff 40 33 00 00 00 01 00
(ada0:ata0:0:1:0): CAM status: Command timeout
(ada0:ata0:0:1:0): Retrying command

The last time I spotted the above error ("CAM status: Command timeout")
was in a single user shell running fsck after an unclean shutdown. No
other command except fsck and reboot was given to the system during that
session.

I am trying to determine whether the errors I am facing are a problem
with the hardware; with the kernel; or with the USB code. The only other
thing notable I can add is the USB scanner works seamlessly under
Windows XP (which serves as my second OS on my dual-boot machine).

If anybody can help me determine what is wrong with the system, I shall
be highly grateful - I feel practically paralysed after investing so
much time, money and energy upgrading the hardware, only to be feeling
as if now I am stuck in no man's land.



Hi,

Did you try an 10-stable kernel?

About the USB scanner we need some more information. Did you set the 
permissions on /dev/ugenX.Y correctly?


--HPS

___
freebsd-usb@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Facing serious problems after hardware upgrade with FreeBSD 10.3

2016-10-22 Thread Manish Jain

Hi,

I am running FreeBSD 10.3 amd64.

Over the last couple of months, I have made a major upgrade of my 
computer - an upgrade which has knocked out virtually everything except 
the CPU (AMD Athlon X2 270).

In phase 1 (about 2 months ago), I moved the motherboard to a new 
Gigabyte SB970 based board (paired with the the old Athlon CPU) and the 
hard disk to a Samsung EVO 850 SSD

In phase 2 (yesterday), I upgraded other components (new components 
listed) : PSU (Corsair RM650x), RAM (Kingston HyperX, 8 GB, single 
piece), DVD drive (Asus DRW-24D5MT), cabinet (Circle 821).

The USB peripherals remain the same ; mouse, keyboard, printer, scanner.

The USB scanner (Canon MG 2470 Pixma; multi-function device serving 
purely as scanner) is the one that is of most interest.

After phase 2 of the upgrade was over, I have been facing this situation 
(since yesterday) :

If I run 'scanimage -L' as root on the console at ttyv4 (no X), most of 
the times it returns with a listing of the Canon scanner. At the same 
time, on ttyv0, I also get the following diagnostics :

ata0: FAILURE - odd-sized DMA transfer attempt 5 % 2
ata0: setting up DMA failed

Once in about 2-3 tries, the command actually gets totally stuck. Not 
even Control-C wakes it up. In such cases, the system usually has to be 
rebooted - sometimes forcibly by hard-pressing the switch on the cabinet.

Further, at the time I boot, I sometimes also see the following 
diagnostics on ttyv0 :

(ada0:ata0:0:1:0): READ_DMA48. ACB: 25 00 df ea ff 40 33 00 00 00 01 00
(ada0:ata0:0:1:0): CAM status: Command timeout
(ada0:ata0:0:1:0): Retrying command

The last time I spotted the above error ("CAM status: Command timeout") 
was in a single user shell running fsck after an unclean shutdown. No 
other command except fsck and reboot was given to the system during that 
session.

I am trying to determine whether the errors I am facing are a problem 
with the hardware; with the kernel; or with the USB code. The only other 
thing notable I can add is the USB scanner works seamlessly under 
Windows XP (which serves as my second OS on my dual-boot machine).

If anybody can help me determine what is wrong with the system, I shall 
be highly grateful - I feel practically paralysed after investing so 
much time, money and energy upgrading the hardware, only to be feeling 
as if now I am stuck in no man's land.


Thanks
Manish Jain
___
freebsd-usb@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"