Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/pci Don't map I/O space if we have already have a go...



details:   https://anonhg.NetBSD.org/src/rev/a125df8ed6b2
branches:  trunk
changeset: 513212:a125df8ed6b2
user:      ad <ad%NetBSD.org@localhost>
date:      Thu Jul 26 12:36:16 2001 +0000

description:
Don't map I/O space if we have already have a good memory mapping.

diffstat:

 sys/dev/pci/mlx_pci.c |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (18 lines):

diff -r ec9618c4ba41 -r a125df8ed6b2 sys/dev/pci/mlx_pci.c
--- a/sys/dev/pci/mlx_pci.c     Thu Jul 26 12:00:22 2001 +0000
+++ b/sys/dev/pci/mlx_pci.c     Thu Jul 26 12:36:16 2001 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: mlx_pci.c,v 1.3 2001/05/15 12:49:37 ad Exp $   */
+/*     $NetBSD: mlx_pci.c,v 1.4 2001/07/26 12:36:16 ad Exp $   */
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -236,7 +236,7 @@
                if (pci_mapreg_map(pa, memr, PCI_MAPREG_TYPE_MEM, 0,
                    &mlx->mlx_iot, &mlx->mlx_ioh, NULL, NULL))
                        memr = -1;
-       if (ior != -1)
+       if (memr == -1 && ior != -1)
                if (pci_mapreg_map(pa, ior, PCI_MAPREG_TYPE_IO, 0,
                    &mlx->mlx_iot, &mlx->mlx_ioh, NULL, NULL))
                        ior = -1;



Home | Main Index | Thread Index | Old Index