Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 23 Jun 2014 08:03:20 +0400
From:      Andrey Chernov <ache@freebsd.org>
To:        Alexander Kabaev <kabaev@gmail.com>
Cc:        current@FreeBSD.org
Subject:   Re: Latest -current panic in uaudio_detach() / bus_dmamem_free()
Message-ID:  <53A7A708.3010204@freebsd.org>
In-Reply-To: <20140622224632.31b4ce3b@kan>
References:  <53A78B24.6050805@freebsd.org> <20140622224632.31b4ce3b@kan>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--V3J2JxX8JFQW6djJoHFdQbv4F4BtpFwV9
Content-Type: text/plain; charset=KOI8-R
Content-Transfer-Encoding: quoted-printable

On 23.06.2014 6:46, Alexander Kabaev wrote:
> Please provide us with the information on the actual audio hardware
> you are using, preferably in form of a dmesg output.=20

uaudio0: <vendor 0x046d product 0x0990, class 239/2, rev 2.00/0.05, addr =
7> on usbus3
uaudio0: No playback.
uaudio0: Record: 16000 Hz, 1 ch, 16-bit S-LE PCM format, 2x8ms buffer.
uaudio0: No MIDI sequencer.
pcm7: <USB audio> on uaudio0
uaudio0: No HID volume keys found.

Thanx, after backing out the patch below this panic is gone. Probably eve=
n=20
additional b->dmatag NULL check is needed for bus_dmamap_unload() too.

> This revision is
> your culpit:
>  http://svnweb.freebsd.org/changeset/base/267581 and I have strong
>  suspicion that restoring the NULL check on dmatag in the chunk below
>  will cure your crash.
>=20
> -- Modified: head/sys/dev/sound/pcm/buffer.c
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D
> --- head/sys/dev/sound/pcm/buffer.c	Tue Jun 17 14:47:49
> 2014	(r267580) +++ head/sys/dev/sound/pcm/buffer.c	Tue
> Jun 17 16:07:57 2014	(r267581) @@ -139,10 +139,9 @@
> sndbuf_free(struct snd_dbuf *b)=20
>  	if (b->buf) {
>  		if (b->flags & SNDBUF_F_MANAGED) {
> -			if (b->dmamap)
> +			if (b->buf_addr)
>  				bus_dmamap_unload(b->dmatag,
> b->dmamap);
> -			if (b->dmatag)
> -				bus_dmamem_free(b->dmatag, b->buf,
> b->dmamap);
> +			bus_dmamem_free(b->dmatag, b->buf, b->dmamap);
>  		} else
>  			free(b->buf, M_DEVBUF);
>  	}
>=20

--=20
http://ache.vniz.net/


--V3J2JxX8JFQW6djJoHFdQbv4F4BtpFwV9
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iEYEARECAAYFAlOnpxAACgkQVg5YK5ZEdN0BpwCgmqV69OJT9Vi12XqLrdVJXK2V
teYAoKH6buCIgDEuziJr8VdtFp4E6LRU
=QtRn
-----END PGP SIGNATURE-----

--V3J2JxX8JFQW6djJoHFdQbv4F4BtpFwV9--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?53A7A708.3010204>