/* handling directory dnode tree - adding, deleteing & searching for dirents  */
static loff_t get_pos(struct dnode *d, struct hpfs_dirent *fde)
/* handling directory dnode tree - adding, deleteing & searching for dirents  */
static loff_t get_pos(struct dnode *d, struct hpfs_dirent *fde)
{
	struct hpfs_dirent *de;
	struct hpfs_dirent *de_end = dnode_end_de(d);
	int i = 1;
	for (de = dnode_first_de(d); de < de_end; de = de_next_de(de)) {
		if (de == fde) return ((loff_t) d->self << 4) | (loff_t)i;
		i++;
	}
	printk("HPFS: get_pos: not_found\n");
	return ((loff_t)d->self << 4) | (loff_t)1;
}