From patchwork Sun Aug 20 05:55:13 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Donglin Peng X-Patchwork-Id: 9910951 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 25547601D4 for ; Sun, 20 Aug 2017 05:55:30 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0BB4D288CD for ; Sun, 20 Aug 2017 05:55:30 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E0BBA288D2; Sun, 20 Aug 2017 05:55:29 +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=0.6 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_HTTP, RCVD_IN_SORBS_SOCKS,RCVD_IN_SORBS_SPAM,T_DKIM_INVALID autolearn=no version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D632E288CD for ; Sun, 20 Aug 2017 05:55:28 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 738742673C0; Sun, 20 Aug 2017 07:55:24 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 4E1622673C1; Sun, 20 Aug 2017 07:55:22 +0200 (CEST) Received: from mail-pf0-f193.google.com (mail-pf0-f193.google.com [209.85.192.193]) by alsa0.perex.cz (Postfix) with ESMTP id 2A58C266BCF for ; Sun, 20 Aug 2017 07:55:19 +0200 (CEST) Received: by mail-pf0-f193.google.com with SMTP id w127so45444pfd.1 for ; Sat, 19 Aug 2017 22:55:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=9MQ4toGIg5PlBuI36O++PhqzJpXFVRChibNH4/e0CmE=; b=umZC4PZXPzBnD9uSTqn8pgFcDr74wwVBoew6vO7ieH7ZnSPCtbFQ33bZJm+4GsWRYZ lKOvhi3RWBHwJEsdo0oUYWYrJGvJXj7GNru+yRaYtaNOltbcOMYIyjAwRf3UWoubUpHY DXyK9511i9CaTeV/dwTkAxEIjCyEwyAseL0AzxWNACSKP23wZAhrLausrv5fQi958aCp naY4yHpAdnx7d9sXBnT9SYAawbH5RN8djicx4iy9H+89eMbo3ucgUGju6J+pA9nHRGn0 DPsKyHO6+X+reQEHY9DPFdj66fq94h5TfC7f3p+LNkFHcEbEyqlemOnNVzVZqBQWr3k+ 9w/w== 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; bh=9MQ4toGIg5PlBuI36O++PhqzJpXFVRChibNH4/e0CmE=; b=ulQ13d48rQyjNgp6rxcdFv4QmPgDxHroEGW7LDoBgrhHjnNqRyOapPLXyr71KMr2Xg CoPgclS9cJnQz3sqnwqRwkHa9nJ7Guklf18GnwzGluOMjY89Mll/zF+V1kgkbqWiioTq hOsBF35oVjHkSUexBAS7VcQzP2UwQEBxIcxcMQKXwRGKtfqrpGR9UoUnRsdxxh/q6bwQ iheYEeJY2ul3awNLC1nDDtOvlExwKecRFL018X2d8jO1VO3YwDkDts2KXDUtxKeuZH6l jvUSB+j+w1lxWO1vJtk9w+9jiftUpYKFZF3qLFYWEBpb+yIdH+B/FRgTHtKI6jNWdz31 2XGw== X-Gm-Message-State: AHYfb5iRMUlBdTIRhA+GWslkoFOe5t3jibU6YWHgGTXg6hh9SmFm0aZ1 L+AS0PXDl263uw== X-Received: by 10.84.210.171 with SMTP id a40mr14928682pli.443.1503208518906; Sat, 19 Aug 2017 22:55:18 -0700 (PDT) Received: from localhost ([221.217.218.132]) by smtp.gmail.com with ESMTPSA id w63sm17713755pfw.28.2017.08.19.22.55.17 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Sat, 19 Aug 2017 22:55:18 -0700 (PDT) From: Peng Donglin To: lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, maxime.ripard@free-electrons.com Date: Sun, 20 Aug 2017 13:55:13 +0800 Message-Id: <1503208513-4015-1-git-send-email-dolinux.peng@gmail.com> X-Mailer: git-send-email 1.9.1 Cc: alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Peng Donglin Subject: [alsa-devel] [PATCH 10/12] ASoC: sun4i-codec: Remove unnecessary function call X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 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: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP First of all,the address of pdev->dev is assigned to card->dev in create_card,then the function platform_set_drvdata copies the value the variable card to pdev->dev.driver_data, but when calling snd_soc_register_card,the function dev_set_drvdata(card->dev, card) will also do the same copy operation,so i think that the former copy operation can be removed. Signed-off-by: Peng Donglin --- sound/soc/sunxi/sun4i-codec.c | 1 - 1 file changed, 1 deletion(-) diff --git a/sound/soc/sunxi/sun4i-codec.c b/sound/soc/sunxi/sun4i-codec.c index 1500699..82beeae 100644 --- a/sound/soc/sunxi/sun4i-codec.c +++ b/sound/soc/sunxi/sun4i-codec.c @@ -1655,7 +1655,6 @@ static int sun4i_codec_probe(struct platform_device *pdev) goto err_unregister_codec; } - platform_set_drvdata(pdev, card); snd_soc_card_set_drvdata(card, scodec); ret = snd_soc_register_card(card);