Lines Matching refs:sb_ptr

380 …struct vfs_superblock_t *sb_ptr = (struct vfs_superblock_t *)kzalloc(sizeof(struct vfs_superblock_…  in fat32_read_superblock()  local
381 blk->bd_superblock = sb_ptr; in fat32_read_superblock()
382 sb_ptr->sb_ops = &fat32_sb_ops; in fat32_read_superblock()
383 sb_ptr->dir_ops = &fat32_dEntry_ops; in fat32_read_superblock()
384 sb_ptr->private_sb_info = kzalloc(sizeof(fat32_sb_info_t), 0); in fat32_read_superblock()
385 sb_ptr->blk_device = blk; in fat32_read_superblock()
389 fat32_sb_info_t *fsbi = (fat32_sb_info_t *)(sb_ptr->private_sb_info); in fat32_read_superblock()
417 sb_ptr->root = vfs_alloc_dentry(2); in fat32_read_superblock()
419 sb_ptr->root->parent = sb_ptr->root; in fat32_read_superblock()
420 sb_ptr->root->dir_ops = &fat32_dEntry_ops; in fat32_read_superblock()
422 sb_ptr->root->name[0] = '/'; in fat32_read_superblock()
423 sb_ptr->root->name_length = 1; in fat32_read_superblock()
426 sb_ptr->root->dir_inode = vfs_alloc_inode(); in fat32_read_superblock()
427 sb_ptr->root->dir_inode->inode_ops = &fat32_inode_ops; in fat32_read_superblock()
428 sb_ptr->root->dir_inode->file_ops = &fat32_file_ops; in fat32_read_superblock()
429 sb_ptr->root->dir_inode->file_size = 0; in fat32_read_superblock()
431 sb_ptr->root->dir_inode->blocks = in fat32_read_superblock()
432 (sb_ptr->root->dir_inode->file_size + fsbi->bytes_per_clus - 1) / fsbi->bytes_per_sec; in fat32_read_superblock()
433 sb_ptr->root->dir_inode->attribute = VFS_IF_DIR; in fat32_read_superblock()
434 sb_ptr->root->dir_inode->sb = sb_ptr; // 反向绑定对应的超级块 in fat32_read_superblock()
437 sb_ptr->root->dir_inode->private_inode_info = kmalloc(sizeof(struct fat32_inode_info_t), 0); in fat32_read_superblock()
438 memset(sb_ptr->root->dir_inode->private_inode_info, 0, sizeof(struct fat32_inode_info_t)); in fat32_read_superblock()
439 …struct fat32_inode_info_t *finode = (struct fat32_inode_info_t *)sb_ptr->root->dir_inode->private_… in fat32_read_superblock()
449 return sb_ptr; in fat32_read_superblock()