From patchwork Sat Jan 7 07:49:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Brian Norris X-Patchwork-Id: 1722660 X-Patchwork-Delegate: ynezz@true.cz Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=Ludha8vN; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=GyPNV0yb; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Npss93vvrz23fw for ; Sat, 7 Jan 2023 18:53:33 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=0l+44eY3HrB/GCoBOUHyAdpF3aBLYhDBfApHLe1YF7E=; b=Ludha8vN2agA01 N3b1e9VqI7MnmruTj+bUrfWI7Bx7L9w2zCxGWn0jIv9xK/uymLz4lYHA7BhxvEOivk021W1SR+YJj EmR56uOUy1607ZwXBqDfGc9TAbgSK7t0kSphXCTFcmlBIVDXM7KI05C7CAZh2140HtYQHawU+ghrA yoPmAtLTMiYnxuKVqvflDb34sFbtwq1oTg+jiaEz8fA+XdFIDAjEUb0JQLswafQvlqfrAkNk2SQPF pOLPubSZugxRehDObrXGKg5dRO40ftk+jl6Ye1qzo6hcqSHuci0FUq1E8hrXRaZNJ9/yjzjB33kGK 2AKktV9TeKuqRrIskK+A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pE3yR-003PNJ-4c; Sat, 07 Jan 2023 07:50:39 +0000 Received: from mail-pf1-x431.google.com ([2607:f8b0:4864:20::431]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pE3xp-003PAV-78 for openwrt-devel@lists.openwrt.org; Sat, 07 Jan 2023 07:50:02 +0000 Received: by mail-pf1-x431.google.com with SMTP id x26so2660107pfq.10 for ; Fri, 06 Jan 2023 23:50:00 -0800 (PST) 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:subject:date :message-id:reply-to; bh=jjjhLbURR/Oonu3gKQs24LmpySNSUQOpNUFKFV63sWQ=; b=GyPNV0ybBeqGXT4TjtJed85dWBOfs5WRvjvv7c9LzI47LDdAG3FPsUUiv9jVLcat4O qdm7Nlm6E/FNEitMJ1X94tzFprkqPJ+o7Q+lCIZFlKaGKea3wnNPQfZW5m0ZMjP7g79S r7/bayj9jZWSQHcHfeycH6Sd7YP0TfJ+yRk51E4ejqfeufUyTE+j/SWDaYBoUbW5kkJ8 oJNgiFeN7dzC9u9+llffVDenFKekhDQPgFWqGZVNmuA3aYLDd0W4Erto48w7Jp+t+/v/ sZfcMcewxMs0d6hZLnVrtX37ggdlZKAlj3nDOJ/8eu6HIIJ7VV3go97yUKbqOhuvpf/j F+yQ== 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 :subject:date:message-id:reply-to; bh=jjjhLbURR/Oonu3gKQs24LmpySNSUQOpNUFKFV63sWQ=; b=Jb1d/8Tk+KbY2deqhoHazz8Spy5BINyC0NEyleIGlx4G9qxQ/O61hrdGfe/hqwQQ4E tgcRGFViKdiJEXrt6naHnQWvyY1qjB8g9DNwJELUAztrcBUlYA+dh6LEHVNCx12vl+nS BJj2dIed8w5e32O+IH9e3nmJkQIRRZ+aWhHgyoCEOGuYd3ixG0AR6vjn3sgKopgglKfg GzsngpgE4B6klqLabxEzB6MM4Im8nHSNd9o8qzr/7jdDsX9c0w95n1Ysuuo+GmO6KZZK iwUzz9HtWfFEKdXzVxhJXNi1aR1gdw3vgciHZtYxev2t66DD3HCMhRtWheE/+mQRNYhy gaJw== X-Gm-Message-State: AFqh2kpHz805ZbSn93irTU57SuGVCGuPLxbR4d35rNWgupAbtOq3HWWY gue2f3cFJOhguw1jeRd07uaju+4C1dk= X-Google-Smtp-Source: AMrXdXt3aJqHa/UMJMZvSsP6wYJ9YJCZX+zpvFz0RJGq0TUqBtmJJBZTqee5YDfhwr18HDCmjr5A4g== X-Received: by 2002:a62:1c8e:0:b0:576:ddd4:6a02 with SMTP id c136-20020a621c8e000000b00576ddd46a02mr61033469pfc.22.1673077799915; Fri, 06 Jan 2023 23:49:59 -0800 (PST) Received: from localhost ([2600:1700:38c1:1d7f:f66d:4ff:fe3c:3ceb]) by smtp.gmail.com with ESMTPSA id s64-20020a625e43000000b0056da63c8515sm2090511pfb.91.2023.01.06.23.49.59 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 06 Jan 2023 23:49:59 -0800 (PST) From: Brian Norris To: openwrt-devel@lists.openwrt.org Cc: Brian Norris Subject: [PATCH v2 4/7] ipq806x: ASoC: qcom: lpass-cpu: Fix fallback SD line index handling Date: Fri, 6 Jan 2023 23:49:42 -0800 Message-Id: <20230107074945.2140362-4-computersforpeace@gmail.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230107074945.2140362-1-computersforpeace@gmail.com> References: <20230107074945.2140362-1-computersforpeace@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230106_235001_292012_333D7129 X-CRM114-Status: GOOD ( 16.65 ) X-Spam-Score: -0.2 (/) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: This fixes device tree registration for 'qcom,lpass-cpu' as used by qcom-ipq8064 SoCs, and allows speaker audio to function. This patch has been submitted (and merged, for -next; likely v6.3) upstream. Content analysis details: (-0.2 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2607:f8b0:4864:20:0:0:0:431 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [computersforpeace[at]gmail.com] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org This fixes device tree registration for 'qcom,lpass-cpu' as used by qcom-ipq8064 SoCs, and allows speaker audio to function. This patch has been submitted (and merged, for -next; likely v6.3) upstream. Signed-off-by: Brian Norris --- Changes in v2: * Add upstream (-next) notes * Renumber to 0xx-v6.3-*.patch ...cpu-Fix-fallback-SD-line-index-handl.patch | 42 +++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 target/linux/ipq806x/patches-5.15/007-v6.3-ASoC-qcom-lpass-cpu-Fix-fallback-SD-line-index-handl.patch diff --git a/target/linux/ipq806x/patches-5.15/007-v6.3-ASoC-qcom-lpass-cpu-Fix-fallback-SD-line-index-handl.patch b/target/linux/ipq806x/patches-5.15/007-v6.3-ASoC-qcom-lpass-cpu-Fix-fallback-SD-line-index-handl.patch new file mode 100644 index 000000000000..099dc606114e --- /dev/null +++ b/target/linux/ipq806x/patches-5.15/007-v6.3-ASoC-qcom-lpass-cpu-Fix-fallback-SD-line-index-handl.patch @@ -0,0 +1,42 @@ +From: Brian Norris +Date: Thu, 15 Dec 2022 01:33:45 -0800 +Subject: [PATCH] ASoC: qcom: lpass-cpu: Fix fallback SD line index handling + +[[ Submitted upstream as: + https://lore.kernel.org/all/20221231061545.2110253-1-computersforpeace@gmail.com/ + Currently queued for -next (v6.3?) as: + 000bca8d706d ASoC: qcom: lpass-cpu: Fix fallback SD line index handling +]] + +These indices should reference the ID placed within the dai_driver +array, not the indices of the array itself. + +This fixes commit 4ff028f6c108 ("ASoC: qcom: lpass-cpu: Make I2S SD +lines configurable"), which among others, broke IPQ8064 audio +(sound/soc/qcom/lpass-ipq806x.c) because it uses ID 4 but we'd stop +initializing the mi2s_playback_sd_mode and mi2s_capture_sd_mode arrays +at ID 0. + +Fixes: 4ff028f6c108 ("ASoC: qcom: lpass-cpu: Make I2S SD lines configurable") +Cc: +Signed-off-by: Brian Norris +--- + sound/soc/qcom/lpass-cpu.c | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +--- a/sound/soc/qcom/lpass-cpu.c ++++ b/sound/soc/qcom/lpass-cpu.c +@@ -851,10 +851,11 @@ static void of_lpass_cpu_parse_dai_data( + struct lpass_data *data) + { + struct device_node *node; +- int ret, id; ++ int ret, i, id; + + /* Allow all channels by default for backwards compatibility */ +- for (id = 0; id < data->variant->num_dai; id++) { ++ for (i = 0; i < data->variant->num_dai; i++) { ++ id = data->variant->dai_driver[i].id; + data->mi2s_playback_sd_mode[id] = LPAIF_I2SCTL_MODE_8CH; + data->mi2s_capture_sd_mode[id] = LPAIF_I2SCTL_MODE_8CH; + }