Message ID | 20240222181851.3398254-1-megi@xff.cz |
---|---|
Headers |
Return-Path: <linux-kernel+bounces-77124-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:a81b:b0:108:e6aa:91d0 with SMTP id bq27csp132706dyb; Thu, 22 Feb 2024 10:34:14 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCU6v9zrx43hqS7Dks4AL71QwBAHNtZfzWHT6lwpyJK7uL2isaAXNO9STJWmjYcjI1ud1UocffT/mvC4WfZ3INM8SZzDHw== X-Google-Smtp-Source: AGHT+IEv1oOmJPpxs1ufs95vjmXagwE/AXEUDsn0nb6bd/Ba8vXP6sE/TieGhyWVsab/5Db2GdGB X-Received: by 2002:a05:6e02:1d95:b0:365:1305:fac5 with SMTP id h21-20020a056e021d9500b003651305fac5mr21935415ila.0.1708626854349; Thu, 22 Feb 2024 10:34:14 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708626854; cv=pass; d=google.com; s=arc-20160816; b=p8epQfPYcmk3deFKTfjHF9nu/s8UqZa3cnUvah2bMp0xCn9g8kn7CZElLqur1Q8hXz PXg5SWKIM2jBgEdjRAX4Q99gblp27QUji1+Ptp9x9jcEwZPVaZhCSlmNgGyQskFn7QMz ajuveTU7zHqCjY8sgHar8s1mdYfVesbBXiWKfMoazjTok7LpjFPbzWwXXU9rN/B3fyKP uDZzb6fuB7QYcp64ALd+6wAxzEfAZ0yeo7Z+Q09bC6cLRbZTHvIiDysT9EAD1EoDfAF/ QEPZYLh9f3vzTCJu9Ht6/mNh/OJj1E6SOpkYcVkZn6hqSSPOPkawgtlKBIXwGUof8/6p 236Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=TyytIujxG3Ikl6cnv6knUNgmoqpVqzSMLYe+uh7SKG0=; fh=LyOUUyERizBut43yg2bQgiL8MyPFN7nnSRizOKM8oK8=; b=VDRzDPHnqgcQa9yN18G+FUE0gax+lm96MmsI2tGlCq8exT/C9PPs1SdIQtLqioYZNG VHJuxVTTRBDvxwLt49RIge1yYeAPoUi76QkxSX66jX+jaFa+Lz+blpt1Qdj5gR8SpYzs b7HahnQLb7lSb5tWOKMswvr6xMOcSUq46PHwQNfTKYTt+YzlQo5yj2gAtZaq2sLL4s0O Y7i1WGSW44eu3ogimlpenh4TzqmbimfzGDieHbjnAU2G8EZUefld62mH40A2QBoHsBCQ X6A95UCHkihzBUg9TkGaYdmYiPJGgXSo3K5FoACBjPRZZOxPTMMLyr2nTKmU0wRUAKPx 1n9g==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@xff.cz header.s=mail header.b=NYF280GF; arc=pass (i=1 spf=pass spfdomain=xff.cz dkim=pass dkdomain=xff.cz dmarc=pass fromdomain=xff.cz); spf=pass (google.com: domain of linux-kernel+bounces-77124-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-77124-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=xff.cz Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id b129-20020a636787000000b005cdf801a27dsi10411288pgc.198.2024.02.22.10.34.14 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Feb 2024 10:34:14 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-77124-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@xff.cz header.s=mail header.b=NYF280GF; arc=pass (i=1 spf=pass spfdomain=xff.cz dkim=pass dkdomain=xff.cz dmarc=pass fromdomain=xff.cz); spf=pass (google.com: domain of linux-kernel+bounces-77124-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-77124-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=xff.cz Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 2831E285335 for <ouuuleilei@gmail.com>; Thu, 22 Feb 2024 18:34:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id ECEE315DBBA; Thu, 22 Feb 2024 18:19:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=xff.cz header.i=@xff.cz header.b="NYF280GF" Received: from vps.xff.cz (vps.xff.cz [195.181.215.36]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 84EA91586EE; Thu, 22 Feb 2024 18:18:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=195.181.215.36 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708625940; cv=none; b=u0GJnsuUNLSW3YjT/w0QR/161Y9wSJF62BMpQzHNn4QopxfiyZ1akCMmavKhVU91vbZk8cXW+cNPBoFqkwFQ1wdk5qjixbEUzfXN3Zj7oRa+IWb+uQ46yJYFJc00fagKj+dG9HLDayVz7VfdPmtW21NIGQ/5xl1QNQfMP70LqVo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708625940; c=relaxed/simple; bh=tVlCmtfnoRWyJBq9HUe/Vjtl8lpr2sLtXU1tQdi2rsg=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type; b=jv3ou7BNTQlIGzPWSz++nelsFQtdjgDrWmwfwkpxHnneW/SdMSNNaSw+8m2z0pKPquXOYKnRVxy2B5ZtoVjykDLqEAJ+KbMZ0P4Sn9X6Y+QyJNf2Zax3373A4ZRwcLPNL7OAFy3iED8HrXI7jsCm9FisKdsu1TtAkScXDLYNZSE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=xff.cz; spf=pass smtp.mailfrom=xff.cz; dkim=pass (1024-bit key) header.d=xff.cz header.i=@xff.cz header.b=NYF280GF; arc=none smtp.client-ip=195.181.215.36 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=xff.cz Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=xff.cz DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=xff.cz; s=mail; t=1708625933; bh=tVlCmtfnoRWyJBq9HUe/Vjtl8lpr2sLtXU1tQdi2rsg=; h=From:To:Cc:Subject:Date:From; b=NYF280GFCZvSQ/yfp5TVqU9IGDB+6wYDZaUUvQBZn11o9TKa/JuS2Mnvzx107Opgm xHYjTSCcZ0gXK/l/l5WyLOFKhMOt4R7lczgsfRKLIHA6CHo+FCfq6mh1waTr/Vhfhi bkiT5KtmTnt6ca6gQYyRV6BWeZPLqHpYf0s4VXxs= From: =?utf-8?q?Ond=C5=99ej_Jirman?= <megi@xff.cz> To: linux-kernel@vger.kernel.org, Liam Girdwood <lgirdwood@gmail.com>, Mark Brown <broonie@kernel.org>, Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com> Cc: Ondrej Jirman <megi@xff.cz>, Chen-Yu Tsai <wens@csie.org>, Jernej Skrabec <jernej.skrabec@gmail.com>, Samuel Holland <samuel@sholland.org>, Arnaud Ferraris <arnaud.ferraris@collabora.com>, linux-sound@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev Subject: [PATCH 0/4] Add support for jack detection to codec present in A64 SoC Date: Thu, 22 Feb 2024 19:18:43 +0100 Message-ID: <20240222181851.3398254-1-megi@xff.cz> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1791625112095745378 X-GMAIL-MSGID: 1791625112095745378 |
Series |
Add support for jack detection to codec present in A64 SoC
|
|
Message
Ondřej Jirman
Feb. 22, 2024, 6:18 p.m. UTC
From: Ondrej Jirman <megi@xff.cz>
This series adds support for jack detection to this codec. I used
and tested this on Pinephone. It works quite nicely. I tested it
against Android headset mic button resistor specification.
The patches are improved and debugged version of the original
ones from Arnaud Ferraris and Samuel Holland, imrpoved to better
handle headset button presses and with more robust plug-in/out
event debouncing.
Please take a look. :)
Thank you very much,
Ondřej Jirman
Arnaud Ferraris (2):
ASoC: sun50i-codec-analog: Enable jack detection on startup
ASoC: sun8i-codec: Implement jack and accessory detection
Samuel Holland (2):
ASoC: sun50i-codec-analog: Move suspend/resume to set_bias_level
ASoC: sun8i-codec: Enable bus clock at STANDBY and higher bias
sound/soc/sunxi/sun50i-codec-analog.c | 73 ++++-
sound/soc/sunxi/sun8i-codec.c | 388 +++++++++++++++++++++++++-
2 files changed, 443 insertions(+), 18 deletions(-)
Comments
On Thu, Feb 22, 2024 at 07:18:43PM +0100, Ondřej Jirman wrote: > From: Ondrej Jirman <megi@xff.cz> > > This series adds support for jack detection to this codec. I used > and tested this on Pinephone. It works quite nicely. I tested it > against Android headset mic button resistor specification. I'd expect to see this implementing a set_jack() operation in the CODEC driver and then using that from the machine driver.