From: Randy Dunlap <randy.dunlap@oracle.com>
To: mgross@linux.intel.com
Cc: Andrew Morton <akpm@linux-foundation.org>,
linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH]intel-iommu batched iotlb flushes
Date: Tue, 12 Feb 2008 08:34:39 -0800 [thread overview]
Message-ID: <47B1CA9F.80004@oracle.com> (raw)
In-Reply-To: <20080212160553.GD27490@linux.intel.com>
mark gross wrote:
>
> Index: linux-2.6.24-mm1/drivers/pci/intel-iommu.c
> ===================================================================
> --- linux-2.6.24-mm1.orig/drivers/pci/intel-iommu.c 2008-02-12 07:12:06.000000000 -0800
> +++ linux-2.6.24-mm1/drivers/pci/intel-iommu.c 2008-02-12 07:47:04.000000000 -0800
> @@ -1672,7 +1702,30 @@
> for_each_drhd_unit(drhd) {
> if (drhd->ignored)
> continue;
> - iommu = alloc_iommu(drhd);
> + g_num_of_iommus++;
> + }
> +
> + nlongs = BITS_TO_LONGS(g_num_of_iommus);
> + g_iommus_to_flush = kzalloc(nlongs * sizeof(unsigned long), GFP_KERNEL);
> + if (!g_iommus_to_flush) {
> + printk(KERN_ERR "Intel-IOMMU: \
> + Allocating bitmap array failed\n");
I think that will make a string like below:
Intel-IOMMU: Allocating bitmap array failed
> + return -ENOMEM;
> + }
> +
> + g_iommus = kzalloc(g_num_of_iommus * sizeof(*iommu), GFP_KERNEL);
> + if (!g_iommus) {
> + kfree(g_iommus_to_flush);
> + ret = -ENOMEM;
> + goto error;
> + }
> +
> + i = 0;
> + for_each_drhd_unit(drhd) {
> + if (drhd->ignored)
> + continue;
> + iommu = alloc_iommu(&g_iommus[i], drhd);
> + i++;
> if (!iommu) {
> ret = -ENOMEM;
> goto error;
> Index: linux-2.6.24-mm1/Documentation/kernel-parameters.txt
> ===================================================================
> --- linux-2.6.24-mm1.orig/Documentation/kernel-parameters.txt 2008-02-12 07:12:06.000000000 -0800
> +++ linux-2.6.24-mm1/Documentation/kernel-parameters.txt 2008-02-12 07:47:02.000000000 -0800
> @@ -822,6 +822,10 @@
> than 32 bit addressing. The default is to look
> for translation below 32 bit and if not available
> then look in the higher range.
> + strict [Default Off]
> + With this option on every umap_signal opperation will
unmap_single operation
> + result in a hardware IOTLB flush opperation as opposed
> + to batching them for performance.
>
> io_delay= [X86-32,X86-64] I/O delay method
> 0x80
--
~Randy
WARNING: multiple messages have this Message-ID (diff)
From: Randy Dunlap <randy.dunlap@oracle.com>
To: mgross@linux.intel.com
Cc: Andrew Morton <akpm@linux-foundation.org>,
linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH]intel-iommu batched iotlb flushes
Date: Tue, 12 Feb 2008 08:34:39 -0800 [thread overview]
Message-ID: <47B1CA9F.80004@oracle.com> (raw)
In-Reply-To: <20080212160553.GD27490@linux.intel.com>
mark gross wrote:
>
> Index: linux-2.6.24-mm1/drivers/pci/intel-iommu.c
> ===================================================================
> --- linux-2.6.24-mm1.orig/drivers/pci/intel-iommu.c 2008-02-12 07:12:06.000000000 -0800
> +++ linux-2.6.24-mm1/drivers/pci/intel-iommu.c 2008-02-12 07:47:04.000000000 -0800
> @@ -1672,7 +1702,30 @@
> for_each_drhd_unit(drhd) {
> if (drhd->ignored)
> continue;
> - iommu = alloc_iommu(drhd);
> + g_num_of_iommus++;
> + }
> +
> + nlongs = BITS_TO_LONGS(g_num_of_iommus);
> + g_iommus_to_flush = kzalloc(nlongs * sizeof(unsigned long), GFP_KERNEL);
> + if (!g_iommus_to_flush) {
> + printk(KERN_ERR "Intel-IOMMU: \
> + Allocating bitmap array failed\n");
I think that will make a string like below:
Intel-IOMMU: Allocating bitmap array failed
> + return -ENOMEM;
> + }
> +
> + g_iommus = kzalloc(g_num_of_iommus * sizeof(*iommu), GFP_KERNEL);
> + if (!g_iommus) {
> + kfree(g_iommus_to_flush);
> + ret = -ENOMEM;
> + goto error;
> + }
> +
> + i = 0;
> + for_each_drhd_unit(drhd) {
> + if (drhd->ignored)
> + continue;
> + iommu = alloc_iommu(&g_iommus[i], drhd);
> + i++;
> if (!iommu) {
> ret = -ENOMEM;
> goto error;
> Index: linux-2.6.24-mm1/Documentation/kernel-parameters.txt
> ===================================================================
> --- linux-2.6.24-mm1.orig/Documentation/kernel-parameters.txt 2008-02-12 07:12:06.000000000 -0800
> +++ linux-2.6.24-mm1/Documentation/kernel-parameters.txt 2008-02-12 07:47:02.000000000 -0800
> @@ -822,6 +822,10 @@
> than 32 bit addressing. The default is to look
> for translation below 32 bit and if not available
> then look in the higher range.
> + strict [Default Off]
> + With this option on every umap_signal opperation will
unmap_single operation
> + result in a hardware IOTLB flush opperation as opposed
> + to batching them for performance.
>
> io_delay= [X86-32,X86-64] I/O delay method
> 0x80
--
~Randy
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2008-02-12 16:39 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-11 22:41 [PATCH]intel-iommu batched iotlb flushes mark gross
2008-02-11 22:41 ` mark gross
2008-02-11 23:27 ` Randy Dunlap
2008-02-11 23:27 ` Randy Dunlap
2008-02-12 16:05 ` mark gross
2008-02-12 16:05 ` mark gross
2008-02-12 16:34 ` Randy Dunlap [this message]
2008-02-12 16:34 ` Randy Dunlap
2008-02-12 19:55 ` mark gross
2008-02-12 19:55 ` mark gross
2008-02-12 20:21 ` Randy Dunlap
2008-02-12 20:21 ` Randy Dunlap
2008-02-13 18:10 ` mark gross
2008-02-13 18:10 ` mark gross
2008-02-13 18:23 ` Randy Dunlap
2008-02-13 18:23 ` Randy Dunlap
2008-02-13 19:35 ` mark gross
2008-02-13 19:35 ` mark gross
2008-02-12 8:52 ` Muli Ben-Yehuda
2008-02-12 8:52 ` Muli Ben-Yehuda
2008-02-12 9:00 ` David Miller
2008-02-12 9:00 ` David Miller, Muli Ben-Yehuda
2008-02-12 9:07 ` Muli Ben-Yehuda
2008-02-12 9:07 ` Muli Ben-Yehuda
2008-02-12 15:54 ` mark gross
2008-02-12 15:54 ` mark gross
2008-02-12 23:46 ` David Miller
2008-02-12 23:46 ` David Miller, mark gross
2008-02-13 18:31 ` mark gross
2008-02-13 18:31 ` mark gross
2008-02-12 15:37 ` mark gross
2008-02-12 15:37 ` mark gross
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=47B1CA9F.80004@oracle.com \
--to=randy.dunlap@oracle.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mgross@linux.intel.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.