* [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
@ 2018-07-25 20:15 Pierre-Louis Bossart
2018-07-26 6:28 ` Takashi Iwai
` (3 more replies)
0 siblings, 4 replies; 8+ messages in thread
From: Pierre-Louis Bossart @ 2018-07-25 20:15 UTC (permalink / raw)
To: alsa-devel; +Cc: tiwai, liam.r.girdwood, vkoul, broonie, Pierre-Louis Bossart
Make this helper inline function available for all platforms. This
helps solve 0-day compilation issues when CONFIG_SND_DMA_SGBUF is not
defined.
Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
include/sound/memalloc.h | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/include/sound/memalloc.h b/include/sound/memalloc.h
index 9c3db3dce32b..c669900e6cbe 100644
--- a/include/sound/memalloc.h
+++ b/include/sound/memalloc.h
@@ -67,6 +67,14 @@ struct snd_dma_buffer {
void *private_data; /* private for allocator; don't touch */
};
+/*
+ * return the pages matching with the given byte size
+ */
+static inline unsigned int snd_sgbuf_aligned_pages(size_t size)
+{
+ return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
+}
+
#ifdef CONFIG_SND_DMA_SGBUF
/*
* Scatter-Gather generic device pages
@@ -90,14 +98,6 @@ struct snd_sg_buf {
struct device *dev;
};
-/*
- * return the pages matching with the given byte size
- */
-static inline unsigned int snd_sgbuf_aligned_pages(size_t size)
-{
- return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
-}
-
/*
* return the physical address at the corresponding offset
*/
--
2.14.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
2018-07-25 20:15 [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally Pierre-Louis Bossart
@ 2018-07-26 6:28 ` Takashi Iwai
2018-07-26 16:08 ` Mark Brown
2018-07-26 14:51 ` kbuild test robot
` (2 subsequent siblings)
3 siblings, 1 reply; 8+ messages in thread
From: Takashi Iwai @ 2018-07-26 6:28 UTC (permalink / raw)
To: Pierre-Louis Bossart; +Cc: liam.r.girdwood, alsa-devel, broonie, vkoul
On Wed, 25 Jul 2018 22:15:56 +0200,
Pierre-Louis Bossart wrote:
>
> Make this helper inline function available for all platforms. This
> helps solve 0-day compilation issues when CONFIG_SND_DMA_SGBUF is not
> defined.
>
> Reported-by: kbuild test robot <lkp@intel.com>
> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Currently it's triggered only by the new Intel patches, so no urgent
material.
I can put this to for-next branch, or to another immutable branch, so
that Mark can pull in. Or, it's fine that Mark applies to his tree
together with other Intel patches, too. Mark, what's your preference?
In the last case, feel free to take my ack:
Reviewed-by: Takashi Iwai <tiwai@suse.de>
thanks,
Takashi
> ---
> include/sound/memalloc.h | 16 ++++++++--------
> 1 file changed, 8 insertions(+), 8 deletions(-)
>
> diff --git a/include/sound/memalloc.h b/include/sound/memalloc.h
> index 9c3db3dce32b..c669900e6cbe 100644
> --- a/include/sound/memalloc.h
> +++ b/include/sound/memalloc.h
> @@ -67,6 +67,14 @@ struct snd_dma_buffer {
> void *private_data; /* private for allocator; don't touch */
> };
>
> +/*
> + * return the pages matching with the given byte size
> + */
> +static inline unsigned int snd_sgbuf_aligned_pages(size_t size)
> +{
> + return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
> +}
> +
> #ifdef CONFIG_SND_DMA_SGBUF
> /*
> * Scatter-Gather generic device pages
> @@ -90,14 +98,6 @@ struct snd_sg_buf {
> struct device *dev;
> };
>
> -/*
> - * return the pages matching with the given byte size
> - */
> -static inline unsigned int snd_sgbuf_aligned_pages(size_t size)
> -{
> - return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
> -}
> -
> /*
> * return the physical address at the corresponding offset
> */
> --
> 2.14.1
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
2018-07-25 20:15 [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally Pierre-Louis Bossart
2018-07-26 6:28 ` Takashi Iwai
@ 2018-07-26 14:51 ` kbuild test robot
2018-07-27 5:11 ` Takashi Iwai
2018-07-26 16:12 ` Applied "ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally" to the asoc tree Mark Brown
2018-07-27 1:00 ` [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally kbuild test robot
3 siblings, 1 reply; 8+ messages in thread
From: kbuild test robot @ 2018-07-26 14:51 UTC (permalink / raw)
Cc: alsa-devel, tiwai, Pierre-Louis Bossart, liam.r.girdwood, vkoul,
broonie, kbuild-all
[-- Attachment #1: Type: text/plain, Size: 2115 bytes --]
Hi Pierre-Louis,
I love your patch! Yet something to improve:
[auto build test ERROR on sound/for-next]
[also build test ERROR on v4.18-rc6 next-20180725]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Pierre-Louis-Bossart/ALSA-memalloc-declare-snd_sgbuf_aligned_pages-unconditionally/20180726-192035
base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
config: alpha-allyesconfig (attached as .config)
compiler: alpha-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.2.0 make.cross ARCH=alpha
All errors (new ones prefixed by >>):
In file included from include/sound/pcm.h:27:0,
from sound/core/pcm_iec958.c:11:
include/sound/memalloc.h: In function 'snd_sgbuf_aligned_pages':
>> include/sound/memalloc.h:75:17: error: 'PAGE_SIZE' undeclared (first use in this function); did you mean 'TASK_SIZE'?
return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
^~~~~~~~~
TASK_SIZE
include/sound/memalloc.h:75:17: note: each undeclared identifier is reported only once for each function it appears in
>> include/sound/memalloc.h:75:35: error: 'PAGE_SHIFT' undeclared (first use in this function); did you mean 'PAGE_SIZE'?
return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
^~~~~~~~~~
PAGE_SIZE
vim +75 include/sound/memalloc.h
69
70 /*
71 * return the pages matching with the given byte size
72 */
73 static inline unsigned int snd_sgbuf_aligned_pages(size_t size)
74 {
> 75 return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
76 }
77
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 53370 bytes --]
[-- Attachment #3: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
2018-07-26 6:28 ` Takashi Iwai
@ 2018-07-26 16:08 ` Mark Brown
0 siblings, 0 replies; 8+ messages in thread
From: Mark Brown @ 2018-07-26 16:08 UTC (permalink / raw)
To: Takashi Iwai; +Cc: liam.r.girdwood, vkoul, alsa-devel, Pierre-Louis Bossart
[-- Attachment #1.1: Type: text/plain, Size: 1440 bytes --]
On Thu, Jul 26, 2018 at 08:28:41AM +0200, Takashi Iwai wrote:
> I can put this to for-next branch, or to another immutable branch, so
> that Mark can pull in. Or, it's fine that Mark applies to his tree
> together with other Intel patches, too. Mark, what's your preference?
> In the last case, feel free to take my ack:
> Reviewed-by: Takashi Iwai <tiwai@suse.de>
Since I can just do it immediately I applied it and pushed out a signed
tag for it:
The following changes since commit ce397d215ccd07b8ae3f71db689aedb85d56ab40:
Linux 4.18-rc1 (2018-06-17 08:04:49 +0900)
are available in the Git repository at:
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git tags/alsa-add-snd-sgbuf-aligned-pages
for you to fetch changes up to 4cae99d9b5305ab8cccc839fccceb81ec9e5abda:
ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally (2018-07-26 17:05:29 +0100)
----------------------------------------------------------------
ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
Make this helper inline function available for all platforms. This
helps solve 0-day compilation issues when CONFIG_SND_DMA_SGBUF is not
defined.
----------------------------------------------------------------
Pierre-Louis Bossart (1):
ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
include/sound/memalloc.h | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
[-- Attachment #2: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Applied "ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally" to the asoc tree
2018-07-25 20:15 [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally Pierre-Louis Bossart
2018-07-26 6:28 ` Takashi Iwai
2018-07-26 14:51 ` kbuild test robot
@ 2018-07-26 16:12 ` Mark Brown
2018-07-27 1:00 ` [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally kbuild test robot
3 siblings, 0 replies; 8+ messages in thread
From: Mark Brown @ 2018-07-26 16:12 UTC (permalink / raw)
To: Pierre-Louis Bossart
Cc: alsa-devel, kbuild test robot, tiwai, liam.r.girdwood, vkoul, broonie
The patch
ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
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 4cae99d9b5305ab8cccc839fccceb81ec9e5abda Mon Sep 17 00:00:00 2001
From: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Date: Wed, 25 Jul 2018 15:15:56 -0500
Subject: [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages()
unconditionally
Make this helper inline function available for all platforms. This
helps solve 0-day compilation issues when CONFIG_SND_DMA_SGBUF is not
defined.
Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
include/sound/memalloc.h | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/include/sound/memalloc.h b/include/sound/memalloc.h
index 9c3db3dce32b..c669900e6cbe 100644
--- a/include/sound/memalloc.h
+++ b/include/sound/memalloc.h
@@ -67,6 +67,14 @@ struct snd_dma_buffer {
void *private_data; /* private for allocator; don't touch */
};
+/*
+ * return the pages matching with the given byte size
+ */
+static inline unsigned int snd_sgbuf_aligned_pages(size_t size)
+{
+ return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
+}
+
#ifdef CONFIG_SND_DMA_SGBUF
/*
* Scatter-Gather generic device pages
@@ -90,14 +98,6 @@ struct snd_sg_buf {
struct device *dev;
};
-/*
- * return the pages matching with the given byte size
- */
-static inline unsigned int snd_sgbuf_aligned_pages(size_t size)
-{
- return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
-}
-
/*
* return the physical address at the corresponding offset
*/
--
2.18.0
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
2018-07-25 20:15 [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally Pierre-Louis Bossart
` (2 preceding siblings ...)
2018-07-26 16:12 ` Applied "ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally" to the asoc tree Mark Brown
@ 2018-07-27 1:00 ` kbuild test robot
3 siblings, 0 replies; 8+ messages in thread
From: kbuild test robot @ 2018-07-27 1:00 UTC (permalink / raw)
Cc: alsa-devel, tiwai, Pierre-Louis Bossart, liam.r.girdwood, vkoul,
broonie, kbuild-all
[-- Attachment #1: Type: text/plain, Size: 2112 bytes --]
Hi Pierre-Louis,
I love your patch! Yet something to improve:
[auto build test ERROR on sound/for-next]
[also build test ERROR on v4.18-rc6 next-20180725]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Pierre-Louis-Bossart/ALSA-memalloc-declare-snd_sgbuf_aligned_pages-unconditionally/20180726-192035
base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
config: microblaze-allmodconfig (attached as .config)
compiler: microblaze-linux-gcc (GCC) 8.1.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=8.1.0 make.cross ARCH=microblaze
All errors (new ones prefixed by >>):
In file included from include/sound/pcm.h:27,
from sound/core/pcm_iec958.c:11:
include/sound/memalloc.h: In function 'snd_sgbuf_aligned_pages':
include/sound/memalloc.h:75:17: error: 'PAGE_SIZE' undeclared (first use in this function); did you mean 'TASK_SIZE'?
return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
^~~~~~~~~
TASK_SIZE
include/sound/memalloc.h:75:17: note: each undeclared identifier is reported only once for each function it appears in
>> include/sound/memalloc.h:75:35: error: 'PAGE_SHIFT' undeclared (first use in this function); did you mean 'NMI_SHIFT'?
return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
^~~~~~~~~~
NMI_SHIFT
vim +75 include/sound/memalloc.h
69
70 /*
71 * return the pages matching with the given byte size
72 */
73 static inline unsigned int snd_sgbuf_aligned_pages(size_t size)
74 {
> 75 return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
76 }
77
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 53677 bytes --]
[-- Attachment #3: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
2018-07-26 14:51 ` kbuild test robot
@ 2018-07-27 5:11 ` Takashi Iwai
2018-07-27 14:54 ` Pierre-Louis Bossart
0 siblings, 1 reply; 8+ messages in thread
From: Takashi Iwai @ 2018-07-27 5:11 UTC (permalink / raw)
To: kbuild test robot
Cc: alsa-devel, Pierre-Louis Bossart, liam.r.girdwood, vkoul,
broonie, kbuild-all
On Thu, 26 Jul 2018 16:51:55 +0200,
kbuild test robot wrote:
>
> Hi Pierre-Louis,
>
> I love your patch! Yet something to improve:
>
> [auto build test ERROR on sound/for-next]
> [also build test ERROR on v4.18-rc6 next-20180725]
> [if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
>
> url: https://github.com/0day-ci/linux/commits/Pierre-Louis-Bossart/ALSA-memalloc-declare-snd_sgbuf_aligned_pages-unconditionally/20180726-192035
> base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
> config: alpha-allyesconfig (attached as .config)
> compiler: alpha-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
> reproduce:
> wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
> chmod +x ~/bin/make.cross
> # save the attached .config to linux build tree
> GCC_VERSION=7.2.0 make.cross ARCH=alpha
>
> All errors (new ones prefixed by >>):
>
> In file included from include/sound/pcm.h:27:0,
> from sound/core/pcm_iec958.c:11:
> include/sound/memalloc.h: In function 'snd_sgbuf_aligned_pages':
> >> include/sound/memalloc.h:75:17: error: 'PAGE_SIZE' undeclared (first use in this function); did you mean 'TASK_SIZE'?
> return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
> ^~~~~~~~~
> TASK_SIZE
OK, we need to include <asm/page.h> in this header file.
Pierre, care to resend with the fix?
thanks,
Takashi
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally
2018-07-27 5:11 ` Takashi Iwai
@ 2018-07-27 14:54 ` Pierre-Louis Bossart
0 siblings, 0 replies; 8+ messages in thread
From: Pierre-Louis Bossart @ 2018-07-27 14:54 UTC (permalink / raw)
To: Takashi Iwai, kbuild test robot
Cc: liam.r.girdwood, vkoul, alsa-devel, broonie, kbuild-all
On 7/27/18 12:11 AM, Takashi Iwai wrote:
> On Thu, 26 Jul 2018 16:51:55 +0200,
> kbuild test robot wrote:
>>
>> Hi Pierre-Louis,
>>
>> I love your patch! Yet something to improve:
>>
>> [auto build test ERROR on sound/for-next]
>> [also build test ERROR on v4.18-rc6 next-20180725]
>> [if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
>>
>> url: https://github.com/0day-ci/linux/commits/Pierre-Louis-Bossart/ALSA-memalloc-declare-snd_sgbuf_aligned_pages-unconditionally/20180726-192035
>> base: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git for-next
>> config: alpha-allyesconfig (attached as .config)
>> compiler: alpha-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
>> reproduce:
>> wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
>> chmod +x ~/bin/make.cross
>> # save the attached .config to linux build tree
>> GCC_VERSION=7.2.0 make.cross ARCH=alpha
>>
>> All errors (new ones prefixed by >>):
>>
>> In file included from include/sound/pcm.h:27:0,
>> from sound/core/pcm_iec958.c:11:
>> include/sound/memalloc.h: In function 'snd_sgbuf_aligned_pages':
>>>> include/sound/memalloc.h:75:17: error: 'PAGE_SIZE' undeclared (first use in this function); did you mean 'TASK_SIZE'?
>> return (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
>> ^~~~~~~~~
>> TASK_SIZE
>
> OK, we need to include <asm/page.h> in this header file.
>
> Pierre, care to resend with the fix?
yes, will do later today.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2018-07-30 18:22 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-25 20:15 [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally Pierre-Louis Bossart
2018-07-26 6:28 ` Takashi Iwai
2018-07-26 16:08 ` Mark Brown
2018-07-26 14:51 ` kbuild test robot
2018-07-27 5:11 ` Takashi Iwai
2018-07-27 14:54 ` Pierre-Louis Bossart
2018-07-26 16:12 ` Applied "ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally" to the asoc tree Mark Brown
2018-07-27 1:00 ` [PATCH] ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally kbuild test robot
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.