Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1229372imu; Fri, 21 Dec 2018 15:17:29 -0800 (PST) X-Google-Smtp-Source: AFSGD/XAtELUk+1bJLNn34h0V/FEyc2YqwrWRuwUq7mNT73hokE18sL1bliFb0v27v/eYduII9Ox X-Received: by 2002:a62:8893:: with SMTP id l141mr4387499pfd.1.1545434249476; Fri, 21 Dec 2018 15:17:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545434249; cv=none; d=google.com; s=arc-20160816; b=0mcmQvr3YZs0THaLEBM5w5bzZKsBzTklB7a+2C2i0K33CjJnW+P3Ujz3LaxWWi71AK 5PvaGv/0Cbpi1Jz+SI/N1bRea+NM9n3/HdIpoWnStu3m9rnRphMfL1yxk4TNGCMHxSKJ a6zNf+KDh7pocCOsLUw5GqityBtqGhc4HynOPNU1m7KS0ai4pvA3CYfENtwkJgt9cAkc lXilEW6cTJgFFNMWc0x6PFZ02f2ebqLp3a3TJ5K+57KGZRZedM1JIJlb8uCXRy8UsSs4 C6hEUdHjDP9LF7yjzOyN3+UsJQ33eVTp+frZ03pIYs6TmhHfxWP0bNc0QjLUJAADUloa PlMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=ffmZcVfSfeQA3nmlJnD8pY5wfE+gHGqpjgHkWfO9544=; b=N7o/afKBZ8V8PniPrQLmIbeEpsR72qI7rqlLpI6WlWyK/TZyLH1xpKyxKqaWHhBJpw shbwLHQoGjtmrsFAfecDHyjX5Tl4ZNK7/TXYcVD2XwmktZ2NLYfICjrO+YX6g7TDg0b1 k4UIUCM3RiZ+vkW0CXxXnmJyCsEAxqVgMIuo1atPOrsst2KJNW5Dk3OQGP6L/UQTd3nX vZwSdWMy9y7c8WRxaMnY7Adsatg8KauyWdIcpiYguh73kxi9f1yGyS/e6aXxxt8X/3Y4 slafh8Nv6ZOYMvpjPij5H8dVFBiuQ6SjvvYtuZP208GlVsSTUepGbjbKO6aJ0mOujWDn M6xA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=SD91lDlO; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z18si21147401plo.89.2018.12.21.15.17.14; Fri, 21 Dec 2018 15:17:29 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=SD91lDlO; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390944AbeLUPVP (ORCPT + 99 others); Fri, 21 Dec 2018 10:21:15 -0500 Received: from mail-lj1-f195.google.com ([209.85.208.195]:43732 "EHLO mail-lj1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729140AbeLUPVO (ORCPT ); Fri, 21 Dec 2018 10:21:14 -0500 Received: by mail-lj1-f195.google.com with SMTP id q2-v6so5048692lji.10 for ; Fri, 21 Dec 2018 07:21:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ffmZcVfSfeQA3nmlJnD8pY5wfE+gHGqpjgHkWfO9544=; b=SD91lDlOM/WdjbURKKFSIHqQ0g0Gza3k7dVUJuwxrVD9duJAgtW3/Br9SYYSinDk0o skLAClHMdQVoxMtT4oYo1BwQiUs7+29V9GeZg1Xxf2JAXVGHCEgfpQagwJL3wSeDFobU k4lHJocQY3Zy9n9n1RQ4sPQDxPEAZ0LCfnlBO+frO9XOTJqddKA0KN/WNWUH9/8T6NWl U/bp/XG86ixxNN1aCGvZVwfBNnVUnUaiIAh6JOPhY1q6RyqepS52LPtUv7nusrfMQ0vE DBl3U+8b2WXVtwSz1jOOsGDII7pHRxvzQCqqSy4sdrqyeHxAKzOz/kwx3tSLdRpxddXM brUA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ffmZcVfSfeQA3nmlJnD8pY5wfE+gHGqpjgHkWfO9544=; b=aJZqBbmDKFepJ6l6UBB/Ht1pgJoqmV7ldN2pXyppLZ0x4suZTheYVxVzYssQoJOgzR hsKKYNOepgekLvFFc8pUGzkTar4rQsyVA4sumCy7IyPpJz9x3SxDiIq1wSWmwS5qV/NC xQalkonX7EXB6kZ4CgRn7s5kOP22YuOBBawAC/7I+PoQ8+4TkG2ND6P32hv12s8e+qMC kqQfTuLpw5KKn7oM7QJ7dc9oYxgBD71BzxCFip1GGLYCHqqC6YFUdllsv0cDfP5VXUem QkZpmdV03S80TZsckiEy4rNB7MJsDSsEIAswQSiq0e5TQXARN2qk+j2kVfi8MBw8Lkkw u3Iw== X-Gm-Message-State: AJcUukeVAye31vtv60iWbN+Qv9+zA2dvMg3/tdplYPX3oI2XVILreE7Z 9DnThaDeAIn6x/fjetuTLng= X-Received: by 2002:a2e:97d7:: with SMTP id m23-v6mr2099630ljj.18.1545405672729; Fri, 21 Dec 2018 07:21:12 -0800 (PST) Received: from localhost.localdomain (c90-142-43-138.bredband.comhem.se. [90.142.43.138]) by smtp.gmail.com with ESMTPSA id q30sm5005601lfi.94.2018.12.21.07.21.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 21 Dec 2018 07:21:11 -0800 (PST) From: codekipper@gmail.com To: maxime.ripard@free-electrons.com, wens@csie.org, linux-sunxi@googlegroups.com Cc: linux-arm-kernel@lists.infradead.org, lgirdwood@gmail.com, broonie@kernel.org, linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, be17068@iperbole.bo.it, Marcus Cooper Subject: [PATCH v3 0/9] ASoC: sun4i-i2s: Updates to the driver Date: Fri, 21 Dec 2018 16:21:01 +0100 Message-Id: <20181221152110.17982-1-codekipper@gmail.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Marcus Cooper Hi All, here is a patch series to add some improvements to the sun4i-i2s driver found whilst getting slave clocking and hdmi audio working on the newer SoCs. Since the last push there has been some activity getting surround sound working and this is included. The functionality included with the new patch set has been extended to cover more sample resolutions, multi-lane data output for HDMI audio and some bug fixes that have been discovered along the way. I can see more usage of the tdm property since I last attempted to push these patches and the examples currently in mainline sort of the opposite to what I'm trying to achieve. When we first started looking at the i2s driver, the codecs that we were using allowed for the frame width to be determined based on the sampling resolution but in most use cases it seems that a fixed width is required(my highest priority should be to get HDMI audio support in). We're using the tdm property to override the old way to calculate the frame width. What I've seen in what has already been mainlined is that the i2s driver has a frame width that is fixed to 32 bits and this can be overridden using the tdm property. Anyway, I've moved the more controversial patches to the top of the stack as I'm expecting feedback. Have a great Xmas and New Year, BR, CK --- v3 changes compared to v2 are: - added back slave mode changes - added back the use of tdm properties - changes to regmap and caching - removed loopback functionality - fixes to the channel offset mask v2 changes compared to v1 are: - removed slave mode changes which didn't set mclk and bclk div. - removed use of tdm and now use a dedicated property. - fix commit message to better explain reason for sign extending - add divider calculations for newer SoCs. - add support for multi-lane i2s data output. - add support for 20, 24 and 32 bit samples. - add loopback property so blocks can be tested without a codec. --- Marcus Cooper (9): ASoC: sun4i-i2s: Adjust regmap settings ASoC: sun4i-i2s: Add regmap field to sign extend sample ASoc: sun4i-i2s: Add 20, 24 and 32 bit support ASoC: sun4i-i2s: Fix offset mask ASoC: sun4i-i2s: Correct divider calculations ASoC: sun4i-i2s: Add multi-lane functionality ASoC: sun4i-i2s: Do not divide clocks when slave ASoC: sun4i-i2s: Add set_tdm_slot functionality ASoC: sun4i-i2s: Add multichannel functionality sound/soc/sunxi/sun4i-i2s.c | 399 ++++++++++++++++++++++++------------ 1 file changed, 267 insertions(+), 132 deletions(-) -- 2.20.1