<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/fs/ecryptfs, branch v3.8</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/fs/ecryptfs?h=v3.8</id>
<link rel='self' href='https://git.amat.us/linux/atom/fs/ecryptfs?h=v3.8'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2012-12-18T16:10:13Z</updated>
<entry>
<title>fs/ecryptfs/crypto.c: make ecryptfs_encode_for_filename() static</title>
<updated>2012-12-18T16:10:13Z</updated>
<author>
<name>Cong Ding</name>
<email>dinggnu@gmail.com</email>
</author>
<published>2012-12-07T22:21:56Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=37028758f92d0a3eb74bcfbecf6bc477072e9e28'/>
<id>urn:sha1:37028758f92d0a3eb74bcfbecf6bc477072e9e28</id>
<content type='text'>
the function ecryptfs_encode_for_filename() is only used in this file

Signed-off-by: Cong Ding &lt;dinggnu@gmail.com&gt;
Signed-off-by: Tyler Hicks &lt;tyhicks@canonical.com&gt;
</content>
</entry>
<entry>
<title>eCryptfs: fix to use list_for_each_entry_safe() when delete items</title>
<updated>2012-12-18T16:07:29Z</updated>
<author>
<name>Wei Yongjun</name>
<email>yongjun_wei@trendmicro.com.cn</email>
</author>
<published>2012-08-21T02:46:05Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=8bbca57cff7f1b1fd046eebd1e9497a00161c2c1'/>
<id>urn:sha1:8bbca57cff7f1b1fd046eebd1e9497a00161c2c1</id>
<content type='text'>
Since we will be removing items off the list using list_del() we need
to use a safer version of the list_for_each_entry() macro aptly named
list_for_each_entry_safe(). We should use the safe macro if the loop
involves deletions of items.

Signed-off-by: Wei Yongjun &lt;yongjun_wei@trendmicro.com.cn&gt;
[tyhicks: Fixed compiler err - missing list_for_each_entry_safe() param]
Signed-off-by: Tyler Hicks &lt;tyhicks@canonical.com&gt;
</content>
</entry>
<entry>
<title>eCryptfs: Avoid unnecessary disk read and data decryption during writing</title>
<updated>2012-11-08T01:56:16Z</updated>
<author>
<name>Li Wang</name>
<email>wangli@kylinos.com.cn</email>
</author>
<published>2012-10-30T11:52:40Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=e4bc6522d53b7b8eb02cfac35fd18275fd86269d'/>
<id>urn:sha1:e4bc6522d53b7b8eb02cfac35fd18275fd86269d</id>
<content type='text'>
ecryptfs_write_begin grabs a page from page cache for writing.
If the page contains invalid data, or data older than the
counterpart on the disk, eCryptfs will read out the
corresponing data from the disk into the page, decrypt them,
then perform writing. However, for this page, if the length
of the data to be written into is equal to page size,
that means the whole page of data will be overwritten,
in which case, it does not matter whatever the data were before,
it is beneficial to perform writing directly rather than bothering
to read and decrypt first.

With this optimization, according to our test on a machine with
Intel Core 2 Duo processor, iozone 'write' operation on an existing
file with write size being multiple of page size will enjoy a steady
3x speedup.

Signed-off-by: Li Wang &lt;wangli@kylinos.com.cn&gt;
Signed-off-by: Yunchuan Wen &lt;wenyunchuan@kylinos.com.cn&gt;
Signed-off-by: Tyler Hicks &lt;tyhicks@canonical.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs</title>
<updated>2012-10-03T03:25:04Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2012-10-03T03:25:04Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=aab174f0df5d72d31caccf281af5f614fa254578'/>
<id>urn:sha1:aab174f0df5d72d31caccf281af5f614fa254578</id>
<content type='text'>
Pull vfs update from Al Viro:

 - big one - consolidation of descriptor-related logics; almost all of
   that is moved to fs/file.c

   (BTW, I'm seriously tempted to rename the result to fd.c.  As it is,
   we have a situation when file_table.c is about handling of struct
   file and file.c is about handling of descriptor tables; the reasons
   are historical - file_table.c used to be about a static array of
   struct file we used to have way back).

   A lot of stray ends got cleaned up and converted to saner primitives,
   disgusting mess in android/binder.c is still disgusting, but at least
   doesn't poke so much in descriptor table guts anymore.  A bunch of
   relatively minor races got fixed in process, plus an ext4 struct file
   leak.

 - related thing - fget_light() partially unuglified; see fdget() in
   there (and yes, it generates the code as good as we used to have).

 - also related - bits of Cyrill's procfs stuff that got entangled into
   that work; _not_ all of it, just the initial move to fs/proc/fd.c and
   switch of fdinfo to seq_file.

 - Alex's fs/coredump.c spiltoff - the same story, had been easier to
   take that commit than mess with conflicts.  The rest is a separate
   pile, this was just a mechanical code movement.

 - a few misc patches all over the place.  Not all for this cycle,
   there'll be more (and quite a few currently sit in akpm's tree)."

Fix up trivial conflicts in the android binder driver, and some fairly
simple conflicts due to two different changes to the sock_alloc_file()
interface ("take descriptor handling from sock_alloc_file() to callers"
vs "net: Providing protocol type via system.sockprotoname xattr of
/proc/PID/fd entries" adding a dentry name to the socket)

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (72 commits)
  MAX_LFS_FILESIZE should be a loff_t
  compat: fs: Generic compat_sys_sendfile implementation
  fs: push rcu_barrier() from deactivate_locked_super() to filesystems
  btrfs: reada_extent doesn't need kref for refcount
  coredump: move core dump functionality into its own file
  coredump: prevent double-free on an error path in core dumper
  usb/gadget: fix misannotations
  fcntl: fix misannotations
  ceph: don't abuse d_delete() on failure exits
  hypfs: -&gt;d_parent is never NULL or negative
  vfs: delete surplus inode NULL check
  switch simple cases of fget_light to fdget
  new helpers: fdget()/fdput()
  switch o2hb_region_dev_write() to fget_light()
  proc_map_files_readdir(): don't bother with grabbing files
  make get_file() return its argument
  vhost_set_vring(): turn pollstart/pollstop into bool
  switch prctl_set_mm_exe_file() to fget_light()
  switch xfs_find_handle() to fget_light()
  switch xfs_swapext() to fget_light()
  ...
</content>
</entry>
<entry>
<title>fs: push rcu_barrier() from deactivate_locked_super() to filesystems</title>
<updated>2012-10-03T01:35:55Z</updated>
<author>
<name>Kirill A. Shutemov</name>
<email>kirill.shutemov@linux.intel.com</email>
</author>
<published>2012-09-26T01:33:07Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=8c0a85377048b64c880e76ec7368904fe46d0b94'/>
<id>urn:sha1:8c0a85377048b64c880e76ec7368904fe46d0b94</id>
<content type='text'>
There's no reason to call rcu_barrier() on every
deactivate_locked_super().  We only need to make sure that all delayed rcu
free inodes are flushed before we destroy related cache.

Removing rcu_barrier() from deactivate_locked_super() affects some fast
paths.  E.g.  on my machine exit_group() of a last process in IPC
namespace takes 0.07538s.  rcu_barrier() takes 0.05188s of that time.

Signed-off-by: Kirill A. Shutemov &lt;kirill.shutemov@linux.intel.com&gt;
Cc: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace</title>
<updated>2012-10-02T18:11:09Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2012-10-02T18:11:09Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=437589a74b6a590d175f86cf9f7b2efcee7765e7'/>
<id>urn:sha1:437589a74b6a590d175f86cf9f7b2efcee7765e7</id>
<content type='text'>
Pull user namespace changes from Eric Biederman:
 "This is a mostly modest set of changes to enable basic user namespace
  support.  This allows the code to code to compile with user namespaces
  enabled and removes the assumption there is only the initial user
  namespace.  Everything is converted except for the most complex of the
  filesystems: autofs4, 9p, afs, ceph, cifs, coda, fuse, gfs2, ncpfs,
  nfs, ocfs2 and xfs as those patches need a bit more review.

  The strategy is to push kuid_t and kgid_t values are far down into
  subsystems and filesystems as reasonable.  Leaving the make_kuid and
  from_kuid operations to happen at the edge of userspace, as the values
  come off the disk, and as the values come in from the network.
  Letting compile type incompatible compile errors (present when user
  namespaces are enabled) guide me to find the issues.

  The most tricky areas have been the places where we had an implicit
  union of uid and gid values and were storing them in an unsigned int.
  Those places were converted into explicit unions.  I made certain to
  handle those places with simple trivial patches.

  Out of that work I discovered we have generic interfaces for storing
  quota by projid.  I had never heard of the project identifiers before.
  Adding full user namespace support for project identifiers accounts
  for most of the code size growth in my git tree.

  Ultimately there will be work to relax privlige checks from
  "capable(FOO)" to "ns_capable(user_ns, FOO)" where it is safe allowing
  root in a user names to do those things that today we only forbid to
  non-root users because it will confuse suid root applications.

  While I was pushing kuid_t and kgid_t changes deep into the audit code
  I made a few other cleanups.  I capitalized on the fact we process
  netlink messages in the context of the message sender.  I removed
  usage of NETLINK_CRED, and started directly using current-&gt;tty.

  Some of these patches have also made it into maintainer trees, with no
  problems from identical code from different trees showing up in
  linux-next.

  After reading through all of this code I feel like I might be able to
  win a game of kernel trivial pursuit."

Fix up some fairly trivial conflicts in netfilter uid/git logging code.

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace: (107 commits)
  userns: Convert the ufs filesystem to use kuid/kgid where appropriate
  userns: Convert the udf filesystem to use kuid/kgid where appropriate
  userns: Convert ubifs to use kuid/kgid
  userns: Convert squashfs to use kuid/kgid where appropriate
  userns: Convert reiserfs to use kuid and kgid where appropriate
  userns: Convert jfs to use kuid/kgid where appropriate
  userns: Convert jffs2 to use kuid and kgid where appropriate
  userns: Convert hpfs to use kuid and kgid where appropriate
  userns: Convert btrfs to use kuid/kgid where appropriate
  userns: Convert bfs to use kuid/kgid where appropriate
  userns: Convert affs to use kuid/kgid wherwe appropriate
  userns: On alpha modify linux_to_osf_stat to use convert from kuids and kgids
  userns: On ia64 deal with current_uid and current_gid being kuid and kgid
  userns: On ppc convert current_uid from a kuid before printing.
  userns: Convert s390 getting uid and gid system calls to use kuid and kgid
  userns: Convert s390 hypfs to use kuid and kgid where appropriate
  userns: Convert binder ipc to use kuids
  userns: Teach security_path_chown to take kuids and kgids
  userns: Add user namespace support to IMA
  userns: Convert EVM to deal with kuids and kgids in it's hmac computation
  ...
</content>
</entry>
<entry>
<title>userns: Convert ecryptfs to use kuid/kgid where appropriate</title>
<updated>2012-09-21T10:13:09Z</updated>
<author>
<name>Eric W. Biederman</name>
<email>ebiederm@xmission.com</email>
</author>
<published>2012-02-08T00:24:33Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=cdf8c58a3546443073cab77d07a88ee439319c19'/>
<id>urn:sha1:cdf8c58a3546443073cab77d07a88ee439319c19</id>
<content type='text'>
Cc: Tyler Hicks &lt;tyhicks@canonical.com&gt;
Cc: Dustin Kirkland &lt;dustin.kirkland@gazzang.com&gt;
Acked-by: Serge Hallyn &lt;serge.hallyn@canonical.com&gt;
Signed-off-by: Eric W. Biederman &lt;ebiederm@xmission.com&gt;
</content>
</entry>
<entry>
<title>eCryptfs: Copy up attributes of the lower target inode after rename</title>
<updated>2012-09-14T16:36:03Z</updated>
<author>
<name>Tyler Hicks</name>
<email>tyhicks@canonical.com</email>
</author>
<published>2012-09-13T19:00:56Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=8335eafc2859e1a26282bef7c3d19f3d68868b8a'/>
<id>urn:sha1:8335eafc2859e1a26282bef7c3d19f3d68868b8a</id>
<content type='text'>
After calling into the lower filesystem to do a rename, the lower target
inode's attributes were not copied up to the eCryptfs target inode. This
resulted in the eCryptfs target inode staying around, rather than being
evicted, because i_nlink was not updated for the eCryptfs inode. This
also meant that eCryptfs didn't do the final iput() on the lower target
inode so it stayed around, as well. This would result in a failure to
free up space occupied by the target file in the rename() operation.
Both target inodes would eventually be evicted when the eCryptfs
filesystem was unmounted.

This patch calls fsstack_copy_attr_all() after the lower filesystem
does its -&gt;rename() so that important inode attributes, such as i_nlink,
are updated at the eCryptfs layer. ecryptfs_evict_inode() is now called
and eCryptfs can drop its final reference on the lower inode.

http://launchpad.net/bugs/561129

Signed-off-by: Tyler Hicks &lt;tyhicks@canonical.com&gt;
Tested-by: Colin Ian King &lt;colin.king@canonical.com&gt;
Cc: &lt;stable@vger.kernel.org&gt; [2.6.39+]
</content>
</entry>
<entry>
<title>eCryptfs: Call lower -&gt;flush() from ecryptfs_flush()</title>
<updated>2012-09-14T16:35:54Z</updated>
<author>
<name>Tyler Hicks</name>
<email>tyhicks@canonical.com</email>
</author>
<published>2012-09-13T01:38:00Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=64e6651dcc10e9d2cc6230208a8e6c2cfd19ae18'/>
<id>urn:sha1:64e6651dcc10e9d2cc6230208a8e6c2cfd19ae18</id>
<content type='text'>
Since eCryptfs only calls fput() on the lower file in
ecryptfs_release(), eCryptfs should call the lower filesystem's
-&gt;flush() from ecryptfs_flush().

If the lower filesystem implements -&gt;flush(), then eCryptfs should try
to flush out any dirty pages prior to calling the lower -&gt;flush(). If
the lower filesystem does not implement -&gt;flush(), then eCryptfs has no
need to do anything in ecryptfs_flush() since dirty pages are now
written out to the lower filesystem in ecryptfs_release().

Signed-off-by: Tyler Hicks &lt;tyhicks@canonical.com&gt;
</content>
</entry>
<entry>
<title>eCryptfs: Write out all dirty pages just before releasing the lower file</title>
<updated>2012-09-14T16:11:29Z</updated>
<author>
<name>Tyler Hicks</name>
<email>tyhicks@canonical.com</email>
</author>
<published>2012-09-13T01:02:46Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7149f2558d5b5b988726662fe58b1c388337805b'/>
<id>urn:sha1:7149f2558d5b5b988726662fe58b1c388337805b</id>
<content type='text'>
Fixes a regression caused by:

821f749 eCryptfs: Revert to a writethrough cache model

That patch reverted some code (specifically, 32001d6f) that was
necessary to properly handle open() -&gt; mmap() -&gt; close() -&gt; dirty pages
-&gt; munmap(), because the lower file could be closed before the dirty
pages are written out.

Rather than reapplying 32001d6f, this approach is a better way of
ensuring that the lower file is still open in order to handle writing
out the dirty pages. It is called from ecryptfs_release(), while we have
a lock on the lower file pointer, just before the lower file gets the
final fput() and we overwrite the pointer.

https://launchpad.net/bugs/1047261

Signed-off-by: Tyler Hicks &lt;tyhicks@canonical.com&gt;
Reported-by: Artemy Tregubenko &lt;me@arty.name&gt;
Tested-by: Artemy Tregubenko &lt;me@arty.name&gt;
Tested-by: Colin Ian King &lt;colin.king@canonical.com&gt;
</content>
</entry>
</feed>
