]>
Commit | Line | Data |
---|---|---|
1 | /* | |
2 | * fs/f2fs/inline.c | |
3 | * Copyright (c) 2013, Intel Corporation | |
4 | * Authors: Huajun Li <huajun.li@intel.com> | |
5 | * Haicheng Li <haicheng.li@intel.com> | |
6 | * This program is free software; you can redistribute it and/or modify | |
7 | * it under the terms of the GNU General Public License version 2 as | |
8 | * published by the Free Software Foundation. | |
9 | */ | |
10 | ||
11 | #include <linux/fs.h> | |
12 | #include <linux/f2fs_fs.h> | |
13 | ||
14 | #include "f2fs.h" | |
15 | ||
16 | bool f2fs_may_inline(struct inode *inode) | |
17 | { | |
18 | block_t nr_blocks; | |
19 | loff_t i_size; | |
20 | ||
21 | if (!test_opt(F2FS_I_SB(inode), INLINE_DATA)) | |
22 | return false; | |
23 | ||
24 | if (f2fs_is_atomic_file(inode)) | |
25 | return false; | |
26 | ||
27 | nr_blocks = F2FS_I(inode)->i_xattr_nid ? 3 : 2; | |
28 | if (inode->i_blocks > nr_blocks) | |
29 | return false; | |
30 | ||
31 | i_size = i_size_read(inode); | |
32 | if (i_size > MAX_INLINE_DATA) | |
33 | return false; | |
34 | ||
35 | return true; | |
36 | } | |
37 | ||
38 | int f2fs_read_inline_data(struct inode *inode, struct page *page) | |
39 | { | |
40 | struct page *ipage; | |
41 | void *src_addr, *dst_addr; | |
42 | ||
43 | if (page->index) { | |
44 | zero_user_segment(page, 0, PAGE_CACHE_SIZE); | |
45 | goto out; | |
46 | } | |
47 | ||
48 | ipage = get_node_page(F2FS_I_SB(inode), inode->i_ino); | |
49 | if (IS_ERR(ipage)) { | |
50 | unlock_page(page); | |
51 | return PTR_ERR(ipage); | |
52 | } | |
53 | ||
54 | zero_user_segment(page, MAX_INLINE_DATA, PAGE_CACHE_SIZE); | |
55 | ||
56 | /* Copy the whole inline data block */ | |
57 | src_addr = inline_data_addr(ipage); | |
58 | dst_addr = kmap(page); | |
59 | memcpy(dst_addr, src_addr, MAX_INLINE_DATA); | |
60 | kunmap(page); | |
61 | f2fs_put_page(ipage, 1); | |
62 | ||
63 | out: | |
64 | SetPageUptodate(page); | |
65 | unlock_page(page); | |
66 | ||
67 | return 0; | |
68 | } | |
69 | ||
70 | static int __f2fs_convert_inline_data(struct inode *inode, struct page *page) | |
71 | { | |
72 | int err = 0; | |
73 | struct page *ipage; | |
74 | struct dnode_of_data dn; | |
75 | void *src_addr, *dst_addr; | |
76 | block_t new_blk_addr; | |
77 | struct f2fs_sb_info *sbi = F2FS_I_SB(inode); | |
78 | struct f2fs_io_info fio = { | |
79 | .type = DATA, | |
80 | .rw = WRITE_SYNC | REQ_PRIO, | |
81 | }; | |
82 | ||
83 | f2fs_lock_op(sbi); | |
84 | ipage = get_node_page(sbi, inode->i_ino); | |
85 | if (IS_ERR(ipage)) { | |
86 | err = PTR_ERR(ipage); | |
87 | goto out; | |
88 | } | |
89 | ||
90 | /* someone else converted inline_data already */ | |
91 | if (!f2fs_has_inline_data(inode)) | |
92 | goto out; | |
93 | ||
94 | /* | |
95 | * i_addr[0] is not used for inline data, | |
96 | * so reserving new block will not destroy inline data | |
97 | */ | |
98 | set_new_dnode(&dn, inode, ipage, NULL, 0); | |
99 | err = f2fs_reserve_block(&dn, 0); | |
100 | if (err) | |
101 | goto out; | |
102 | ||
103 | f2fs_wait_on_page_writeback(page, DATA); | |
104 | zero_user_segment(page, MAX_INLINE_DATA, PAGE_CACHE_SIZE); | |
105 | ||
106 | /* Copy the whole inline data block */ | |
107 | src_addr = inline_data_addr(ipage); | |
108 | dst_addr = kmap(page); | |
109 | memcpy(dst_addr, src_addr, MAX_INLINE_DATA); | |
110 | kunmap(page); | |
111 | SetPageUptodate(page); | |
112 | ||
113 | /* write data page to try to make data consistent */ | |
114 | set_page_writeback(page); | |
115 | write_data_page(page, &dn, &new_blk_addr, &fio); | |
116 | update_extent_cache(new_blk_addr, &dn); | |
117 | f2fs_wait_on_page_writeback(page, DATA); | |
118 | ||
119 | /* clear inline data and flag after data writeback */ | |
120 | zero_user_segment(ipage, INLINE_DATA_OFFSET, | |
121 | INLINE_DATA_OFFSET + MAX_INLINE_DATA); | |
122 | clear_inode_flag(F2FS_I(inode), FI_INLINE_DATA); | |
123 | stat_dec_inline_inode(inode); | |
124 | ||
125 | sync_inode_page(&dn); | |
126 | f2fs_put_dnode(&dn); | |
127 | out: | |
128 | f2fs_unlock_op(sbi); | |
129 | return err; | |
130 | } | |
131 | ||
132 | int f2fs_convert_inline_data(struct inode *inode, pgoff_t to_size, | |
133 | struct page *page) | |
134 | { | |
135 | struct page *new_page = page; | |
136 | int err; | |
137 | ||
138 | if (!f2fs_has_inline_data(inode)) | |
139 | return 0; | |
140 | else if (to_size <= MAX_INLINE_DATA) | |
141 | return 0; | |
142 | ||
143 | if (!page || page->index != 0) { | |
144 | new_page = grab_cache_page(inode->i_mapping, 0); | |
145 | if (!new_page) | |
146 | return -ENOMEM; | |
147 | } | |
148 | ||
149 | err = __f2fs_convert_inline_data(inode, new_page); | |
150 | if (!page || page->index != 0) | |
151 | f2fs_put_page(new_page, 1); | |
152 | return err; | |
153 | } | |
154 | ||
155 | int f2fs_write_inline_data(struct inode *inode, | |
156 | struct page *page, unsigned size) | |
157 | { | |
158 | void *src_addr, *dst_addr; | |
159 | struct page *ipage; | |
160 | struct dnode_of_data dn; | |
161 | int err; | |
162 | ||
163 | set_new_dnode(&dn, inode, NULL, NULL, 0); | |
164 | err = get_dnode_of_data(&dn, 0, LOOKUP_NODE); | |
165 | if (err) | |
166 | return err; | |
167 | ipage = dn.inode_page; | |
168 | ||
169 | /* Release any data block if it is allocated */ | |
170 | if (!f2fs_has_inline_data(inode)) { | |
171 | int count = ADDRS_PER_PAGE(dn.node_page, F2FS_I(inode)); | |
172 | truncate_data_blocks_range(&dn, count); | |
173 | set_inode_flag(F2FS_I(inode), FI_INLINE_DATA); | |
174 | stat_inc_inline_inode(inode); | |
175 | } | |
176 | ||
177 | f2fs_wait_on_page_writeback(ipage, NODE); | |
178 | zero_user_segment(ipage, INLINE_DATA_OFFSET, | |
179 | INLINE_DATA_OFFSET + MAX_INLINE_DATA); | |
180 | src_addr = kmap(page); | |
181 | dst_addr = inline_data_addr(ipage); | |
182 | memcpy(dst_addr, src_addr, size); | |
183 | kunmap(page); | |
184 | ||
185 | set_inode_flag(F2FS_I(inode), FI_APPEND_WRITE); | |
186 | sync_inode_page(&dn); | |
187 | f2fs_put_dnode(&dn); | |
188 | ||
189 | return 0; | |
190 | } | |
191 | ||
192 | void truncate_inline_data(struct inode *inode, u64 from) | |
193 | { | |
194 | struct page *ipage; | |
195 | ||
196 | if (from >= MAX_INLINE_DATA) | |
197 | return; | |
198 | ||
199 | ipage = get_node_page(F2FS_I_SB(inode), inode->i_ino); | |
200 | if (IS_ERR(ipage)) | |
201 | return; | |
202 | ||
203 | f2fs_wait_on_page_writeback(ipage, NODE); | |
204 | ||
205 | zero_user_segment(ipage, INLINE_DATA_OFFSET + from, | |
206 | INLINE_DATA_OFFSET + MAX_INLINE_DATA); | |
207 | set_page_dirty(ipage); | |
208 | f2fs_put_page(ipage, 1); | |
209 | } | |
210 | ||
211 | bool recover_inline_data(struct inode *inode, struct page *npage) | |
212 | { | |
213 | struct f2fs_sb_info *sbi = F2FS_I_SB(inode); | |
214 | struct f2fs_inode *ri = NULL; | |
215 | void *src_addr, *dst_addr; | |
216 | struct page *ipage; | |
217 | ||
218 | /* | |
219 | * The inline_data recovery policy is as follows. | |
220 | * [prev.] [next] of inline_data flag | |
221 | * o o -> recover inline_data | |
222 | * o x -> remove inline_data, and then recover data blocks | |
223 | * x o -> remove inline_data, and then recover inline_data | |
224 | * x x -> recover data blocks | |
225 | */ | |
226 | if (IS_INODE(npage)) | |
227 | ri = F2FS_INODE(npage); | |
228 | ||
229 | if (f2fs_has_inline_data(inode) && | |
230 | ri && (ri->i_inline & F2FS_INLINE_DATA)) { | |
231 | process_inline: | |
232 | ipage = get_node_page(sbi, inode->i_ino); | |
233 | f2fs_bug_on(sbi, IS_ERR(ipage)); | |
234 | ||
235 | f2fs_wait_on_page_writeback(ipage, NODE); | |
236 | ||
237 | src_addr = inline_data_addr(npage); | |
238 | dst_addr = inline_data_addr(ipage); | |
239 | memcpy(dst_addr, src_addr, MAX_INLINE_DATA); | |
240 | update_inode(inode, ipage); | |
241 | f2fs_put_page(ipage, 1); | |
242 | return true; | |
243 | } | |
244 | ||
245 | if (f2fs_has_inline_data(inode)) { | |
246 | ipage = get_node_page(sbi, inode->i_ino); | |
247 | f2fs_bug_on(sbi, IS_ERR(ipage)); | |
248 | f2fs_wait_on_page_writeback(ipage, NODE); | |
249 | zero_user_segment(ipage, INLINE_DATA_OFFSET, | |
250 | INLINE_DATA_OFFSET + MAX_INLINE_DATA); | |
251 | clear_inode_flag(F2FS_I(inode), FI_INLINE_DATA); | |
252 | update_inode(inode, ipage); | |
253 | f2fs_put_page(ipage, 1); | |
254 | } else if (ri && (ri->i_inline & F2FS_INLINE_DATA)) { | |
255 | truncate_blocks(inode, 0, false); | |
256 | set_inode_flag(F2FS_I(inode), FI_INLINE_DATA); | |
257 | goto process_inline; | |
258 | } | |
259 | return false; | |
260 | } | |
261 | ||
262 | struct f2fs_dir_entry *find_in_inline_dir(struct inode *dir, | |
263 | struct qstr *name, struct page **res_page) | |
264 | { | |
265 | struct f2fs_sb_info *sbi = F2FS_SB(dir->i_sb); | |
266 | struct f2fs_inline_dentry *inline_dentry; | |
267 | struct f2fs_dir_entry *de; | |
268 | struct page *ipage; | |
269 | int max_slots = NR_INLINE_DENTRY; | |
270 | ||
271 | ipage = get_node_page(sbi, dir->i_ino); | |
272 | if (IS_ERR(ipage)) | |
273 | return NULL; | |
274 | ||
275 | inline_dentry = inline_data_addr(ipage); | |
276 | ||
277 | de = find_target_dentry(name, &max_slots, &inline_dentry->dentry_bitmap, | |
278 | inline_dentry->dentry, | |
279 | inline_dentry->filename); | |
280 | unlock_page(ipage); | |
281 | if (de) | |
282 | *res_page = ipage; | |
283 | else | |
284 | f2fs_put_page(ipage, 0); | |
285 | ||
286 | /* | |
287 | * For the most part, it should be a bug when name_len is zero. | |
288 | * We stop here for figuring out where the bugs has occurred. | |
289 | */ | |
290 | f2fs_bug_on(sbi, max_slots < 0); | |
291 | return de; | |
292 | } | |
293 | ||
294 | struct f2fs_dir_entry *f2fs_parent_inline_dir(struct inode *dir, | |
295 | struct page **p) | |
296 | { | |
297 | struct f2fs_sb_info *sbi = F2FS_I_SB(dir); | |
298 | struct page *ipage; | |
299 | struct f2fs_dir_entry *de; | |
300 | struct f2fs_inline_dentry *dentry_blk; | |
301 | ||
302 | ipage = get_node_page(sbi, dir->i_ino); | |
303 | if (IS_ERR(ipage)) | |
304 | return NULL; | |
305 | ||
306 | dentry_blk = inline_data_addr(ipage); | |
307 | de = &dentry_blk->dentry[1]; | |
308 | *p = ipage; | |
309 | unlock_page(ipage); | |
310 | return de; | |
311 | } | |
312 | ||
313 | int make_empty_inline_dir(struct inode *inode, struct inode *parent, | |
314 | struct page *ipage) | |
315 | { | |
316 | struct f2fs_inline_dentry *dentry_blk; | |
317 | struct f2fs_dir_entry *de; | |
318 | ||
319 | dentry_blk = inline_data_addr(ipage); | |
320 | ||
321 | de = &dentry_blk->dentry[0]; | |
322 | de->name_len = cpu_to_le16(1); | |
323 | de->hash_code = 0; | |
324 | de->ino = cpu_to_le32(inode->i_ino); | |
325 | memcpy(dentry_blk->filename[0], ".", 1); | |
326 | set_de_type(de, inode); | |
327 | ||
328 | de = &dentry_blk->dentry[1]; | |
329 | de->hash_code = 0; | |
330 | de->name_len = cpu_to_le16(2); | |
331 | de->ino = cpu_to_le32(parent->i_ino); | |
332 | memcpy(dentry_blk->filename[1], "..", 2); | |
333 | set_de_type(de, inode); | |
334 | ||
335 | test_and_set_bit_le(0, &dentry_blk->dentry_bitmap); | |
336 | test_and_set_bit_le(1, &dentry_blk->dentry_bitmap); | |
337 | ||
338 | set_page_dirty(ipage); | |
339 | ||
340 | /* update i_size to MAX_INLINE_DATA */ | |
341 | if (i_size_read(inode) < MAX_INLINE_DATA) { | |
342 | i_size_write(inode, MAX_INLINE_DATA); | |
343 | set_inode_flag(F2FS_I(inode), FI_UPDATE_DIR); | |
344 | } | |
345 | return 0; | |
346 | } | |
347 | ||
348 | int f2fs_convert_inline_dir(struct inode *dir, struct page *ipage, | |
349 | struct f2fs_inline_dentry *inline_dentry) | |
350 | { | |
351 | struct page *page; | |
352 | struct dnode_of_data dn; | |
353 | struct f2fs_dentry_block *dentry_blk; | |
354 | int err; | |
355 | ||
356 | page = grab_cache_page(dir->i_mapping, 0); | |
357 | if (!page) | |
358 | return -ENOMEM; | |
359 | ||
360 | set_new_dnode(&dn, dir, ipage, NULL, 0); | |
361 | err = f2fs_reserve_block(&dn, 0); | |
362 | if (err) | |
363 | goto out; | |
364 | ||
365 | f2fs_wait_on_page_writeback(page, DATA); | |
366 | zero_user_segment(page, 0, PAGE_CACHE_SIZE); | |
367 | ||
368 | dentry_blk = kmap(page); | |
369 | ||
370 | /* copy data from inline dentry block to new dentry block */ | |
371 | memcpy(dentry_blk->dentry_bitmap, inline_dentry->dentry_bitmap, | |
372 | INLINE_DENTRY_BITMAP_SIZE); | |
373 | memcpy(dentry_blk->dentry, inline_dentry->dentry, | |
374 | sizeof(struct f2fs_dir_entry) * NR_INLINE_DENTRY); | |
375 | memcpy(dentry_blk->filename, inline_dentry->filename, | |
376 | NR_INLINE_DENTRY * F2FS_SLOT_LEN); | |
377 | ||
378 | kunmap(page); | |
379 | SetPageUptodate(page); | |
380 | set_page_dirty(page); | |
381 | ||
382 | /* clear inline dir and flag after data writeback */ | |
383 | zero_user_segment(ipage, INLINE_DATA_OFFSET, | |
384 | INLINE_DATA_OFFSET + MAX_INLINE_DATA); | |
385 | clear_inode_flag(F2FS_I(dir), FI_INLINE_DENTRY); | |
386 | stat_dec_inline_inode(dir); | |
387 | ||
388 | if (i_size_read(dir) < PAGE_CACHE_SIZE) { | |
389 | i_size_write(dir, PAGE_CACHE_SIZE); | |
390 | set_inode_flag(F2FS_I(dir), FI_UPDATE_DIR); | |
391 | } | |
392 | ||
393 | sync_inode_page(&dn); | |
394 | out: | |
395 | f2fs_put_page(page, 1); | |
396 | return err; | |
397 | } | |
398 | ||
399 | int f2fs_add_inline_entry(struct inode *dir, const struct qstr *name, | |
400 | struct inode *inode) | |
401 | { | |
402 | struct f2fs_sb_info *sbi = F2FS_I_SB(dir); | |
403 | struct page *ipage; | |
404 | unsigned int bit_pos; | |
405 | f2fs_hash_t name_hash; | |
406 | struct f2fs_dir_entry *de; | |
407 | size_t namelen = name->len; | |
408 | struct f2fs_inline_dentry *dentry_blk = NULL; | |
409 | int slots = GET_DENTRY_SLOTS(namelen); | |
410 | struct page *page; | |
411 | int err = 0; | |
412 | int i; | |
413 | ||
414 | name_hash = f2fs_dentry_hash(name); | |
415 | ||
416 | ipage = get_node_page(sbi, dir->i_ino); | |
417 | if (IS_ERR(ipage)) | |
418 | return PTR_ERR(ipage); | |
419 | ||
420 | dentry_blk = inline_data_addr(ipage); | |
421 | bit_pos = room_for_filename(&dentry_blk->dentry_bitmap, | |
422 | slots, NR_INLINE_DENTRY); | |
423 | if (bit_pos >= NR_INLINE_DENTRY) { | |
424 | err = f2fs_convert_inline_dir(dir, ipage, dentry_blk); | |
425 | if (!err) | |
426 | err = -EAGAIN; | |
427 | goto out; | |
428 | } | |
429 | ||
430 | f2fs_wait_on_page_writeback(ipage, DATA); | |
431 | ||
432 | down_write(&F2FS_I(inode)->i_sem); | |
433 | page = init_inode_metadata(inode, dir, name); | |
434 | if (IS_ERR(page)) { | |
435 | err = PTR_ERR(page); | |
436 | goto fail; | |
437 | } | |
438 | de = &dentry_blk->dentry[bit_pos]; | |
439 | de->hash_code = name_hash; | |
440 | de->name_len = cpu_to_le16(namelen); | |
441 | memcpy(dentry_blk->filename[bit_pos], name->name, name->len); | |
442 | de->ino = cpu_to_le32(inode->i_ino); | |
443 | set_de_type(de, inode); | |
444 | for (i = 0; i < slots; i++) | |
445 | test_and_set_bit_le(bit_pos + i, &dentry_blk->dentry_bitmap); | |
446 | set_page_dirty(ipage); | |
447 | ||
448 | /* we don't need to mark_inode_dirty now */ | |
449 | F2FS_I(inode)->i_pino = dir->i_ino; | |
450 | update_inode(inode, page); | |
451 | f2fs_put_page(page, 1); | |
452 | ||
453 | update_parent_metadata(dir, inode, 0); | |
454 | fail: | |
455 | up_write(&F2FS_I(inode)->i_sem); | |
456 | ||
457 | if (is_inode_flag_set(F2FS_I(dir), FI_UPDATE_DIR)) { | |
458 | update_inode(dir, ipage); | |
459 | clear_inode_flag(F2FS_I(dir), FI_UPDATE_DIR); | |
460 | } | |
461 | out: | |
462 | f2fs_put_page(ipage, 1); | |
463 | return err; | |
464 | } | |
465 | ||
466 | void f2fs_delete_inline_entry(struct f2fs_dir_entry *dentry, struct page *page, | |
467 | struct inode *dir, struct inode *inode) | |
468 | { | |
469 | struct f2fs_inline_dentry *inline_dentry; | |
470 | int slots = GET_DENTRY_SLOTS(le16_to_cpu(dentry->name_len)); | |
471 | unsigned int bit_pos; | |
472 | int i; | |
473 | ||
474 | lock_page(page); | |
475 | f2fs_wait_on_page_writeback(page, DATA); | |
476 | ||
477 | inline_dentry = inline_data_addr(page); | |
478 | bit_pos = dentry - inline_dentry->dentry; | |
479 | for (i = 0; i < slots; i++) | |
480 | test_and_clear_bit_le(bit_pos + i, | |
481 | &inline_dentry->dentry_bitmap); | |
482 | ||
483 | set_page_dirty(page); | |
484 | ||
485 | dir->i_ctime = dir->i_mtime = CURRENT_TIME; | |
486 | ||
487 | if (inode) | |
488 | f2fs_drop_nlink(dir, inode, page); | |
489 | ||
490 | f2fs_put_page(page, 1); | |
491 | } | |
492 | ||
493 | bool f2fs_empty_inline_dir(struct inode *dir) | |
494 | { | |
495 | struct f2fs_sb_info *sbi = F2FS_I_SB(dir); | |
496 | struct page *ipage; | |
497 | unsigned int bit_pos = 2; | |
498 | struct f2fs_inline_dentry *dentry_blk; | |
499 | ||
500 | ipage = get_node_page(sbi, dir->i_ino); | |
501 | if (IS_ERR(ipage)) | |
502 | return false; | |
503 | ||
504 | dentry_blk = inline_data_addr(ipage); | |
505 | bit_pos = find_next_bit_le(&dentry_blk->dentry_bitmap, | |
506 | NR_INLINE_DENTRY, | |
507 | bit_pos); | |
508 | ||
509 | f2fs_put_page(ipage, 1); | |
510 | ||
511 | if (bit_pos < NR_INLINE_DENTRY) | |
512 | return false; | |
513 | ||
514 | return true; | |
515 | } | |
516 | ||
517 | int f2fs_read_inline_dir(struct file *file, struct dir_context *ctx) | |
518 | { | |
519 | struct inode *inode = file_inode(file); | |
520 | struct f2fs_sb_info *sbi = F2FS_I_SB(inode); | |
521 | unsigned int bit_pos = 0; | |
522 | struct f2fs_inline_dentry *inline_dentry = NULL; | |
523 | struct f2fs_dir_entry *de = NULL; | |
524 | struct page *ipage = NULL; | |
525 | unsigned char d_type = DT_UNKNOWN; | |
526 | ||
527 | if (ctx->pos == NR_INLINE_DENTRY) | |
528 | return 0; | |
529 | ||
530 | ipage = get_node_page(sbi, inode->i_ino); | |
531 | if (IS_ERR(ipage)) | |
532 | return PTR_ERR(ipage); | |
533 | ||
534 | bit_pos = ((unsigned long)ctx->pos % NR_INLINE_DENTRY); | |
535 | ||
536 | inline_dentry = inline_data_addr(ipage); | |
537 | while (bit_pos < NR_INLINE_DENTRY) { | |
538 | bit_pos = find_next_bit_le(&inline_dentry->dentry_bitmap, | |
539 | NR_INLINE_DENTRY, | |
540 | bit_pos); | |
541 | if (bit_pos >= NR_INLINE_DENTRY) | |
542 | break; | |
543 | ||
544 | de = &inline_dentry->dentry[bit_pos]; | |
545 | if (de->file_type < F2FS_FT_MAX) | |
546 | d_type = f2fs_filetype_table[de->file_type]; | |
547 | else | |
548 | d_type = DT_UNKNOWN; | |
549 | ||
550 | if (!dir_emit(ctx, | |
551 | inline_dentry->filename[bit_pos], | |
552 | le16_to_cpu(de->name_len), | |
553 | le32_to_cpu(de->ino), d_type)) | |
554 | goto out; | |
555 | ||
556 | bit_pos += GET_DENTRY_SLOTS(le16_to_cpu(de->name_len)); | |
557 | ctx->pos = bit_pos; | |
558 | } | |
559 | ||
560 | ctx->pos = NR_INLINE_DENTRY; | |
561 | out: | |
562 | f2fs_put_page(ipage, 1); | |
563 | ||
564 | return 0; | |
565 | } |