From patchwork Tue Jul 26 08:25:06 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhu Ning X-Patchwork-Id: 593893 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 80914C433EF for ; Tue, 26 Jul 2022 08:25:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238242AbiGZIZl (ORCPT ); Tue, 26 Jul 2022 04:25:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42878 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238386AbiGZIZk (ORCPT ); Tue, 26 Jul 2022 04:25:40 -0400 Received: from mail-pf1-x42b.google.com (mail-pf1-x42b.google.com [IPv6:2607:f8b0:4864:20::42b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E7D52DEE for ; Tue, 26 Jul 2022 01:25:39 -0700 (PDT) Received: by mail-pf1-x42b.google.com with SMTP id b133so12631657pfb.6 for ; Tue, 26 Jul 2022 01:25:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=y1MIWnHCM+GAst9qr5uT5FWNOFAzzBmNsrQ4ccKB8sg=; b=hCAMyRX5bwda3HXY2lwU+EyjnGLlHgZuasVDr5bzLtOmT92o+1ZiT80LTsgMOvs+vs mN6ge2XpEOKH632dXkeQ0tk1tUB8/31iZAnEblxpLRuEZSy71aD/HU1CxuMIfvylCzXv FCDkObDuVWq5PeBij4QUGg+Z0gASZST6Xsvrh4T409gkuDMSXlWEvvnc/G8a4ofNR7LJ FRGmFtYRQt0eL2qVh9hslZcfL+r/VSsQMBf2RB19g5unRdFViVyZAuNbr1lm8nmyZ1zM aZZFRma1hhxZCOW8JXa1J/CgAeXXkIWp/y83NiTLK87R468kiPd0O+npRtWwMrfCxbFA wfRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=y1MIWnHCM+GAst9qr5uT5FWNOFAzzBmNsrQ4ccKB8sg=; b=N4E0j4ScxNbSRu0WjF0p6ROdcx54aWd+HS6Ieh5kbNpQ8KZDCy6bXZYeOBnR9rxpp3 hbEnBTttC81AqMiLeCyGeUH54wXXzpF05XzSs0QesC4gUOloejD5kdLhY2s0VQswlvJa 9F0l8qXXUeViWJIo2ziJw98XDqduzg2DmaU4jxxR518f4GrLKhnIo/peP2ilVScsP9AS yz7tCQxaZBPDCbaLEfnmXt/PUbmUKfrBuCr+Pnyx8AHAFElIZ3v4fX19d2HKbY1LglRI rO2Ea5XbjCeYs+g9Kgm+ELZ59QwJ4lRbL0lAv4+1vaqL0E+snyOmeuWqsZsENXuzgeM8 muNg== X-Gm-Message-State: AJIora/fyysmcfiiLY8wSoTbpfZIKi0oy4Ao+nl8+Anvbq2MflTyiNcJ pLUea89JG1mm4nYjC0r9SGs= X-Google-Smtp-Source: AGRyM1ssGcNsC1CNCZvW1Q+AUnTwTpJEiPoGQ8vm7stODtUF5C2WfXk/WXWB3akQBRNsSkhTPvIKoA== X-Received: by 2002:a63:1a09:0:b0:415:fa9a:ae57 with SMTP id a9-20020a631a09000000b00415fa9aae57mr13725105pga.181.1658823938419; Tue, 26 Jul 2022 01:25:38 -0700 (PDT) Received: from a-VirtualBox.. ([116.233.75.140]) by smtp.gmail.com with ESMTPSA id q3-20020a170902a3c300b0016c6a6d8967sm10783991plb.83.2022.07.26.01.25.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 26 Jul 2022 01:25:37 -0700 (PDT) From: Zhu Ning To: alsa-devel@alsa-project.org Cc: pierre-louis.bossart@linux.intel.com, tiwai@suse.com, broonie@kernel.org, devicetree@vger.kernel.org, robh@kernel.org, ckeepax@opensource.cirrus.com, Zhu Ning , David Yang , Zhu Ning Subject: [PATCH v2 2/2] ASoC: dt-bindings: Add Everest ES8326 audio CODEC Date: Tue, 26 Jul 2022 16:25:06 +0800 Message-Id: <20220726082505.125267-2-zhuning0077@gmail.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220726082505.125267-1-zhuning0077@gmail.com> References: <20220726082505.125267-1-zhuning0077@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Add device tree binding documentation for Everest ES8326 Signed-off-by: David Yang Signed-off-by: Zhu Ning --- .../bindings/sound/everest,es8326.yaml | 84 +++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100755 Documentation/devicetree/bindings/sound/everest,es8326.yaml diff --git a/Documentation/devicetree/bindings/sound/everest,es8326.yaml b/Documentation/devicetree/bindings/sound/everest,es8326.yaml new file mode 100755 index 000000000000..f6aa3c03d456 --- /dev/null +++ b/Documentation/devicetree/bindings/sound/everest,es8326.yaml @@ -0,0 +1,84 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/sound/everest,es8326.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Everest ES8326 audio CODEC + +maintainers: + - David Yang + +properties: + compatible: + const: everest,es8326 + + reg: + maxItems: 1 + + clocks: + items: + - description: clock for master clock (MCLK) + + clock-names: + items: + - const: mclk + + "#sound-dai-cells": + const: 0 + + everest,jack-pol: + description: + just the value of reg 57. Bit(3) decides whether the jack polarity is inverted. + Bit(2) decides whether the bottom on the headset is inverted. + Bit(1)/(0) decides the mic properity to be OMTP/CTIA or auto. + $ref: /schemas/types.yaml#/definitions/uint8-array + minimum: 0 + maximum: 0x0f + default: 0x0f + + everest,mic1-src: + description: + the value of reg 2A when headset plugged. + $ref: /schemas/types.yaml#/definitions/uint8-array + minimum: 0x00 + maximum: 0x77 + default: 0x22 + + everest,mic2-src: + description: + the value of reg 2A when headset unplugged. + $ref: /schemas/types.yaml#/definitions/uint8-array + minimum: 0x00 + maximum: 0x77 + default: 0x44 + + everest,jack-detect-inverted: + description: + Defined to invert the jack detection. + $ref: /schemas/types.yaml#/definitions/flag + +required: + - compatible + - reg + - "#sound-dai-cells" + + +additionalProperties: false + +examples: + - | + i2c0 { + #address-cells = <1>; + #size-cells = <0>; + es8326: codec@19 { + compatible = "everest,es8326"; + reg = <0x19>; + clocks = <&clks 10>; + clock-names = "mclk"; + #sound-dai-cells = <0>; + everest,mic1-src = [22]; + everest,mic2-src = [44]; + everest,jack-pol = [0e]; + }; + };