- rc = libcfs_debug_init(5 * 1024 * 1024);
- if (rc != 0) {
- CERROR("libcfs_debug_init() failed: %d\n", rc);
- return -1;
- }
-
- rc = LNetInit();
- if (rc != 0) {
- CERROR("LNetInit() failed: %d\n", rc);
- libcfs_debug_cleanup();
- return -1;
- }
+ if ((feats & ~LST_FEATS_MASK) != 0) {
+ fprintf(stderr,
+ "lstclient can't understand these feature bits: %x\n",
+ (feats & ~LST_FEATS_MASK));
+ return -1;
+ }
+
+ rc = libcfs_debug_init(5 * 1024 * 1024);
+ if (rc != 0) {
+ fprintf(stderr, "libcfs_debug_init() failed: %d\n", rc);
+ return -1;
+ }
+
+ rc = cfs_wi_startup();
+ if (rc != 0) {
+ fprintf(stderr, "cfs_wi_startup() failed: %d\n", rc);
+ libcfs_debug_cleanup();
+ return -1;
+ }
+
+ rc = LNetInit();
+ if (rc != 0) {
+ fprintf(stderr, "LNetInit() failed: %d\n", rc);
+ cfs_wi_shutdown();
+ libcfs_debug_cleanup();
+ return -1;
+ }