linux/fs/ceph
Michal Hocko 752ade68cb treewide: use kv[mz]alloc* rather than opencoded variants
There are many code paths opencoding kvmalloc.  Let's use the helper
instead.  The main difference to kvmalloc is that those users are
usually not considering all the aspects of the memory allocator.  E.g.
allocation requests <= 32kB (with 4kB pages) are basically never failing
and invoke OOM killer to satisfy the allocation.  This sounds too
disruptive for something that has a reasonable fallback - the vmalloc.
On the other hand those requests might fallback to vmalloc even when the
memory allocator would succeed after several more reclaim/compaction
attempts previously.  There is no guarantee something like that happens
though.

This patch converts many of those places to kv[mz]alloc* helpers because
they are more conservative.

Link: http://lkml.kernel.org/r/20170306103327.2766-2-mhocko@kernel.org
Signed-off-by: Michal Hocko <mhocko@suse.com>
Reviewed-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> # Xen bits
Acked-by: Kees Cook <keescook@chromium.org>
Acked-by: Vlastimil Babka <vbabka@suse.cz>
Acked-by: Andreas Dilger <andreas.dilger@intel.com> # Lustre
Acked-by: Christian Borntraeger <borntraeger@de.ibm.com> # KVM/s390
Acked-by: Dan Williams <dan.j.williams@intel.com> # nvdim
Acked-by: David Sterba <dsterba@suse.com> # btrfs
Acked-by: Ilya Dryomov <idryomov@gmail.com> # Ceph
Acked-by: Tariq Toukan <tariqt@mellanox.com> # mlx4
Acked-by: Leon Romanovsky <leonro@mellanox.com> # mlx5
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Anton Vorontsov <anton@enomsg.org>
Cc: Colin Cross <ccross@android.com>
Cc: Tony Luck <tony.luck@intel.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Ben Skeggs <bskeggs@redhat.com>
Cc: Kent Overstreet <kent.overstreet@gmail.com>
Cc: Santosh Raspatur <santosh@chelsio.com>
Cc: Hariprasad S <hariprasad@chelsio.com>
Cc: Yishai Hadas <yishaih@mellanox.com>
Cc: Oleg Drokin <oleg.drokin@intel.com>
Cc: "Yan, Zheng" <zyan@redhat.com>
Cc: Alexander Viro <viro@zeniv.linux.org.uk>
Cc: Alexei Starovoitov <ast@kernel.org>
Cc: Eric Dumazet <eric.dumazet@gmail.com>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-05-08 17:15:13 -07:00
..
acl.c ceph: Propagate dentry down to inode_change_ok() 2016-09-22 10:56:19 +02:00
addr.c ceph: Convert to separately allocated bdi 2017-04-20 12:09:55 -06:00
cache.c ceph: fix spelling mistake: "enabing" -> "enabling" 2017-02-20 12:16:05 +01:00
cache.h ceph: improve fscache revalidation 2016-06-01 10:31:50 +02:00
caps.c sched/headers: Prepare to move signal wakeup & sigpending methods from <linux/sched.h> into <linux/sched/signal.h> 2017-03-02 08:42:32 +01:00
ceph_frag.c
debugfs.c ceph: Convert to separately allocated bdi 2017-04-20 12:09:55 -06:00
dir.c ceph: do a LOOKUP in d_revalidate instead of GETATTR 2017-02-20 12:16:10 +01:00
export.c ceph: add a new flag to indicate whether parent is locked 2017-02-20 12:16:08 +01:00
file.c treewide: use kv[mz]alloc* rather than opencoded variants 2017-05-08 17:15:13 -07:00
inode.c ceph: fix recursion between ceph_set_acl() and __ceph_setattr() 2017-04-25 21:08:26 +02:00
ioctl.c ceph: fix bogus endianness change in ceph_ioctl_set_layout 2017-02-20 12:16:07 +01:00
ioctl.h
Kconfig ceph: add acl for cephfs 2013-12-31 20:32:01 +02:00
locks.c ceph: fix mandatory flock check 2016-10-03 16:13:49 +02:00
Makefile ceph: add acl for cephfs 2013-12-31 20:32:01 +02:00
mds_client.c ceph: tidy some white space in get_nonsnap_parent() 2017-02-23 22:22:02 +01:00
mds_client.h ceph: add a new flag to indicate whether parent is locked 2017-02-20 12:16:08 +01:00
mdsmap.c ceph: check availability of mds cluster on mount 2016-12-12 23:54:27 +01:00
snap.c ceph: record truncate size/seq for snap data writeback 2016-12-12 23:54:27 +01:00
strings.c ceph: handle CEPH_SESSION_REJECT message 2016-10-03 16:13:50 +02:00
super.c ceph: Convert to separately allocated bdi 2017-04-20 12:09:55 -06:00
super.h ceph: Convert to separately allocated bdi 2017-04-20 12:09:55 -06:00
xattr.c ceph: fix non static symbol warning 2016-10-18 12:30:32 +02:00