Whamcloud - gitweb
LU-540 quota: move quota ioctl handling to helper
authorAndreas Dilger <adilger@whamcloud.com>
Wed, 27 Jul 2011 07:54:20 +0000 (01:54 -0600)
committerOleg Drokin <green@whamcloud.com>
Fri, 29 Jul 2011 15:00:03 +0000 (11:00 -0400)
commit770f9c0e7e8eb3dc3a9e531210cbf29008e9a27d
tree1d067c53bf08f5ac1665ce39f606b2ce3431f1b8
parentd4ea36c7373eddb01bcdda32ca8894764f61e1cb
LU-540 quota: move quota ioctl handling to helper

The ll_dir_ioctl()::OBD_IOC_QUOTACTL handling is very large, and
is moved to a helper routine quotactl_ioctl() instead of being inline.
This will also facilitate the compatibility handling for the 1.x
QUOTACTL ioctl handling, by being able to share quotactl_ioctl() code.

Also, check for LL_IOC_QUOTACTL in ll_dir_ioctl(), since this is the
ioctl() number exported to userspace, and it also facilitates being
able to find the kernel-side ioctl handler for llapi_quotactl().

Add comments to show the duplicate user/kernel ioctl definitions.
Keep these separate for now, to allow the kernel/userspace values
to be defined differently for compatibility reasons.

There should be no functional differences with this change.

Change-Id: Iecfaf20ddbd78d77a546e1ba5a60b281732a85d9
Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/1151
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Johann Lombardi <johann@whamcloud.com>
Reviewed-by: Fan Yong <yong.fan@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/lustre/lustre_user.h
lustre/include/lustre_lib.h
lustre/llite/dir.c