From nobody Wed Apr 03 13:19:27 2024 X-Original-To: freebsd-multimedia@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4V8lhh605dz5Gncd for ; Wed, 3 Apr 2024 13:19:32 +0000 (UTC) (envelope-from markjdb@gmail.com) Received: from mail-qt1-x834.google.com (mail-qt1-x834.google.com [IPv6:2607:f8b0:4864:20::834]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4V8lhh2Pghz4SbZ; Wed, 3 Apr 2024 13:19:32 +0000 (UTC) (envelope-from markjdb@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-qt1-x834.google.com with SMTP id d75a77b69052e-430a65e973bso37752151cf.3; Wed, 03 Apr 2024 06:19:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1712150370; x=1712755170; darn=freebsd.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:sender :from:to:cc:subject:date:message-id:reply-to; bh=mgXnKb3um595YtaqUmMc0P7XszqYSUNh3IQJXBUgqOk=; b=DIFoEJUKNoJJEVeJpU4Lk4fPOtLn79LqF5iDTQiUXHwbO/AiZrMnQB2RjRaglEv5tf CFPAnRvTi2Y26jHHIR8l+tu5+zWKLBUcFTOoGSbTtIbc3dLm0w2Tayyl7hcugEyKsiaS S5ygHo8dcXj0dNf8fIpxUQbFhepcnSXKnEdckFjWOjjd4qVIDIuIsY/6UPX8z8PjpLSs +aVNE/MqdQinF9yKbylc/iEyJpLjHssfblLTgmjRUEZtARtCS6NKlXF+XJ2lLbBqYIUg E2D76eCV9l4R2IJYBTM8R9JHVxniy1rM9+rt1kG0S5xR2sp9dySpQXDVRNBcO9TdZsM0 oIkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712150370; x=1712755170; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:sender :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=mgXnKb3um595YtaqUmMc0P7XszqYSUNh3IQJXBUgqOk=; b=xK5IQ43YUPgmuzOArYD1GmaZ/3bR3cgVxrSRQ5BWvYDc06bls39pIPgy0scBsjbIAZ LChvD1UJkZPyay1k2VVpVLz5pwy6XHTW9omD9HOLcu8/XFMkNTgYJLujh/8lU6MW+ztN RymTwZ4C1mbcdHn1X5/0D5nko/ZYdjOf4AHl92HH08lBeAqTFjqhK/oOzukdoy7Zlosc q0N7zZZAIT0Lqt8zPEsETXMLZtV+MqU5Bn3k9XChS/gFDkJwiBhQKO1PDOBG8HAdSkUW 7ZK9LrNsh7b3rKEEmej+QHzLxLDRCLFLu8nMdCSyjpS/z83V8TU6rKSdOejL1NdG8dkJ rjEw== X-Forwarded-Encrypted: i=1; AJvYcCXJWv3i/8jaQUatavFpWN7QNWosYUz3KkR6fHUTo4hNPWxvMzO/MDEOYMo583FYfKPGoiIWvczzmN7GYpEQ8bFkToJa8xJtuuTIpdF4jnSKgkApCkdS9t2OiQ4NU0Afag== X-Gm-Message-State: AOJu0YybIuM4pnRd+rJifsVUaVmj/mdrwxYgZuJDmzjyY9Zv+jqjuvCE 2JoUqMWeD62fFrnHSyNWjNB7jR+xGJxN5HGuhblGOCSoDCAfS02Z990qfRox X-Google-Smtp-Source: AGHT+IGl6xZM/g95dhx9bNbqQi1FU7Vc+cxDqMOswcvBd8xg0/4N//D7x/HtIPj7FD+6K84Rg+il8w== X-Received: by 2002:ac8:7d86:0:b0:431:395f:c10c with SMTP id c6-20020ac87d86000000b00431395fc10cmr18613929qtd.4.1712150370635; Wed, 03 Apr 2024 06:19:30 -0700 (PDT) Received: from nuc (192-0-220-237.cpe.teksavvy.com. [192.0.220.237]) by smtp.gmail.com with ESMTPSA id dr14-20020a05622a528e00b0042f43a486c9sm6602784qtb.77.2024.04.03.06.19.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Apr 2024 06:19:30 -0700 (PDT) Date: Wed, 3 Apr 2024 09:19:27 -0400 From: Mark Johnston To: Baptiste Daroussin Cc: Christos Margiolis , freebsd-multimedia@freebsd.org, jrm@freebsd.org Subject: Re: [Development report #9] Audio Stack Improvements Message-ID: References: List-Id: Multimedia discussions List-Archive: https://lists.freebsd.org/archives/freebsd-multimedia List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-multimedia@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US] X-Rspamd-Queue-Id: 4V8lhh2Pghz4SbZ On Wed, Apr 03, 2024 at 01:31:54PM +0200, Baptiste Daroussin wrote: > On Tue 02 Apr 16:14, Christos Margiolis wrote: > > Committed DEVFS_CDEVPRIV(9) patch: > > - https://cgit.freebsd.org/src/commit/?id=dc831e93bad63f9faea09f1806a7733a40bff316 > > - Updated the SNDCTL_AUDIOINFO ioctl to write /dev/dspX instead of > > /dev/dspX.Y to ai->devnode. > > - Closed https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=246208 as > > accessing specific channels through device nodes is no longer > > possible. > > > > Committed asynchronous audio device detach patch: > > - https://cgit.freebsd.org/src/commit/?id=9eff58c6d52b66eb8abe7f724dabcd804a566df4 > > - Fixed a kern_poll() panic caught after applying the patch and > > hot-unplugging the audio device while jackd is running: > > https://cgit.freebsd.org/src/commit/?id=fba54d0179aabb3d94211ca80f94fe5b98ac6d3b > > - Will send call-for-testing and mail annoyed people once a snapshot > > build with the patch included is built. > > - Debugging an LOR reported in D44411, although it’s not related to the > > patch. > > > > Updates to /dev/sndstat: > > - https://cgit.freebsd.org/src/commit/?id=6d1cee1640e1c360917e483ece5ec1bde423b788 > > - https://reviews.freebsd.org/D44571 > > - https://reviews.freebsd.org/D44546 (Abandoned since it will break > > backwards compatibility and this functionality will be built into a > > new userland tool anyway.) > > > > Implementing missing OSSv4 ioctls: > > - https://reviews.freebsd.org/D44570 > > > > Minor patches: > > - https://cgit.freebsd.org/src/commit/?id=c136e6180e4762c1180d89cd2291fd9a935a721d > > - https://cgit.freebsd.org/src/commit/?id=b5e55dbf357472ffa39345b30b8b781e988a440f > > - https://cgit.freebsd.org/src/commit/?id=d46a6a77e8e14177d07e3a53f68b428e5d1cb416 > > > > Submitted a 2024Q1 report: > > https://cgit.freebsd.org/doc/commit/?id=df8f360e93a2fa210dc3a0a7aa4dae6e855a8076 > > > > This work is sponsored by the FreeBSD Foundation. > > Thanks a log for your hard work! one thing I would like to report, I had an > issue with pulseaudio with latest kernel as of today. > > On thing specific my laptop internal audio is actually uaudio which makes it > maybe a bit specific. > > I have an application which queries pulseaudio every minute to get the status of > the mixer, this application starts pulseaudio if not present. It starts it a > first time, the process run but seems to hang somehow and becomes unkillable > (even via kill -9) > > the backtraces shows: mi_switch+0xba _cv_wait+0xf8 getchns+0x9f > dsp_poll+0xc4 devfs_poll_f+0x7d kern_poll_kfds+0x3f6 kern_poll+0x9d > sys_ppoll+0x70 amd64_syscall+0x109 fast_syscall_common+0xf8 > > with a kernel from 10 days ago this wasn't happening. > > if I change the PCM_WAIT() macro to use cv_wait_sig then everything seems to be > back to normal. Presumably this means that some other thread is holding the device busy, i.e., sleeping with the device busied, or the busy state was leaked. PCM_WAIT() can't use cv_wait_sig() directly unless all callers are patched to handle signals. So, it'd be useful to see the full "procstat -kka" output when you have a stuck pulseaudio. I believe pulseaudio will log to syslog as well, I see its messages in /var/log/messages on my desktop. It would be worth checking for messages on your system. > I don't know if that rings a bell or how to help you more on debugging this. > > Best regards, > Bapt