]>
Commit | Line | Data |
---|---|---|
2bd0ea18 | 1 | /* |
da23017d NS |
2 | * Copyright (c) 2000-2001,2005 Silicon Graphics, Inc. |
3 | * All Rights Reserved. | |
dfc130f3 | 4 | * |
da23017d NS |
5 | * This program is free software; you can redistribute it and/or |
6 | * modify it under the terms of the GNU General Public License as | |
2bd0ea18 | 7 | * published by the Free Software Foundation. |
dfc130f3 | 8 | * |
da23017d NS |
9 | * This program is distributed in the hope that it would be useful, |
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | * GNU General Public License for more details. | |
dfc130f3 | 13 | * |
da23017d NS |
14 | * You should have received a copy of the GNU General Public License |
15 | * along with this program; if not, write the Free Software Foundation, | |
16 | * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | |
2bd0ea18 NS |
17 | */ |
18 | ||
19 | #include <libxfs.h> | |
20 | #include "avl.h" | |
21 | #include "globals.h" | |
22 | #include "incore.h" | |
23 | #include "agheader.h" | |
24 | #include "protos.h" | |
25 | #include "err_protos.h" | |
26 | ||
27 | void | |
28 | init_bm_cursor(bmap_cursor_t *cursor, int num_levels) | |
29 | { | |
30 | int i; | |
31 | ||
32 | bzero(cursor, sizeof(bmap_cursor_t)); | |
33 | cursor->ino = NULLFSINO; | |
34 | cursor->num_levels = num_levels; | |
35 | ||
36 | for (i = 0; i < XR_MAX_BMLEVELS; i++) { | |
37 | cursor->level[i].fsbno = NULLDFSBNO; | |
38 | cursor->level[i].right_fsbno = NULLDFSBNO; | |
39 | cursor->level[i].left_fsbno = NULLDFSBNO; | |
40 | cursor->level[i].first_key = NULLDFILOFF; | |
41 | cursor->level[i].last_key = NULLDFILOFF; | |
42 | } | |
43 | } |