[<prev] [next>] [day] [month] [year] [list]
Message-ID: <7F38996F7185A24AB9071ED4950AD8C102253087@swsmsx413.ger.corp.intel.com>
Date: Tue, 28 Oct 2008 16:30:26 -0000
From: "Sosnowski, Maciej" <maciej.sosnowski@...el.com>
To: "Pallipadi, Venkatesh" <venkatesh.pallipadi@...el.com>,
"Williams, Dan J" <dan.j.williams@...el.com>
Cc: <ak@...ux.intel.com>, <lenb@...nel.org>, <mingo@...e.hu>,
<linux-acpi@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
"Henroid, Andrew D" <andrew.d.henroid@...el.com>,
<torvalds@...ux-foundation.org>, <tglx@...utronix.de>,
<hpa@...or.com>
Subject: RE: [PATCH] Disable ioat channel only on platforms where ile driver can load
> ---------- Original message ----------
> From: Venki Pallipadi <venkatesh.pallipadi@...el.com>
> Date: Oct 23, 2008 12:34 AM
> Subject: [PATCH] Disable ioat channel only on platforms where ile
> driver can load
> To: Andi Kleen <ak@...ux.intel.com>
> Cc: "Pallipadi, Venkatesh" <venkatesh.pallipadi@...el.com>, Len Brown
> <lenb@...nel.org>, Ingo Molnar <mingo@...e.hu>,
> "linux-acpi@...r.kernel.org" <linux-acpi@...r.kernel.org>, Linux
> Kernel Mailing List <linux-kernel@...r.kernel.org>, "Henroid, Andrew
> D" <andrew.d.henroid@...el.com>, Linus Torvalds
> <torvalds@...ux-foundation.org>, Thomas Gleixner <tglx@...utronix.de>,
> "H. Peter Anvin" <hpa@...or.com>
>
>
> On Wed, Oct 22, 2008 at 12:19:22AM -0700, Andi Kleen wrote:
>> Pallipadi, Venkatesh wrote:
>>>
>>>>> +#if CONFIG_I7300_IDLE_IOAT_CHANNEL
>>>>> + device->common.chancnt--;
>>>>> +#endif
>>>> I still think this lone decrement looks fishy. Can there please be
>>>> some explanation how it exactly relates to the i7300 idle driver,
>>>> where the matching increment is, etc.?
>>>
>>> No. This is not a increment/decrement thing. It is basically
>>> telling other Users of IOAT that they have one IOAT channel less
>>> that they can use.
>>> The last IOAT channel is used by i7300 idle driver to get the
>>> throttling to work.
>>
>> Ok then it should be made conditional on the i7300 actually be
>> available
>> in the system? It looks like you do it always no matter what
>> chipset is in there.
>
> Does the patch below look OK?
>
> Thanks,
> Venki
>
> Based on input from Andi Kleen:
> share the platform detection code with ioat_dma and disable the
> channel in
> dma engine only for specific platforms.
>
> Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@...el.com>
>
> ---
Hi Venki,
Why for your purposes don't you use dmaengine to request an ioatdma
channel from ioatdma driver?
This way sharing of this channel with other clients
(like TCP which uses ioatdma for receive offloading) would be possible .
In the previous approach your change was not acceptable from ioatdma
perspective
(for IOAT_VER_3_0 there are 8 ioat devices, each with single channel
- in this case you would take away all 8 channels and make ioat ver.3.0
totally disfunctional).
Even with this approach (assuming that it would affect IOAT_VER_1_2
only)
you reserve one channel of four statically for your purposes only,
leaving for TCP receive offloading 75% of ioatdma resources and thus
affecting its efficiency.
Dan, what do you think?
BTW, could you please next time in case of ioat/dmaengine changes
include Dan and me in the list?
Thanks,
Maciej
> Index: linux-acpi-2.6/drivers/dma/ioat_dma.c
> ===================================================================
> --- linux-acpi-2.6.orig/drivers/dma/ioat_dma.c 2008-10-22
> 11:42:04.000000000 -0700
> +++ linux-acpi-2.6/drivers/dma/ioat_dma.c 2008-10-22
> 11:42:46.000000000 -0700
> @@ -33,6 +33,7 @@
> #include <linux/delay.h>
> #include <linux/dma-mapping.h>
> #include <linux/workqueue.h>
> +#include <linux/i7300_idle.h>
> #include "ioatdma.h"
> #include "ioatdma_registers.h"
> #include "ioatdma_hw.h"
> @@ -172,7 +173,9 @@ static int ioat_dma_enumerate_channels(s
> xfercap = (xfercap_scale == 0 ? -1 : (1UL << xfercap_scale));
>
> #if CONFIG_I7300_IDLE_IOAT_CHANNEL
> - device->common.chancnt--;
> + if (i7300_idle_platform_probe(NULL, NULL) == 0) {
> + device->common.chancnt--;
> + }
> #endif
> for (i = 0; i < device->common.chancnt; i++) {
> ioat_chan = kzalloc(sizeof(*ioat_chan), GFP_KERNEL);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists