All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marek Szyprowski <m.szyprowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
To: Laura Abbott <lauraa-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>,
	Stefan Hengelein <stefan.hengelein-d40JDW7QUjc@public.gmane.org>
Cc: linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
	andreas.herrmann-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org,
	akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	Valentin Rothberg
	<valentinrothberg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Subject: Re: [PATCH] arm: dma-mapping: fix compilation error when CONFIG_MMU is not present
Date: Thu, 23 Oct 2014 10:15:44 +0200	[thread overview]
Message-ID: <5448B930.7070800@samsung.com> (raw)
In-Reply-To: <5445A345.7010401-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>

Hello,

On 2014-10-21 02:05, Laura Abbott wrote:
> On 10/20/2014 6:50 AM, Stefan Hengelein wrote:
>> Well,
>>
>> arch/arm/mm/dma-mapping.c: In function ‘__atomic_get_pages’:
>> arch/arm/mm/dma-mapping.c:1265:31: error: ‘atomic_pool’ undeclared
>> (first use in this function)
>>
>> arch/arm/mm/dma-mapping.c: In function ‘__iommu_get_pages’:
>> arch/arm/mm/dma-mapping.c:1275:2: error: implicit declaration of
>> function ‘__in_atomic_pool’ [-Werror=implicit-function-declaration]
>>
>>
>> others:
>> arch/arm/mm/dma-mapping.c: In function ‘__iommu_alloc_remap’:
>> arch/arm/mm/dma-mapping.c:1200:4: error: ‘VM_ARM_DMA_CONSISTENT’
>> undeclared (first use in this function)
>> arch/arm/mm/dma-mapping.c:1200:4: note: each undeclared identifier is
>> reported only once for each function it appears in
>>
>> arch/arm/mm/dma-mapping.c: In function ‘__iommu_get_pages’:
>> arch/arm/mm/dma-mapping.c:1282:29: error: ‘VM_ARM_DMA_CONSISTENT’
>> undeclared (first use in this function)
>> arch/arm/mm/dma-mapping.c: In function ‘arm_iommu_free_attrs’:
>> arch/arm/mm/dma-mapping.c:1411:4: error: ‘VM_ARM_DMA_CONSISTENT’
>> undeclared (first use in this function)
>>
>>
>> i've attached a configuration where it happens.
>> when you place the configuration in your tree and compile the file,
>> the errors should show up.
>>
>> However, within the configuration CONFIG_ARM_DMA_USE_IOMMU is defined
>> and CONFIG_MMU is not. AFAIUI, if both should be enabled together, it
>> should be mapped in Kconfig somewhere, right?
>
> There isn't a nice way to fixup the dma consistent flags so I would
> say this option should just depend on MMU.

The question is which option should depend on MMU? Making 
CONFIG_ARM_DMA_USE_IOMMU
to depend on MMU doesn't solve this case. It only gives following 
warning with the
mentioned .config:
warning: (VIDEO_OMAP3 && EXYNOS_IOMMU && SHMOBILE_IOMMU && IPMMU_VMSA && 
ARM_SMMU) selects ARM_DMA_USE_IOMMU which has unmet direct dependencies 
(MMU)

IMHO the best solution will be to either make the whole IOMMU subsystem 
to depend
on MMU or alternatively, add this dependency to all IOMMU drivers which 
can be
enabled by COMPILE_TEST option (here the issue is caused by 
SHMOBILE_IOMMU, which
otherwise cannot be enabled when no-mmu systems are selected).

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland

_______________________________________________
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu

WARNING: multiple messages have this Message-ID (diff)
From: m.szyprowski@samsung.com (Marek Szyprowski)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] arm: dma-mapping: fix compilation error when CONFIG_MMU is not present
Date: Thu, 23 Oct 2014 10:15:44 +0200	[thread overview]
Message-ID: <5448B930.7070800@samsung.com> (raw)
In-Reply-To: <5445A345.7010401@codeaurora.org>

Hello,

On 2014-10-21 02:05, Laura Abbott wrote:
> On 10/20/2014 6:50 AM, Stefan Hengelein wrote:
>> Well,
>>
>> arch/arm/mm/dma-mapping.c: In function ?__atomic_get_pages?:
>> arch/arm/mm/dma-mapping.c:1265:31: error: ?atomic_pool? undeclared
>> (first use in this function)
>>
>> arch/arm/mm/dma-mapping.c: In function ?__iommu_get_pages?:
>> arch/arm/mm/dma-mapping.c:1275:2: error: implicit declaration of
>> function ?__in_atomic_pool? [-Werror=implicit-function-declaration]
>>
>>
>> others:
>> arch/arm/mm/dma-mapping.c: In function ?__iommu_alloc_remap?:
>> arch/arm/mm/dma-mapping.c:1200:4: error: ?VM_ARM_DMA_CONSISTENT?
>> undeclared (first use in this function)
>> arch/arm/mm/dma-mapping.c:1200:4: note: each undeclared identifier is
>> reported only once for each function it appears in
>>
>> arch/arm/mm/dma-mapping.c: In function ?__iommu_get_pages?:
>> arch/arm/mm/dma-mapping.c:1282:29: error: ?VM_ARM_DMA_CONSISTENT?
>> undeclared (first use in this function)
>> arch/arm/mm/dma-mapping.c: In function ?arm_iommu_free_attrs?:
>> arch/arm/mm/dma-mapping.c:1411:4: error: ?VM_ARM_DMA_CONSISTENT?
>> undeclared (first use in this function)
>>
>>
>> i've attached a configuration where it happens.
>> when you place the configuration in your tree and compile the file,
>> the errors should show up.
>>
>> However, within the configuration CONFIG_ARM_DMA_USE_IOMMU is defined
>> and CONFIG_MMU is not. AFAIUI, if both should be enabled together, it
>> should be mapped in Kconfig somewhere, right?
>
> There isn't a nice way to fixup the dma consistent flags so I would
> say this option should just depend on MMU.

The question is which option should depend on MMU? Making 
CONFIG_ARM_DMA_USE_IOMMU
to depend on MMU doesn't solve this case. It only gives following 
warning with the
mentioned .config:
warning: (VIDEO_OMAP3 && EXYNOS_IOMMU && SHMOBILE_IOMMU && IPMMU_VMSA && 
ARM_SMMU) selects ARM_DMA_USE_IOMMU which has unmet direct dependencies 
(MMU)

IMHO the best solution will be to either make the whole IOMMU subsystem 
to depend
on MMU or alternatively, add this dependency to all IOMMU drivers which 
can be
enabled by COMPILE_TEST option (here the issue is caused by 
SHMOBILE_IOMMU, which
otherwise cannot be enabled when no-mmu systems are selected).

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland

WARNING: multiple messages have this Message-ID (diff)
From: Marek Szyprowski <m.szyprowski@samsung.com>
To: Laura Abbott <lauraa@codeaurora.org>,
	Stefan Hengelein <stefan.hengelein@fau.de>
Cc: linux-kernel@vger.kernel.org, linux@arm.linux.org.uk,
	akpm@linux-foundation.org, linux-arm-kernel@lists.infradead.org,
	andreas.herrmann@calxeda.com,
	Valentin Rothberg <valentinrothberg@gmail.com>,
	iommu@lists.linux-foundation.org
Subject: Re: [PATCH] arm: dma-mapping: fix compilation error when CONFIG_MMU is not present
Date: Thu, 23 Oct 2014 10:15:44 +0200	[thread overview]
Message-ID: <5448B930.7070800@samsung.com> (raw)
In-Reply-To: <5445A345.7010401@codeaurora.org>

Hello,

On 2014-10-21 02:05, Laura Abbott wrote:
> On 10/20/2014 6:50 AM, Stefan Hengelein wrote:
>> Well,
>>
>> arch/arm/mm/dma-mapping.c: In function ‘__atomic_get_pages’:
>> arch/arm/mm/dma-mapping.c:1265:31: error: ‘atomic_pool’ undeclared
>> (first use in this function)
>>
>> arch/arm/mm/dma-mapping.c: In function ‘__iommu_get_pages’:
>> arch/arm/mm/dma-mapping.c:1275:2: error: implicit declaration of
>> function ‘__in_atomic_pool’ [-Werror=implicit-function-declaration]
>>
>>
>> others:
>> arch/arm/mm/dma-mapping.c: In function ‘__iommu_alloc_remap’:
>> arch/arm/mm/dma-mapping.c:1200:4: error: ‘VM_ARM_DMA_CONSISTENT’
>> undeclared (first use in this function)
>> arch/arm/mm/dma-mapping.c:1200:4: note: each undeclared identifier is
>> reported only once for each function it appears in
>>
>> arch/arm/mm/dma-mapping.c: In function ‘__iommu_get_pages’:
>> arch/arm/mm/dma-mapping.c:1282:29: error: ‘VM_ARM_DMA_CONSISTENT’
>> undeclared (first use in this function)
>> arch/arm/mm/dma-mapping.c: In function ‘arm_iommu_free_attrs’:
>> arch/arm/mm/dma-mapping.c:1411:4: error: ‘VM_ARM_DMA_CONSISTENT’
>> undeclared (first use in this function)
>>
>>
>> i've attached a configuration where it happens.
>> when you place the configuration in your tree and compile the file,
>> the errors should show up.
>>
>> However, within the configuration CONFIG_ARM_DMA_USE_IOMMU is defined
>> and CONFIG_MMU is not. AFAIUI, if both should be enabled together, it
>> should be mapped in Kconfig somewhere, right?
>
> There isn't a nice way to fixup the dma consistent flags so I would
> say this option should just depend on MMU.

The question is which option should depend on MMU? Making 
CONFIG_ARM_DMA_USE_IOMMU
to depend on MMU doesn't solve this case. It only gives following 
warning with the
mentioned .config:
warning: (VIDEO_OMAP3 && EXYNOS_IOMMU && SHMOBILE_IOMMU && IPMMU_VMSA && 
ARM_SMMU) selects ARM_DMA_USE_IOMMU which has unmet direct dependencies 
(MMU)

IMHO the best solution will be to either make the whole IOMMU subsystem 
to depend
on MMU or alternatively, add this dependency to all IOMMU drivers which 
can be
enabled by COMPILE_TEST option (here the issue is caused by 
SHMOBILE_IOMMU, which
otherwise cannot be enabled when no-mmu systems are selected).

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland


  parent reply	other threads:[~2014-10-23  8:15 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-19 15:59 [PATCH] arm: dma-mapping: fix compilation error when CONFIG_MMU is not present Stefan Hengelein
2014-10-19 15:59 ` Stefan Hengelein
2014-10-20  7:42 ` Marek Szyprowski
2014-10-20  7:42   ` Marek Szyprowski
2014-10-20 13:50   ` Stefan Hengelein
2014-10-21  0:05     ` Laura Abbott
2014-10-21  0:05       ` Laura Abbott
     [not found]       ` <5445A345.7010401-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
2014-10-23  8:15         ` Marek Szyprowski [this message]
2014-10-23  8:15           ` Marek Szyprowski
2014-10-23  8:15           ` Marek Szyprowski
2014-10-24 13:15           ` Stefan Hengelein
2014-10-24 13:15             ` Stefan Hengelein
     [not found]             ` <CABv5NL_E83CgBcHbAqo9xejWAEamO3oxX6ZjU+fo9X6k4cE_1w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-10-27 11:59               ` Marek Szyprowski
2014-10-27 11:59                 ` Marek Szyprowski
2014-10-27 11:59                 ` Marek Szyprowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5448B930.7070800@samsung.com \
    --to=m.szyprowski-sze3o3uu22jbdgjk7y7tuq@public.gmane.org \
    --cc=akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org \
    --cc=andreas.herrmann-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org \
    --cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=lauraa-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org \
    --cc=stefan.hengelein-d40JDW7QUjc@public.gmane.org \
    --cc=valentinrothberg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.