Ryusuke Konishi | ae98043 | 2018-09-04 15:46:30 -0700 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0+ */ |
Koji Sato | 36a580e | 2009-04-06 19:01:25 -0700 | [diff] [blame] | 2 | /* |
Ryusuke Konishi | 94ee1d9 | 2021-11-08 18:35:01 -0800 | [diff] [blame] | 3 | * NILFS direct block pointer. |
Koji Sato | 36a580e | 2009-04-06 19:01:25 -0700 | [diff] [blame] | 4 | * |
| 5 | * Copyright (C) 2006-2008 Nippon Telegraph and Telephone Corporation. |
| 6 | * |
Ryusuke Konishi | 4b420ab | 2016-05-23 16:23:09 -0700 | [diff] [blame] | 7 | * Written by Koji Sato. |
Koji Sato | 36a580e | 2009-04-06 19:01:25 -0700 | [diff] [blame] | 8 | */ |
| 9 | |
| 10 | #ifndef _NILFS_DIRECT_H |
| 11 | #define _NILFS_DIRECT_H |
| 12 | |
| 13 | #include <linux/types.h> |
| 14 | #include <linux/buffer_head.h> |
| 15 | #include "bmap.h" |
| 16 | |
| 17 | |
Koji Sato | 36a580e | 2009-04-06 19:01:25 -0700 | [diff] [blame] | 18 | #define NILFS_DIRECT_NBLOCKS (NILFS_BMAP_SIZE / sizeof(__le64) - 1) |
| 19 | #define NILFS_DIRECT_KEY_MIN 0 |
| 20 | #define NILFS_DIRECT_KEY_MAX (NILFS_DIRECT_NBLOCKS - 1) |
| 21 | |
| 22 | |
Ryusuke Konishi | 3033342 | 2009-05-24 00:09:44 +0900 | [diff] [blame] | 23 | int nilfs_direct_init(struct nilfs_bmap *); |
Koji Sato | 36a580e | 2009-04-06 19:01:25 -0700 | [diff] [blame] | 24 | int nilfs_direct_delete_and_convert(struct nilfs_bmap *, __u64, __u64 *, |
Ryusuke Konishi | 3033342 | 2009-05-24 00:09:44 +0900 | [diff] [blame] | 25 | __u64 *, int); |
Koji Sato | 36a580e | 2009-04-06 19:01:25 -0700 | [diff] [blame] | 26 | |
| 27 | |
| 28 | #endif /* _NILFS_DIRECT_H */ |