This project is mirrored from https://github.com/marc0601/stable_android_kernel_samsung_smdk4412.
Pull mirroring updated .
- May 06, 2019
-
-
Ярик authored
Used backport for 3.4, all conflicts resolved. SafetyNet successfully passed on m0. Commits used: vfs: Add setns support for the mount namespace setns support for the mount namespace is a little tricky as an arbitrary decision must be made about what to set fs->root and fs->pwd to, as there is no expectation of a relationship between the two mount namespaces. Therefore I arbitrarily find the root mount point, and follow every mount on top of it to find the top of the mount stack. Then I set fs->root and fs->pwd to that location. The topmost root of the mount stack seems like a reasonable place to be. Bind mount support for the mount namespace inodes has the possibility of creating circular dependencies between mount namespaces. Circular dependencies can result in loops that prevent mount namespaces from every being freed. I avoid creating those circular dependencies by adding a sequence number to the mount namespace and require all bind mounts be of a younger mount namespace into an older mount namespace. Add a helper function proc_ns_inode so it is possible to detect when we are attempting to bind mound a namespace inode. Acked-by:
Serge Hallyn <serge.hallyn@canonical.com> Signed-off-by:
Eric W. Biederman <ebiederm@xmission.com> (cherry picked from commit 8823c07) ---- vfs: Only support slave subtrees across different user namespaces Sharing mount subtress with mount namespaces created by unprivileged users allows unprivileged mounts created by unprivileged users to propagate to mount namespaces controlled by privileged users. Prevent nasty consequences by changing shared subtrees to slave subtress when an unprivileged users creates a new mount namespace. Acked-by:
Serge Hallyn <serge.hallyn@canonical.com> Signed-off-by:
"Eric W. Biederman" <ebiederm@xmission.com> ---- vfs: Allow unprivileged manipulation of the mount namespace. - Add a filesystem flag to mark filesystems that are safe to mount as an unprivileged user. - Add a filesystem flag to mark filesystems that don't need MNT_NODEV when mounted by an unprivileged user. - Relax the permission checks to allow unprivileged users that have CAP_SYS_ADMIN permissions in the user namespace referred to by the current mount namespace to be allowed to mount, unmount, and move filesystems. Acked-by:
"Serge E. Hallyn" <serge@hallyn.com> Signed-off-by:
"Eric W. Biederman" <ebiederm@xmission.com> ---- vfs: Add a user namespace reference from struct mnt_namespace This will allow for support for unprivileged mounts in a new user namespace. Acked-by:
"Serge E. Hallyn" <serge@hallyn.com> Signed-off-by:
"Eric W. Biederman" <ebiederm@xmission.com> ---- proc: Generalize proc inode allocation Generalize the proc inode allocation so that it can be used without having to having to create a proc_dir_entry. This will allow namespace file descriptors to remain light weight entitities but still have the same inode number when the backing namespace is the same. Acked-by:
Serge E. Hallyn <serge.hallyn@ubuntu.com> Signed-off-by:
Eric W. Biederman <ebiederm@xmission.com> ---- proc: Fix the namespace inode permission checks. Change the proc namespace files into symlinks so that we won't cache the dentries for the namespace files which can bypass the ptrace_may_access checks. To support the symlinks create an additional namespace inode with it's own set of operations distinct from the proc pid inode and dentry methods as those no longer make sense. Signed-off-by:
Eric W. Biederman <ebiederm@xmission.com> ---- proc: Usable inode numbers for the namespace file descriptors. Assign a unique proc inode to each namespace, and use that inode number to ensure we only allocate at most one proc inode for every namespace in proc. A single proc inode per namespace allows userspace to test to see if two processes are in the same namespace. This has been a long requested feature and only blocked because a naive implementation would put the id in a global space and would ultimately require having a namespace for the names of namespaces, making migration and certain virtualization tricks impossible. We still don't have per superblock inode numbers for proc, which appears necessary for application unaware checkpoint/restart and migrations (if the application is using namespace file descriptors) but that is now allowd by the design if it becomes important. I have preallocated the ipc and uts initial proc inode numbers so their structures can be statically initialized. Signed-off-by:
Eric W. Biederman <ebiederm@xmission.com> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
- Dec 13, 2018
-
-
marc0601 authored
-
- Nov 27, 2018
-
-
marc0601 authored
-
- Nov 12, 2018
-
-
marc0601 authored
-
- Oct 31, 2018
-
-
marc0601 authored
-
- Oct 21, 2018
-
-
marc0601 authored
-
- Feb 12, 2018
-
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Andrei F authored
This includes the alteration of the load calculation frequency by Klaus Ripke <klaus@ripke.com> "LOAD_FREQ (4*HZ+61) avoids loadavg Moire" http://ripke.com/loadavg/moire But correctly alters the timings for 200 HZ devices as in the mobile space, the original patch is meant for 100 HZ kernels on x86 and other archs. Furthermore, the exponential constants are completely wrong for the same reason, they were caluclated and hardcoded for 100 HZ. From https://lkml.org/lkml/2013/2/1/93 , the exponential math is taken to fully expand the macro behind those values and to be truly HZ independent. The 64bit-ness of the above patch is avoided for our ARM purposes. Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Samuel Pascua authored
This reverts commit e9ad2566.
-
John Stultz authored
With the relase of Lollipop, Android no longer requires the logger driver. There are three patches which the android dev's still need before they drop logger on all their devices: [PATCH v4 1/5] pstores: use scnprintf [PATCH v2 2/5] pstore: remove superfluous memory size check [PATCH 3/5] pstore: handle zero-sized prz in series [PATCH v4 4/5] pstore: add pmsg [PATCH 5/5] pstore: selinux: add security in-core xattr support for pstore and debugfs But these seem to have been acked and are hopefully queued for upstream. So this patch removes the logger driver from staging. Cc: Rom Lemarchand <romlem@google.com>, Cc: Mark Salyzyn <salyzyn@google.com> Cc: Kees Cook <keescook@chromium.org> Cc: Android Kernel Team <kernel-team@android.com> Signed-off-by:
John Stultz <john.stultz@linaro.org> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org> Bug: 13505761 Change-Id: I21b6897f01871851e05b6eb53c7c08a1cb597e3d Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
- Feb 11, 2018
-
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
This reverts commit 2117195c.
-
Samuel Pascua authored
This reverts commit 7e7edb2d.
-
Samuel Pascua authored
This reverts commit 41b32d75.
-
- Feb 10, 2018
-
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Jaegeuk Kim authored
Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Conflicts: fs/f2fs/data.c fs/f2fs/f2fs.h fs/f2fs/inode.c fs/f2fs/shrinker.c fs/f2fs/super.c Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Jaegeuk Kim authored
This patch relocates cached_en not only to be covered by spin_lock, but also to set once after checking out completely. Reviewed-by:
Chao Yu <chao2.yu@samsung.com> Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Jaegeuk Kim authored
Previously, f2fs_update_extent_cache() updates in-memory extent_cache all the time, and then finally preserves its up-to-date extent into on-disk one during f2fs_evict_inode. But, in the following scenario: 1. mount 2. open & write an extent X 3. f2fs_evict_inode; on-disk extent is X 4. open & update the extent X with Y 5. sync; trigger checkpoint 6. power-cut after power-on, f2fs should serve extent Y, but we have an on-disk extent X. This causes a failure on xfstests/311. Reviewed-by:
Chao Yu <chao2.yu@samsung.com> Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Jaegeuk Kim authored
This patch fixes wrong calculation on block address field when an extent is split. Reviewed-by:
Chao Yu <chao2.yu@samsung.com> Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Jaegeuk Kim authored
For newly added fallocate types, it should convert inline_data before handling block swapping. Reviewed-by:
Chao Yu <chao2.yu@samsung.com> Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Jaegeuk Kim authored
Before iput is called, the inode number used by a bad inode can be reassigned to other new inode, resulting in any abnormal behaviors on the new inode. This should not happen for the new inode. Reviewed-by:
Chao Yu <chao2.yu@samsung.com> Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Jaegeuk Kim authored
The write_checkpoint can update stat information, so we should destroy the stat structure after it. Reviewed-by:
Chao Yu <chao2.yu@samsung.com> Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Chao Yu authored
Dirty page can be exist in mapping of newly created symlink, but previously we did not maintain the counting of dirty page for symlink like we maintained for regular/directory, so the counting we lookuped should be wrong. This patch adds missed dirty page counting for symlink to fix this issue. Signed-off-by:
Chao Yu <chao2.yu@samsung.com> Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Markus Elfring authored
The key_put() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by:
Markus Elfring <elfring@users.sourceforge.net> Signed-off-by:
Jaegeuk Kim <jaegeuk@kernel.org> Signed-off-by:
Samuel Pascua <pascua.samuel.14@gmail.com>
-
Samuel Pascua authored
There are still some changes not merged in this kernel. So merge them right now.
-
- Feb 09, 2018
-
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-
Samuel Pascua authored
-