OSDN Git Service

xfs: only allocate the buffer size actually needed in __xfs_set_acl
authorChristoph Hellwig <hch@lst.de>
Thu, 27 Feb 2020 01:30:44 +0000 (17:30 -0800)
committerDarrick J. Wong <darrick.wong@oracle.com>
Tue, 3 Mar 2020 04:55:55 +0000 (20:55 -0800)
commited02d13f5da896f5563b3673dd16db6c268c0f83
tree5eea9997b9cda376fcd98a84a1d9f79ce84f699b
parentf311d771a090f5cc96b65ab76737cbf13914bc0c
xfs: only allocate the buffer size actually needed in __xfs_set_acl

No need to allocate the max size if we can just allocate the easily
known actual ACL size.

Suggested-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
fs/xfs/xfs_acl.c