Whamcloud - gitweb
Branch b1_6
[fs/lustre-release.git] / lnet / klnds / mxlnd / mxlnd_modparams.c
1 /* -*- mode: c; c-basic-offset: 8; indent-tabs-mode: nil; -*-
2  * vim:expandtab:shiftwidth=8:tabstop=8:
3  *
4  * Copyright (C) 2004 Cluster File Systems, Inc.
5  *   Author: Eric Barton <eric@bartonsoftware.com>
6  * Copyright (C) 2006 Myricom, Inc.
7  *   Author: Scott Atchley <atchley at myri.com>
8  *
9  *   This file is part of Lustre, http://www.lustre.org.
10  *
11  *   Lustre is free software; you can redistribute it and/or
12  *   modify it under the terms of version 2 of the GNU General Public
13  *   License as published by the Free Software Foundation.
14  *
15  *   Lustre is distributed in the hope that it will be useful,
16  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
17  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  *   GNU General Public License for more details.
19  *
20  *   You should have received a copy of the GNU General Public License
21  *   along with Lustre; if not, write to the Free Software
22  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23  */
24
25 #include "mxlnd.h"
26
27 static int n_waitd = MXLND_N_SCHED;
28 CFS_MODULE_PARM(n_waitd, "i", int, 0444,
29                 "# of completion daemons");
30
31 static int max_peers = MXLND_MAX_PEERS;
32 CFS_MODULE_PARM(max_peers, "i", int, 0444,
33                 "maximum number of peers that may connect");
34
35 static int cksum = MXLND_CKSUM;
36 CFS_MODULE_PARM(cksum, "i", int, 0644,
37                 "set non-zero to enable message (not data payload) checksums");
38
39 static int ntx = MXLND_NTX;
40 CFS_MODULE_PARM(ntx, "i", int, 0444,
41                 "# of total tx message descriptors");
42
43 static int credits = MXLND_MSG_QUEUE_DEPTH;
44 CFS_MODULE_PARM(credits, "i", int, 0444,
45                 "# concurrent sends");
46
47 static int board = MXLND_MX_BOARD;
48 CFS_MODULE_PARM(board, "i", int, 0444,
49                 "index value of the Myrinet board (NIC)");
50
51 static int ep_id = MXLND_MX_EP_ID;
52 CFS_MODULE_PARM(ep_id, "i", int, 0444, "MX endpoint ID");
53
54 static int polling = MXLND_POLLING;
55 CFS_MODULE_PARM(polling, "i", int, 0444,
56                 "Use 0 to block (wait). A value > 0 will poll that many times before blocking");
57
58 static char *hosts = NULL;
59 CFS_MODULE_PARM(hosts, "s", charp, 0444,
60                 "IP-to-hostname resolution file");
61
62 kmx_tunables_t kmxlnd_tunables = {
63         .kmx_n_waitd            = &n_waitd,
64         .kmx_max_peers          = &max_peers,
65         .kmx_cksum              = &cksum,
66         .kmx_ntx                = &ntx,
67         .kmx_credits            = &credits,
68         .kmx_board              = &board,
69         .kmx_ep_id              = &ep_id,
70         .kmx_polling            = &polling,
71         .kmx_hosts              = &hosts
72 };