Whamcloud - gitweb
LU-4961 lustre: remove liblustre.h and obd.h from userspace
[fs/lustre-release.git] / lustre / utils / req-layout.c
index 389d158..22e1972 100644 (file)
-/* -*- mode: c; c-basic-offset: 8; indent-tabs-mode: nil; -*-
- * vim:expandtab:shiftwidth=8:tabstop=8:
+/*
+ * GPL HEADER START
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 only,
+ * as published by the Free Software Foundation.
  *
- *  req_layout.c
- *  User-level tool for printing request layouts
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * General Public License version 2 for more details (a copy is included
+ * in the LICENSE file that accompanied this code).
  *
- *  Copyright (c) 2006 Cluster File Systems, Inc.
- *   Author: Nikita Danilov <nikita@clusterfs.com>
+ * You should have received a copy of the GNU General Public License
+ * version 2 along with this program; If not, see
+ * http://www.sun.com/software/products/lustre/docs/GPLv2.pdf
  *
- *   This file is part of the Lustre file system, http://www.lustre.org
- *   Lustre is a trademark of Cluster File Systems, Inc.
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ *
+ * GPL HEADER END
+ */
+/*
+ * Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
+ * Use is subject to license terms.
+ *
+ * Copyright (c) 2011, 2013, Intel Corporation.
+ */
+/*
+ * This file is part of Lustre, http://www.lustre.org/
+ * Lustre is a trademark of Sun Microsystems, Inc.
  *
- *   You may have signed or agreed to another license before downloading
- *   this software.  If so, you are bound by the terms and conditions
- *   of that agreement, and the following does not apply to you.  See the
- *   LICENSE file included with this distribution for more information.
+ * lustre/utils/req-layout.c
  *
- *   If you did not agree to a different license, then this copy of Lustre
- *   is open source software; you can redistribute it and/or modify it
- *   under the terms of version 2 of the GNU General Public License as
- *   published by the Free Software Foundation.
+ * User-level tool for printing request layouts
  *
- *   In either case, Lustre is distributed in the hope that it will be
- *   useful, but WITHOUT ANY WARRANTY; without even the implied warranty
- *   of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *   license text for more details.
+ * Author: Nikita Danilov <nikita@clusterfs.com>
  */
 
 #include <stdio.h>
 #include <stdlib.h>
 #include <unistd.h>
 
-#include <liblustre.h>
+#include <libcfs/libcfs.h>
 #include <lustre/lustre_idl.h>
 
 #define __REQ_LAYOUT_USER__ (1)
 
 #define lustre_swab_generic_32s NULL
-#define lustre_swab_lu_range NULL
-#define lustre_swab_md_fld NULL
+#define lustre_swab_lu_seq_range NULL
 #define lustre_swab_mdt_body NULL
-#define lustre_swab_mdt_epoch NULL
+#define lustre_swab_mdt_ioepoch NULL
 #define lustre_swab_ptlrpc_body NULL
 #define lustre_swab_obd_statfs NULL
 #define lustre_swab_connect NULL
 #define lustre_swab_ldlm_request NULL
 #define lustre_swab_ldlm_reply NULL
 #define lustre_swab_ldlm_intent NULL
-#define lustre_swab_lov_mds_md NULL
-#define lustre_swab_mdt_rec_unlink NULL
-#define lustre_swab_mdt_rec_link NULL
-#define lustre_swab_mdt_rec_rename NULL
-#define lustre_swab_mdt_rec_create NULL
-#define lustre_swab_mdt_rec_setattr NULL
+#define lustre_swab_layout_intent NULL
+/* #define lustre_swab_lov_mds_md NULL */
+#define lustre_swab_mdt_rec_reint NULL
 #define lustre_swab_lustre_capa NULL
 #define lustre_swab_lustre_capa_key NULL
+#define lustre_swab_llogd_conn_body NULL
+#define lustre_swab_llog_hdr NULL
+#define lustre_swab_llogd_body NULL
+#define lustre_swab_obd_quotactl NULL
+#define lustre_swab_mgs_target_info NULL
+#define lustre_swab_niobuf_remote NULL
+#define lustre_swab_obd_ioobj NULL
+#define lustre_swab_ost_body NULL
+#define lustre_swab_ost_last_id NULL
+#define lustre_swab_fiemap NULL
+#define lustre_swab_idx_info NULL
+#define lustre_swab_qdata NULL
+#define lustre_swab_quota_body NULL
+#define lustre_swab_ost_lvb_v1 NULL
+#define lustre_swab_ost_lvb NULL
+#define lustre_swab_gl_desc NULL
+#define lustre_swab_mgs_config_body NULL
+#define lustre_swab_mgs_config_res NULL
+#define lustre_swab_swap_layouts NULL
+#define lustre_swab_lu_fid NULL
+#define lustre_swab_ost_id NULL
+#define lustre_swab_hsm_progress_kernel NULL
+#define lustre_swab_hsm_user_item NULL
+#define lustre_swab_hsm_user_state NULL
+#define lustre_swab_hsm_state_set NULL
+#define lustre_swab_hsm_current_action NULL
+#define lustre_swab_hsm_request NULL
+#define lustre_swab_close_data NULL
+#define lustre_swab_object_update NULL
+#define lustre_swab_object_update_result NULL
+#define lustre_swab_object_update_reply NULL
+#define lustre_swab_object_update_request NULL
+
+#define dump_rniobuf NULL
+#define dump_ioo NULL
+#define dump_obdo NULL
+#define dump_ost_body NULL
+#define dump_rcs NULL
+#define lustre_swab_lmv_user_md NULL
+#define lustre_swab_lfsck_request NULL
+#define lustre_swab_lfsck_reply NULL
 
 /*
  * Yes, include .c file.
@@ -93,7 +144,7 @@ void print_layout(const struct req_format *rf)
 
                         fld = rf->rf_fields[j].d[k];
 
-                        printf("        F%s %i [%03.3i%s %-20.20s (",
+                        printf("        F%s %i [%3.3i%s %-20.20s (",
                                prefix[j], k, offset,
                                variable ? " + ...]" : "]      ",
                                fld->rmf_name);