All of lore.kernel.org
 help / color / mirror / Atom feed
From: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
To: Arnd Bergmann <arnd@arndb.de>, linux-arm-kernel@lists.infradead.org
Cc: rjw@rjwysocki.net, lenb@kernel.org, catalin.marinas@arm.com,
	will.deacon@arm.com, al.stone@linaro.org,
	linaro-acpi@lists.linaro.org, linux-kernel@vger.kernel.org,
	linux-acpi@vger.kernel.org, leo.duran@amd.com,
	hanjun.guo@linaro.org, msalter@redhat.com,
	grant.likely@linaro.org
Subject: Re: [PATCH 2/2] ACPI / scan: Parse _CCA and setup device coherency
Date: Wed, 29 Apr 2015 09:45:43 -0500	[thread overview]
Message-ID: <5540EE97.70202@amd.com> (raw)
In-Reply-To: <5542288.z0SSOZ4xV7@wuerfel>



On 04/29/2015 09:03 AM, Arnd Bergmann wrote:
> On Wednesday 29 April 2015 08:44:09 Suravee Suthikulpanit wrote:
>> +                       device->flags.cca_seen = 1;
>> +               } else if (IS_ENABLED(CONFIG_ACPI_MUST_HAVE_CCA)) {
>> +                       /*
>> +                        * Architecture has specified that if the device
>> +                        * can do DMA, it must have ACPI _CCA object.
>> +                        * Here, there could be two cases:
>> +                        *   1. Not DMA-able device.
>> +                        *   2. DMA-able device, but missing _CCA object.
>> +                        *
>> +                        * In both cases, we will default to dma non-coherent.
>> +                        */
>> +                       cca = 0;
>> +               } else {
>> +                       /*
>> +                        * If architecture does not specify that device must
>> +                        * specify ACPI _CCA (e.g. x86), we default to use
>> +                        * dma coherent.
>> +                        */
>> +                       cca = 1;
>> +               }
>>
>
> What does it mean here if a device does DMA but is not coherent? Do you
> have an example of a server that needs this?
>
> Can we please make the default for ARM64 cca=1 as well?
>
> 	Arnd
>

Actually, I am trying to implement the logic for when missing _CCA to be 
consistent with the behavior when the devicetree entry does not specify 
"dma-coherent" property. IIUC, in such case, Linux will default to using 
non-coherent DMA.

Thanks,

Suravee

WARNING: multiple messages have this Message-ID (diff)
From: suravee.suthikulpanit@amd.com (Suravee Suthikulpanit)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/2] ACPI / scan: Parse _CCA and setup device coherency
Date: Wed, 29 Apr 2015 09:45:43 -0500	[thread overview]
Message-ID: <5540EE97.70202@amd.com> (raw)
In-Reply-To: <5542288.z0SSOZ4xV7@wuerfel>



On 04/29/2015 09:03 AM, Arnd Bergmann wrote:
> On Wednesday 29 April 2015 08:44:09 Suravee Suthikulpanit wrote:
>> +                       device->flags.cca_seen = 1;
>> +               } else if (IS_ENABLED(CONFIG_ACPI_MUST_HAVE_CCA)) {
>> +                       /*
>> +                        * Architecture has specified that if the device
>> +                        * can do DMA, it must have ACPI _CCA object.
>> +                        * Here, there could be two cases:
>> +                        *   1. Not DMA-able device.
>> +                        *   2. DMA-able device, but missing _CCA object.
>> +                        *
>> +                        * In both cases, we will default to dma non-coherent.
>> +                        */
>> +                       cca = 0;
>> +               } else {
>> +                       /*
>> +                        * If architecture does not specify that device must
>> +                        * specify ACPI _CCA (e.g. x86), we default to use
>> +                        * dma coherent.
>> +                        */
>> +                       cca = 1;
>> +               }
>>
>
> What does it mean here if a device does DMA but is not coherent? Do you
> have an example of a server that needs this?
>
> Can we please make the default for ARM64 cca=1 as well?
>
> 	Arnd
>

Actually, I am trying to implement the logic for when missing _CCA to be 
consistent with the behavior when the devicetree entry does not specify 
"dma-coherent" property. IIUC, in such case, Linux will default to using 
non-coherent DMA.

Thanks,

Suravee

WARNING: multiple messages have this Message-ID (diff)
From: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
To: Arnd Bergmann <arnd@arndb.de>, <linux-arm-kernel@lists.infradead.org>
Cc: <rjw@rjwysocki.net>, <lenb@kernel.org>, <catalin.marinas@arm.com>,
	<will.deacon@arm.com>, <al.stone@linaro.org>,
	<linaro-acpi@lists.linaro.org>, <linux-kernel@vger.kernel.org>,
	<linux-acpi@vger.kernel.org>, <leo.duran@amd.com>,
	<hanjun.guo@linaro.org>, <msalter@redhat.com>,
	<grant.likely@linaro.org>
Subject: Re: [PATCH 2/2] ACPI / scan: Parse _CCA and setup device coherency
Date: Wed, 29 Apr 2015 09:45:43 -0500	[thread overview]
Message-ID: <5540EE97.70202@amd.com> (raw)
In-Reply-To: <5542288.z0SSOZ4xV7@wuerfel>



On 04/29/2015 09:03 AM, Arnd Bergmann wrote:
> On Wednesday 29 April 2015 08:44:09 Suravee Suthikulpanit wrote:
>> +                       device->flags.cca_seen = 1;
>> +               } else if (IS_ENABLED(CONFIG_ACPI_MUST_HAVE_CCA)) {
>> +                       /*
>> +                        * Architecture has specified that if the device
>> +                        * can do DMA, it must have ACPI _CCA object.
>> +                        * Here, there could be two cases:
>> +                        *   1. Not DMA-able device.
>> +                        *   2. DMA-able device, but missing _CCA object.
>> +                        *
>> +                        * In both cases, we will default to dma non-coherent.
>> +                        */
>> +                       cca = 0;
>> +               } else {
>> +                       /*
>> +                        * If architecture does not specify that device must
>> +                        * specify ACPI _CCA (e.g. x86), we default to use
>> +                        * dma coherent.
>> +                        */
>> +                       cca = 1;
>> +               }
>>
>
> What does it mean here if a device does DMA but is not coherent? Do you
> have an example of a server that needs this?
>
> Can we please make the default for ARM64 cca=1 as well?
>
> 	Arnd
>

Actually, I am trying to implement the logic for when missing _CCA to be 
consistent with the behavior when the devicetree entry does not specify 
"dma-coherent" property. IIUC, in such case, Linux will default to using 
non-coherent DMA.

Thanks,

Suravee

  reply	other threads:[~2015-04-29 14:45 UTC|newest]

Thread overview: 83+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-29 13:44 [PATCH 0/2] ACPI : Introduce support for _CCA object Suravee Suthikulpanit
2015-04-29 13:44 ` Suravee Suthikulpanit
2015-04-29 13:44 ` Suravee Suthikulpanit
2015-04-29 13:44 ` [PATCH 1/2] arm/arm64: ACPI: Introduce CONFIG_ACPI_MUST_HAVE_CCA Suravee Suthikulpanit
2015-04-29 13:44   ` Suravee Suthikulpanit
2015-04-29 13:44   ` Suravee Suthikulpanit
2015-04-29 14:04   ` Catalin Marinas
2015-04-29 14:04     ` Catalin Marinas
2015-04-29 14:31     ` Suravee Suthikulpanit
2015-04-29 14:31       ` Suravee Suthikulpanit
2015-04-29 14:31       ` Suravee Suthikulpanit
2015-04-29 14:42       ` Catalin Marinas
2015-04-29 14:42         ` Catalin Marinas
2015-04-29 14:44         ` Suravee Suthikulpanit
2015-04-29 14:44           ` Suravee Suthikulpanit
2015-04-29 14:44           ` Suravee Suthikulpanit
2015-04-30 13:47         ` Hanjun Guo
2015-04-30 13:47           ` Hanjun Guo
2015-04-30 13:47           ` Hanjun Guo
2015-04-30 13:50           ` Will Deacon
2015-04-30 13:50             ` Will Deacon
2015-04-30 13:50             ` Will Deacon
2015-04-30 14:14             ` Hanjun Guo
2015-04-30 14:14               ` Hanjun Guo
2015-04-30 14:14               ` Hanjun Guo
2015-04-30 15:01             ` Lorenzo Pieralisi
2015-04-30 15:01               ` Lorenzo Pieralisi
2015-04-29 13:44 ` [PATCH 2/2] ACPI / scan: Parse _CCA and setup device coherency Suravee Suthikulpanit
2015-04-29 13:44   ` Suravee Suthikulpanit
2015-04-29 13:44   ` Suravee Suthikulpanit
2015-04-29 14:03   ` Arnd Bergmann
2015-04-29 14:03     ` Arnd Bergmann
2015-04-29 14:45     ` Suravee Suthikulpanit [this message]
2015-04-29 14:45       ` Suravee Suthikulpanit
2015-04-29 14:45       ` Suravee Suthikulpanit
2015-04-29 14:47       ` [Linaro-acpi] " Arnd Bergmann
2015-04-29 14:47         ` Arnd Bergmann
2015-04-29 14:57         ` Suthikulpanit, Suravee
2015-04-29 14:57           ` Suthikulpanit, Suravee
2015-04-29 15:39           ` Al Stone
2015-04-29 15:39             ` Al Stone
2015-04-29 16:15             ` Arnd Bergmann
2015-04-29 16:15               ` Arnd Bergmann
2015-04-29 15:54           ` Arnd Bergmann
2015-04-29 15:54             ` Arnd Bergmann
2015-05-01 11:06             ` Catalin Marinas
2015-05-01 11:06               ` Catalin Marinas
2015-05-08 14:08               ` Arnd Bergmann
2015-05-08 14:08                 ` Arnd Bergmann
2015-05-11 17:10                 ` Catalin Marinas
2015-05-11 17:10                   ` Catalin Marinas
2015-05-11 17:24                   ` Robin Murphy
2015-05-11 17:24                     ` Robin Murphy
2015-04-29 16:25   ` Arnd Bergmann
2015-04-29 16:25     ` Arnd Bergmann
2015-04-29 21:53     ` Suravee Suthikulpanit
2015-04-29 21:53       ` Suravee Suthikulpanit
2015-04-29 21:53       ` Suravee Suthikulpanit
2015-04-30  8:23       ` [Linaro-acpi] " Arnd Bergmann
2015-04-30  8:23         ` Arnd Bergmann
2015-04-30 10:41         ` Will Deacon
2015-04-30 10:41           ` Will Deacon
2015-04-30 10:47           ` Arnd Bergmann
2015-04-30 10:47             ` Arnd Bergmann
2015-04-30 11:07             ` Will Deacon
2015-04-30 11:07               ` Will Deacon
2015-04-30 11:24               ` Arnd Bergmann
2015-04-30 11:24                 ` Arnd Bergmann
2015-04-30 11:46                 ` Will Deacon
2015-04-30 11:46                   ` Will Deacon
2015-04-30 13:03                   ` Arnd Bergmann
2015-04-30 13:03                     ` Arnd Bergmann
2015-04-30 13:13                     ` Will Deacon
2015-04-30 13:13                       ` Will Deacon
2015-04-30 13:52                       ` Arnd Bergmann
2015-04-30 13:52                         ` Arnd Bergmann
2015-04-30 15:55                         ` Catalin Marinas
2015-04-30 15:55                           ` Catalin Marinas
2015-05-08 14:01                           ` Arnd Bergmann
2015-05-08 14:01                             ` Arnd Bergmann
2015-04-30 23:39         ` Suravee Suthikulanit
2015-04-30 23:39           ` Suravee Suthikulanit
2015-04-30 23:39           ` Suravee Suthikulanit

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=5540EE97.70202@amd.com \
    --to=suravee.suthikulpanit@amd.com \
    --cc=al.stone@linaro.org \
    --cc=arnd@arndb.de \
    --cc=catalin.marinas@arm.com \
    --cc=grant.likely@linaro.org \
    --cc=hanjun.guo@linaro.org \
    --cc=lenb@kernel.org \
    --cc=leo.duran@amd.com \
    --cc=linaro-acpi@lists.linaro.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=msalter@redhat.com \
    --cc=rjw@rjwysocki.net \
    --cc=will.deacon@arm.com \
    /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.