From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 60444C17445 for ; Mon, 11 Nov 2019 17:20:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3D2F120656 for ; Mon, 11 Nov 2019 17:20:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727027AbfKKRUU (ORCPT ); Mon, 11 Nov 2019 12:20:20 -0500 Received: from mx2.suse.de ([195.135.220.15]:50538 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726845AbfKKRUT (ORCPT ); Mon, 11 Nov 2019 12:20:19 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id F37BCAC2C; Mon, 11 Nov 2019 17:20:17 +0000 (UTC) Date: Mon, 11 Nov 2019 18:20:17 +0100 Message-ID: From: Takashi Iwai To: "RAVULAPATI, VISHNU VARDHAN RAO" Cc: Pierre-Louis Bossart , "moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM..." , Maruthi Srinivas Bayyavarapu , open list , Takashi Iwai , Liam Girdwood , "Agrawal, Akshu" , Mark Brown , "djkurtz@google.com" , "Mukunda, Vijendar" , "Deucher, Alexander" , Colin Ian King , Dan Carpenter Subject: Re: [alsa-devel] [RESEND PATCH v4 1/6] ASoC: amd:Create multiple I2S platform device Endpoint In-Reply-To: References: <1573483794-8921-1-git-send-email-Vishnuvardhanrao.Ravulapati@amd.com> <1573483794-8921-2-git-send-email-Vishnuvardhanrao.Ravulapati@amd.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/25.3 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 11 Nov 2019 18:16:25 +0100, RAVULAPATI, VISHNU VARDHAN RAO wrote: > > > + pdevinfo[2].name = "acp3x_i2s_playcap"; > > + pdevinfo[2].id = 1; > > + pdevinfo[2].parent = &pci->dev; > > + pdevinfo[2].num_res = 1; > > + pdevinfo[2].res = &adata->res[2]; > > + for (i = 0; i < ACP3x_DEVS ; i++) { > > + adata->pdev[i] = > > + platform_device_register_full(&pdevinfo[i]); > > + IS_ERR(adata->pdev[i]) { > > how does this even compile? > > I have not faced any issue of compilation. > Can I know what is wrong with it please so that it can be re checked. The "if" is missing around IS_ERR() in the above line. It should have been if (IS_ERR(adata->pdev[i])) { ..... It's interesting the code didn't give any compile warning or error, indeed. thanks, Takashi From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 68229C43331 for ; Mon, 11 Nov 2019 17:21:17 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id DE55D2184C for ; Mon, 11 Nov 2019 17:21:16 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="XkLvn21J" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DE55D2184C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org 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 BFCCF166D; Mon, 11 Nov 2019 18:20:24 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz BFCCF166D DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1573492874; bh=zogVsltFDq0vfJ68bhi5MsbHM3xT/mYiQo4JrES9i50=; h=Date:From:To:In-Reply-To:References:Cc:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=XkLvn21JxddeNiIpEN2+iTrOkbo+9UFAPFPQ8pcKYylc+HuVIVTS+uw6pDpkTTjZU 5JGhNleUcnhPv098wnaWl/VXwY5SkiohofgDcsuXTJfHZQMysQCWHNCAObcYo3UEPt DMuIga6dmarQHnyEGV+8adKAJRElVlqvPXFispVk= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 47F84F8045D; Mon, 11 Nov 2019 18:20:24 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 272E8F804FF; Mon, 11 Nov 2019 18:20:22 +0100 (CET) Received: from mx1.suse.de (mx2.suse.de [195.135.220.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id AEE07F80275 for ; Mon, 11 Nov 2019 18:20:19 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz AEE07F80275 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id F37BCAC2C; Mon, 11 Nov 2019 17:20:17 +0000 (UTC) Date: Mon, 11 Nov 2019 18:20:17 +0100 Message-ID: From: Takashi Iwai To: "RAVULAPATI, VISHNU VARDHAN RAO" In-Reply-To: References: <1573483794-8921-1-git-send-email-Vishnuvardhanrao.Ravulapati@amd.com> <1573483794-8921-2-git-send-email-Vishnuvardhanrao.Ravulapati@amd.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/25.3 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Cc: Pierre-Louis Bossart , "moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM..." , Maruthi Srinivas Bayyavarapu , open list , Liam Girdwood , Takashi Iwai , Mark Brown , "djkurtz@google.com" , "Mukunda, Vijendar" , "Deucher, Alexander" , Colin Ian King , "Agrawal, Akshu" , Dan Carpenter Subject: Re: [alsa-devel] [RESEND PATCH v4 1/6] ASoC: amd:Create multiple I2S platform device Endpoint 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: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" On Mon, 11 Nov 2019 18:16:25 +0100, RAVULAPATI, VISHNU VARDHAN RAO wrote: > > > + pdevinfo[2].name = "acp3x_i2s_playcap"; > > + pdevinfo[2].id = 1; > > + pdevinfo[2].parent = &pci->dev; > > + pdevinfo[2].num_res = 1; > > + pdevinfo[2].res = &adata->res[2]; > > + for (i = 0; i < ACP3x_DEVS ; i++) { > > + adata->pdev[i] = > > + platform_device_register_full(&pdevinfo[i]); > > + IS_ERR(adata->pdev[i]) { > > how does this even compile? > > I have not faced any issue of compilation. > Can I know what is wrong with it please so that it can be re checked. The "if" is missing around IS_ERR() in the above line. It should have been if (IS_ERR(adata->pdev[i])) { ..... It's interesting the code didn't give any compile warning or error, indeed. thanks, Takashi _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org https://mailman.alsa-project.org/mailman/listinfo/alsa-devel