FUJITA Tomonori | 2 Mar 2008 07:10
Picon
Gravatar

[PATCH -mm 1/3] export iommu_is_span_boundary helper function

iommu_is_span_boundary is used internally in the IOMMU helper
(lib/iommu-helper.c), a primitive function that judges whether a
memory area spans LLD's segment boundary or not.

It's difficult to convert some IOMMUs to use the IOMMU helper but
iommu_is_span_boundary is still useful for them. So this patch exports
it.

Signed-off-by: FUJITA Tomonori <fujita.tomonori <at> lab.ntt.co.jp>
Cc: Andrew Morton <akpm <at> linux-foundation.org>
---
 include/linux/iommu-helper.h |    3 +++
 lib/iommu-helper.c           |   10 ++++++----
 2 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/include/linux/iommu-helper.h b/include/linux/iommu-helper.h
index 4dd4c04..c975caf 100644
--- a/include/linux/iommu-helper.h
+++ b/include/linux/iommu-helper.h
 <at>  <at>  -1,3 +1,6  <at>  <at> 
+extern int iommu_is_span_boundary(unsigned int index, unsigned int nr,
+				  unsigned long shift,
+				  unsigned long boundary_size);
 extern unsigned long iommu_area_alloc(unsigned long *map, unsigned long size,
 				      unsigned long start, unsigned int nr,
 				      unsigned long shift,
diff --git a/lib/iommu-helper.c b/lib/iommu-helper.c
index 495575a..a3b8d4c 100644
--- a/lib/iommu-helper.c
+++ b/lib/iommu-helper.c
(Continue reading)

FUJITA Tomonori | 2 Mar 2008 07:10
Picon
Gravatar

[PATCH -mm 2/3] parisc: pass struct device to iommu_alloc_range

This adds struct device argument to sba_alloc_range and
ccio_alloc_range, a preparation for modifications to fix the IOMMU
segment boundary problem. This change enables ccio_alloc_range to
access to LLD's segment boundary limits.

Signed-off-by: FUJITA Tomonori <fujita.tomonori <at> lab.ntt.co.jp>
Cc: Kyle McMartin <kyle <at> parisc-linux.org>
Cc: Matthew Wilcox <matthew <at> wil.cx>
Cc: Grant Grundler <grundler <at> parisc-linux.org>
Cc: Andrew Morton <akpm <at> linux-foundation.org>
---
 drivers/parisc/ccio-dma.c      |    4 ++--
 drivers/parisc/iommu-helpers.h |    4 ++--
 drivers/parisc/sba_iommu.c     |    4 ++--
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/parisc/ccio-dma.c b/drivers/parisc/ccio-dma.c
index d08b284..1695fac 100644
--- a/drivers/parisc/ccio-dma.c
+++ b/drivers/parisc/ccio-dma.c
 <at>  <at>  -341,7 +341,7  <at>  <at>  static int ioc_count;
  * of available pages for the requested size.
  */
 static int
-ccio_alloc_range(struct ioc *ioc, size_t size)
+ccio_alloc_range(struct ioc *ioc, struct device *dev, size_t size)
 {
 	unsigned int pages_needed = size >> IOVP_SHIFT;
 	unsigned int res_idx;
 <at>  <at>  -760,7 +760,7  <at>  <at>  ccio_map_single(struct device *dev, void *addr, size_t size,
(Continue reading)

FUJITA Tomonori | 2 Mar 2008 07:10
Picon
Gravatar

[PATCH -mm 0/3] fix iommu segment boundary problems (parisc)

This patchset is another sequel to my patchset to fix iommu segment
boundary problems, IOMMUs allocate memory areas without considering a
low level driver's segment boundary limits:

http://www.mail-archive.com/linux-scsi <at> vger.kernel.org/msg11919.html

This patchset fixes the PARISC IOMMU code (sbc and ccio).

There are three patches in this patchset. The first patch is for the
IOMMU helper (lib/iommu-helper.c) to enable PARISC IOMMUs use it.

The second and third patches are for PARISC IOMMUs, the second one is
preparation for the third patch, which fixes the IOMMU segment
boundary problem.

The third patch assumes that ioc->ibase is on IOVP_SIZE boundary. If
not, please let me know. I'll fix the patch.

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo <at> vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

FUJITA Tomonori | 2 Mar 2008 07:10
Picon
Gravatar

[PATCH -mm 3/3] parisc: make the IOMMUs respect the segment boundary limits

This patch makes PARISC's two IOMMU implementations not allocate a
memory area spanning LLD's segment boundary.

Signed-off-by: FUJITA Tomonori <fujita.tomonori <at> lab.ntt.co.jp>
Cc: Kyle McMartin <kyle <at> parisc-linux.org>
Cc: Matthew Wilcox <matthew <at> wil.cx>
Cc: Grant Grundler <grundler <at> parisc-linux.org>
Cc: Andrew Morton <akpm <at> linux-foundation.org>
---
 drivers/parisc/Kconfig     |    5 ++++
 drivers/parisc/ccio-dma.c  |   13 ++++++++++-
 drivers/parisc/sba_iommu.c |   48 +++++++++++++++++++++++++++++++++----------
 3 files changed, 53 insertions(+), 13 deletions(-)

diff --git a/drivers/parisc/Kconfig b/drivers/parisc/Kconfig
index 1d3b84b..553a990 100644
--- a/drivers/parisc/Kconfig
+++ b/drivers/parisc/Kconfig
 <at>  <at>  -103,6 +103,11  <at>  <at>  config IOMMU_SBA
 	depends on PCI_LBA
 	default PCI_LBA

+config IOMMU_HELPER
+	bool
+	depends on IOMMU_SBA || IOMMU_CCIO
+	default y
+
 #config PCI_EPIC
 #	bool "EPIC/SAGA PCI support"
 #	depends on PCI
(Continue reading)

Kyle McMartin | 2 Mar 2008 18:13
Picon

Re: [PATCH -mm 0/3] fix iommu segment boundary problems (parisc)

On Sun, Mar 02, 2008 at 03:10:25PM +0900, FUJITA Tomonori wrote:
> This patchset is another sequel to my patchset to fix iommu segment
> boundary problems, IOMMUs allocate memory areas without considering a
> low level driver's segment boundary limits:
> 
> http://www.mail-archive.com/linux-scsi <at> vger.kernel.org/msg11919.html
> 

This looks fine. Are you able to test this? If not, we can set you up
with an account on a machine with remote console and all that jazz, if
you'd like to.

cheers, Kyle
--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo <at> vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Stuart Brady | 3 Mar 2008 05:47

Segfault when using SDL with POSIX timers

Hi,

The test program below segfaults on parisc, but not on x86-64.  It's
based on code from QEMU, which was crashing on exit.  Can anyone see
what the cause is?  Here's the backtrace:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x4000 (LWP 8682)]
0x00000000 in ?? ()
(gdb) bt
#0  0x00000000 in ?? ()
#1  0x403c7aac in ?? () from /lib/ld.so.1
#2  0x403c7c08 in ?? () from /lib/ld.so.1
#3  0x400490dc in ?? () from /lib/libdl.so.2
#4  0x403c1834 in ?? () from /lib/ld.so.1
#5  0x40049590 in ?? () from /lib/libdl.so.2
#6  0x40049118 in dlclose () from /lib/libdl.so.2
#7  0x403297f4 in ?? () from /usr/lib/libSDL-1.2.so.0
#8  0x4031fff8 in SDL_VideoQuit () from /usr/lib/libSDL-1.2.so.0
#9  0x402f2c78 in SDL_QuitSubSystem () from /usr/lib/libSDL-1.2.so.0
#10 0x402f2d20 in SDL_Quit () from /usr/lib/libSDL-1.2.so.0
#11 0x000109d8 in main ()

The output is simply:

Starting timer
Starting SDL
Quitting SDL
Segmentation fault (core dumped)

(Continue reading)

Stuart Brady | 3 Mar 2008 05:50

Re: Segfault when using SDL with POSIX timers

On Mon, Mar 03, 2008 at 04:47:27AM +0000, Stuart Brady wrote:
> I'm running Debian Etch

Sorry, when I said Etch, I meant Lenny. :)
--

-- 
Stuart Brady
--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo <at> vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Randolph Chung | 3 Mar 2008 06:28

[patch] Remove HPUX and SOM support

Remove unsupported and bitrotten HPUX and SOM support from the kernel.

Signed-off-by: Randolph Chung <tausq <at> parisc-linux.org>

randolph
Attachment (remove-hpux.diff.gz): application/octet-stream, 22 KiB
rubisher | 3 Mar 2008 11:36
Picon
Favicon

Re: [PATCH -mm 0/3] fix iommu segment boundary problems (parisc)

> On Sun, Mar 02, 2008 at 03:10:25PM +0900, FUJITA Tomonori wrote:
> > This patchset is another sequel to my patchset to fix iommu segment
> > boundary problems, IOMMUs allocate memory areas without considering a
> > low level driver's segment boundary limits:
> > 
> > http://www.mail-archive.com/linux-scsi <at> vger.kernel.org/msg11919.html
> > 
> 
> This looks fine. Are you able to test this? If not, we can set you up
> with an account on a machine with remote console and all that jazz, if
> you'd like to.
> 
> cheers, Kyle
> --
> To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
> the body of a message to majordomo <at> vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
Dear *,

I have access to 3 kind of boxes which needed one of those drivers: a b2k and
mainly a c110 and a d380 for which I hope a lot of this patch ;-)

I will so try the patch asap and let you know the results.

hth,
    r.

---
Scarlet One, ADSL 6 Mbps + Telephone, from EUR 29,95...
(Continue reading)

rubisher | 3 Mar 2008 12:04
Picon
Favicon

Re: [PATCH -mm 0/3] fix iommu segment boundary problems (parisc)

> On Sun, Mar 02, 2008 at 03:10:25PM +0900, FUJITA Tomonori wrote:
> > This patchset is another sequel to my patchset to fix iommu segment
> > boundary problems, IOMMUs allocate memory areas without considering a
> > low level driver's segment boundary limits:
> > 
> > http://www.mail-archive.com/linux-scsi <at> vger.kernel.org/msg11919.html
> > 
> 
> This looks fine. Are you able to test this? If not, we can set you up
> with an account on a machine with remote console and all that jazz, if
> you'd like to.
> 
> cheers, Kyle
> --
> To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
> the body of a message to majordomo <at> vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
Sorry for bad news but using a kernel known to work fine on my b2k (kyle's
parisc-2.6.git date 2008_02_21) against which I applied those patches, this
new kernel 32bit up failled to boot with this panic message:

Linux Tulip driver version 1.1.15 (Feb 27, 2007)
------------[ cut here ]------------
Kernel BUG at 1029520c [verbose debug info unavailable]

     YZrvWESTHLNXBCVMcbcbcbcbOGFRQPDI
PSW: 00000000000001001111111100001110 Not tainted
r00-03  0004ff0e 1054c010 1029e774 80000000
r04-07  1fc2b020 00000100 00000000 00000001
(Continue reading)


Gmane