Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-08-21 Thread Andriy Gapon
on 30/07/2010 17:36 Anton Shterenlikht said the following:
 On Fri, Jul 30, 2010 at 04:31:44PM +0300, Andriy Gapon wrote:
 Just a one thing to try - can you please add hdac_reset(sc, 1) call in
 hdac_attach() right before hdac_get_capabilities() call?
 The idea is to reset the controller before trying to get its capabilities.
 
 OSS became 1, no other change:
 
 % dmesg | fgrep -i hda
 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: Lazy allocation of 0x4000 bytes rid 0x10 type 3 at 0xb7fb
 hdac0: [MPSAFE]
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (0)
 hdac0: Resetting corb size to 256
 hdac0: hdac_get_capabilities: Invalid rirb size (0)
 hdac0: Resetting rirb size to 256
 hdac0: Caps: OSS 1, ISS 0, BSS 0, NSDO 1, CORB 256, RIRB 256
 hdac0: 

Just a notice that I don't have any further ideas, sorry.

-- 
Andriy Gapon
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-08-21 Thread Anton Shterenlikht
On Sat, Aug 21, 2010 at 07:20:18PM +0300, Andriy Gapon wrote:
 on 30/07/2010 17:36 Anton Shterenlikht said the following:
  On Fri, Jul 30, 2010 at 04:31:44PM +0300, Andriy Gapon wrote:
  Just a one thing to try - can you please add hdac_reset(sc, 1) call in
  hdac_attach() right before hdac_get_capabilities() call?
  The idea is to reset the controller before trying to get its capabilities.
  
  OSS became 1, no other change:
  
  % dmesg | fgrep -i hda
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: Lazy allocation of 0x4000 bytes rid 0x10 type 3 at 0xb7fb
  hdac0: [MPSAFE]
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid corb size (0)
  hdac0: Resetting corb size to 256
  hdac0: hdac_get_capabilities: Invalid rirb size (0)
  hdac0: Resetting rirb size to 256
  hdac0: Caps: OSS 1, ISS 0, BSS 0, NSDO 1, CORB 256, RIRB 256
  hdac0: 
 
 Just a notice that I don't have any further ideas, sorry.

ok, many thanks
I might be back if I get a different message in future.

manton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-08-04 Thread Gavin Atkinson
On Tue, 27 Jul 2010, Anton Shterenlikht wrote:

 On Tue, Jul 27, 2010 at 05:53:25PM +0100, Gavin Atkinson wrote:
  On Tue, 2010-07-27 at 15:47 +0100, Anton Shterenlikht wrote:
   db bt
   Tracing pid 0 tid 10 td 0x80b40de0
   kdb_enter() at kdb_enter+0x3d
   panic() at panic+0x17b
   uma_dbg_free() at uma_zfree_arg+0x62
   free() at free+0xcd
   device_set_driver() at device_set_driver+0x7c
   device_attach() at device_attach+0x1a3
  
  Thanks.  Can you try
  http://people.freebsd.org/~gavin/mexas-hda-panic.diff
  
  and see if that solves things for you?
  
  (Credit goes to avg@ for looking into this before me :)
 
 yes, thanks, the panic has gone away.

I've committed this patch, and will MFC in one week.

Thanks,

Gavin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-30 Thread Anton Shterenlikht
On Wed, Jul 28, 2010 at 08:17:47PM +0300, Andriy Gapon wrote:
 on 28/07/2010 20:13 Anton Shterenlikht said the following:
  On Wed, Jul 28, 2010 at 07:51:08PM +0300, Andriy Gapon wrote:
  on 28/07/2010 19:44 Anton Shterenlikht said the following:
But I just rebooted again, and reset
  to defaults in BIOS, now I get:
 
  % dmesg | fgrep -i hda
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid corb size (1)
  device_attach: hdac0 attach returned 6
 
  This gets even stranger.
  Ultimate attempt - can you drop the size == 0 condition, so that reset is 
  always
  tried when initial value is not correct?
  
  you mean drop both
  if (corbsize == 0) {}
  
  and
  if (rirbsize == 0) {}
  
  ?
 
 Change it to if (1) { ...}.

did that, and did a cold reboot:

% dmesg | fgrep -i hda
hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
pci0
hdac0: HDA Driver Revision: 20100226_0142
hdac0: [ITHREAD]
hdac0: hdac_get_capabilities: Invalid corb size (0)
hdac0: Resetting corb size to 256
hdac0: hdac_get_capabilities: Invalid rirb size (0)
hdac0: Resetting rirb size to 256
%

I don't think the device attached.

many thanks
anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-30 Thread Andriy Gapon
on 30/07/2010 14:57 Anton Shterenlikht said the following:
 On Wed, Jul 28, 2010 at 08:17:47PM +0300, Andriy Gapon wrote:
 Change it to if (1) { ...}.
 
 did that, and did a cold reboot:
 
 % dmesg | fgrep -i hda
 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (0)
 hdac0: Resetting corb size to 256
 hdac0: hdac_get_capabilities: Invalid rirb size (0)
 hdac0: Resetting rirb size to 256
 %
 
 I don't think the device attached.

No further interesting/related messages after those above?
Could you please try a verbose boot?

-- 
Andriy Gapon
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-30 Thread Anton Shterenlikht
On Fri, Jul 30, 2010 at 03:05:34PM +0300, Andriy Gapon wrote:
 on 30/07/2010 14:57 Anton Shterenlikht said the following:
  On Wed, Jul 28, 2010 at 08:17:47PM +0300, Andriy Gapon wrote:
  Change it to if (1) { ...}.
  
  did that, and did a cold reboot:
  
  % dmesg | fgrep -i hda
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid corb size (0)
  hdac0: Resetting corb size to 256
  hdac0: hdac_get_capabilities: Invalid rirb size (0)
  hdac0: Resetting rirb size to 256
  %
  
  I don't think the device attached.
 
 No further interesting/related messages after those above?
 Could you please try a verbose boot?

from a verbose boot:

% dmesg | fgrep -i hda
hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
pci0
hdac0: HDA Driver Revision: 20100226_0142
hdac0: Lazy allocation of 0x4000 bytes rid 0x10 type 3 at 0xb7fb
hdac0: [MPSAFE]
hdac0: [ITHREAD]
hdac0: hdac_get_capabilities: Invalid corb size (0)
hdac0: Resetting corb size to 256
hdac0: hdac_get_capabilities: Invalid rirb size (0)
hdac0: Resetting rirb size to 256
hdac0: Caps: OSS 0, ISS 0, BSS 0, NSDO 1, CORB 256, RIRB 256
hdac0: 
%

here's the full /var/run/dmesg.boot from boot -v:


Copyright (c) 1992-2010 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 9.0-CURRENT #0 r210638M: Fri Jul 30 12:16:29 BST 2010
r...@mech-aslap239.men.bris.ac.uk:/usr/obj/usr/src/sys/BUZI amd64
WARNING: WITNESS option enabled, expect reduced performance.
Table 'FACP' at 0xb7fc8084
Table 'SLIC' at 0xb7fc8220
Table 'EPTH' at 0xb7fc8398
Table 'APIC' at 0xb7fc83d0
Table 'MCFG' at 0xb7fc8434
Table 'TCPA' at 0xb7fc8470
Table 'SSDT' at 0xb7fd98db
Table 'SSDT' at 0xb7fd9934
ACPI: No SRAT table found
Preloaded elf kernel /boot/kernel/kernel at 0x810a8000.
Preloaded elf obj module /boot/kernel/zfs.ko at 0x810a8208.
Preloaded elf obj module /boot/kernel/opensolaris.ko at 0x810a88b0.
Preloaded elf obj module /boot/kernel/krpc.ko at 0x810a8ee0.
Preloaded /boot/zfs/zpool.cache /boot/zfs/zpool.cache at 0x810a9508.
Calibrating TSC clock ... TSC clock: 1994947870 Hz
CPU: AMD Turion(tm) 64 X2 Mobile Technology TL-60 (1994.95-MHz K8-class CPU)
  Origin = AuthenticAMD  Id = 0x60f82  Family = f  Model = 68  Stepping = 2
  
Features=0x178bfbffFPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,MMX,FXSR,SSE,SSE2,HTT
  Features2=0x2001SSE3,CX16
  AMD Features=0xea500800SYSCALL,NX,MMX+,FFXSR,RDTSCP,LM,3DNow!+,3DNow!
  AMD Features2=0x11fLAHF,CMP,SVM,ExtAPIC,CR8,Prefetch
L1 2MB data TLB: 8 entries, fully associative
L1 2MB instruction TLB: 8 entries, fully associative
L1 4KB data TLB: 32 entries, fully associative
L1 4KB instruction TLB: 32 entries, fully associative
L1 data cache: 64 kbytes, 64 bytes/line, 1 lines/tag, 2-way associative
L1 instruction cache: 64 kbytes, 64 bytes/line, 1 lines/tag, 2-way associative
L2 2MB unified TLB: 0 entries, disabled/not present
L2 4KB data TLB: 512 entries, 4-way associative
L2 4KB instruction TLB: 512 entries, 4-way associative
L2 unified cache: 512 kbytes, 64 bytes/line, 1 lines/tag, 16-way associative
real memory  = 3221225472 (3072 MB)
Physical memory chunk(s):
0x1000 - 0x0009bfff, 634880 bytes (155 pages)
0x010d7000 - 0xb2903fff, 2978140160 bytes (727085 pages)
avail memory = 2960908288 (2823 MB)
Event timer LAPIC frequency 0 Hz quality 500
ACPI APIC Table: HP 0944
INTR: Adding local APIC 1 as a target
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
FreeBSD/SMP: 1 package(s) x 2 core(s)
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
x86bios:   IVT 0x00-0x0004ff at 0xff00
x86bios:  SSEG 0x01-0x01 at 0xff81
x86bios:  EBDA 0x09f000-0x09 at 0xff09f000
x86bios:   ROM 0x0a-0x0e at 0xff0a
APIC: CPU 0 has ACPI ID 1
APIC: CPU 1 has ACPI ID 2
ULE: setup cpu 0
ULE: setup cpu 1
ACPI: RSDP 0xfe0b0 00024 (v02 HP)
ACPI: XSDT 0xb7fc81bc 00064 (v01 HPQOEM SLIC-MPC 0001 HP   0001)
ACPI: FACP 0xb7fc8084 000F4 (v04 HP 0944 0003 HP   0001)
ACPI Error: 32/64X address mismatch in Pm2ControlBlock: 
0x8800/0x8100, using 32 (20100702/tbfadt-526)
ACPI: DSDT 0xb7fc84a4 11437 (v01 HPSB400 0001 MSFT 0301)
ACPI: FACS 0xb7fe7d80 00040
ACPI: SLIC 0xb7fc8220 00176 (v01 HPQOEM SLIC-MPC 0001 HP   0001)
ACPI: EPTH 0xb7fc8398 00038 (v01 HP 0944 0001 HP   0001)
ACPI: APIC 0xb7fc83d0 00062 (v01 HP 0944 0001 HP   0001)
ACPI: MCFG 0xb7fc8434 0003C (v01 HP 0944 0001 HP   0001)
ACPI: TCPA 0xb7fc8470 00032 (v02 HP 0944 0001 HP   0001)

Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-30 Thread Andriy Gapon
on 30/07/2010 16:02 Anton Shterenlikht said the following:
 % dmesg | fgrep -i hda
 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: Lazy allocation of 0x4000 bytes rid 0x10 type 3 at 0xb7fb
 hdac0: [MPSAFE]
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (0)
 hdac0: Resetting corb size to 256
 hdac0: hdac_get_capabilities: Invalid rirb size (0)
 hdac0: Resetting rirb size to 256
 hdac0: Caps: OSS 0, ISS 0, BSS 0, NSDO 1, CORB 256, RIRB 256
 hdac0: 
 %

Oh, zero OSS + ISS is bad too.
Need to think about it, but no time now...

Just a one thing to try - can you please add hdac_reset(sc, 1) call in
hdac_attach() right before hdac_get_capabilities() call?
The idea is to reset the controller before trying to get its capabilities.

-- 
Andriy Gapon
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-30 Thread Anton Shterenlikht
On Fri, Jul 30, 2010 at 04:31:44PM +0300, Andriy Gapon wrote:
 on 30/07/2010 16:02 Anton Shterenlikht said the following:
  % dmesg | fgrep -i hda
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: Lazy allocation of 0x4000 bytes rid 0x10 type 3 at 0xb7fb
  hdac0: [MPSAFE]
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid corb size (0)
  hdac0: Resetting corb size to 256
  hdac0: hdac_get_capabilities: Invalid rirb size (0)
  hdac0: Resetting rirb size to 256
  hdac0: Caps: OSS 0, ISS 0, BSS 0, NSDO 1, CORB 256, RIRB 256
  hdac0: 
  %
 
 Oh, zero OSS + ISS is bad too.
 Need to think about it, but no time now...
 
 Just a one thing to try - can you please add hdac_reset(sc, 1) call in
 hdac_attach() right before hdac_get_capabilities() call?
 The idea is to reset the controller before trying to get its capabilities.

OSS became 1, no other change:

% dmesg | fgrep -i hda
hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
pci0
hdac0: HDA Driver Revision: 20100226_0142
hdac0: Lazy allocation of 0x4000 bytes rid 0x10 type 3 at 0xb7fb
hdac0: [MPSAFE]
hdac0: [ITHREAD]
hdac0: hdac_get_capabilities: Invalid corb size (0)
hdac0: Resetting corb size to 256
hdac0: hdac_get_capabilities: Invalid rirb size (0)
hdac0: Resetting rirb size to 256
hdac0: Caps: OSS 1, ISS 0, BSS 0, NSDO 1, CORB 256, RIRB 256
hdac0: 

thanks
anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Andriy Gapon
on 27/07/2010 20:20 Anton Shterenlikht said the following:
 yes, thanks, the panic has gone away.
 There still seems to be a problem with this device:
 
 
 hd...@pci0:0:20:2:class=0x040300 card=0x30c2103c chip=0x43831002 rev=0x00 
 hdr=0x00
 vendor = 'ATI Technologies Inc. / Advanced Micro Devices, Inc.'
 device = 'IXP SB600 High Definition Audio Controller'
 class  = multimedia
 subclass   = HDA
 
 
 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid rirb size (0)
 device_attach: hdac0 attach returned 6
 
 
 I understand from the manual, there should 
 be devices /dev/pcmX and /dev/dsp, but I have neither.
 
 I'll ask in @questions.
 
 many thanks for a quick fix!

Can you also try the following patch?
If the patch works, could you please report back `dmesg | fgrep -i hda` output?

diff --git a/sys/dev/sound/pci/hda/hdac.c b/sys/dev/sound/pci/hda/hdac.c
index 22ea4c8..a5556d2 100644
--- a/sys/dev/sound/pci/hda/hdac.c
+++ b/sys/dev/sound/pci/hda/hdac.c
@@ -1609,7 +1609,15 @@ hdac_get_capabilities(struct hdac_softc *sc)
else {
device_printf(sc-dev, %s: Invalid corb size (%x)\n,
__func__, corbsize);
-   return (ENXIO);
+   if (corbsize == 0) {
+   device_printf(sc-dev, Resetting corb size to 256\n);
+   sc-corb_size = 256;
+   corbsize =
+   HDAC_CORBSIZE_CORBSIZE(HDAC_CORBSIZE_CORBSIZE_256);
+   HDAC_WRITE_1(sc-mem, HDAC_CORBSIZE, corbsize);
+   }
+   else
+   return (ENXIO);
}

rirbsize = HDAC_READ_1(sc-mem, HDAC_RIRBSIZE);
@@ -1625,7 +1633,15 @@ hdac_get_capabilities(struct hdac_softc *sc)
else {
device_printf(sc-dev, %s: Invalid rirb size (%x)\n,
__func__, rirbsize);
-   return (ENXIO);
+   if (rirbsize == 0) {
+   device_printf(sc-dev, Resetting rirb size to 256\n);
+   sc-rirb_size = 256;
+   rirbsize =
+   HDAC_RIRBSIZE_RIRBSIZE(HDAC_RIRBSIZE_RIRBSIZE_256);
+   HDAC_WRITE_1(sc-mem, HDAC_RIRBSIZE, rirbsize);
+   }
+   else
+   return (ENXIO);
}

HDA_BOOTVERBOSE(

-- 
Andriy Gapon
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Anton Shterenlikht
On Wed, Jul 28, 2010 at 03:56:34PM +0300, Andriy Gapon wrote:
 on 27/07/2010 20:20 Anton Shterenlikht said the following:
  yes, thanks, the panic has gone away.
  There still seems to be a problem with this device:
  
  
  hd...@pci0:0:20:2:  class=0x040300 card=0x30c2103c chip=0x43831002 rev=0x00 
  hdr=0x00
  vendor = 'ATI Technologies Inc. / Advanced Micro Devices, Inc.'
  device = 'IXP SB600 High Definition Audio Controller'
  class  = multimedia
  subclass   = HDA
  
  
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid rirb size (0)
  device_attach: hdac0 attach returned 6
  
  
  I understand from the manual, there should 
  be devices /dev/pcmX and /dev/dsp, but I have neither.
  
  I'll ask in @questions.
  
  many thanks for a quick fix!
 
 Can you also try the following patch?
 If the patch works, could you please report back `dmesg | fgrep -i hda` 
 output?

here it is:

% dmesg|fgrep -i hda
pci0: multimedia, HDA at device 20.2 (no driver attached)
pci0: multimedia, HDA at device 20.2 (no driver attached)
hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
pci0
hdac0: HDA Driver Revision: 20100226_0142
hdac0: [ITHREAD]
hdac0: hdac_get_capabilities: Invalid rirb size (0)
device_attach: hdac0 attach returned 6
hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
pci0
hdac0: HDA Driver Revision: 20100226_0142
hdac0: [ITHREAD]
hdac0: hdac_get_capabilities: Invalid rirb size (0)
hdac0: Resetting rirb size to 256


many thanks
anton


 
 diff --git a/sys/dev/sound/pci/hda/hdac.c b/sys/dev/sound/pci/hda/hdac.c
 index 22ea4c8..a5556d2 100644
 --- a/sys/dev/sound/pci/hda/hdac.c
 +++ b/sys/dev/sound/pci/hda/hdac.c
 @@ -1609,7 +1609,15 @@ hdac_get_capabilities(struct hdac_softc *sc)
   else {
   device_printf(sc-dev, %s: Invalid corb size (%x)\n,
   __func__, corbsize);
 - return (ENXIO);
 + if (corbsize == 0) {
 + device_printf(sc-dev, Resetting corb size to 256\n);
 + sc-corb_size = 256;
 + corbsize =
 + HDAC_CORBSIZE_CORBSIZE(HDAC_CORBSIZE_CORBSIZE_256);
 + HDAC_WRITE_1(sc-mem, HDAC_CORBSIZE, corbsize);
 + }
 + else
 + return (ENXIO);
   }
 
   rirbsize = HDAC_READ_1(sc-mem, HDAC_RIRBSIZE);
 @@ -1625,7 +1633,15 @@ hdac_get_capabilities(struct hdac_softc *sc)
   else {
   device_printf(sc-dev, %s: Invalid rirb size (%x)\n,
   __func__, rirbsize);
 - return (ENXIO);
 + if (rirbsize == 0) {
 + device_printf(sc-dev, Resetting rirb size to 256\n);
 + sc-rirb_size = 256;
 + rirbsize =
 + HDAC_RIRBSIZE_RIRBSIZE(HDAC_RIRBSIZE_RIRBSIZE_256);
 + HDAC_WRITE_1(sc-mem, HDAC_RIRBSIZE, rirbsize);
 + }
 + else
 + return (ENXIO);
   }
 
   HDA_BOOTVERBOSE(
 
 -- 
 Andriy Gapon

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Andriy Gapon
on 28/07/2010 19:01 Anton Shterenlikht said the following:
 here it is:

So did it work? :)

 % dmesg|fgrep -i hda
 pci0: multimedia, HDA at device 20.2 (no driver attached)
 pci0: multimedia, HDA at device 20.2 (no driver attached)
 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid rirb size (0)
 device_attach: hdac0 attach returned 6

I presume the above is from previous load attempt?

 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid rirb size (0)
 hdac0: Resetting rirb size to 256

Hmm, so no message about corb, just rirb?
Also, no codec and pcm output lines?  Did the driver get attached?

-- 
Andriy Gapon
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Anton Shterenlikht
On Wed, Jul 28, 2010 at 07:07:34PM +0300, Andriy Gapon wrote:
 on 28/07/2010 19:01 Anton Shterenlikht said the following:
  here it is:
 
 So did it work? :)

not as far as I can tell

 
  % dmesg|fgrep -i hda
  pci0: multimedia, HDA at device 20.2 (no driver attached)
  pci0: multimedia, HDA at device 20.2 (no driver attached)
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid rirb size (0)
  device_attach: hdac0 attach returned 6
 
 I presume the above is from previous load attempt?

yes, probably. I think /var/run/dmesg used
to contain only the current boot, but some
time ago I noticed that quite a few previous
boots are stored. Or maybe it's my misconfiguration..

 
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid rirb size (0)
  hdac0: Resetting rirb size to 256
 
 Hmm, so no message about corb, just rirb?
 Also, no codec and pcm output lines?  Did the driver get attached?

As far as I can (cannot) see, the driver didn't attach.
There's no /dev/dsp or /dev/pcm.

% cat /dev/sndstat 
FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64)
Installed devices:
%

I also get (probably not related)

% dmesg|grep dead
Event timer i8254 is dead.
%

many thanks
anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Andriy Gapon
on 28/07/2010 19:17 Anton Shterenlikht said the following:
 On Wed, Jul 28, 2010 at 07:07:34PM +0300, Andriy Gapon wrote:
 on 28/07/2010 19:01 Anton Shterenlikht said the following:
 here it is:
 So did it work? :)
 
 not as far as I can tell
 
 % dmesg|fgrep -i hda
 pci0: multimedia, HDA at device 20.2 (no driver attached)
 pci0: multimedia, HDA at device 20.2 (no driver attached)
 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
 on pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid rirb size (0)
 device_attach: hdac0 attach returned 6
 I presume the above is from previous load attempt?
 
 yes, probably. I think /var/run/dmesg used
 to contain only the current boot, but some
 time ago I noticed that quite a few previous
 boots are stored. Or maybe it's my misconfiguration..

Did you just kldload the module?
Or do you have hda in your kernel and you performed a reboot?
If you didn't reboot, can you do it now?

 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
 on pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid rirb size (0)
 hdac0: Resetting rirb size to 256
 Hmm, so no message about corb, just rirb?

So no corb message?
This seems very strange, especially given the subject line.

 Also, no codec and pcm output lines?  Did the driver get attached?
 
 As far as I can (cannot) see, the driver didn't attach.
 There's no /dev/dsp or /dev/pcm.

What is output of the following command?
kldstat -v | egrep 'sound|snd'

 % cat /dev/sndstat 
 FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64)
 Installed devices:
 %
 
 I also get (probably not related)
 
 % dmesg|grep dead
 Event timer i8254 is dead.
 %

You can try to use a different timer.
See sysctl kern.eventtimer, you can override timer1 and timer2 in your 
loader.conf.

-- 
Andriy Gapon
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Anton Shterenlikht
On Wed, Jul 28, 2010 at 07:33:44PM +0300, Andriy Gapon wrote:
 on 28/07/2010 19:17 Anton Shterenlikht said the following:
  On Wed, Jul 28, 2010 at 07:07:34PM +0300, Andriy Gapon wrote:
  on 28/07/2010 19:01 Anton Shterenlikht said the following:
  here it is:
  So did it work? :)
  
  not as far as I can tell
  
  % dmesg|fgrep -i hda
  pci0: multimedia, HDA at device 20.2 (no driver attached)
  pci0: multimedia, HDA at device 20.2 (no driver attached)
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid rirb size (0)
  device_attach: hdac0 attach returned 6
  I presume the above is from previous load attempt?
  
  yes, probably. I think /var/run/dmesg used
  to contain only the current boot, but some
  time ago I noticed that quite a few previous
  boots are stored. Or maybe it's my misconfiguration..
 
 Did you just kldload the module?
 Or do you have hda in your kernel and you performed a reboot?
 If you didn't reboot, can you do it now?

it's in the kernel, and yes, I did reboot.



 
 So no corb message?
 This seems very strange, especially given the subject line.

But I just rebooted again, and reset
to defaults in BIOS, now I get:

% dmesg | fgrep -i hda
hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
pci0
hdac0: HDA Driver Revision: 20100226_0142
hdac0: [ITHREAD]
hdac0: hdac_get_capabilities: Invalid corb size (1)
device_attach: hdac0 attach returned 6


 
  Also, no codec and pcm output lines?  Did the driver get attached?
  
  As far as I can (cannot) see, the driver didn't attach.
  There's no /dev/dsp or /dev/pcm.
 
 What is output of the following command?
 kldstat -v | egrep 'sound|snd'

% kldstat -v | egrep 'sound|snd'
139 sound
138 pci/snd_hda
137 hdac/snd_hda_pcm


thanks
anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Andriy Gapon
on 28/07/2010 19:44 Anton Shterenlikht said the following:
  But I just rebooted again, and reset
 to defaults in BIOS, now I get:
 
 % dmesg | fgrep -i hda
 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (1)
 device_attach: hdac0 attach returned 6
 

This gets even stranger.
Ultimate attempt - can you drop the size == 0 condition, so that reset is always
tried when initial value is not correct?

Then, of course, build and install new kernel and reboot.
If possible, with power down to get the cleanest results.

P.S. I lied actually - the ultimate attempt would be to not even try to read 
CORB
and RIRB size and just force them to 256 always.  It seems that's what Linux
driver does.

-- 
Andriy Gapon
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Anton Shterenlikht
On Wed, Jul 28, 2010 at 07:51:08PM +0300, Andriy Gapon wrote:
 on 28/07/2010 19:44 Anton Shterenlikht said the following:
   But I just rebooted again, and reset
  to defaults in BIOS, now I get:
  
  % dmesg | fgrep -i hda
  hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid corb size (1)
  device_attach: hdac0 attach returned 6
  
 
 This gets even stranger.
 Ultimate attempt - can you drop the size == 0 condition, so that reset is 
 always
 tried when initial value is not correct?

you mean drop both
if (corbsize == 0) {}

and
if (rirbsize == 0) {}

?

Or did I get you wrong?

anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-28 Thread Andriy Gapon
on 28/07/2010 20:13 Anton Shterenlikht said the following:
 On Wed, Jul 28, 2010 at 07:51:08PM +0300, Andriy Gapon wrote:
 on 28/07/2010 19:44 Anton Shterenlikht said the following:
   But I just rebooted again, and reset
 to defaults in BIOS, now I get:

 % dmesg | fgrep -i hda
 hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 
 on pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (1)
 device_attach: hdac0 attach returned 6

 This gets even stranger.
 Ultimate attempt - can you drop the size == 0 condition, so that reset is 
 always
 tried when initial value is not correct?
 
 you mean drop both
 if (corbsize == 0) {}
 
 and
 if (rirbsize == 0) {}
 
 ?

Change it to if (1) { ...}.


-- 
Andriy Gapon
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Lawrence Stewart
On 07/27/10 02:07, Anton Shterenlikht wrote:
 On Mon, Jul 26, 2010 at 02:24:52PM +0100, Anton Shterenlikht wrote:
 On amd64 r210496 I get this panic when booting a kernel
 with snd_hda(4). I haven't used this driver before, so
 can't say if this is a regression.

 (copied by hand)

 hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 20.2 
 on pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (0)
 device_attach: hdac0 attach returned 6
 Slab at 0xff000261eb18, freei 3 = 0
 panic: Duplicate free of item 0xff0002661c00 from zone 
 0xff00b7f9a500(1024)

 cpuid = 0
 KDB: enter: panic
 [ thread pid 0 tid 10 ]
 Stopped at kdb_enter+0x3d: movq  $0,0x74f360(%rip)
 dbbt

 (very long output.. ending in)

 mi_startup() at mi_startup_0x59
 btext() at btext+0x2c
 
 I moved back as far as r204000, still the same panic.
 
 Please advise

I get this same panic on my Toshiba Portege R600 laptop when I boot it
into Windows and then reboot it into FreeBSD. My guess is that the
Windows drivers leave the hardware in a state which the FreeBSD code
doesn't know how to deal with. I don't run Windows often so haven't hit
this panic in a while, but the trick that always worked for me was to go
into the BIOS and Reset to defaults, then boot into FreeBSD.

Cheers,
Lawrence
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Anton Shterenlikht
On Tue, Jul 27, 2010 at 05:37:49PM +1000, Lawrence Stewart wrote:
 On 07/27/10 02:07, Anton Shterenlikht wrote:
  On Mon, Jul 26, 2010 at 02:24:52PM +0100, Anton Shterenlikht wrote:
  On amd64 r210496 I get this panic when booting a kernel
  with snd_hda(4). I haven't used this driver before, so
  can't say if this is a regression.
 
  (copied by hand)
 
  hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid corb size (0)
  device_attach: hdac0 attach returned 6
  Slab at 0xff000261eb18, freei 3 = 0
  panic: Duplicate free of item 0xff0002661c00 from zone 
  0xff00b7f9a500(1024)
 
  cpuid = 0
  KDB: enter: panic
  [ thread pid 0 tid 10 ]
  Stopped at kdb_enter+0x3d: movq  $0,0x74f360(%rip)
  dbbt
 
  (very long output.. ending in)
 
  mi_startup() at mi_startup_0x59
  btext() at btext+0x2c
  
  I moved back as far as r204000, still the same panic.
  
  Please advise
 
 I get this same panic on my Toshiba Portege R600 laptop when I boot it
 into Windows and then reboot it into FreeBSD. My guess is that the
 Windows drivers leave the hardware in a state which the FreeBSD code
 doesn't know how to deal with. I don't run Windows often so haven't hit
 this panic in a while, but the trick that always worked for me was to go
 into the BIOS and Reset to defaults, then boot into FreeBSD.

no, that doesn't help, still the same panic

Also, I've only FBSD installed on this laptop (HP Compaq 6715s),
no other OS.

many thanks
anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Gavin Atkinson
On Mon, 2010-07-26 at 14:24 +0100, Anton Shterenlikht wrote:
 On amd64 r210496 I get this panic when booting a kernel
 with snd_hda(4). I haven't used this driver before, so
 can't say if this is a regression.
 
 (copied by hand)
 
 hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (0)
 device_attach: hdac0 attach returned 6
 Slab at 0xff000261eb18, freei 3 = 0
 panic: Duplicate free of item 0xff0002661c00 from zone 
 0xff00b7f9a500(1024)
 
 cpuid = 0
 KDB: enter: panic
 [ thread pid 0 tid 10 ]
 Stopped at kdb_enter+0x3d: movq  $0,0x74f360(%rip)
 dbbt
 
 (very long output.. ending in)

Can you give us this output please?  At least the panic() line and the
next six or so lines?

Thanks,

Gavin

-- 
Gavin Atkinson
FreeBSD committer and bugmeister
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Anton Shterenlikht
On Tue, Jul 27, 2010 at 11:23:24AM +0100, Gavin Atkinson wrote:
 On Mon, 2010-07-26 at 14:24 +0100, Anton Shterenlikht wrote:
  On amd64 r210496 I get this panic when booting a kernel
  with snd_hda(4). I haven't used this driver before, so
  can't say if this is a regression.
  
  (copied by hand)
  
  hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 20.2 
  on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid corb size (0)
  device_attach: hdac0 attach returned 6
  Slab at 0xff000261eb18, freei 3 = 0
  panic: Duplicate free of item 0xff0002661c00 from zone 
  0xff00b7f9a500(1024)
  
  cpuid = 0
  KDB: enter: panic
  [ thread pid 0 tid 10 ]
  Stopped at kdb_enter+0x3d: movq  $0,0x74f360(%rip)
  dbbt
  
  (very long output.. ending in)
 
 Can you give us this output please?  At least the panic() line and the
 next six or so lines?
 

ok, will do.
I wish the modern laptops had a serial link..

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Gavin Atkinson
On Tue, 2010-07-27 at 12:58 +0100, Anton Shterenlikht wrote:
 On Tue, Jul 27, 2010 at 11:23:24AM +0100, Gavin Atkinson wrote:
  On Mon, 2010-07-26 at 14:24 +0100, Anton Shterenlikht wrote:
   On amd64 r210496 I get this panic when booting a kernel
   with snd_hda(4). I haven't used this driver before, so
   can't say if this is a regression.
   
   (copied by hand)
   
   hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 
   20.2 on pci0
   hdac0: HDA Driver Revision: 20100226_0142
   hdac0: [ITHREAD]
   hdac0: hdac_get_capabilities: Invalid corb size (0)
   device_attach: hdac0 attach returned 6
   Slab at 0xff000261eb18, freei 3 = 0
   panic: Duplicate free of item 0xff0002661c00 from zone 
   0xff00b7f9a500(1024)
   
   cpuid = 0
   KDB: enter: panic
   [ thread pid 0 tid 10 ]
   Stopped at kdb_enter+0x3d: movq  $0,0x74f360(%rip)
   dbbt
   
   (very long output.. ending in)
  
  Can you give us this output please?  At least the panic() line and the
  next six or so lines?
  
 
 ok, will do.
 I wish the modern laptops had a serial link..

Indeed.  I keep buying Toshibas, who still have a range with serial
ports.

Having said that, have you tried to use the dcons stuff over firewire?
That usually works pretty well in my experience.
http://wiki.freebsd.org/DebugWithDcons

Thanks,

Gavin

-- 
Gavin Atkinson
FreeBSD committer and bugmeister
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Anton Shterenlikht
On Tue, Jul 27, 2010 at 02:52:17PM +0100, Gavin Atkinson wrote:
 On Tue, 2010-07-27 at 12:58 +0100, Anton Shterenlikht wrote:
  On Tue, Jul 27, 2010 at 11:23:24AM +0100, Gavin Atkinson wrote:
   On Mon, 2010-07-26 at 14:24 +0100, Anton Shterenlikht wrote:
On amd64 r210496 I get this panic when booting a kernel
with snd_hda(4). I haven't used this driver before, so
can't say if this is a regression.

(copied by hand)

hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 
20.2 on pci0
hdac0: HDA Driver Revision: 20100226_0142
hdac0: [ITHREAD]
hdac0: hdac_get_capabilities: Invalid corb size (0)
device_attach: hdac0 attach returned 6
Slab at 0xff000261eb18, freei 3 = 0
panic: Duplicate free of item 0xff0002661c00 from zone 
0xff00b7f9a500(1024)

cpuid = 0
KDB: enter: panic
[ thread pid 0 tid 10 ]
Stopped at kdb_enter+0x3d: movq  $0,0x74f360(%rip)
dbbt

(very long output.. ending in)
   
   Can you give us this output please?  At least the panic() line and the
   next six or so lines?

here it is:

db bt
Tracing pid 0 tid 10 td 0x80b40de0
kdb_enter() at kdb_enter+0x3d
panic() at panic+0x17b
uma_dbg_free() at uma_zfree_arg+0x62
free() at free+0xcd
device_set_driver() at device_set_driver+0x7c
device_attach() at device_attach+0x1a3
bus_generic_attach() at bus_generic_attach+0x1a
acpi_pci_attach() at acpi_pci_attach+0x14f
device_attach() at dvice_attach+0x69
bus_generic_attach() at bus_generic_attach+0x1a
acpi_pcib_attach() at acpi_pcib_attach+0x1a7
acpi_pcib_acpi_attach() at acpi_pcib_acpi_attach+0x1fd
device_attach() at dvice_attach+0x69
bus_generic_attach() at bus_generic_attach+0x1a
acpi_attach() at acpi_attach+0xa28
device_attach() at dvice_attach+0x69
bus_generic_attach() at bus_generic_attach+0x1a
nexus_acpi_attach() at nexus_acpi_attach+0x69
device_attach() at dvice_attach+0x69
bus_generic_new_pass() at bus_generic_new_pass+0xd6
bus_set_pass() at bus_set_pass+0x7a
configure() at configure+0xa
mi_startup() at mi_startup+0x59
btext() at btext+0x2c
db

many thanks
anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Gavin Atkinson
On Tue, 2010-07-27 at 15:47 +0100, Anton Shterenlikht wrote:
 On Tue, Jul 27, 2010 at 02:52:17PM +0100, Gavin Atkinson wrote:
  On Tue, 2010-07-27 at 12:58 +0100, Anton Shterenlikht wrote:
   On Tue, Jul 27, 2010 at 11:23:24AM +0100, Gavin Atkinson wrote:
On Mon, 2010-07-26 at 14:24 +0100, Anton Shterenlikht wrote:
 
 hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 
 20.2 on pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (0)
 device_attach: hdac0 attach returned 6
 Slab at 0xff000261eb18, freei 3 = 0
 panic: Duplicate free of item 0xff0002661c00 from zone 
 0xff00b7f9a500(1024)

Can you give us this output please?  At least the panic() line and the
next six or so lines?
 
 here it is:
 
 db bt
 Tracing pid 0 tid 10 td 0x80b40de0
 kdb_enter() at kdb_enter+0x3d
 panic() at panic+0x17b
 uma_dbg_free() at uma_zfree_arg+0x62
 free() at free+0xcd
 device_set_driver() at device_set_driver+0x7c
 device_attach() at device_attach+0x1a3

Thanks.  Can you try
http://people.freebsd.org/~gavin/mexas-hda-panic.diff

and see if that solves things for you?

(Credit goes to avg@ for looking into this before me :)

Gavin

-- 
Gavin Atkinson
FreeBSD committer and bugmeister
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Anton Shterenlikht
On Tue, Jul 27, 2010 at 05:53:25PM +0100, Gavin Atkinson wrote:
 On Tue, 2010-07-27 at 15:47 +0100, Anton Shterenlikht wrote:
  On Tue, Jul 27, 2010 at 02:52:17PM +0100, Gavin Atkinson wrote:
   On Tue, 2010-07-27 at 12:58 +0100, Anton Shterenlikht wrote:
On Tue, Jul 27, 2010 at 11:23:24AM +0100, Gavin Atkinson wrote:
 On Mon, 2010-07-26 at 14:24 +0100, Anton Shterenlikht wrote:
  
  hdac0: ATI SB600 High Definition Audion Controller irq 16 at 
  device 20.2 on pci0
  hdac0: HDA Driver Revision: 20100226_0142
  hdac0: [ITHREAD]
  hdac0: hdac_get_capabilities: Invalid corb size (0)
  device_attach: hdac0 attach returned 6
  Slab at 0xff000261eb18, freei 3 = 0
  panic: Duplicate free of item 0xff0002661c00 from zone 
  0xff00b7f9a500(1024)
 
 Can you give us this output please?  At least the panic() line and 
 the
 next six or so lines?
  
  here it is:
  
  db bt
  Tracing pid 0 tid 10 td 0x80b40de0
  kdb_enter() at kdb_enter+0x3d
  panic() at panic+0x17b
  uma_dbg_free() at uma_zfree_arg+0x62
  free() at free+0xcd
  device_set_driver() at device_set_driver+0x7c
  device_attach() at device_attach+0x1a3
 
 Thanks.  Can you try
 http://people.freebsd.org/~gavin/mexas-hda-panic.diff
 
 and see if that solves things for you?
 
 (Credit goes to avg@ for looking into this before me :)

yes, thanks, the panic has gone away.
There still seems to be a problem with this device:


hd...@pci0:0:20:2:  class=0x040300 card=0x30c2103c chip=0x43831002 rev=0x00 
hdr=0x00
vendor = 'ATI Technologies Inc. / Advanced Micro Devices, Inc.'
device = 'IXP SB600 High Definition Audio Controller'
class  = multimedia
subclass   = HDA


hdac0: ATI SB600 High Definition Audio Controller irq 16 at device 20.2 on 
pci0
hdac0: HDA Driver Revision: 20100226_0142
hdac0: [ITHREAD]
hdac0: hdac_get_capabilities: Invalid rirb size (0)
device_attach: hdac0 attach returned 6


I understand from the manual, there should 
be devices /dev/pcmX and /dev/dsp, but I have neither.

I'll ask in @questions.

many thanks for a quick fix!

anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-27 Thread Lawrence Stewart
On 07/27/10 18:09, Anton Shterenlikht wrote:
 On Tue, Jul 27, 2010 at 05:37:49PM +1000, Lawrence Stewart wrote:
 On 07/27/10 02:07, Anton Shterenlikht wrote:
 On Mon, Jul 26, 2010 at 02:24:52PM +0100, Anton Shterenlikht wrote:
 On amd64 r210496 I get this panic when booting a kernel
 with snd_hda(4). I haven't used this driver before, so
 can't say if this is a regression.

 (copied by hand)

 hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 20.2 
 on pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (0)
 device_attach: hdac0 attach returned 6
 Slab at 0xff000261eb18, freei 3 = 0
 panic: Duplicate free of item 0xff0002661c00 from zone 
 0xff00b7f9a500(1024)

 cpuid = 0
 KDB: enter: panic
 [ thread pid 0 tid 10 ]
 Stopped at kdb_enter+0x3d: movq  $0,0x74f360(%rip)
 dbbt

 (very long output.. ending in)

 mi_startup() at mi_startup_0x59
 btext() at btext+0x2c

 I moved back as far as r204000, still the same panic.

 Please advise

 I get this same panic on my Toshiba Portege R600 laptop when I boot it
 into Windows and then reboot it into FreeBSD. My guess is that the
 Windows drivers leave the hardware in a state which the FreeBSD code
 doesn't know how to deal with. I don't run Windows often so haven't hit
 this panic in a while, but the trick that always worked for me was to go
 into the BIOS and Reset to defaults, then boot into FreeBSD.
 
 no, that doesn't help, still the same panic
 
 Also, I've only FBSD installed on this laptop (HP Compaq 6715s),
 no other OS.

hmm I'll have to try the patch and see if it resolves the issue for me.
I guess in my case resetting the BIOS was causing a different code path
to be taken and thus the panic never triggered. Good to here it's
resovled for you though.

Cheers,
Lawrence
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: amd64 panic snd_hda - hdac_get_capabilities: Invalid corb size (0)

2010-07-26 Thread Anton Shterenlikht
On Mon, Jul 26, 2010 at 02:24:52PM +0100, Anton Shterenlikht wrote:
 On amd64 r210496 I get this panic when booting a kernel
 with snd_hda(4). I haven't used this driver before, so
 can't say if this is a regression.
 
 (copied by hand)
 
 hdac0: ATI SB600 High Definition Audion Controller irq 16 at device 20.2 on 
 pci0
 hdac0: HDA Driver Revision: 20100226_0142
 hdac0: [ITHREAD]
 hdac0: hdac_get_capabilities: Invalid corb size (0)
 device_attach: hdac0 attach returned 6
 Slab at 0xff000261eb18, freei 3 = 0
 panic: Duplicate free of item 0xff0002661c00 from zone 
 0xff00b7f9a500(1024)
 
 cpuid = 0
 KDB: enter: panic
 [ thread pid 0 tid 10 ]
 Stopped at kdb_enter+0x3d: movq  $0,0x74f360(%rip)
 dbbt
 
 (very long output.. ending in)
 
 mi_startup() at mi_startup_0x59
 btext() at btext+0x2c

I moved back as far as r204000, still the same panic.

Please advise

many thanks
anton

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org