History log of /external/e2fsprogs/lib/quota/mkquota.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
e0ed7404719a9ddd2ba427a80db5365c8bad18c0 20-Mar-2014 JP Abgrall <jpa@google.com> Switch back to 1.42.9 now that there is a fix

Revert "Revert changes that moved from 1.41.14 to 1.42.9"

This reverts commit 65f0aab98b20b5994a726ab90d355248bcddfffd.
/external/e2fsprogs/lib/quota/mkquota.c
65f0aab98b20b5994a726ab90d355248bcddfffd 06-Mar-2014 JP Abgrall <jpa@google.com> Revert changes that moved from 1.41.14 to 1.42.9

Revert "e2fsck: Don't use e2fsck_global_ctx unless HAVE_SIGNAL_H"
commit e80e74c41d85ff93f3d212ba6512340f48054a93.

Revert "Merge remote-tracking branch 'linaro/linaro-1.42.9' into aosp_master"
This reverts commit e97b2b6fc82f840e84dfc631b87f21be44ff2421, reversing
changes made to 7e2fb9d09c245eba70ee008b78007315e9c0f1df.

Revert "Prepare for upstream 1.42.9"
This reverts commit 7e2fb9d09c245eba70ee008b78007315e9c0f1df.

Bug: 13340735
Change-Id: If48b153a95ef5f69f7cdccb00e23524abff3c5a8
Signed-off-by: JP Abgrall <jpa@google.com>
/external/e2fsprogs/lib/quota/mkquota.c
18a1444b4f1e6a0948fd38fa0de382d86cfe04de 31-Dec-2013 Bernhard Rosenkränzer <Bernhard.Rosenkranzer@linaro.org> Add files that would normally be generated by the e2fsprogs build system

Android doesn't run ./configure and friends, so it has to rely on
pre-populated versions of the autogenerated files.

This is somewhat bogus (e.g. hardcoded little-endian reference in
lib/ext2fs/ext2_types.h) and should at some point be fixed, but it's
what Android has always done, not a regression from the 1.41.14 branch.

Also, don't #include config.h which we don't generate (we pass what it
usually contains as -D parameters from Android.mk) anywhere.

Add a new Android.mk file for the quota library.

Change-Id: I162c6327fee5bd06261d9cdcc34bda10f04a6f21
Signed-off-by: Bernhard Rosenkränzer <Bernhard.Rosenkranzer@linaro.org>
/external/e2fsprogs/lib/quota/mkquota.c
b2778bcb8c37705ea97fee58199446d83dbda927 12-Dec-2013 Darrick J. Wong <darrick.wong@oracle.com> libquota: fix memory leak (on error path)

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
43075b42bdff509cc567bd870a32072edf05d04c 14-Oct-2013 Niu Yawei <niu@whamcloud.com> quota: fix disabling quota, add quota tests

Update all superblock copies when disabling the quota feature.

Added basic tests for the quota feature.

Signed-off-by: Niu Yawei <niu@whamcloud.com>
Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
0ce0172984c807d3366e8db6e2a2b6ecae314832 29-Nov-2012 Andreas Dilger <adilger@dilger.ca> libquota: quiet log_err() bad format warnings

The macro for log_err() was written so that it needed to always
have an argument, but GCC was unhappy to have an argument when
none was specified in the format string. Use the CPP "##" to
eat the preceeding comma if no argument is specified.

Signed-off-by: Andreas Dilger <adilger@dilger.ca>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
00eb0eee0addfd3b7ede98b85e00dff1547838a0 29-Nov-2012 Andreas Dilger <adilger@dilger.ca> build: quiet some "gcc -Wall" compiler warnings

Quiet a number of simple compiler warnings:
- pointers not initialized by ext2fs_get_mem()
- return without value in non-void function
- dereferencing type-punned pointers
- unused variables

Signed-off-by: Andreas Dilger <adilger@dilger.ca>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
5027751530980c61e313d265b1367fee90589cf4 14-Jul-2012 Aditya Kali <adityakali@google.com> tune2fs/quota: always create hidden quota files

Currently 'tune2fs -O quota <dev>' will try to use existing
quota files and write their inode numbers in the superblock.
Next e2fsck run then converts these into hidden quota inodes
(ino #3 & #4). But this approach has problems:
1) Before e2fsck run, the inodes are visible to the user and
might get corrupted or removed or replaced by the user.
2) Since these are user visible, we have to include
their block usage in the quota accounting. But once
these inodes are hidden, e2fsck will have to decrement
their usage from the quota accounting (which e2fsck
currently doesn't do and instead reports error).
(the following used to give e2fsck error previously:
# assume <dev> has aquota.user & aquota.group files
$ tune2fs -O quota <dev> # stores ino# of quota files in
# ext4 superblock
$ e2fsck -f <dev> # hides quota files, but now quota
# usage is incorrect.
<< quota errors >>
Instead of making e2fsck complicated, this patch creates the
hidden quota inodes at 'tune2fs -O quota' time iteself. The
usage is computed freshly and limits are copied from the
aquota.user and aquota.group files as earlier.

Signed-off-by: Aditya Kali <adityakali@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
2ae58b6d5c73e044f3d498feea5d81892af2671f 04-Jun-2012 Jan Kara <jack@suse.cz> libquota: remove unnecessary definitions

Quite some definitions in quota library are not necessary. Remove them.
Also fold quota.h file into quotaio.h since it didn't contain that many
definitions.

Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
3b802e43d9276a13cbc75144087cbf017672ca6c 28-May-2012 Theodore Ts'o <tytso@mit.edu> libquota: remove quota_is_on() which was the last user of quotactl()

The quotactl() system call was being used without the use of a
function prototype. On closer examination, it turns out the one user
of that system call was the quota_is_on() function, which is not used
by e2fsprogs at all. Since libquota is an e2fsprogs-internal library,
and not one that we plan to export any time soon, the simplest thing
to do is to simply remove quota_is_on(), which in turn allows us to
remove all of the infrastructure around using the Linux-specific
quotactl() system call.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
7943ccf5f2fa76f1dc164ddd1ffd5044a1dca31a 24-Apr-2012 Aditya Kali <adityakali@google.com> e2fsck,libquota: Update quota only if its inconsistent

Currently fsck recomputes quotas and overwrites quota files
whenever its run. This causes unnecessary modification of
filesystem even when quotas were never inconsistent. We also
lose the limits information because of this. With this patch,
e2fsck compares the computed quotas to the on-disk quotas
(while updating the in-memory limits) and writes out the
quota inode only if it is inconsistent.

Signed-off-by: Aditya Kali <adityakali@google.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
0df8a27bbaf51b55c0e8c3a533ef4c2ff9d79c9f 24-Feb-2012 Andreas Dilger <adilger@whamcloud.com> libquota: don't include system quota.h header

Don't use the system <sys/quota.h> header in mkquota.c, since there
is a local e2fsprogs version of quota.h that is already included and
has the desired quota constants, and avoids symbol conflicts with the
system <sys/quota.h> on other platforms (in particular OSX).

Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
1527d99d378a4a45f1e36b197bed628ce28d73ee 14-Nov-2011 Niu Yawei <niu@whamcloud.com> libquota: fix get_dq()

The dq_id should be set on newly created dqout.

Signed-off-by: Niu Yawei <niu@whamcloud.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
7bed9a78828e56ddb687cf2b5f1d6ec1f5e5ecc6 14-Nov-2011 Niu <niu@whamcloud.com> libquota: fix quota usage compute

In quota_compute_usage(), the space usage should be in bytes but
not quota block.

Signed-off-by: Niu Yawei <niu@whamcloud.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
198d20fc74a6124548b96e4c14c38ff8d5a95ae5 14-Nov-2011 Niu <niu@whamcloud.com> libquota: quota file read support

This patch adds read quota file support, which includes:
- Improve scan dquot APIs & fix defects in scan dquot functions;
- Implement quota_file_open();
- Introduce quota_update_inode() to update usage in old quota file,
and keep the limits unchanged.

Signed-off-by: Niu Yawei <niu@whamcloud.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
a86d55da8bf41335aa2fc5ec16ca63859d918e81 14-Nov-2011 Aditya Kali <adityakali@google.com> libquota: cleanup libquota code

This patch cleans up the quota code as suggested in previous reviews. This
includes
* remove BUG_ON()s and 'exit()' calls from library code
* remove calls to malloc/free and instead use ext2fs_get/free_mem functions.
* lib/quota/common.c file in not needed anymore and is removed.
* rename exported functions to start with quota_
(ex: init_quota_context --> quota_init_context)
* better error handling in quota library

Signed-off-by: Aditya Kali <adityakali@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
b5ba6f5b9da9d4e3d6f52ef9470ec12a161b1a7f 05-Oct-2011 Theodore Ts'o <tytso@mit.edu> libquota: remove flag argument to commit_dquot()

The flag parameter wasn't being used, and using it meant that we had
to define the COMMIT_* flags, which relied on the QIF_* flags being
present. Removing this allows for increased portability.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
36e4e21f511423450285568ceb26b3ddb233e286 04-Oct-2011 Theodore Ts'o <tytso@mit.edu> libquota: remove get_qf_name()

The get_qf_name() function used PATH_MAX, which is non-portable.
Worse, it blindly assumed that PATH_MAX was the size of the buffer
passed to it --- which in the one and only place where it was used in
libquota, was a buffer declared to a fixed size 256 bytes.

Fix this by simply getting rid of the function altogether.

Cc: Aditya Kali <adityakali@google.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
edbfd75d8fb4a13eccc2cadb12a453c3425d17d1 04-Oct-2011 Theodore Ts'o <tytso@mit.edu> libquota: clean up some gcc -Wall warnings

Remove unused variables, places where 'return' was used with no value
in a non-void function, missing function declarations, etc. Don't
assume that all systems have quotactl(), and use <sys/quota.h> if it
exists to define the quotactl interfaces.

One of the unused variables also got rid of a non-portable use of
PATH_MAX.

Cc: Aditya Kali <adityakali@google.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
d1154eb460efe588eaed3d439c1caaca149fa362 18-Sep-2011 Theodore Ts'o <tytso@mit.edu> Shorten compile commands run by the build system

The DEFS line in MCONFIG had gotten so long that it exceeded 4k, and
this was starting to cause some tools heartburn. It also made "make
V=1" almost useless, since trying to following the individual commands
run by make was lost in the noise of all of the defines.

So fix this by putting the configure-generated defines in lib/config.h
and the directory pathnames to lib/dirpaths.h.

In addition, clean up some vestigal defines in configure.in and in the
Makefiles to further shorten the cc command lines.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c
f239fefc14226f655477179801c734749a04d4b4 20-Jul-2011 Aditya Kali <adityakali@google.com> e2fsprogs: add quota library to e2fsprogs

This patch adds the quota library (ported form Jan Kara's quota-tools) in
e2fsprogs in order to make quotas as a first class supported feature in Ext4.
This patch also provides interface in lib/quota/mkquota.h that will be used by
mke2fs, tune2fs, e2fsck, etc. to initialize and update quota files.
This first version of the quota library does not support reading existing quota
files. This support will be added in the near future.
Thanks to Jan Kara for his work on quota-tools. Most of the files in this patch
are taken as-is from quota tools and were simply modified to work with
libext2fs in e2fsprogs.

Signed-off-by: Aditya Kali <adityakali@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
/external/e2fsprogs/lib/quota/mkquota.c