Received: by 10.223.185.116 with SMTP id b49csp7188690wrg; Thu, 1 Mar 2018 01:05:20 -0800 (PST) X-Google-Smtp-Source: AG47ELsGZiBIRRGuFUld6f72pu0JIhW5UJGF1ZmpC9IQICt7o5xoAQ6Rc+a0jAFU7kSc/uCP8783 X-Received: by 10.101.76.134 with SMTP id m6mr969009pgt.445.1519895120235; Thu, 01 Mar 2018 01:05:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519895120; cv=none; d=google.com; s=arc-20160816; b=JHBI+U8DXzGmJkdikzsJ5GgNTauFmcQWAUJEw9MReMx1KErAN5m8MxyBXMzrDrLULe +/Ys26ZrOktjOXCP2TfIdryPjycgWY0RiIfiRVKcl+fAYAIfJMMwSU63ecB6RTybfvya Dh+WyyCg/oWZOKICZx0q3yyORxdTCXfJqsvEAEWj/5uMGQbNfZePxpWg7eI2t+sqfQRo 7ZlTM8MrwgchT1I9NlZYXzY/EKq628HDs1Q50p/WV7w63/dOFbTN0ORu/7GDUYiUj0Fu LA/nIZ0IuB9ihVyGa6XidkF2Oa9QxhfP/0OuUtQ6HIFg/Cq/wiKGdLH21k5gL/TM12oI W+6w== 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:cc:to:subject :message-id:date:from:references:in-reply-to:mime-version :dkim-signature:arc-authentication-results; bh=znNLFj9DJqpkAlKktJQ8f1yxSMRMCUWXRzwRqNp3t4Q=; b=T55ZDaZoHGGjr23/Pty4GLIvflu84Hq1davXxXorfHQeQwBQwlQ6grP3GyNDoBoTJn dqIGp6LLPtdCWqTqtoqM+ogvjFG0zvH6q8e9EXMQpB3St3AdXy+hZUIZADkUVaRLXKQR mNg9d1dHEGLF6zpmyvvzsaIvRT3pV4wB3y6wGVO1O+HhmeOtbqtex8NkEDUjZpVL2KVS wI/yJTauDA6gyXAXryC1NSkROEZgHE7/yb3Np3QF6qesjQcUSQVq4i3NH+1reCW2WFvs AsR0tvlO9XQ1YkCXjb9oAGUhAj7hv/t1fbnUYv5DXtZlA8VUDgRBXOHle2OAvlqCT6pP KRyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions-com.20150623.gappssmtp.com header.s=20150623 header.b=dfb45y21; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u7si2201406pgq.796.2018.03.01.01.05.04; Thu, 01 Mar 2018 01:05:20 -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=@amarulasolutions-com.20150623.gappssmtp.com header.s=20150623 header.b=dfb45y21; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S966606AbeCAJEU (ORCPT + 99 others); Thu, 1 Mar 2018 04:04:20 -0500 Received: from mail-it0-f67.google.com ([209.85.214.67]:35745 "EHLO mail-it0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965281AbeCAJEM (ORCPT ); Thu, 1 Mar 2018 04:04:12 -0500 Received: by mail-it0-f67.google.com with SMTP id v194so7028903itb.0 for ; Thu, 01 Mar 2018 01:04:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=znNLFj9DJqpkAlKktJQ8f1yxSMRMCUWXRzwRqNp3t4Q=; b=dfb45y21FegFQKKLAGD0rVXdPvAtW57k8TmpwOHVKVpYLDyf0faQ0nKp0MmTsxVHcx tycfdFBeCWfPVFbOFLBrdW3t9kJy5zV0WQ/jXG47SLnudLOSQhezr6EnnGATymOcA3RD /1j+Bel2GMpkdfSkb4O0dWDb/XYCE3rorKsvfq1ipT0+zmMUpdXfLtnuoBZR5Dw2a1BW u3GyKIpAI6MkjeAMIu1QvtR9ue8NTylopj3+r+f9JxVME6SEmqq9FBV1yzVXPhS9rX3H 5Uxf3TIfDb6lqfqi9vH5meU8Q6O3rJeDt/b2Ta3eDMMlXJ0dpeBQ4YpWcbHtUZHPfIDa 1lIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=znNLFj9DJqpkAlKktJQ8f1yxSMRMCUWXRzwRqNp3t4Q=; b=nxD7IobKhEXj0OnR4DbhYikXyzUROMmPPA2yhYNV9mX24YXeggF190jtkK5l3ZYafQ +uGXHNFyjnBVXxIfYkVlxX9O/SdutfdyL/iTaLwLoiX1LUMW5duj1cUpLOhjZKmaemhB 6Quq8vMF8eRF2LQb558G3DU/8/rA659zBj/PHsj+41Ustr9cf54DXF2dSkX6jV9tIvs9 FeBNwaLWz3NMy8n7oxi4nfPVxgEsdRDjkXsY7JaMDsiSOybVJ9Fv4FZBNauJ8mc9Sl9q v5KuDhODdlYcQH9eWFR/etMmv7dlyZnMBCWxVim0cKCWh3OC4TqG7zBLy0UHAA1Eg5ut jW/A== X-Gm-Message-State: APf1xPD1/Eivz9WMNmj7ugjSxt3dmXGsIW3ke1Gg2jRBrsFPkAtYxOsT VGly3YBCI/FJLhi9Q8dv2rs+RSmISAUBSD9JGJsjFw== X-Received: by 10.36.145.1 with SMTP id i1mr1667308ite.54.1519895051609; Thu, 01 Mar 2018 01:04:11 -0800 (PST) MIME-Version: 1.0 Received: by 10.79.227.194 with HTTP; Thu, 1 Mar 2018 01:04:11 -0800 (PST) In-Reply-To: <20180301084315.0811f712@dell-desktop.home> References: <20180227212433.2189-1-mylene.josserand@bootlin.com> <20180227212433.2189-2-mylene.josserand@bootlin.com> <20180227225140.6f9902b8@windsurf.lan> <20180301084315.0811f712@dell-desktop.home> From: Michael Nazzareno Trimarchi Date: Thu, 1 Mar 2018 10:04:11 +0100 Message-ID: Subject: Re: [alsa-devel] [PATCH v1 1/4] ASoC: codecs: pcm179x: Add PCM1789 id To: =?UTF-8?Q?Myl=C3=A8ne_Josserand?= Cc: Thomas Petazzoni , Mark Rutland , devicetree@vger.kernel.org, Linux-ALSA , alexandre.belloni@bootlin.com, LKML , Takashi Iwai , Rob Herring , Liam Girdwood , Mark Brown Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi On Thu, Mar 1, 2018 at 8:43 AM, Myl=C3=A8ne Josserand wrote: > Hello, > > Thank you for the review. > > On Tue, 27 Feb 2018 22:51:40 +0100 > Thomas Petazzoni wrote: > >> Hello, >> >> On Tue, 27 Feb 2018 22:24:30 +0100, Myl=C3=A8ne Josserand wrote: >> > To prepare the support for the PCM1789, add a new compatible >> > and use the i2c_id to handle, later, the differences between >> > these two DACs even if they are pretty similar. >> > >> > Signed-off-by: Myl=C3=A8ne Josserand >> > --- >> > Documentation/devicetree/bindings/sound/pcm179x.txt | 2 +- >> >> The DT binding change should be in a separate patch. >> >> > sound/soc/codecs/pcm179x-i2c.c | 6 ++++-- >> > sound/soc/codecs/pcm179x.c | 3 ++- >> > sound/soc/codecs/pcm179x.h | 8 +++++++- >> >> And this should be together with the PCM1789 support patch. Otherwise >> your series is not bisectable: if we apply only PATCH 1/4, the driver >> supports the new compatible string, but it doesn't have the actual code >> to handle PCM1789. Am I missing something here ? > > No, you are right, I will merge it with patch 02. > Can you please include me in next series? I have several hardware running on pcm179x family Michael >> >> > - return pcm179x_common_init(&client->dev, regmap); >> > + return pcm179x_common_init(&client->dev, regmap, id->driver_data); >> >> This can be done in a preparation patch. >> >> > } >> > >> > static const struct of_device_id pcm179x_of_match[] =3D { >> > { .compatible =3D "ti,pcm1792a", }, >> > + { .compatible =3D "ti,pcm1789", }, >> > { } >> > }; >> > MODULE_DEVICE_TABLE(of, pcm179x_of_match); >> > >> > static const struct i2c_device_id pcm179x_i2c_ids[] =3D { >> > - { "pcm179x", 0 }, >> > + { "pcm179x", PCM179X }, >> >> And also this addition. >> >> > + { "pcm1789", PCM1789 }, >> > { } >> > }; >> > MODULE_DEVICE_TABLE(i2c, pcm179x_i2c_ids); >> > diff --git a/sound/soc/codecs/pcm179x.c b/sound/soc/codecs/pcm179x.c >> > index 4b311c06f97d..81cbf09319f6 100644 >> > --- a/sound/soc/codecs/pcm179x.c >> > +++ b/sound/soc/codecs/pcm179x.c >> > @@ -218,7 +218,8 @@ static const struct snd_soc_component_driver soc_c= omponent_dev_pcm179x =3D { >> > .non_legacy_dai_naming =3D 1, >> > }; >> > >> > -int pcm179x_common_init(struct device *dev, struct regmap *regmap) >> > +int pcm179x_common_init(struct device *dev, struct regmap *regmap, >> > + enum pcm17xx_type type) >> >> And this done. >> >> > { >> > struct pcm179x_private *pcm179x; >> > >> > diff --git a/sound/soc/codecs/pcm179x.h b/sound/soc/codecs/pcm179x.h >> > index cf8681c9a373..8c08689e3b8b 100644 >> > --- a/sound/soc/codecs/pcm179x.h >> > +++ b/sound/soc/codecs/pcm179x.h >> > @@ -17,11 +17,17 @@ >> > #ifndef __PCM179X_H__ >> > #define __PCM179X_H__ >> > >> > +enum pcm17xx_type { >> > + PCM179X, >> >> And this one. >> >> > + PCM1789, >> > +}; >> > + >> > #define PCM1792A_FORMATS (SNDRV_PCM_FMTBIT_S32_LE | SNDRV_PCM_FMTBIT_= S24_LE | \ >> > SNDRV_PCM_FMTBIT_S16_LE) >> > >> > extern const struct regmap_config pcm179x_regmap_config; >> > >> > -int pcm179x_common_init(struct device *dev, struct regmap *regmap); >> > +int pcm179x_common_init(struct device *dev, struct regmap *regmap, >> > + enum pcm17xx_type type); >> >> And this one. Just as a "preparation patch" to support multiple codecs >> in the existing pcm179x.c driver. >> >> Thanks! >> >> Thomas > > Thanks, > > Myl=C3=A8ne > > -- > Myl=C3=A8ne Josserand, Bootlin (formerly Free Electrons) > Embedded Linux and Kernel engineering > http://bootlin.com > _______________________________________________ > Alsa-devel mailing list > Alsa-devel@alsa-project.org > http://mailman.alsa-project.org/mailman/listinfo/alsa-devel --=20 | Michael Nazzareno Trimarchi Amarula Solutions BV | | COO - Founder Cruquiuskade 47 | | +31(0)851119172 Amsterdam 1018 AM NL | | [`as] http://www.amarulasolutions.com |