1
0
Fork 0
Commit Graph

45 Commits (09cbfeaf1a5a67bfb3201e0c83c810cecb2efa5a)

Author SHA1 Message Date
Kirill A. Shutemov 09cbfeaf1a mm, fs: get rid of PAGE_CACHE_* and page_cache_{get,release} macros
PAGE_CACHE_{SIZE,SHIFT,MASK,ALIGN} macros were introduced *long* time
ago with promise that one day it will be possible to implement page
cache with bigger chunks than PAGE_SIZE.

This promise never materialized.  And unlikely will.

We have many places where PAGE_CACHE_SIZE assumed to be equal to
PAGE_SIZE.  And it's constant source of confusion on whether
PAGE_CACHE_* or PAGE_* constant should be used in a particular case,
especially on the border between fs and mm.

Global switching to PAGE_CACHE_SIZE != PAGE_SIZE would cause to much
breakage to be doable.

Let's stop pretending that pages in page cache are special.  They are
not.

The changes are pretty straight-forward:

 - <foo> << (PAGE_CACHE_SHIFT - PAGE_SHIFT) -> <foo>;

 - <foo> >> (PAGE_CACHE_SHIFT - PAGE_SHIFT) -> <foo>;

 - PAGE_CACHE_{SIZE,SHIFT,MASK,ALIGN} -> PAGE_{SIZE,SHIFT,MASK,ALIGN};

 - page_cache_get() -> get_page();

 - page_cache_release() -> put_page();

This patch contains automated changes generated with coccinelle using
script below.  For some reason, coccinelle doesn't patch header files.
I've called spatch for them manually.

The only adjustment after coccinelle is revert of changes to
PAGE_CAHCE_ALIGN definition: we are going to drop it later.

There are few places in the code where coccinelle didn't reach.  I'll
fix them manually in a separate patch.  Comments and documentation also
will be addressed with the separate patch.

virtual patch

@@
expression E;
@@
- E << (PAGE_CACHE_SHIFT - PAGE_SHIFT)
+ E

@@
expression E;
@@
- E >> (PAGE_CACHE_SHIFT - PAGE_SHIFT)
+ E

@@
@@
- PAGE_CACHE_SHIFT
+ PAGE_SHIFT

@@
@@
- PAGE_CACHE_SIZE
+ PAGE_SIZE

@@
@@
- PAGE_CACHE_MASK
+ PAGE_MASK

@@
expression E;
@@
- PAGE_CACHE_ALIGN(E)
+ PAGE_ALIGN(E)

@@
expression E;
@@
- page_cache_get(E)
+ get_page(E)

@@
expression E;
@@
- page_cache_release(E)
+ put_page(E)

Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Acked-by: Michal Hocko <mhocko@suse.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-04-04 10:41:08 -07:00
Oleg Drokin c56e256d50 staging/lustre/include: Adjust comment style
This fixes most of the
"Block comments use a trailing */ on a separate line" checkpatch
warnings, also some slight reformats of structures or comments
at places.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-25 22:05:50 -08:00
Oleg Drokin d2a13989d2 staging/lustre/include: Adjust NULL comparison codestyle
All instances of "x == NULL" are changed to "!x" and
"x != NULL" to "x"

Also remove some redundant assertions.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20 14:33:11 -08:00
Andreas Dilger 1dc563a682 staging: lustre: update Intel copyright messages 2015
Update copyright messages in files modified by Intel employees
in 2015 by non-trivial patches.  Exclude patches that are only
deleting code, renaming functions, or adding or removing whitespace.

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7243
Reviewed-on: http://review.whamcloud.com/16758
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-12-21 15:38:00 -08:00
Mike Rapoport 242b532500 staging: lustre: remove unused OBD_PAGE_ALLOC/FREE and friends
The OBD_PAGE_ALLOC/FREE and related macros are not used and can be
removed

Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-27 14:35:29 +09:00
Mike Rapoport 185938e06f staging: lustre: remove unused OBD_SLAB_ALLOC* and OBD_SLAB_FREE* macros
The OBD_SLAB_ALLOC* and OBD_SLAB_FREE* macros are not used and can be
removed.

Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24 18:46:17 -07:00
Mike Rapoport 4490ff89b1 staging: lustre: remove unused OBD_SLAB_CPT_ALLOC* macros
The OBD_SLAB_CPT_ALLOC* macros are not used and can be removed

Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24 18:44:26 -07:00
Shraddha Barke 673536c988 Staging: lustre: obd_support.h: Remove unused OBD_SLAB_FREE_RTN0
Remove macro OBD_SLAB_FREE_RTN0 since it is defined but not used

Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16 22:34:06 -07:00
Mike Rapoport 106495c41f staging: lustre: remove multiple blank lines
Fixes checkpatch.pl CHECK:LINE_SPACING: Please don't use multiple blank
lines.

The patch is generated using checkpatch.pl --fix-inplace:

for f in $(find drivers/staging/lustre/ -type f) ; do
    ./scripts/checkpatch.pl --types "LINE_SPACING" --test-only=multiple \
    --fix-inplace  -f $f
done

Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-13 10:21:10 -07:00
Oleg Drokin bea5820d7a staging/lustre: remove obd_memory stats counter
Now that we no longer track allocated memory, remove
obd_memory statistics counter and all references to it everywhere

Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-16 20:32:14 -07:00
Oleg Drokin 9ea9d6652b staging/lustre: Remove lustre used memory tracking framework
Lustre memory allocation framework has a feature to track amount
of allocated memory, but since it's not being used consistently anymore
and is on the way out in general, just remove it.

Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-16 20:32:14 -07:00
Oleg Drokin 543d5f3d28 staging/lustre: Remove memory allocation fault injection framework
Lustre memory allocation wrappers also included a fault injection
framework that's totally redundant, since in-kernel offering is
actually superior to what we had.
So let's remove it.

Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-16 20:32:13 -07:00
Oleg Drokin e1708ad714 staging/lustre: Remove unused OBD_ALLOC* and OBD_FREE macros
This removes now unused OBD_ALLOC, OBD_ALLOC_GFP, OBD_ALLOC_PTR,
OBD_ALLOC_LARGE and supporting infrastructure.
Also OBD_FREE, OBD_FREE_PTR, OBD_FREE_LARGE and supporting infrastructure.

Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-16 20:32:13 -07:00
Oleg Drokin 35eaf88724 staging/lustre: Remove stray bit of userland utils code
The UTILS are userland and I see it's causing confusion
with things beging already converted to kmalloc,
so just remove it.

Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-16 20:32:13 -07:00
Oleg Drokin f6173fe0be staging/lustre: Remove unused OBD_CPT_ALLOC* macros
OBD_CPT_ALLOC and friends are no longer used, so remove them.

Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-16 20:32:10 -07:00
Oleg Drokin 8800d8cf7e staging/lustre: Remove unused OBD_VMALLOC
These macros are not used anymore, so let's remove them,
also __OBD_VMALLOC_VEROBSE and OBD_CPT_VMALLOC

Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-16 20:32:09 -07:00
Oleg Drokin 6fd57333de staging/lustre: Remove OBD_CPT_ALLOC_LARGE
Remove OBD_CPT_ALLOC_LARGE define and convert the only user to
libcfs_kvzalloc_cpt.

Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-16 20:32:09 -07:00
Mike Rapoport 910b551c85 staging: lustre: fix TRAILING_STATEMENTS checkpatch errors
Move trailing statements to be on the next line to fix the
TRAILING_STATEMENTS checkpatch error.

Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:44 -07:00
Mike Rapoport b2952d62ba staging: lustre: fix whitespace errors reported by checkpatch.pl
Added/removed spaces and replaced '+1' with '1' in several places to
eliminate SPACING and POINTER_LOCATION errors reported by checkpatch.pl

Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:39 -07:00
Joe Perches 8150a97fdd staging: lustre: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignments

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:48:34 -07:00
Dmitry Eremin 323b0b2c1e staging/lustre/libcfs: Remove redundant enums and sysctl moduleparams
/proc/sys/lnet/lnet_memused
Remove memory tracking for LNet.
Remove redundant enums definition.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-13 19:47:20 -07:00
Oleg Drokin 082a33441f staging/lustre: Remove unneeded ldlm_timeout control
ldlm_timeout is used server-side to determine AST timeouts,
so it makes no sense on the client, esp. since it's not really used
anywhere.
Remove all traces of it except from the config where make
it a noop.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-13 19:47:20 -07:00
Dmitry Eremin e4ba525e8f staging/lustre/obd: final removal of procfs stuff
Signed-off-by: Dmitry Eremin <dmiter4ever@gmail.com>
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-31 15:26:38 +09:00
Arnd Bergmann 7f804436fb staging: lustre: remove unused variable warning
A recent patch to simplify the lustre large memory allocation
causes new warnings as an unintended side-effect:

lustre/lov/lov_request.c: In function 'lov_finish_set':
lustre/lov/lov_request.c:78:7: warning: unused variable 'len' [-Wunused-variable]
   int len = set->set_oabufs * sizeof(*set->set_pga);
       ^
lustre/obdclass/acl.c: In function 'lustre_ext_acl_xattr_reduce_space':
lustre/obdclass/acl.c:123:6: warning: unused variable 'old_size' [-Wunused-variable]
  int old_size = CFS_ACL_XATTR_SIZE(old_count, ext_acl_xattr);
      ^

The reason is that the 'size' argument to OBD_FREE_LARGE()
is never needed, which was previously hidden by the extra
abstractions.

This avoids the warnings by adding a cast to void, to tell
the compiler that the argument is intentionally unused.
A better fix is probably to remove the entire set of allocation
macros and open-code the normal kernel interface calls.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 99d56ff7c1 ("staging/lustre: Always try kmalloc first for OBD_ALLOC_LARGE")
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-31 09:42:27 +09:00
Oleg Drokin 99d56ff7c1 staging/lustre: Always try kmalloc first for OBD_ALLOC_LARGE
Create libcfs_kvzalloc and libcfs_kvzalloc_cpt that
are designed to replace OBD_ALLOC_LARGE and OBD_CPT_ALLOC_LARGE.

Not a drop-in replacement as they also take gfp flags armument
for more flexibility.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10 15:03:13 +02:00
John L. Hammond 91b3aaf991 staging/lustre: remove lvfs.h
Move the definition of struct lvfs_run_ctxt to the one file that
needed it (lustre/include/obd.h). Remove the then unneeded headers
lustre/include/lvfs.h and lustre/include/linux/lvfs.h.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-09-11 14:45:01 -07:00
John L. Hammond 6cc9e6124d staging/lustre: remove linux/obd_support.h
Remove the superfluous header lustre/include/linux/obd_support.h.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-30 12:19:34 -07:00
Greg Donald 1d8cb70c7b drivers: staging: lustre: Fix space required after that ',' errors
Fix checkpatch.pl space required after that ',' errors

Signed-off-by: Greg Donald <gdonald@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-30 12:05:39 -07:00
Greg Donald a58a38ac0d drivers: staging: lustre: Fix space required before the open parenthesis '(' errors
Fix checkpatch.pl space required before the open parenthesis '(' errors

Signed-off-by: Greg Donald <gdonald@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-30 11:59:52 -07:00
Fan Yong f261f48a39 staging/lustre/ldlm: drop redundant ibits lock interoperability check
In very old release (older than Lustre-1.8), if the client talks with
the server that does not support ibits lock, then the client needs to
convert it as plain lock. Such interoperability check and convertion
is out of date for a long time. Drop it.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Reviewed-on: http://review.whamcloud.com/11004
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4971
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: wangdi <di.wang@intel.com>
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-17 09:38:42 -07:00
Greg Kroah-Hartman f267cdb464 staging: lustre: use CONFIG_PROC_FS
Don't rely on a "custom" LPROCFS define, it's not needed, just check for
the real thing.  This will let us delete a whole .h file that is not
being used for anything other than one #define.

Cc: Andreas Dilger <andreas.dilger@intel.com>
Cc: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-07-12 21:13:25 -07:00
Greg Kroah-Hartman b0f5aad587 staging: lustre: remove LPU64 define
Just use the proper modifier type...

Cc: Andreas Dilger <andreas.dilger@intel.com>
Cc: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-07-12 20:25:57 -07:00
Greg Kroah-Hartman 1accaadf2a staging: lustre: fix include relative paths
In drivers/staging/lustre/lustre/include there was a bunch of .h files
relying on ccflags to be set up right.  Make all of them proper relative
paths so that ccflags for different subdirs can be now removed.

Cc: Andreas Dilger <andreas.dilger@intel.com>
Cc: Oleg Drokin <oleg.drokin@intel.com>
Cc: hpdd-discuss <hpdd-discuss@lists.01.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-07-11 21:34:24 -07:00
Greg Kroah-Hartman 9fdaf8c0b9 staging: lustre: remove top level ccflags variable
We need to remove the ccflags from the Lustre code as it prevents
individual object files from building properly in the kernel build
system.  It also hids the horrid mess that the Lustre include files are
made up of.

Start out by removing the toplevel ccflags variable pointing to
drivers/staging/lustre/include/ as a valid include path.  This requires
the absolute include markings of a bunch of .h and .c files, which is
also done here.

Cc: Andreas Dilger <andreas.dilger@intel.com>
Cc: Oleg Drokin <oleg.drokin@intel.com>
Cc: hpdd-discuss <hpdd-discuss@lists.01.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-07-11 20:51:16 -07:00
Ann Koehler 0be19afa74 staging/lustre: restore __GFP_WAIT flag to memalloc calls
In Lustre 2.4, the flags passed to the memory allocation functions are
translated from CFS enumeration values types to the kernel GFP
values by calling cfs_alloc_flags_to_gfp(). This function adds
__GFP_WAIT to all flags except CFS_ALLOC_ATOMIC. In 2.5, when
the cfs wrappers were dropped, cfs_alloc_flags_to_gfp() was
removed and the CFS_ALLOC_xxxx was simply replaced with __GFP_xxxx.
This means that most memory allocation calls are missing the
__GFP_WAIT flag. The result is that Lustre experiences more ENOMEM
errors, many of which the higher levels of Lustre do not handle
robustly.
Notes GFP_NOFS = __GFP_WAIT | __GFP_IO. So the patch replaces
__GFP_IO with GFP_NOFS.
Patch does not add __GFP_WAIT to GFP_IOFS. GFP_IOFS was not used in
Lustre 2.4 so it has never been used with __GFP_WAIT.

Signed-off-by: Ann Koehler <amk@cray.com>
Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Reviewed-on: http://review.whamcloud.com/9223
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4357
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-27 10:23:15 -07:00
Masanari Iida bd9070cb99 staging: lustre: Fix typo in lustre/include part2
This path fix spelling typo in lustre/include.

Signed-off-by: Masanari Iida <standby24x7@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-08 19:33:11 -08:00
Peng Tao 9d2834ddae staging/lustre: fix undefined reference if CONFIG_PROC_FS is off
When building Lustre with CONFIG_PROC_FS off, we'll get many errors like:

drivers/staging/lustre/lustre/obdclass/llog_test.c:1053: error: implicit declaration of function ‘lprocfs_llog_test_init_vars’
make[3]: *** [drivers/staging/lustre/lustre/obdclass/llog_test.o] Error 1
make[2]: *** [drivers/staging/lustre/lustre/obdclass] Error 2
make[2]: *** Waiting for unfinished jobs....
  CC [M]  drivers/staging/lustre/lustre/ptlrpc/ptlrpcd.o
drivers/staging/lustre/lustre/ptlrpc/pinger.c: In function ‘ptlrpc_pinger_main’:
drivers/staging/lustre/lustre/ptlrpc/pinger.c:331: error: implicit declaration of function ‘obd_update_maxusage’

The patch defines following symbols when CONFIG_PROC_FS is off:
fld_type_proc_dir, obd_update_maxusage(), obd_max_pages, obd_max_alloc, obd_alloc,
obd_pages, lprocfs_llog_test_init_vars().

Signed-off-by: Peng Tao <bergwolf@gmail.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-04 15:28:10 -08:00
Andrew Perepechko 7fc1f831d8 staging/lustre/llite: extended attribute cache
This patch implements an extended attribute cache for
a Lustre client. It is organized as a write-through
cache: reads are performed from cache, updates are sent
synchronously to the MDS. An additional inode bit
MDS_INODELOCK_XATTR is added to protect the cache.

Lustre-change: http://review.whamcloud.com/5537
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2869
Signed-off-by: Andrew Perepechko <andrew_perepechko@xyratex.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
[remove extra GPL notice in original patch as kernel already has one
and it causes checkpatch error. -- Peng Tao]
Signed-off-by: Peng Tao <bergwolf@gmail.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-03 08:45:29 -08:00
Fan Yong c0ac76d9bc staging/lustre/scrub: OI scrub on OST
Main part of original patch in Lustre tree
(http://review.whamcloud.com/6669) changes server code and
is unneeded by client. The patch only picks up common
functions and data structures change.

Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3335
Lustre-change: http://review.whamcloud.com/6669
Signed-off-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Signed-off-by: Peng Tao <bergwolf@gmail.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-03 08:45:29 -08:00
Mikhail Pershin 65f1c7816d staging/lustre/server: use unified request handler for MGS
- Unify request handler. It finds target for particular request and
  calls appropriate handler for it. Generic handlers are moved to
  the unified target code. The tgt_session_info is introduced to
  store all request-related data and passed to all handlers.
- Pack reply in llog server functions early and use err_serious()
- remove obsoleted llog_origin_handle_cancel(), it is not used
  anymore
- remove push_ctxt/pop_ctxt from llog server function, it is based
  on OSD now.

Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2145
Lustre-change: http://review.whamcloud.com/4826
Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Signed-off-by: Peng Tao <bergwolf@gmail.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-11-25 19:08:16 -08:00
Joe Perches ec83e611c2 staging: lustre: Use parenthesis around sizeof
Convert sizeof foo to sizeof(foo) to be more kernel style compatible.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-10-14 09:34:15 -07:00
Fan Yong c6c9f60d9d staging/lustre/lfsck: LFSCK 1.5 technical debts (3)
Original patch resolves some LFSCK 1.5 technical debts, including:
1) Check and remove repeated linkea entries.
2) Merge some "goto" branches to make the code more readable.
3) Some comments about object's nlink inconsistency processing.

This patch picks the obd flags change.

Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2915
Lustre-change: http://review.whamcloud.com/6344
Signed-off-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Peng Tao <tao.peng@emc.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-07-23 13:35:50 -07:00
Peng Tao 49c02a7570 staging/lustre: clean up and remove libcfs/linux/linux-mem.c
Those are simple wrappers for numa allocator. We don't need them.

Signed-off-by: Peng Tao <tao.peng@emc.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-06-03 11:32:51 -07:00
Oleg Drokin c52f69c578 staging/lustre: Revert "LU-2139 osc: Track and limit "unstable" pages"
This seems to be causing multiple issues: LU-3274, LU-3277

[The original commit is folded in the large Lusre patch. So we don't
have an exact commit to revert for kernel client -- Peng Tao]
Signed-off-by: Peng Tao <tao.peng@emc.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-06-03 11:26:34 -07:00
Peng Tao d7e09d0397 staging: add Lustre file system client support
Lustre is the most deployed distributed file system
in the HPC (High Performance Computing) world. The patch
adds its client side support.

The code is not very clean and needs to live in drivers/staging
for some time for continuing cleanup work. See
drivers/staging/lustre/TODO for details.

The code is based on Lustre master commit faefbfc04

commit faefbfc0460bc00f2ee4c1c1c86aa1e39b9eea49
Author: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Date:   Tue Apr 30 23:05:21 2013 +0400

    LU-3244 utils: tunefs.lustre should preserve virgin label

Plus a few under-review patches on Whamcloud gerrit:
3.8 kernel support:
http://review.whamcloud.com/#change,5973
http://review.whamcloud.com/#change,5974
http://review.whamcloud.com/#change,5768
http://review.whamcloud.com/#change,5781
http://review.whamcloud.com/#change,5763
http://review.whamcloud.com/#change,5613
http://review.whamcloud.com/#change,5655

3.9 kernel support:
http://review.whamcloud.com/#change,5898
http://review.whamcloud.com/#change,5899

Kconfig/Kbuild:
http://review.whamcloud.com/#change,4646
http://review.whamcloud.com/#change,4644

libcfs cleanup:
http://review.whamcloud.com/#change,2831
http://review.whamcloud.com/#change,4775
http://review.whamcloud.com/#change,4776
http://review.whamcloud.com/#change,4777
http://review.whamcloud.com/#change,4778
http://review.whamcloud.com/#change,4779
http://review.whamcloud.com/#change,4780

All starting/trailing whitespaces are removed, to match kernel
coding style. Also ran scripts/cleanfile on all lustre source files.

[maked the Kconfig depend on BROKEN as the recent procfs changes causes
this to fail - gregkh]

Signed-off-by: Peng Tao <tao.peng@emc.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-05-14 13:54:50 -04:00