Lines Matching defs:off
22 void hfs_bnode_read(struct hfs_bnode *node, void *buf, int off, int len)
27 off += node->page_offset;
28 pagep = node->page + (off >> PAGE_SHIFT);
29 off &= ~PAGE_MASK;
31 l = min_t(int, len, PAGE_SIZE - off);
32 memcpy_from_page(buf, *pagep, off, l);
41 u16 hfs_bnode_read_u16(struct hfs_bnode *node, int off)
45 hfs_bnode_read(node, &data, off, 2);
49 u8 hfs_bnode_read_u8(struct hfs_bnode *node, int off)
53 hfs_bnode_read(node, &data, off, 1);
57 void hfs_bnode_read_key(struct hfs_bnode *node, void *key, int off)
66 key_len = hfs_bnode_read_u16(node, off) + 2;
70 hfs_bnode_read(node, key, off, key_len);
73 void hfs_bnode_write(struct hfs_bnode *node, void *buf, int off, int len)
78 off += node->page_offset;
79 pagep = node->page + (off >> PAGE_SHIFT);
80 off &= ~PAGE_MASK;
82 l = min_t(int, len, PAGE_SIZE - off);
83 memcpy_to_page(*pagep, off, buf, l);
94 void hfs_bnode_write_u16(struct hfs_bnode *node, int off, u16 data)
98 hfs_bnode_write(node, &v, off, 2);
101 void hfs_bnode_clear(struct hfs_bnode *node, int off, int len)
106 off += node->page_offset;
107 pagep = node->page + (off >> PAGE_SHIFT);
108 off &= ~PAGE_MASK;
110 l = min_t(int, len, PAGE_SIZE - off);
111 memzero_page(*pagep, off, l);
295 int i, off, key_off;
303 off = node->tree->node_size - 2;
304 for (i = be16_to_cpu(desc.num_recs); i >= 0; off -= 2, i--) {
305 key_off = hfs_bnode_read_u16(node, off);
399 loff_t off;
436 off = (loff_t)cnid << tree->node_size_shift;
437 block = off >> PAGE_SHIFT;
438 node->page_offset = off & ~PAGE_MASK;
471 int i, rec_off, off, next_off;
522 off = hfs_bnode_read_u16(node, rec_off);
523 if (off != sizeof(struct hfs_bnode_desc))
525 for (i = 1; i <= node->num_recs; off = next_off, i++) {
528 if (next_off <= off ||
532 entry_size = next_off - off;
536 key_size = hfs_bnode_read_u16(node, off) + 2;