Re: Panic when copying files

2015-12-28 Thread Thomas Bohl
For the archive:
I changed the cabling.
RW disk on SATA3_A1
RO disk on SATA3_A2
(Instead of the other way around.)
Now no more kernel panic.



Re: Panic when copying files

2015-12-28 Thread Thomas Bohl
I tried EFI for a change. Same panic there:

# time cp -R /mnt/BackupDisk/Tag.0/a/b/c/* /home/c
panic: kernel diagnostic assertin "(cmd & AHCI_PREG_CMD_CR) == 0"
failed: files "../../../../dev/ic/ahci.c", line 2513
wsdisplay_switch2: not switching
Stopped at  Debugger+0x9:   leave
   TIDPIDUID PRFLAGS PFLAGS  CPU  COMMAND
Debugger() at Debugger+0x9
panic() at panic+0xfe
__assert() at __assert+0x25
ahci_port_read_ncp_error() at ahci_port_read_ncp_error+0x251
ahci_port_intr() at ahci_port_intr+0x73c
ahci_intr() at ahci_intr+0x5b
intr_handler() at intr_handler+0x67
Xintr_ioapic_edge23() at Xintr_ioapic_ewdsgdei2s3p+10axyc_9s
h-i-n-g  tc
h-i-n-g interrupt ---tc
tacchp2i:c pnuo_ti dslwei(t)c haitn ga
dw   2
:c pnuo_ti dslwei_tccyhcilneg(
cle+0x10  y
end trace frame: 0x0, count: 5

ddb{0}> trace
Debugger() at Debugger+0x9
panic() at panic+0xfe
__assert() at __assert+0x25
ahci_port_read_ncp_error() at ahci_port_read_ncp_error+0x251
ahci_port_intr() at ahci_port_intr+0x73c
ahci_intr() at ahci_intr+0x5b
intr_handler() at intr_handler+0x67
Xintr_ioapic_edge23() at Xintr_ioapic_edge23+0xc9
--- interrupt ---
acpicpu_idle() at acpicpu_idle+0x22d
cpu_idle_cycle() at cpu_idle_cycle+0x10
end trace frame: 0x0, count: -10

ddb{0}> mach ddbcpu 1
Stopped at  Debugger+0x9:   leave
Debugger() at Debugger+0x9
x86_ipi_handler() at x86_ipi_handler+0x76
Xresume_lapic_ipi()at Xresume_lapic_ipi+0x1c
--- interrupt ---
acpicpu_idle() at acpicpu_idle+0x22d
cpu_idle_cycle() at cpu_idle_cycle+0x10
end trace frame: 0x0, count: 10
ddb{1}> trace
Debugger() at Debugger+0x9
x86_ipi_handler() at x86_ipi_handler+0x76
Xresume_lapic_ipi() at Xresume_lapic_ipi+0x1c
--- interrupt ---
acpicpu_idle() at acpicpu_idle+0x22d
cpu_idle_cycle() at cpu_idle_cycle+0x10
end trace frame: 0x0, count: -5

ddb{1}> mach ddbcpu 2
Stopped at  Debugger+0x9:   leave
Debugger() at Debugger+0x9
x86_ipi_handler() at x86_ipi_handler+0x76
Xresume_lapic_ipi()at Xresume_lapic_ipi+0x1c
--- interrupt ---
acpicpu_idle() at acpicpu_idle+0x22d
cpu_idle_cycle() at cpu_idle_cycle+0x10
end trace frame: 0x0, count: 10
ddb{2}> trace
Debugger() at Debugger+0x9
x86_ipi_handler() at x86_ipi_handler+0x76
Xresume_lapic_ipi() at Xresume_lapic_ipi+0x1c
--- interrupt ---
acpicpu_idle() at acpicpu_idle+0x22d
cpu_idle_cycle() at cpu_idle_cycle+0x10
end trace frame: 0x0, count: -5

ddb{2}> mach ddbcpu 3
Stopped at  Debugger+0x9:   leave
Debugger() at Debugger+0x9
x86_ipi_handler() at x86_ipi_handler+0x76
Xresume_lapic_ipi()at Xresume_lapic_ipi+0x1c
--- interrupt ---
acpicpu_idle() at acpicpu_idle+0x22d
cpu_idle_cycle() at cpu_idle_cycle+0x10
end trace frame: 0x0, count: 10
ddb{3}> trace
Debugger() at Debugger+0x9
x86_ipi_handler() at x86_ipi_handler+0x76
Xresume_lapic_ipi() at Xresume_lapic_ipi+0x1c
--- interrupt ---
acpicpu_idle() at acpicpu_idle+0x22d
cpu_idle_cycle() at cpu_idle_cycle+0x10
end trace frame: 0x0, count: -5

ddb{3}> ps
   TID   PPID   PGRPUID  S   FLAGS  WAIT   COMMAND
  8960  15339   8960  0  3 0x3  bioait cp
 16465  18320  16465  0  30x83  poll   systat
 26860  0  0  0  3 0x14200  bored  srdis
 22457  1  22457  0  30x100083  ttyin  getty
 10940  1  10940  0  30x100083  ttyin  getty
 30641  1  30641  0  30x100083  ttyin  getty
 18320  1  18320  0  30x10008b  pause  ksh
 15339  1  15339  0  30x10008b  pause  ksh
  2381  1   2381  0  30x100098  pool   cron
 14885  1  14885 99  30x100090  pool   sndiod
 25921  1  25921110  30x100090  pool   sndiod
 19894  26249  26249 95  30x100090  kqread smtpd
 19281  26249  26249 95  30x100090  kqread smtpd
 10089  26249  26249 95  30x100090  kqread smtpd
 25084  26249  26249 95  30x100090  kqread smtpd
 24862  26249  26249 95  30x100090  kqread smtpd
 15496  26249  26249103  30x100090  kqread smtpd
 26249  1  26249  0  30x100090  kqread smtpd
 16966  1  16966  0  30x80  select sshd
 22068  28619  22385 83  30x100090  poll   ntpd
 28619  22385  22385 83  30x100090  poll   ntpd
 22385  1  22385  0  30x100080  poll   ntpd
  9328  28932  28932 74  30x100090  bpfpflogd
 28932  1  28932  0  30x80  netio  pflogd
  5510   9277   9277 73  30x100090  kqread syslogd
  9277  1   9277  0  30x100080  netio  syslogd
 12989  1  12989 77  30x100090  poll   dhclient
 28690  1  28690  0  30x80  poll   dhclient
 23316  0  0  0  3 0x14200  pgzero zerothread
  2296  0  0  0  3 0x14200  

Panic when copying files

2015-12-26 Thread Thomas Bohl
Hello,

when copying files from one harddisk to another, which are both
connected via the same SATA3 ASMedia ASM1061 controller, there
eventually will be a kernel panic on my setup. It's reproducible, but
the timing is different on each run of cp -R.
Copying files to a harddisk on the Intel controller works without a problem.

(Already tried two different hard disks. Could still be a hardware
issue, though.)

I was able to take pictures of ddb.

# uname -a
OpenBSD sw2.cve.local 5.9 GENERIC.MP#1778 amd64

# dmesg
OpenBSD 5.9-beta (GENERIC.MP) #1778: Wed Dec 23 18:23:06 MST 2015
dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
real mem = 17014210560 (16226MB)
avail mem = 16494436352 (15730MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.8 @ 0xecec0 (18 entries)
bios0: vendor American Megatrends Inc. version "C1.60" date 12/15/2015
bios0: ASRock N3700-ITX
acpi0 at bios0: rev 2
acpi0: sleep states S0 S4 S5
acpi0: tables DSDT FACP APIC FPDT FIDT AAFT MCFG HPET SSDT SSDT SSDT
UEFI LPIT CSRT SSDT
acpi0: wakeup devices PS2K(S4) PS2M(S4) UAR1(S4) UR11(S1) UR12(S1)
UR13(S1) UR14(S1) XHC1(S4) HDEF(S4) PXSX(S4) RP01(S4) PXSX(S4) RP02(S4)
PXSX(S4) RP03(S4) PXSX(S4) [...]
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Pentium(R) CPU N3700 @ 1.60GHz, 1600.43 MHz
cpu0:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,MOVBE,POPCNT,DEADLINE,AES,RDRAND,NXE,LONG,LAHF,3DNOWP,PERF,ITSC,SMEP,ERMS,SENSOR,ARAT
cpu0: 1MB 64b/line 16-way L2 cache
cpu0: smt 0, core 0, package 0
mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges
cpu0: apic clock running at 80MHz
cpu0: mwait min=64, max=64, C-substates=0.2.0.0.0.0.3.3, IBE
cpu1 at mainbus0: apid 2 (application processor)
cpu1: Intel(R) Pentium(R) CPU N3700 @ 1.60GHz, 1600.01 MHz
cpu1:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,MOVBE,POPCNT,DEADLINE,AES,RDRAND,NXE,LONG,LAHF,3DNOWP,PERF,ITSC,SMEP,ERMS,SENSOR,ARAT
cpu1: 1MB 64b/line 16-way L2 cache
cpu1: smt 0, core 1, package 0
cpu2 at mainbus0: apid 4 (application processor)
cpu2: Intel(R) Pentium(R) CPU N3700 @ 1.60GHz, 1600.01 MHz
cpu2:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,MOVBE,POPCNT,DEADLINE,AES,RDRAND,NXE,LONG,LAHF,3DNOWP,PERF,ITSC,SMEP,ERMS,SENSOR,ARAT
cpu2: 1MB 64b/line 16-way L2 cache
cpu2: smt 0, core 2, package 0
cpu3 at mainbus0: apid 6 (application processor)
cpu3: Intel(R) Pentium(R) CPU N3700 @ 1.60GHz, 1600.01 MHz
cpu3:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,MOVBE,POPCNT,DEADLINE,AES,RDRAND,NXE,LONG,LAHF,3DNOWP,PERF,ITSC,SMEP,ERMS,SENSOR,ARAT
cpu3: 1MB 64b/line 16-way L2 cache
cpu3: smt 0, core 3, package 0
ioapic0 at mainbus0: apid 1 pa 0xfec0, version 20, 115 pins
acpimcfg0 at acpi0 addr 0xe000, bus 0-255
acpihpet0 at acpi0: 14318179 Hz
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 1 (RP01)
acpiprt2 at acpi0: bus 2 (RP02)
acpiprt3 at acpi0: bus 3 (RP03)
acpiprt4 at acpi0: bus 4 (RP04)
acpiec0 at acpi0: not present
acpicpu0 at acpi0
C2: state 6: substate 8 >= num 3
C3: state 7: substate 4 >= num 3: C1(1000@1 mwait.1), PSS
acpicpu1 at acpi0
C2: state 6: substate 8 >= num 3
C3: state 7: substate 4 >= num 3: C1(1000@1 mwait.1), PSS
acpicpu2 at acpi0
C2: state 6: substate 8 >= num 3
C3: state 7: substate 4 >= num 3: C1(1000@1 mwait.1), PSS
acpicpu3 at acpi0
C2: state 6: substate 8 >= num 3
C3: state 7: substate 4 >= num 3: C1(1000@1 mwait.1), PSS
acpipwrres0 at acpi0: CLK0, resource for CAMD
acpipwrres1 at acpi0: CLK0, resource for CAM1
acpipwrres2 at acpi0: CLK1, resource for CAM2, CAM3
acpipwrres3 at acpi0: USBC, resource for XHC1
acpibat0 at acpi0: BAT0 not present
acpibat1 at acpi0: BAT1 not present
acpibat2 at acpi0: BAT2 not present
acpibtn0 at acpi0: LID0
acpibtn1 at acpi0: PWRB
acpibtn2 at acpi0: SLPB
acpivideo0 at acpi0: GFX0
acpivout0 at acpivideo0: DD1F
cpu0: Enhanced SpeedStep 1600 MHz: speeds: 1601, 1600, 1520, 1440, 1360,
1280, 1200, 1120, 1040, 960, 880, 800, 720, 640, 560, 480 MHz
pci0 at mainbus0 bus 0
pchb0 at pci0 dev 0 function 0 "Intel Braswell Host" rev 0x21
vga1 at pci0 dev 2 function 0 "Intel HD Graphics" rev 0x21
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
ahci0 at pci0 dev 19 function 0 "Intel Braswell AHCI" rev 0x21: