diff options
author | Michael S. Tsirkin <mst@mellanox.co.il> | 2005-04-16 18:26:30 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-04-16 18:26:30 -0400 |
commit | e0f5fdca1ca9d1659b920827e5cf6dbad20e5391 (patch) | |
tree | 71e6410e14c4c285ce128e99070a38ded75a14f7 /drivers/infiniband/hw/mthca/mthca_main.c | |
parent | d0a9d25cdcd511dd523357bc902979220dc72a2e (diff) |
[PATCH] IB/mthca: add fast memory region implementation
Implement fast memory regions (FMRs), where the driver writes directly into
the HCA's translation tables rather than requiring a firmware command. For
Tavor, MTTs for FMR are separate from regular MTTs, and are reserved at driver
initialization. This is done to limit the amount of virtual memory needed to
map the MTTs. For Arbel, there's no such limitation, and all MTTs and MPTs
may be used for FMR or for regular MR.
Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il>
Signed-off-by: Roland Dreier <roland@topspin.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/infiniband/hw/mthca/mthca_main.c')
-rw-r--r-- | drivers/infiniband/hw/mthca/mthca_main.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/drivers/infiniband/hw/mthca/mthca_main.c b/drivers/infiniband/hw/mthca/mthca_main.c index 7912b262a4cf..fdfc2b788e64 100644 --- a/drivers/infiniband/hw/mthca/mthca_main.c +++ b/drivers/infiniband/hw/mthca/mthca_main.c | |||
@@ -73,14 +73,15 @@ static const char mthca_version[] __devinitdata = | |||
73 | DRV_VERSION " (" DRV_RELDATE ")\n"; | 73 | DRV_VERSION " (" DRV_RELDATE ")\n"; |
74 | 74 | ||
75 | static struct mthca_profile default_profile = { | 75 | static struct mthca_profile default_profile = { |
76 | .num_qp = 1 << 16, | 76 | .num_qp = 1 << 16, |
77 | .rdb_per_qp = 4, | 77 | .rdb_per_qp = 4, |
78 | .num_cq = 1 << 16, | 78 | .num_cq = 1 << 16, |
79 | .num_mcg = 1 << 13, | 79 | .num_mcg = 1 << 13, |
80 | .num_mpt = 1 << 17, | 80 | .num_mpt = 1 << 17, |
81 | .num_mtt = 1 << 20, | 81 | .num_mtt = 1 << 20, |
82 | .num_udav = 1 << 15, /* Tavor only */ | 82 | .num_udav = 1 << 15, /* Tavor only */ |
83 | .uarc_size = 1 << 18, /* Arbel only */ | 83 | .fmr_reserved_mtts = 1 << 18, /* Tavor only */ |
84 | .uarc_size = 1 << 18, /* Arbel only */ | ||
84 | }; | 85 | }; |
85 | 86 | ||
86 | static int __devinit mthca_tune_pci(struct mthca_dev *mdev) | 87 | static int __devinit mthca_tune_pci(struct mthca_dev *mdev) |