1 # This Cplant(TM) source code is the property of Sandia National
4 # This Cplant(TM) source code is copyrighted by Sandia National
7 # The redistribution of this Cplant(TM) source code is subject to the
8 # terms of the GNU Lesser General Public License
9 # (see cit/LGPL or http://www.gnu.org/licenses/lgpl.html)
11 # Cplant(TM) Copyright 1998-2003 Sandia Corporation.
12 # Under the terms of Contract DE-AC04-94AL85000, there is a non-exclusive
13 # license for use of this work by or on behalf of the US Government.
14 # Export of this program may require a license from the United States
17 # This library is free software; you can redistribute it and/or
18 # modify it under the terms of the GNU Lesser General Public
19 # License as published by the Free Software Foundation; either
20 # version 2.1 of the License, or (at your option) any later version.
22 # This library is distributed in the hope that it will be useful,
23 # but WITHOUT ANY WARRANTY; without even the implied warranty of
24 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
25 # Lesser General Public License for more details.
27 # You should have received a copy of the GNU Lesser General Public
28 # License along with this library; if not, write to the Free Software
29 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
31 # Questions or comments about this library should be sent to:
34 # Sandia National Laboratories, New Mexico
36 # Albuquerque, NM 87185-1110
41 # Useful commands for debugging libsysio in gdb
46 if $arg0->pb_name.name
53 set $x_p = $arg0->pb_aliases.lh_first
55 printf "<%p r:%d mnt:%p>", \
59 set $x_p = $x_p->p_links.le_next
63 document x_dump_pbnode
64 Dump path-base node and it's aliases
66 Usage: x_dump_pbnode <pbnode>
70 printf "%spnode %p, mount %p, base: ", $arg0, $arg1, $arg1->p_mount
71 x_dump_pbnode $arg1->p_base
75 __x_dump_pnode "" $arg0
78 Dump path node information
80 Usage: x_dump_pnode <pnode>
84 printf "MOUNT %p: root pnode %p, covers %p\n", \
85 $arg0, $arg0->mnt_root, $arg0->mnt_covers
86 set $_x_dump_mount_var_pno = _sysio_pnodes->tqh_first
87 while $_x_dump_mount_var_pno != 0
88 printf "%p, %p\n", $_x_dump_mount_var_pno, $arg0
89 if $_x_dump_mount_var_pno->p_mount == $arg0
90 __x_dump_pnode " " $_x_dump_mount_var_pno
92 set $_x_dump_mount_var_pno = \
93 $_x_dump_mount_var_pno->p_nodes.tqe_next
97 Dump single mount record information
99 Usage: x_dump_mount <mnt>
103 set $__x_dump_mounts_var_mnt = mounts.lh_first
104 while $__x_dump_mounts_var_mnt
105 x_dump_mount $__x_dump_mounts_var_mnt
106 set $__x_dump_mounts_var_mnt = \
107 $__x_dump_mounts_var_mnt->mnt_link.le_next
110 document x_dump_mounts
111 Dump the contents of the libsysio mount table
117 set $_x_dump_pnodes_var_pno = _sysio_pnodes.tqh_first
118 while $_x_dump_pnodes_var_pno
119 x_dump_pnode $_x_dump_pnodes_var_pno
120 set $_x_dump_pnodes_var_pno = \
121 $_x_dump_pnodes_var_pno->p_nodes.tqe_next
125 br _sysio_unmount_all
126 run -r /tmp/lee foo bar