Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751783AbdLBMKJ (ORCPT ); Sat, 2 Dec 2017 07:10:09 -0500 Received: from mail-it0-f66.google.com ([209.85.214.66]:42868 "EHLO mail-it0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751673AbdLBMKF (ORCPT ); Sat, 2 Dec 2017 07:10:05 -0500 X-Google-Smtp-Source: AGs4zMZPvV+gvJGDdZjcU5xZGHpteWNPkIuv5gnRaAoCMaOPR57QY96nRSPlGwcs8bL3kHFI+UJkfgH20RLudJ2JSbI= MIME-Version: 1.0 In-Reply-To: <1eff5a38-cff3-449b-bda4-047f50a9f1d4@EX17.ad.cirrus.com> References: <20171123171316.10868-1-rf@opensource.wolfsonmicro.com> <1eff5a38-cff3-449b-bda4-047f50a9f1d4@EX17.ad.cirrus.com> From: Linus Walleij Date: Sat, 2 Dec 2017 13:10:04 +0100 Message-ID: Subject: Re: [PATCH v6 03/17] mfd: madera: Add common support for Cirrus Logic Madera codecs To: Richard Fitzgerald Cc: Lee Jones , Mark Brown , Alexandre Courbot , Rob Herring , Thomas Gleixner , Jason Cooper , alsa-devel@alsa-project.org, "open list:WOLFSON MICROELECTRONICS DRIVERS" , linux-gpio@vger.kernel.org, "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , "linux-kernel@vger.kernel.org" , Charles Keepax , Nikesh Oswal Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1847 Lines: 52 On Wed, Nov 29, 2017 at 12:36 PM, Richard Fitzgerald wrote: > On 29/11/17 10:18, Linus Walleij wrote: >> >> On Thu, Nov 23, 2017 at 6:13 PM, Richard Fitzgerald >> wrote: >> >>> +config MFD_MADERA_I2C >>> + bool "Cirrus Logic Madera codecs with I2C" >>> + select MFD_MADERA >>> + select REGMAP_I2C >>> + depends on I2C >>> + depends on PINCTRL >>> + help >>> + Support for the Cirrus Logic Madera platform audio SoC >>> + core functionality controlled via I2C. >>> + >>> +config MFD_MADERA_SPI >>> + bool "Cirrus Logic Madera codecs with SPI" >>> + select MFD_MADERA >>> + select REGMAP_SPI >>> + depends on SPI_MASTER >>> + depends on PINCTRL >>> + help >>> + Support for the Cirrus Logic Madera platform audio SoC >>> + core functionality controlled via SPI. >> >> >> Why do the I2C and SPI subdrivers depend on PINCTRL? >> >> They sure don't seem to be using any pinctrl-specific APIs. >> > > They require PINCTRL even if they don't call any functions on it because the > chip won't work correctly if there isn't a PINCTRL driver to apply the > correct pinmux configuration. Apply the configuration to what? Sorry I don't get it. You can't be referring to the internal pin controller of the Madera, since that has to come up before its pin controller can even be communicated with. If you mean it is to apply the configuration to the system SoC where this coded is connected, this is wrong. There may very well be systems which have dedicated pins for the codec, atleast in theory. The fact that your reference board needs this is not a universal requirement, it should be set up in the machine-specific Kconfig for the reference board in that case. Yours, Linus Walleij