From patchwork Tue Apr 9 11:27:39 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viorel Suman X-Patchwork-Id: 10891043 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 836DE1800 for ; Tue, 9 Apr 2019 11:29:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6B39623B24 for ; Tue, 9 Apr 2019 11:29:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5F0C42787C; Tue, 9 Apr 2019 11:29:41 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=unavailable version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id B27B02582C for ; Tue, 9 Apr 2019 11:29:39 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 05694922; Tue, 9 Apr 2019 13:28:47 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 05694922 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1554809377; bh=lFpT7B0+Scza401FLm9JUu0LLGZzd/nYkRddW7sDjuo=; h=From:To:Date:References:In-Reply-To:Cc:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=D8C6vdce6RIa2WlbSWCx1Sv+p14nKTbu9kDaQuoA6pmCjpORokz6vFN2PiShyQj2f z50mP+8nW9D3bLc/l9NdAb3waxfkpAYy3GURYchveYDO7eUQL+UBb5/YfRuq+O0JGk pYJw6F3dWgiQQsZ0heNbHnp1mVj5crJEOerolnhI= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id D4224F896F7; Tue, 9 Apr 2019 13:27:52 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa1.perex.cz (Postfix, from userid 50401) id 99461F896F2; Tue, 9 Apr 2019 13:27:48 +0200 (CEST) Received: from EUR02-AM5-obe.outbound.protection.outlook.com (mail-eopbgr00064.outbound.protection.outlook.com [40.107.0.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 68C27F80765 for ; Tue, 9 Apr 2019 13:27:43 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 68C27F80765 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="SEFirZVX" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=j2Ju+O4UGe6Y9ew5sPc51J2IVGIlIFdE3CIXc++UUIQ=; b=SEFirZVXUjYg3rzInFTKNYZGQmNwdgeqvz3bjxgWoNc2QI9C36mI07MnlSPpwL06qFqNjvHijuYhQIT7oax1Z/Yt9bJowcX3gCiNhSg4vYV2d0361ZhTvdABU6j6zYJAXtR+QLc/Xxa6V1ufVu+yBvLIsm0Cj0p8qVOv+BIYlqo= Received: from VI1PR04MB4704.eurprd04.prod.outlook.com (20.177.48.157) by VI1PR04MB3086.eurprd04.prod.outlook.com (10.170.228.160) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1771.16; Tue, 9 Apr 2019 11:27:39 +0000 Received: from VI1PR04MB4704.eurprd04.prod.outlook.com ([fe80::2594:3cf0:20a2:8888]) by VI1PR04MB4704.eurprd04.prod.outlook.com ([fe80::2594:3cf0:20a2:8888%3]) with mapi id 15.20.1792.009; Tue, 9 Apr 2019 11:27:39 +0000 From: Viorel Suman To: Timur Tabi , Nicolin Chen , Xiubo Li , Fabio Estevam , Liam Girdwood , Mark Brown , Jaroslav Kysela , Rob Herring , Mark Rutland , Takashi Iwai , Shawn Guo , Sascha Hauer , Julia Lawall Thread-Topic: [PATCH v2 1/3] ASoC: fsl_audmix: remove "model" attribute Thread-Index: AQHU7sc9qpmulFGub0K/+sjdGTcqzQ== Date: Tue, 9 Apr 2019 11:27:39 +0000 Message-ID: <1554809242-27475-2-git-send-email-viorel.suman@nxp.com> References: <1554809242-27475-1-git-send-email-viorel.suman@nxp.com> In-Reply-To: <1554809242-27475-1-git-send-email-viorel.suman@nxp.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: VI1PR08CA0187.eurprd08.prod.outlook.com (2603:10a6:800:d2::17) To VI1PR04MB4704.eurprd04.prod.outlook.com (2603:10a6:803:52::29) authentication-results: spf=none (sender IP is ) smtp.mailfrom=viorel.suman@nxp.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.7.4 x-originating-ip: [212.146.100.6] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: e6a08f5c-6eb6-42a6-7f9d-08d6bcde5fc7 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(5600139)(711020)(4605104)(4618075)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7193020); SRVR:VI1PR04MB3086; x-ms-traffictypediagnostic: VI1PR04MB3086: x-microsoft-antispam-prvs: x-forefront-prvs: 000227DA0C x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(346002)(136003)(39860400002)(366004)(396003)(376002)(189003)(199004)(106356001)(71200400001)(71190400001)(256004)(68736007)(5660300002)(8676002)(81156014)(81166006)(105586002)(478600001)(97736004)(66066001)(36756003)(102836004)(6506007)(7416002)(486006)(476003)(2616005)(11346002)(446003)(4326008)(8936002)(386003)(6512007)(26005)(186003)(14454004)(50226002)(25786009)(6436002)(53936002)(76176011)(2906002)(54906003)(3846002)(6116002)(99286004)(44832011)(52116002)(305945005)(316002)(110136005)(86362001)(6486002)(7736002)(921003)(1121003); DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR04MB3086; H:VI1PR04MB4704.eurprd04.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: 95i6TN7GaBzkU5P57jb+4ULHKIXyclcp3SSHC54zAkXb2aIdZ2F3l4pZndhNXdYV3oZ9nCEt1rS8kcZXYAqaHuMILVpvta9fRQGA/Ave8X5oZQDlxz4FISAkpBnMyimDBeEMuHsjnbVRfXzf1LVCLffMJfx70qLSkzQwxiumbyIVKhbWvQdO7JQmzDkP3Yx7kGjZodwOhIsX7JifTB/gzFTOnJdXPKMafpjwNzI0LkJRSpw/qM+oqX5kQoswPlcMZyNHEBpjqfo3bGL0JAgSMoLnUzXc69BJuJTeCNaKz4zybxUfNbK0wSvn1pYBTUeQPz3SrjO1h+h2WxukGLFVgKuom3RmJmj4ohbDcE8rO+POEBV10le11YU9yZtK9KFuXUQSB10Lr8GMfHQpZeZSOiNRSBfS7dKFDm6fAfmrs+4= MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: e6a08f5c-6eb6-42a6-7f9d-08d6bcde5fc7 X-MS-Exchange-CrossTenant-originalarrivaltime: 09 Apr 2019 11:27:39.7927 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB3086 Cc: "devicetree@vger.kernel.org" , "alsa-devel@alsa-project.org" , Viorel Suman , "linux-kernel@vger.kernel.org" , Viorel Suman , dl-linux-imx , Pengutronix Kernel Team , "linuxppc-dev@lists.ozlabs.org" , "linux-arm-kernel@lists.infradead.org" Subject: [alsa-devel] [PATCH v2 1/3] ASoC: fsl_audmix: remove "model" attribute X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" X-Virus-Scanned: ClamAV using ClamSMTP Use "of_device_id.data" to specify the machine driver instead of "model" DTS attribute. Signed-off-by: Viorel Suman Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_audmix.c | 43 +++++++++++++++++++++++-------------------- 1 file changed, 23 insertions(+), 20 deletions(-) diff --git a/sound/soc/fsl/fsl_audmix.c b/sound/soc/fsl/fsl_audmix.c index dabde03..dc802d5 100644 --- a/sound/soc/fsl/fsl_audmix.c +++ b/sound/soc/fsl/fsl_audmix.c @@ -445,13 +445,29 @@ static const struct regmap_config fsl_audmix_regmap_config = { .cache_type = REGCACHE_FLAT, }; +static const struct of_device_id fsl_audmix_ids[] = { + { + .compatible = "fsl,imx8qm-audmix", + .data = "imx-audmix", + }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(of, fsl_audmix_ids); + static int fsl_audmix_probe(struct platform_device *pdev) { struct fsl_audmix *priv; struct resource *res; + const char *mdrv; + const struct of_device_id *of_id; void __iomem *regs; int ret; - const char *sprop; + + of_id = of_match_device(fsl_audmix_ids, &pdev->dev); + if (!of_id || !of_id->data) + return -EINVAL; + + mdrv = of_id->data; priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL); if (!priv) @@ -487,19 +503,12 @@ static int fsl_audmix_probe(struct platform_device *pdev) return ret; } - sprop = of_get_property(pdev->dev.of_node, "model", NULL); - if (sprop) { - priv->pdev = platform_device_register_data(&pdev->dev, sprop, 0, - NULL, 0); - if (IS_ERR(priv->pdev)) { - ret = PTR_ERR(priv->pdev); - dev_err(&pdev->dev, - "failed to register platform %s: %d\n", sprop, - ret); - } - } else { - dev_err(&pdev->dev, "[model] attribute missing.\n"); - ret = -EINVAL; + priv->pdev = platform_device_register_data(&pdev->dev, mdrv, 0, NULL, + 0); + if (IS_ERR(priv->pdev)) { + ret = PTR_ERR(priv->pdev); + dev_err(&pdev->dev, "failed to register platform %s: %d\n", + mdrv, ret); } return ret; @@ -553,12 +562,6 @@ static const struct dev_pm_ops fsl_audmix_pm = { pm_runtime_force_resume) }; -static const struct of_device_id fsl_audmix_ids[] = { - { .compatible = "fsl,imx8qm-audmix", }, - { /* sentinel */ } -}; -MODULE_DEVICE_TABLE(of, fsl_audmix_ids); - static struct platform_driver fsl_audmix_driver = { .probe = fsl_audmix_probe, .remove = fsl_audmix_remove, From patchwork Tue Apr 9 11:27:40 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viorel Suman X-Patchwork-Id: 10891079 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 04A861515 for ; Tue, 9 Apr 2019 11:30:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E070B23B24 for ; Tue, 9 Apr 2019 11:30:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D3EAA28872; Tue, 9 Apr 2019 11:30:24 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 3283D23B24 for ; Tue, 9 Apr 2019 11:30:24 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 69264888; Tue, 9 Apr 2019 13:29:32 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 69264888 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1554809422; bh=/kwXbuGe1sh2zfAeFwBREHy/PbcEhIRw49E3KHZL3vk=; h=From:To:Date:References:In-Reply-To:Cc:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=TDPKTyzilMEhDjx1qiRj2+liK/gAJOW5iDu+o7iYVY16HDItYytlVkbE3cHpvv45t DBdhxaKu2mRqD0dGfnCscE4gE3rLx6f+eqJ9oUd3y7pxvjC+bYAaQ1kdet8Rb90Z0K 3gKiAy2JXtctG5XDQ8vO8jBuYFkpYbShzz0QRnI8= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 1327EF8971A; Tue, 9 Apr 2019 13:27:56 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa1.perex.cz (Postfix, from userid 50401) id 86E6CF896F7; Tue, 9 Apr 2019 13:27:49 +0200 (CEST) Received: from EUR02-AM5-obe.outbound.protection.outlook.com (mail-eopbgr00064.outbound.protection.outlook.com [40.107.0.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 320BFF89625 for ; Tue, 9 Apr 2019 13:27:45 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 320BFF89625 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="QjQ67Dno" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=c6NrgQhMOQwwBdEIxmvg14af3hG4jnoZ5T+SkoB+wJU=; b=QjQ67DnorCPSJWbXEtwoigWTK9kuD6looLJVxLKrUV1g9b4xr0PF1LqzY85AekMYcThox3O/kttfxuDgqjQ7KWXlSPH+FY3PZiEOZZLExgdbKbL7can01PoSeato1mZl5kWfqSrz589gQZJiCiL6JtCBFRnwkkJQGBbrpj4loxc= Received: from VI1PR04MB4704.eurprd04.prod.outlook.com (20.177.48.157) by VI1PR04MB3086.eurprd04.prod.outlook.com (10.170.228.160) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1771.16; Tue, 9 Apr 2019 11:27:41 +0000 Received: from VI1PR04MB4704.eurprd04.prod.outlook.com ([fe80::2594:3cf0:20a2:8888]) by VI1PR04MB4704.eurprd04.prod.outlook.com ([fe80::2594:3cf0:20a2:8888%3]) with mapi id 15.20.1792.009; Tue, 9 Apr 2019 11:27:40 +0000 From: Viorel Suman To: Timur Tabi , Nicolin Chen , Xiubo Li , Fabio Estevam , Liam Girdwood , Mark Brown , Jaroslav Kysela , Rob Herring , Mark Rutland , Takashi Iwai , Shawn Guo , Sascha Hauer , Julia Lawall Thread-Topic: [PATCH v2 2/3] dt-bindings: fsl, audmix: remove "model" attribute Thread-Index: AQHU7sc+tBzccqTIbEGI7+Z1sKouvQ== Date: Tue, 9 Apr 2019 11:27:40 +0000 Message-ID: <1554809242-27475-3-git-send-email-viorel.suman@nxp.com> References: <1554809242-27475-1-git-send-email-viorel.suman@nxp.com> In-Reply-To: <1554809242-27475-1-git-send-email-viorel.suman@nxp.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: VI1PR08CA0187.eurprd08.prod.outlook.com (2603:10a6:800:d2::17) To VI1PR04MB4704.eurprd04.prod.outlook.com (2603:10a6:803:52::29) authentication-results: spf=none (sender IP is ) smtp.mailfrom=viorel.suman@nxp.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.7.4 x-originating-ip: [212.146.100.6] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: c86c69e9-90f9-4da6-9e10-08d6bcde606f x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(5600139)(711020)(4605104)(4618075)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7193020); SRVR:VI1PR04MB3086; x-ms-traffictypediagnostic: VI1PR04MB3086: x-microsoft-antispam-prvs: x-forefront-prvs: 000227DA0C x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(346002)(136003)(39860400002)(366004)(396003)(376002)(189003)(199004)(106356001)(71200400001)(71190400001)(256004)(68736007)(5660300002)(8676002)(81156014)(81166006)(105586002)(478600001)(97736004)(66066001)(36756003)(102836004)(6506007)(7416002)(486006)(476003)(2616005)(11346002)(446003)(4326008)(8936002)(386003)(6512007)(26005)(186003)(14454004)(50226002)(25786009)(6436002)(53936002)(76176011)(2906002)(54906003)(3846002)(6116002)(99286004)(44832011)(52116002)(305945005)(316002)(110136005)(4744005)(86362001)(6486002)(7736002)(921003)(142933001)(1121003); DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR04MB3086; H:VI1PR04MB4704.eurprd04.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: Nafi6YjdUjjf5he3lyG7UWSij61zj9CkDA8daQK8yNbl7uaMhI7fti3WZCKV224s3786ZXWkzuHMrkD27I3mKpwfc+nWcNqDXT+Fq5gpfVHoBZ1GrwBX9EjYudccJiu7UW2h9ID/vq90vis6NU/9jHNr5fT9fTx5D5gMbwz9rELYh/dorQ/TbSKExHHgjyZlCQpYskAYpm6nPEV/OAAGb+zraR5cK555FKa8VsBxFnWxSFduAY2x5lcWOT9i0opR/huzqznmll7sviBGiYlIOb4/pPSHvoniBM7b5119WEDrPy3UTmEHxImqknap5RuXtfgSNoGt2VTjxzoMGx+e4Uy9RiBh7D+r24IvftWW+rmhFAzuEspbqjD/1XmTEQNfF5kRXcXS/L6FSh9UO7/3HjCVpy/nWMU5DTb9QYMmP14= MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: c86c69e9-90f9-4da6-9e10-08d6bcde606f X-MS-Exchange-CrossTenant-originalarrivaltime: 09 Apr 2019 11:27:40.8654 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB3086 Cc: "devicetree@vger.kernel.org" , "alsa-devel@alsa-project.org" , Viorel Suman , "linux-kernel@vger.kernel.org" , Viorel Suman , dl-linux-imx , Pengutronix Kernel Team , "linuxppc-dev@lists.ozlabs.org" , "linux-arm-kernel@lists.infradead.org" Subject: [alsa-devel] [PATCH v2 2/3] dt-bindings: fsl, audmix: remove "model" attribute X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" X-Virus-Scanned: ClamAV using ClamSMTP Remove "model" attribute. Signed-off-by: Viorel Suman Acked-by: Nicolin Chen --- Documentation/devicetree/bindings/sound/fsl,audmix.txt | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Documentation/devicetree/bindings/sound/fsl,audmix.txt b/Documentation/devicetree/bindings/sound/fsl,audmix.txt index 45f807e..840b7e0 100644 --- a/Documentation/devicetree/bindings/sound/fsl,audmix.txt +++ b/Documentation/devicetree/bindings/sound/fsl,audmix.txt @@ -38,9 +38,6 @@ Device driver required properties: to SAI interfaces to be provided, the first SAI in the list being used to route the AUDMIX output. - - model : Must contain machine driver name which will configure - and instantiate the appropriate audio card. - Device driver configuration example: ====================================== audmix: audmix@59840000 { @@ -50,5 +47,4 @@ Device driver configuration example: clock-names = "ipg"; power-domains = <&pd_audmix>; dais = <&sai4>, <&sai5>; - model = "imx-audmix"; }; From patchwork Tue Apr 9 11:27:42 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viorel Suman X-Patchwork-Id: 10891081 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id BA412139A for ; Tue, 9 Apr 2019 11:31:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A02AE23B24 for ; Tue, 9 Apr 2019 11:31:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 93C852886F; Tue, 9 Apr 2019 11:31:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D69C523B24 for ; Tue, 9 Apr 2019 11:31:14 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 08B6A884; Tue, 9 Apr 2019 13:30:23 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 08B6A884 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1554809473; bh=mbpeA4pplFjSdTw4MCOVThs7P/b2nb5s8GDcgUtTNCs=; h=From:To:Date:References:In-Reply-To:Cc:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=Sci8QPTAV5zpABGF8UMXQmqK60TJlBjWvN/bG6W8dEowyyQ95ufrp3jCqliZT8JIe NM1jYLQ4XnsYjXjtIFxRJbY3n9omLQIvxjix/Hu630hYpTgM0V7UjjuiefOOfx7KtO 5DOGOz2Ayue/fVByG4FpuM/zpH9Rdcxp1ZvQPSU8= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 231E1F89726; Tue, 9 Apr 2019 13:28:00 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa1.perex.cz (Postfix, from userid 50401) id D73DEF89636; Tue, 9 Apr 2019 13:27:50 +0200 (CEST) Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-eopbgr60076.outbound.protection.outlook.com [40.107.6.76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id E96E3F80C17 for ; Tue, 9 Apr 2019 13:27:46 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz E96E3F80C17 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="OSNiQCGG" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=1CN2h3kDeze9CrlUJZ2HyX75qCHNNCF8VcNChwJhJM8=; b=OSNiQCGGIOHvnDhu2EOGaREzSJv2dA5tKL8ZubRnq4Iv24Aink61y+tLfcOPgCQ9Ld4Jpv9gQD0xk4H2pfPM5P2h/FavNbocW9oknbnIH+wKZVAxqKtXBL4W9Hec214Sk4ZU6qkjFCOPXBFbGuj/8ENcNZKVVHmNZJrtYc2G9lQ= Received: from VI1PR04MB4704.eurprd04.prod.outlook.com (20.177.48.157) by VI1PR04MB5216.eurprd04.prod.outlook.com (20.177.51.205) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1771.16; Tue, 9 Apr 2019 11:27:42 +0000 Received: from VI1PR04MB4704.eurprd04.prod.outlook.com ([fe80::2594:3cf0:20a2:8888]) by VI1PR04MB4704.eurprd04.prod.outlook.com ([fe80::2594:3cf0:20a2:8888%3]) with mapi id 15.20.1792.009; Tue, 9 Apr 2019 11:27:42 +0000 From: Viorel Suman To: Timur Tabi , Nicolin Chen , Xiubo Li , Fabio Estevam , Liam Girdwood , Mark Brown , Jaroslav Kysela , Rob Herring , Mark Rutland , Takashi Iwai , Shawn Guo , Sascha Hauer , Julia Lawall Thread-Topic: [PATCH v2 3/3] ASoC: imx-audmix: fix object reference leaks in probe Thread-Index: AQHU7sc+9q6sLFqPvEazfy9Py2lM7g== Date: Tue, 9 Apr 2019 11:27:42 +0000 Message-ID: <1554809242-27475-4-git-send-email-viorel.suman@nxp.com> References: <1554809242-27475-1-git-send-email-viorel.suman@nxp.com> In-Reply-To: <1554809242-27475-1-git-send-email-viorel.suman@nxp.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: VI1PR08CA0187.eurprd08.prod.outlook.com (2603:10a6:800:d2::17) To VI1PR04MB4704.eurprd04.prod.outlook.com (2603:10a6:803:52::29) authentication-results: spf=none (sender IP is ) smtp.mailfrom=viorel.suman@nxp.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.7.4 x-originating-ip: [212.146.100.6] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 98b606a0-705f-46a2-15c5-08d6bcde6131 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600139)(711020)(4605104)(4618075)(2017052603328)(7193020); SRVR:VI1PR04MB5216; x-ms-traffictypediagnostic: VI1PR04MB5216: x-microsoft-antispam-prvs: x-forefront-prvs: 000227DA0C x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(136003)(366004)(396003)(346002)(39860400002)(376002)(189003)(199004)(386003)(6486002)(106356001)(5660300002)(6512007)(26005)(76176011)(44832011)(8936002)(7416002)(8676002)(81156014)(81166006)(3846002)(71190400001)(71200400001)(6506007)(105586002)(97736004)(86362001)(6116002)(68736007)(66066001)(102836004)(14454004)(99286004)(316002)(11346002)(2616005)(110136005)(486006)(478600001)(54906003)(256004)(36756003)(305945005)(7736002)(53936002)(476003)(4326008)(6436002)(446003)(2906002)(50226002)(25786009)(186003)(52116002)(921003)(1121003); DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR04MB5216; H:VI1PR04MB4704.eurprd04.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: FWC/57vLScyCH9XwTHP4ash9QthHXueBXNaCJ8KwqwrPhdqLNyJuStOaDHNbc0EtaiDGSS78OKgpV6fNUDNXtncjmICfKvvN+Vof+krr7gnfxPgYX1kPsm3PtCvuKX/TM+jdMHWoiNuBJUZXIrtNRMAWesUjQ/hp+mOESPPP0VbOKoRyM/Pg64pOJErO87ewSRVGrJ8fGtJHYHj6twfumEmmgytBHz+JxOluO942h2E3ZHJVkSpm+3rfeCRgWGh3xcThzbnHjOlENfPu5JhQ9DL5WK93dzhNy/YfCDr6/G19V2tb0iTzPoG6q4SwkXRL3cG8KhBHslv9bdiJQyvunFk229Aq+iJZQGvxjhA5A6IRispFSeWm2TioKNR/7JpWnG28vH4GZfZ0qOfIqNDLzndY0fPG7BksrfMaLhKy7lg= MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 98b606a0-705f-46a2-15c5-08d6bcde6131 X-MS-Exchange-CrossTenant-originalarrivaltime: 09 Apr 2019 11:27:42.2755 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB5216 Cc: "devicetree@vger.kernel.org" , "alsa-devel@alsa-project.org" , Viorel Suman , "linux-kernel@vger.kernel.org" , Viorel Suman , dl-linux-imx , Pengutronix Kernel Team , "linuxppc-dev@lists.ozlabs.org" , "linux-arm-kernel@lists.infradead.org" Subject: [alsa-devel] [PATCH v2 3/3] ASoC: imx-audmix: fix object reference leaks in probe X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" X-Virus-Scanned: ClamAV using ClamSMTP Release the reference to the underlying device taken by of_find_device_by_node() call. Signed-off-by: Viorel Suman Reported-by: Julia Lawall Acked-by: Nicolin Chen --- sound/soc/fsl/imx-audmix.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sound/soc/fsl/imx-audmix.c b/sound/soc/fsl/imx-audmix.c index 7983bd3..9aaf3e5 100644 --- a/sound/soc/fsl/imx-audmix.c +++ b/sound/soc/fsl/imx-audmix.c @@ -171,6 +171,7 @@ static int imx_audmix_probe(struct platform_device *pdev) np->full_name); return -EINVAL; } + put_device(&audmix_pdev->dev); num_dai = of_count_phandle_with_args(audmix_np, "dais", NULL); if (num_dai != FSL_AUDMIX_MAX_DAIS) { @@ -216,6 +217,7 @@ static int imx_audmix_probe(struct platform_device *pdev) dev_err(&pdev->dev, "failed to find SAI platform device\n"); return -EINVAL; } + put_device(&cpu_pdev->dev); dai_name = devm_kasprintf(&pdev->dev, GFP_KERNEL, "%s%s", fe_name_pref, args.np->full_name + 1); @@ -280,6 +282,8 @@ static int imx_audmix_probe(struct platform_device *pdev) dev_err(&pdev->dev, "failed to find SAI platform device\n"); return -EINVAL; } + put_device(&cpu_pdev->dev); + priv->cpu_mclk = devm_clk_get(&cpu_pdev->dev, "mclk1"); if (IS_ERR(priv->cpu_mclk)) { ret = PTR_ERR(priv->cpu_mclk);