1 --- linux-2.6.19/fs/quota.c~ 2007-03-01 19:45:40.694648408 +0100
2 +++ linux-2.6.19/fs/quota.c 2007-03-02 00:27:24.196276620 +0100
8 - * look up a superblock on which quota ops will be performed
9 - * - use the name of a block device to find the superblock thereon
11 -static inline struct super_block *quotactl_block(const char __user *special)
14 - struct block_device *bdev;
15 - struct super_block *sb;
16 - char *tmp = getname(special);
19 - return ERR_PTR(PTR_ERR(tmp));
20 - bdev = lookup_bdev(tmp);
23 - return ERR_PTR(PTR_ERR(bdev));
24 - sb = get_super(bdev);
27 - return ERR_PTR(-ENODEV);
31 - return ERR_PTR(-ENODEV);
35 #if defined(CONFIG_BLK_DEV_VROOT) || defined(CONFIG_BLK_DEV_VROOT_MODULE)
37 #include <linux/vroot.h>
42 + * look up a superblock on which quota ops will be performed
43 + * - use the name of a block device to find the superblock thereon
45 +static inline struct super_block *quotactl_block(const char __user *special)
48 + struct block_device *bdev;
49 + struct super_block *sb;
50 + char *tmp = getname(special);
53 + return ERR_PTR(PTR_ERR(tmp));
54 + bdev = lookup_bdev(tmp);
57 + return ERR_PTR(PTR_ERR(bdev));
58 +#if defined(CONFIG_BLK_DEV_VROOT) || defined(CONFIG_BLK_DEV_VROOT_MODULE)
59 + if (bdev && bdev->bd_inode &&
60 + imajor(bdev->bd_inode) == VROOT_MAJOR) {
61 + struct block_device *bdnew = (void *)-EINVAL;
63 + if (vroot_get_real_bdev)
64 + bdnew = vroot_get_real_bdev(bdev);
66 + vxdprintk(VXD_CBIT(misc, 0),
67 + "vroot_get_real_bdev not set");
70 + return ERR_PTR(PTR_ERR(bdnew));
74 + sb = get_super(bdev);
77 + return ERR_PTR(-ENODEV);
81 + return ERR_PTR(-ENODEV);
86 * This is the system call interface. This communicates with
87 * the user-level programs. Currently this only supports diskquota
88 * calls. Maybe we need to add the process quotas etc. in the future,