diff options
author | Dave Chinner <david@fromorbit.com> | 2010-01-19 18:47:48 -0500 |
---|---|---|
committer | Dave Chinner <david@fromorbit.com> | 2010-01-19 18:47:48 -0500 |
commit | a9273ca5c6814f393e18ed66645f817b2b71e9ad (patch) | |
tree | 3714b7de8b233a31ea6995754f80349327738a88 /fs/xfs/linux-2.6/xfs_ioctl.c | |
parent | b9c48649577dfc4a8c263c106d518effa24ea54b (diff) |
xfs: convert attr to use unsigned names
To be consistent with the directory code, the attr code should use
unsigned names. Convert the names from the vfs at the highest level
to unsigned, and ænsure they are consistenly used as unsigned down
to disk.
Signed-off-by: Dave Chinner <david@fromorbit.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/xfs/linux-2.6/xfs_ioctl.c')
-rw-r--r-- | fs/xfs/linux-2.6/xfs_ioctl.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/fs/xfs/linux-2.6/xfs_ioctl.c b/fs/xfs/linux-2.6/xfs_ioctl.c index a034cf624437..3906e85abfdc 100644 --- a/fs/xfs/linux-2.6/xfs_ioctl.c +++ b/fs/xfs/linux-2.6/xfs_ioctl.c | |||
@@ -447,12 +447,12 @@ xfs_attrlist_by_handle( | |||
447 | int | 447 | int |
448 | xfs_attrmulti_attr_get( | 448 | xfs_attrmulti_attr_get( |
449 | struct inode *inode, | 449 | struct inode *inode, |
450 | char *name, | 450 | unsigned char *name, |
451 | char __user *ubuf, | 451 | unsigned char __user *ubuf, |
452 | __uint32_t *len, | 452 | __uint32_t *len, |
453 | __uint32_t flags) | 453 | __uint32_t flags) |
454 | { | 454 | { |
455 | char *kbuf; | 455 | unsigned char *kbuf; |
456 | int error = EFAULT; | 456 | int error = EFAULT; |
457 | 457 | ||
458 | if (*len > XATTR_SIZE_MAX) | 458 | if (*len > XATTR_SIZE_MAX) |
@@ -476,12 +476,12 @@ xfs_attrmulti_attr_get( | |||
476 | int | 476 | int |
477 | xfs_attrmulti_attr_set( | 477 | xfs_attrmulti_attr_set( |
478 | struct inode *inode, | 478 | struct inode *inode, |
479 | char *name, | 479 | unsigned char *name, |
480 | const char __user *ubuf, | 480 | const unsigned char __user *ubuf, |
481 | __uint32_t len, | 481 | __uint32_t len, |
482 | __uint32_t flags) | 482 | __uint32_t flags) |
483 | { | 483 | { |
484 | char *kbuf; | 484 | unsigned char *kbuf; |
485 | int error = EFAULT; | 485 | int error = EFAULT; |
486 | 486 | ||
487 | if (IS_IMMUTABLE(inode) || IS_APPEND(inode)) | 487 | if (IS_IMMUTABLE(inode) || IS_APPEND(inode)) |
@@ -501,7 +501,7 @@ xfs_attrmulti_attr_set( | |||
501 | int | 501 | int |
502 | xfs_attrmulti_attr_remove( | 502 | xfs_attrmulti_attr_remove( |
503 | struct inode *inode, | 503 | struct inode *inode, |
504 | char *name, | 504 | unsigned char *name, |
505 | __uint32_t flags) | 505 | __uint32_t flags) |
506 | { | 506 | { |
507 | if (IS_IMMUTABLE(inode) || IS_APPEND(inode)) | 507 | if (IS_IMMUTABLE(inode) || IS_APPEND(inode)) |
@@ -519,7 +519,7 @@ xfs_attrmulti_by_handle( | |||
519 | xfs_fsop_attrmulti_handlereq_t am_hreq; | 519 | xfs_fsop_attrmulti_handlereq_t am_hreq; |
520 | struct dentry *dentry; | 520 | struct dentry *dentry; |
521 | unsigned int i, size; | 521 | unsigned int i, size; |
522 | char *attr_name; | 522 | unsigned char *attr_name; |
523 | 523 | ||
524 | if (!capable(CAP_SYS_ADMIN)) | 524 | if (!capable(CAP_SYS_ADMIN)) |
525 | return -XFS_ERROR(EPERM); | 525 | return -XFS_ERROR(EPERM); |
@@ -547,7 +547,7 @@ xfs_attrmulti_by_handle( | |||
547 | 547 | ||
548 | error = 0; | 548 | error = 0; |
549 | for (i = 0; i < am_hreq.opcount; i++) { | 549 | for (i = 0; i < am_hreq.opcount; i++) { |
550 | ops[i].am_error = strncpy_from_user(attr_name, | 550 | ops[i].am_error = strncpy_from_user((char *)attr_name, |
551 | ops[i].am_attrname, MAXNAMELEN); | 551 | ops[i].am_attrname, MAXNAMELEN); |
552 | if (ops[i].am_error == 0 || ops[i].am_error == MAXNAMELEN) | 552 | if (ops[i].am_error == 0 || ops[i].am_error == MAXNAMELEN) |
553 | error = -ERANGE; | 553 | error = -ERANGE; |