From patchwork Fri Jun 29 11:07:25 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 140548 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp698946ljj; Fri, 29 Jun 2018 04:07:59 -0700 (PDT) X-Google-Smtp-Source: AAOMgpeIJnQikEM+DiJBaSE75wSI9N0lbg7GwfAW2VihHRkuKhMSmT7im5EfcewAeXeWOnYOhx4A X-Received: by 2002:adf:d142:: with SMTP id b2-v6mr6510900wri.17.1530270479825; Fri, 29 Jun 2018 04:07:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530270479; cv=none; d=google.com; s=arc-20160816; b=ADnS2co71DEWdVwxkWc69/3wCw6tz5N2RDZqfIgCJAC4OxGPPLx6OJZtUYjrB0OmHO i88daIs4gHiITh5L+VR1vhQbU0wm0JjRg6QJf6U4hdaqCuTLSWf2GV/cVtAgqI99bY2Z vZfGjIeaPWgFQd3jVBUFAj43tHUR8iacMs5jtKY1zE/4ENSI28UyZlHxy7GFrATVeaAr fLBxE2R0GZIDNLjVdy/aI+sT3zEdMHUGYKC2nx4I2oQFz+lnGAcJd6p9TqhFigpKgESZ foxTXPgk/n7oy7XJcsLm9ciGVcj0aCqZzflcusCEmpzIubEattjeFyPd+diRoSCe0Gwe g94g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:date:message-id:in-reply-to:to:from :dkim-signature:delivered-to:arc-authentication-results; bh=LLlJOtiqvsGs9dX3+egnVqwmSgslbfDwg1KOdnwMvhY=; b=HTiyueJjlqy+y1EFw5xU6S9m/clK8qCQZcO1P9CcrU82UBcTQ09+LsREVkcmB9nEg5 eFnjtrFPudITheH7gT+7G2v1Db9n9n+FjJ40fSFT+cnwaABzMqDpvp6IxAKwHyBQVduu pQ0RIKf4FPCsiFDMcJBpvAI+miLlpfhaquFXPzzAdu91D2VtKcLU1kymB5biuD55DijC m2gkNhmAkQzMzM3TKhn1qjhnYWkriNpecZQkORFRRwMVYthqj/U7iypFmp1uWNNuA7eL UDOpd3E8R7fPGV6/wH+hRFBDW48WpKPKXv20m3l4mDH7sQOzgM6XSWSy3hs40+fqb3XF qQ8A== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=AE4QuTS0; spf=pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) smtp.mailfrom=alsa-devel-bounces@alsa-project.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from alsa0.perex.cz (alsa0.perex.cz. [77.48.224.243]) by mx.google.com with ESMTP id q184-v6si1254124wmg.176.2018.06.29.04.07.59; Fri, 29 Jun 2018 04:07:59 -0700 (PDT) Received-SPF: pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) client-ip=77.48.224.243; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=AE4QuTS0; spf=pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) smtp.mailfrom=alsa-devel-bounces@alsa-project.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 41760267A52; Fri, 29 Jun 2018 13:07:32 +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 024B7267A46; Fri, 29 Jun 2018 13:07:29 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail1.perex.cz X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=disabled version=3.4.0 Received: from heliosphere.sirena.org.uk (heliosphere.sirena.org.uk [172.104.155.198]) by alsa0.perex.cz (Postfix) with ESMTP id A63BA267A50 for ; Fri, 29 Jun 2018 13:07:27 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=Date:Message-Id:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner: List-Archive; bh=TWwhhUd+iWHLJocGGZVAnlJjEhvs8m8nlg0w5OEcHQo=; b=AE4QuTS0PHLv bhW5H3WZ2VAkztn2o/uI7KEATP3gdDLC2C6Pax4pHHNYvgxidvLpaizVSx90181Rc//nldECeyop2 o3OMuPwYvrrnHX7jfCw9IiyNA87vleF+lRTIRDHKMqwxU+DepubBy+xyVci8iskJhqAk+hcpZeTg2 WBGBk=; Received: from debutante.sirena.org.uk ([2001:470:1f1d:6b5::3] helo=debutante) by heliosphere.sirena.org.uk with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1fYrFN-0007l9-Rf; Fri, 29 Jun 2018 11:07:25 +0000 Received: from broonie by debutante with local (Exim 4.91) (envelope-from ) id 1fYrFN-0002eG-Dl; Fri, 29 Jun 2018 12:07:25 +0100 From: Mark Brown To: Daniel Mack In-Reply-To: <20180627193359.26631-3-daniel@zonque.org> Message-Id: Date: Fri, 29 Jun 2018 12:07:25 +0100 Cc: alsa-devel@alsa-project.org, broonie@kernel.org, robert.jarzmik@free.fr, lgirdwood@gmail.com, haojian.zhuang@gmail.com Subject: [alsa-devel] Applied "ASoC: pxa: clean up function names in pxa2xx-lib" to the asoc tree 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 The patch ASoC: pxa: clean up function names in pxa2xx-lib has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark >From a7160670b5e2d6b59e0f7a5b7e5bcef3b532c24c Mon Sep 17 00:00:00 2001 From: Daniel Mack Date: Wed, 27 Jun 2018 21:33:54 +0200 Subject: [PATCH] ASoC: pxa: clean up function names in pxa2xx-lib Clean up the namespace a bit and drop the __ prefix of all functions exported by pxa2xx-lib. This improves the readability of the code. Signed-off-by: Daniel Mack Signed-off-by: Mark Brown --- include/sound/pxa2xx-lib.h | 10 +++++----- sound/arm/pxa2xx-ac97.c | 10 +++++----- sound/arm/pxa2xx-pcm-lib.c | 22 +++++++++++----------- sound/soc/pxa/pxa2xx-pcm.c | 21 +++++++-------------- 4 files changed, 28 insertions(+), 35 deletions(-) -- 2.18.0.rc2 _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel diff --git a/include/sound/pxa2xx-lib.h b/include/sound/pxa2xx-lib.h index 63f75450d3db..b43de38de8b2 100644 --- a/include/sound/pxa2xx-lib.h +++ b/include/sound/pxa2xx-lib.h @@ -10,14 +10,14 @@ struct snd_pcm_substream; struct snd_pcm_hw_params; struct snd_pcm; -extern int __pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, +extern int pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params); -extern int __pxa2xx_pcm_hw_free(struct snd_pcm_substream *substream); +extern int pxa2xx_pcm_hw_free(struct snd_pcm_substream *substream); extern int pxa2xx_pcm_trigger(struct snd_pcm_substream *substream, int cmd); extern snd_pcm_uframes_t pxa2xx_pcm_pointer(struct snd_pcm_substream *substream); -extern int __pxa2xx_pcm_prepare(struct snd_pcm_substream *substream); -extern int __pxa2xx_pcm_open(struct snd_pcm_substream *substream); -extern int __pxa2xx_pcm_close(struct snd_pcm_substream *substream); +extern int pxa2xx_pcm_prepare(struct snd_pcm_substream *substream); +extern int pxa2xx_pcm_open(struct snd_pcm_substream *substream); +extern int pxa2xx_pcm_close(struct snd_pcm_substream *substream); extern int pxa2xx_pcm_mmap(struct snd_pcm_substream *substream, struct vm_area_struct *vma); extern int pxa2xx_pcm_preallocate_dma_buffer(struct snd_pcm *pcm, int stream); diff --git a/sound/arm/pxa2xx-ac97.c b/sound/arm/pxa2xx-ac97.c index 7d8d7b7199dc..0d624337857b 100644 --- a/sound/arm/pxa2xx-ac97.c +++ b/sound/arm/pxa2xx-ac97.c @@ -70,7 +70,7 @@ static int pxa2xx_ac97_pcm_open(struct snd_pcm_substream *substream) pxa2xx_audio_ops_t *platform_ops; int ret, i; - ret = __pxa2xx_pcm_open(substream); + ret = pxa2xx_pcm_open(substream); if (ret) return ret; @@ -86,7 +86,7 @@ static int pxa2xx_ac97_pcm_open(struct snd_pcm_substream *substream) if (platform_ops && platform_ops->startup) { ret = platform_ops->startup(substream, platform_ops->priv); if (ret < 0) - __pxa2xx_pcm_close(substream); + pxa2xx_pcm_close(substream); } return ret; @@ -110,7 +110,7 @@ static int pxa2xx_ac97_pcm_prepare(struct snd_pcm_substream *substream) AC97_PCM_FRONT_DAC_RATE : AC97_PCM_LR_ADC_RATE; int ret; - ret = __pxa2xx_pcm_prepare(substream); + ret = pxa2xx_pcm_prepare(substream); if (ret < 0) return ret; @@ -178,8 +178,8 @@ static const struct snd_pcm_ops pxa2xx_pcm_ops = { .open = pxa2xx_ac97_pcm_open, .close = pxa2xx_ac97_pcm_close, .ioctl = snd_pcm_lib_ioctl, - .hw_params = __pxa2xx_pcm_hw_params, - .hw_free = __pxa2xx_pcm_hw_free, + .hw_params = pxa2xx_pcm_hw_params, + .hw_free = pxa2xx_pcm_hw_free, .prepare = pxa2xx_ac97_pcm_prepare, .trigger = pxa2xx_pcm_trigger, .pointer = pxa2xx_pcm_pointer, diff --git a/sound/arm/pxa2xx-pcm-lib.c b/sound/arm/pxa2xx-pcm-lib.c index b927fa5ddbc0..dc56dbebf441 100644 --- a/sound/arm/pxa2xx-pcm-lib.c +++ b/sound/arm/pxa2xx-pcm-lib.c @@ -33,8 +33,8 @@ static const struct snd_pcm_hardware pxa2xx_pcm_hardware = { .fifo_size = 32, }; -int __pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, - struct snd_pcm_hw_params *params) +int pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, + struct snd_pcm_hw_params *params) { struct dma_chan *chan = snd_dmaengine_pcm_get_chan(substream); struct snd_soc_pcm_runtime *rtd = substream->private_data; @@ -62,14 +62,14 @@ int __pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, return 0; } -EXPORT_SYMBOL(__pxa2xx_pcm_hw_params); +EXPORT_SYMBOL(pxa2xx_pcm_hw_params); -int __pxa2xx_pcm_hw_free(struct snd_pcm_substream *substream) +int pxa2xx_pcm_hw_free(struct snd_pcm_substream *substream) { snd_pcm_set_runtime_buffer(substream, NULL); return 0; } -EXPORT_SYMBOL(__pxa2xx_pcm_hw_free); +EXPORT_SYMBOL(pxa2xx_pcm_hw_free); int pxa2xx_pcm_trigger(struct snd_pcm_substream *substream, int cmd) { @@ -84,13 +84,13 @@ pxa2xx_pcm_pointer(struct snd_pcm_substream *substream) } EXPORT_SYMBOL(pxa2xx_pcm_pointer); -int __pxa2xx_pcm_prepare(struct snd_pcm_substream *substream) +int pxa2xx_pcm_prepare(struct snd_pcm_substream *substream) { return 0; } -EXPORT_SYMBOL(__pxa2xx_pcm_prepare); +EXPORT_SYMBOL(pxa2xx_pcm_prepare); -int __pxa2xx_pcm_open(struct snd_pcm_substream *substream) +int pxa2xx_pcm_open(struct snd_pcm_substream *substream) { struct snd_soc_pcm_runtime *rtd = substream->private_data; struct snd_pcm_runtime *runtime = substream->runtime; @@ -127,13 +127,13 @@ int __pxa2xx_pcm_open(struct snd_pcm_substream *substream) substream, dma_request_slave_channel(rtd->cpu_dai->dev, dma_params->chan_name)); } -EXPORT_SYMBOL(__pxa2xx_pcm_open); +EXPORT_SYMBOL(pxa2xx_pcm_open); -int __pxa2xx_pcm_close(struct snd_pcm_substream *substream) +int pxa2xx_pcm_close(struct snd_pcm_substream *substream) { return snd_dmaengine_pcm_close_release_chan(substream); } -EXPORT_SYMBOL(__pxa2xx_pcm_close); +EXPORT_SYMBOL(pxa2xx_pcm_close); int pxa2xx_pcm_mmap(struct snd_pcm_substream *substream, struct vm_area_struct *vma) diff --git a/sound/soc/pxa/pxa2xx-pcm.c b/sound/soc/pxa/pxa2xx-pcm.c index 445e691126e5..da252d1f732e 100644 --- a/sound/soc/pxa/pxa2xx-pcm.c +++ b/sound/soc/pxa/pxa2xx-pcm.c @@ -20,8 +20,8 @@ #include #include -static int pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, - struct snd_pcm_hw_params *params) +static int __pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, + struct snd_pcm_hw_params *params) { struct snd_soc_pcm_runtime *rtd = substream->private_data; struct snd_dmaengine_dai_dma_data *dma; @@ -33,23 +33,16 @@ static int pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, if (!dma) return 0; - return __pxa2xx_pcm_hw_params(substream, params); -} - -static int pxa2xx_pcm_hw_free(struct snd_pcm_substream *substream) -{ - __pxa2xx_pcm_hw_free(substream); - - return 0; + return pxa2xx_pcm_hw_params(substream, params); } static const struct snd_pcm_ops pxa2xx_pcm_ops = { - .open = __pxa2xx_pcm_open, - .close = __pxa2xx_pcm_close, + .open = pxa2xx_pcm_open, + .close = pxa2xx_pcm_close, .ioctl = snd_pcm_lib_ioctl, - .hw_params = pxa2xx_pcm_hw_params, + .hw_params = __pxa2xx_pcm_hw_params, .hw_free = pxa2xx_pcm_hw_free, - .prepare = __pxa2xx_pcm_prepare, + .prepare = pxa2xx_pcm_prepare, .trigger = pxa2xx_pcm_trigger, .pointer = pxa2xx_pcm_pointer, .mmap = pxa2xx_pcm_mmap,