Whamcloud - gitweb
fs/lustre-release.git
10 years agoLU-4199 libcfs: add CPU table functions for uniprocessor 73/8873/3
Li Xi [Tue, 4 Feb 2014 13:41:49 +0000 (08:41 -0500)]
LU-4199 libcfs: add CPU table functions for uniprocessor

Some CPU table functions for uniprocessor architecture is
missing.

Signed-off-by: Li Xi <lixi@ddn.com>
Signed-off-by: James Simmons <uja.ornl@gmail.com>
Change-Id: I2b41af63ebb5e4a1362e026d75b87855c1e7e2fa
Reviewed-on: http://review.whamcloud.com/8873
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3963 libcfs: convert ptlrpc,quota plus others to linux atomics 77/7077/11
Peng Tao [Thu, 27 Feb 2014 13:59:46 +0000 (08:59 -0500)]
LU-3963 libcfs: convert ptlrpc,quota plus others to linux atomics

This patch converts all cfs_atomic primitives in
liblustre, osp, ptlrpc and quota.

Signed-off-by: Liu Xuezhao <xuezhao.liu@emc.com>
Signed-off-by: Peng Tao <tao.peng@emc.com>
Signed-off-by: James Simmons <uja.ornl@gmail.com>
Change-Id: If21fdd31441d4b2a23df8cbd9db8187bb827ab2f
Reviewed-on: http://review.whamcloud.com/7077
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
10 years agoLU-4086 tests: strengthen sanity-hsm/test_33 00/9600/8
Bruno Faccini [Wed, 12 Mar 2014 13:12:33 +0000 (14:12 +0100)]
LU-4086 tests: strengthen sanity-hsm/test_33

Instead of waiting+checking both Restore and Cancel HSM operations
sequentially, wait for both to be finished and then check each
results. This will allow to handle conditions where Restore
terminates before the Cancel is started.

Also added to wait_all_done() the capability to only work on
requests for a specific fid.

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I480ce074513d6829ecb3078c273bac1fdffa6256
Reviewed-on: http://review.whamcloud.com/9600
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4759 build: Remove obsolete file. Documentation was removed from the tree FDL... 70/9770/3
Cliff White [Mon, 24 Mar 2014 22:01:04 +0000 (15:01 -0700)]
LU-4759  build: Remove obsolete file. Documentation was removed from the tree FDL needs to be removed also.

Signed-off-by: Cliff White <cliff.white@intel.com>
Change-Id: I7c57491416460af6bbce4c355b4b16888427e73c
Reviewed-on: http://review.whamcloud.com/9770
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4679 liblustre: remove dead code and clean headers 29/9429/5
John L. Hammond [Thu, 27 Feb 2014 23:43:08 +0000 (17:43 -0600)]
LU-4679 liblustre: remove dead code and clean headers

In liblustre, remove statically unused functions, varaibles and
macros. Also ensure that the headers needed by the c and h files are
included at top level. Prune unneeded includes. In libsysio, include
sys/queue.h in fs.h.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I878b442b6d0ae17d8d5d33375ca7596618323c52
Reviewed-on: http://review.whamcloud.com/9429
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4585 out: memset(ta, 0) will cause memory leak 04/9804/2
wang di [Wed, 26 Mar 2014 16:01:58 +0000 (09:01 -0700)]
LU-4585 out: memset(ta, 0) will cause memory leak

thandle_exec_args should not be memset to 0 in
out_trans_start or out_handle, otherwise ta_args
will never be released.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I3b6a8dc8c62af743015f6022afdeda14264574c8
Reviewed-on: http://review.whamcloud.com/9804
Tested-by: Jenkins
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-2675 lustre: remove lustre/include/ioctl.h 57/9757/2
John L. Hammond [Sun, 23 Mar 2014 18:34:15 +0000 (13:34 -0500)]
LU-2675 lustre: remove lustre/include/ioctl.h

Remove the nowhere included header lustre/include/ioctl.h.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: Ie059084c0e4ffb946694fc0a170f9200f12dda89
Reviewed-on: http://review.whamcloud.com/9757
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4462 mdt: don't apply mdt_object_fid() to ERR_PTRs 88/8788/3
John L. Hammond [Thu, 9 Jan 2014 19:09:49 +0000 (13:09 -0600)]
LU-4462 mdt: don't apply mdt_object_fid() to ERR_PTRs

In mdt_reconstruct_open(), mdt_reconstruct_create(), and
mdt_reconstruct_setattr() print the FID from the request rather than
applying mdt_object_fid() to a known ERR_PTR.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: Ifb9365dbef1492d8fb5c7ff27d00f5155b0e7525
Reviewed-on: http://review.whamcloud.com/8788
Tested-by: Jenkins
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4655 libcfs: properly (un)define CDEBUG_ENTRY_EXIT 17/9517/2
John L. Hammond [Wed, 5 Mar 2014 22:06:55 +0000 (16:06 -0600)]
LU-4655 libcfs: properly (un)define CDEBUG_ENTRY_EXIT

In lustre-libcfs.m4 we defined CDEBUG_ENTRY_EXIT to 1 or 0 according
to whether libcfs-trace was enabled. But in libcfs_debug.h we tested
CDEBUG_ENTRY_EXIT using #ifdef and enabled the trace macros
accrodingly. Fix this and use CDEBUG_ENTRY_EXIT to control GOTO()
tracing as well. The ability to properly disable these macros will
make some static analyses easier.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: Ia016b4ddd45f8c39704a84908665757aa17bd3d2
Reviewed-on: http://review.whamcloud.com/9517
Tested-by: Jenkins
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4747 tests: Call get_param from MDS 81/9581/2
James Nunez [Tue, 11 Mar 2014 15:07:03 +0000 (09:07 -0600)]
LU-4747 tests: Call get_param from MDS

In sanity tests 120a, b, c, d, e, f and g,
"lctl get_param ldlm.services.ldlm_canceld.stats" is
called from the client, but these stats are only
on the MDS.

Adding do_facet to the MDS gets the necessary stats.

Signed-off-by: James Nunez <james.a.nunez@intel.com>
Change-Id: I6b8434960bf5ec5e1220460612a583f2ab763980
Reviewed-on: http://review.whamcloud.com/9581
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
10 years agoLU-4742 mdd: improve error messages in obf_lookup() 94/9594/2
Niu Yawei [Wed, 12 Mar 2014 06:06:04 +0000 (02:06 -0400)]
LU-4742 mdd: improve error messages in obf_lookup()

To make user able to understand that's just an invalid operation
in .lustre/fid, but not a serious error.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I928cdf61ae6a70c0ff5bbe1133338c54cd997aa2
Reviewed-on: http://review.whamcloud.com/9594
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4065 mdt: missing NL in CERROR format 97/9597/2
Bruno Faccini [Wed, 12 Mar 2014 08:36:20 +0000 (09:36 +0100)]
LU-4065 mdt: missing NL in CERROR format

Add a missing 'n' at the end of the CERROR format parameter to
avoid annoying "format at mdt_coordinator.c:977:mdt_hsm_cdt_start
doesn't end in newline" msg in syslog and the consequence of 2
merged lines/traces in Lustre debug-log.

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: Ic8baf81886b5be3de32ee595be99e20428729f6d
Reviewed-on: http://review.whamcloud.com/9597
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
10 years agoLU-4674 endianness: Fix __{LITTLE,BIG}_ENDIAN macro usage 41/9641/4
Swapnil Pimpale [Thu, 13 Mar 2014 11:11:07 +0000 (16:41 +0530)]
LU-4674 endianness: Fix __{LITTLE,BIG}_ENDIAN macro usage

Fixed the userspace code where __{LITTLE,BIG}_ENDIAN is tested
with #ifdef. This patch replaces those checks
with #if __BYTE_ORDER == __{LITTLE,BIG}_ENDIAN

Signed-off-by: Swapnil Pimpale <spimpale@ddn.com>
Change-Id: I92d4cf0c880d8032ea5023cb47ccfe7236dd03ab
Reviewed-on: http://review.whamcloud.com/9641
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4738 lmv: access lum_stripe_offset as little endian 71/9671/2
John L. Hammond [Fri, 14 Mar 2014 16:01:32 +0000 (11:01 -0500)]
LU-4738 lmv: access lum_stripe_offset as little endian

By the time that a struct lmv_user_md reaches lmv_placement_policy()
it has already been converted to little endian. Therefore use the
appropriate macros around accesses to this this field. This issue was
found by rewriting the definition of struct lmv_user_md to use the
__leXX typedefs and running sparse.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: If641375eabd22cc3e935a2e8f1327c48081c6ed1
Reviewed-on: http://review.whamcloud.com/9671
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Swapnil Pimpale <spimpale@ddn.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4780 lnet: NI shutdown may loop forever 06/9706/2
Liang Zhen [Tue, 18 Mar 2014 12:55:28 +0000 (20:55 +0800)]
LU-4780 lnet: NI shutdown may loop forever

lnet_shutdown_lndnis() may enter endless loop if there is a busy NI,
this is injected by LNet SMP improvements. It's fixed in this patch.

Signed-off-by: Liang Zhen <liang.zhen@intel.com>
Change-Id: I612ab9ff15aa40c05d6bd4cfee7cd107715f41b4
Reviewed-on: http://review.whamcloud.com/9706
Tested-by: Jenkins
Reviewed-by: Isaac Huang <he.huang@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-2982 build: make AC check for linux arch sandbox friendly 58/9458/2
Dmitry Eremin [Mon, 3 Mar 2014 15:06:04 +0000 (19:06 +0400)]
LU-2982 build: make AC check for linux arch sandbox friendly

I didn't found any usage of LINUXARCH definition in sources now.
But this check is problematic in sandbox. Therefore, I removed
it from sources at all.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: Ibdf0a3c26950a59d7f9cc51687d725d9c8835374
Reviewed-on: http://review.whamcloud.com/9458
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alexey Shvetsov <alexxy@gentoo.org>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4629 libcfs: fix issues found by Klocwork Insight tool 00/9400/7
Dmitry Eremin [Wed, 26 Feb 2014 08:20:03 +0000 (12:20 +0400)]
LU-4629 libcfs: fix issues found by Klocwork Insight tool

sscanf format specification '%u' expects type 'unsigned int *'
for 'u', but parameter 3 has a different type 'int*'.

Pointer 'cfs_crypto_hash_type(d->hd_hash->ha_id)' returned from
call to function 'cfs_crypto_hash_type' at line 261 may be NULL
and will be dereferenced at line 261.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: I9945a7e5d44329aa6417946106212cb269395290
Reviewed-on: http://review.whamcloud.com/9400
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4629 obdclass: fix use after release 88/9388/3
Dmitry Eremin [Tue, 25 Feb 2014 20:17:24 +0000 (00:17 +0400)]
LU-4629 obdclass: fix use after release

Pointer 'type->typ_name' checked for NULL at line 195 will be passed
to function and may be dereferenced there by passing argument 1 to
function 'lprocfs_try_remove_proc_entry' at line 246.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: I697ffab97a5bd1ab55339722d87a3dfca5c1e173
Reviewed-on: http://review.whamcloud.com/9388
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4629 mdc: fix issue found by Klocwork Insight tool 87/9387/4
Dmitry Eremin [Tue, 25 Feb 2014 18:41:26 +0000 (22:41 +0400)]
LU-4629 mdc: fix issue found by Klocwork Insight tool

Pointer 'mod' checked for NULL at line 160 may be dereferenced at line 208.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: I130de2f5b2066b8797e2454d4a603f53b3ffcbef
Reviewed-on: http://review.whamcloud.com/9387
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4629 lnet: fix issues found by Klocwork Insight tool 86/9386/5
Dmitry Eremin [Tue, 25 Feb 2014 18:44:09 +0000 (22:44 +0400)]
LU-4629 lnet: fix issues found by Klocwork Insight tool

Null pointer 'cp' that comes from line 2544 may be dereferenced
at line 2618.

Pointer 'ni' checked for NULL at line 1569 may be passed to
function and may be dereferenced there by passing argument 1 to
function 'lnet_ni_notify_locked' at line 1621.

Null pointer 'best_iface' that comes from line 802 may be
dereferenced at line 832.

Buffer overflow of string buffer due to non null terminated string.

sscanf format specification '%lx' expects type 'unsigned long int *'
for 'x', but parameter 4 has a different type 'long int*'.

Pointer 'tsc' returned from call to function 'sfw_find_test_case'
at line 571 may be NULL and will be dereferenced at line 572.

sscanf format specification '%i' expects type 'int *' for 'i',
but parameter 3 has a different type 'unsigned int*'.

Local variable 'hash' is never used.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: I2a942735cd93906453b92dcc711a956b7adf5615
Reviewed-on: http://review.whamcloud.com/9386
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Isaac Huang <he.huang@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4629 ldlm: fix NULL pointer dereference 23/9323/4
Dmitry Eremin [Thu, 20 Feb 2014 08:39:30 +0000 (12:39 +0400)]
LU-4629 ldlm: fix NULL pointer dereference

Pointer '*exp' returned from call to function 'class_conn2export'
at line 523 may be NULL and may be dereferenced at line 543.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: I084ae2ae76861aef4fd93477551bc9d0dd5f4478
Reviewed-on: http://review.whamcloud.com/9323
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4496 build: enable RPMs build with --disable-modules 06/9306/4
Dmitry Eremin [Wed, 19 Feb 2014 11:42:38 +0000 (15:42 +0400)]
LU-4496 build: enable RPMs build with --disable-modules

Enable the following RPMs build:
  ./configure --disable-modules
  make rpms

Addition to commit c92afbcd4a8234994affa444d59645b80fa19ec5
(Reviewed-on: http://review.whamcloud.com/6020)

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: I7b26fac928404a75e974b414085bf1a584ad8bb9
Reviewed-on: http://review.whamcloud.com/9306
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Christopher J. Morrone <chris.morrone.llnl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4614 llite: remove lustre_generic_file_{read,write} 30/9230/2
Jinshan Xiong [Tue, 11 Feb 2014 19:58:32 +0000 (11:58 -0800)]
LU-4614 llite: remove lustre_generic_file_{read,write}

It looks like lustre_generic_file_{read,write} are a holdover from
2.6.19 where generic_file_aio_read() replaced generic_file_readv()
and cross-kernel interoperability was required for some period of
time. Lustre has since removed support for those older kernels, but
it looks like the wrappers were not deleted at that time. This patch
will delete them.

Pass &iocb->ki_pos as the last argument for these functions instead
of crw_pos, since this is the convention for other callers.  Verify
that this is the same as the current crw_pos argument.  This code can
likely be cleaned up further in a later patch.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: Id19edacf93ee2538634feb95580ab885f6069ee7
Reviewed-on: http://review.whamcloud.com/9230
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
10 years agoLU-3059 lu: shrink lu_object_header by 8 bytes on x86_64 85/9185/2
Andreas Dilger [Sat, 8 Feb 2014 03:33:02 +0000 (20:33 -0700)]
LU-3059 lu: shrink lu_object_header by 8 bytes on x86_64

Locate the loh_flags and loh_ref fields together in lu_object_header
to avoid holes and shrink the structure by 8 bytes.

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: I36b6132a819b6557d6d1688adb3e1f7d282d22b5
Reviewed-on: http://review.whamcloud.com/9185
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4596 lprocfs: mdt/*/exports/*/uuid is empty after remount 71/9171/4
Andriy Skulysh [Thu, 6 Feb 2014 22:50:08 +0000 (00:50 +0200)]
LU-4596 lprocfs: mdt/*/exports/*/uuid is empty after remount

need to assign exp_nid_stats even if old stats are present

Change-Id: I9b0ac4c7ccee6cbd457827b20123bf40d91aaf33
Xyratex-bug-id: MRP-1641
Signed-off-by: Andriy Skulysh <Andriy_Skulysh@xyratex.com>
Reviewed-on: http://review.whamcloud.com/9171
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Emoly Liu <emoly.liu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3254 llite: access layout version under a lock 89/8689/2
Jinshan Xiong [Tue, 31 Dec 2013 21:49:33 +0000 (13:49 -0800)]
LU-3254 llite: access layout version under a lock

We used to access layout version under the protection of ldlm
lock, this introduces extra overhead for dlm lock matching.

In this patch, lli_layout_lock is introduced to access the layout
version. Also, when a layout lock is losing, we should tear down
mmap of the correspoding inode to avoid stale data accessing in the
future.

This is part of technical verification of replication.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I657c6a8b27f2cdaf468dc208c43c1d92f3843705
Reviewed-on: http://review.whamcloud.com/8689
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-1538 tests: unmount /sbin/mount.lustre bind mount 12/8912/4
Andreas Dilger [Sat, 18 Jan 2014 05:30:16 +0000 (22:30 -0700)]
LU-1538 tests: unmount /sbin/mount.lustre bind mount

If the lustre/utils/mount.lustre file has changed since it was bind
mounted on /sbin/mount.lustre, unmount it and mount the new one
there, to avoid strange problems when testing from a local tree

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: Ie5360dae9f33553acb914c8ce549e848c1500c1e
Reviewed-on: http://review.whamcloud.com/8912
Tested-by: Jenkins
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4446 tests: block on layout lock fix up on sanityn:51c 89/8789/4
Jinshan Xiong [Thu, 9 Jan 2014 20:32:13 +0000 (12:32 -0800)]
LU-4446 tests: block on layout lock fix up on sanityn:51c

Fixed two problems: set fail_loc on MDS and block at layout lock
by writing the test file.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I8028e855aad5882981a313fb28ec5b87f593832b
Reviewed-on: http://review.whamcloud.com/8789
Tested-by: Jenkins
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3373 osd-ldiskfs: readdir replace by iterate 31/8231/11
yangsheng [Thu, 27 Feb 2014 14:19:21 +0000 (22:19 +0800)]
LU-3373 osd-ldiskfs: readdir replace by iterate

Use iterate instead of readdir callback in iop.

Signed-off-by: yang sheng <yang.sheng@intel.com>
Change-Id: Icb08292009c965ca693814e854ae2e77b3e7a4f0
Reviewed-on: http://review.whamcloud.com/8231
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Jenkins
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Peng Tao <bergwolf@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4167 tests: update version check to conf-sanity test_32 32/8132/11
Emoly Liu [Sun, 2 Mar 2014 19:06:56 +0000 (03:06 +0800)]
LU-4167 tests: update version check to conf-sanity test_32

This patch updates version check codes to skip running LFSCK on an
OST for versions >= 2.5.0 in conf-sanity.sh test_32.

Test-Parameters: testlist=conf-sanity envdefinitions=SLOW=yes, ONLY=32 ossjob=lustre-b2_4 mdsjob=lustre-b2_4 ossbuildno=71 mdsbuildno=71 clientdistro=el6 ossdistro=el6 mdsdistro=el6 clientarch=x86_64 ossarch=x86_64 mdsarch=x86_64
Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Change-Id: Ibc0c34a0c15f4882a0dd06dae75d1f1fe10b6f16
Reviewed-on: http://review.whamcloud.com/8132
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-4585 out: remove OBJECT_UPDATE_PER_RPC_MAX limit. 90/9590/4
wang di [Tue, 11 Mar 2014 15:38:24 +0000 (08:38 -0700)]
LU-4585 out: remove OBJECT_UPDATE_PER_RPC_MAX limit.

Extend tx_args if the update inside 1 RPC is more than
the count of tx_args count in tgt_thread_info.

And also for create remote object, the remote RPC might
happen in trans stop, so we need to add return value
for mdd_trans_stop to track the error.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: Ibb87181d87dfb6c3ed7e6757592bccd4a836a98a
Reviewed-on: http://review.whamcloud.com/9590
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
10 years agoLU-4108 tests: decrease load for zfs in performance-sanity/4 25/9725/2
Nathaniel Clark [Wed, 19 Mar 2014 14:33:32 +0000 (10:33 -0400)]
LU-4108 tests: decrease load for zfs in performance-sanity/4

Given the poor performance of metadata on ZFS (cf LU-2600), this patch
decreases the number of files created (similar to what happens in
perforamnce-scale.sh).

Test-Parameters: mdtfilesystemtype=zfs ostfilesystemtype=zfs  mdsfilesystemtype=zfs testlist=performance-sanity
Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: I998c8525bf218dacad07d98ac842f4c12102cd9a
Reviewed-on: http://review.whamcloud.com/9725
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
10 years agoLU-4777 lfsck: redefine LFSCK_RBTREE_BITMAP_MASK 03/9703/2
Fan Yong [Tue, 4 Mar 2014 11:40:48 +0000 (19:40 +0800)]
LU-4777 lfsck: redefine LFSCK_RBTREE_BITMAP_MASK

It should be the rbtree bitmap bits size, not the bytes size.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: I0c090702f3f2f5037926d6384b605751a0a9c948
Reviewed-on: http://review.whamcloud.com/9703
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
10 years agoLU-4775 lfsck: dump all visibile lfsck parameter correctly 90/9690/2
Fan Yong [Tue, 4 Mar 2014 06:19:41 +0000 (14:19 +0800)]
LU-4775 lfsck: dump all visibile lfsck parameter correctly

We missed to handle "LPF_BROADCAST" and "LPF_ORPHAN" when dump
the lfsck parameters and caused the output via /proc interface
incomplete and bad formatted.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: I462c79e80be5b384a291b30980a95698a8dd9d19
Reviewed-on: http://review.whamcloud.com/9690
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
10 years agoLU-4611 osd: improve credits calculation 58/9258/15
Alex Zhuravlev [Thu, 13 Feb 2014 19:55:43 +0000 (23:55 +0400)]
LU-4611 osd: improve credits calculation

- llog catalog do not declare records twice (for old and new objects)
  this might be an issue on ZFS with full debug enabled..
- llog to specify append by pos=-1, so OSD can take this into account
- object create/destroy should not include OI, this is calculated yet
- EA declaration to improve few specific cases
- osd_declare_write() to recognize overwrite optimistically,
  using inode size and i_blocks
- osd_declare_write() to optimize very specific cases, like legacy
  blockmaps with small offsets and allocated indirects
- index delete modify just a single block

preliminary testing on a local setup with 7 OSTs:
1360 credits before and 436 credits after.

llog declarations and index inserts (part of llog object creation)
still consume about 70% (7 OSTs):
   create: 7/28, destroy: 1/4
   attr_set: 2/2, xattr_set: 8/21
   write: 37/179, punch: 14/56, quota 2/2
   insert: 8/135, delete: 2/5
   ref_add: 1/1, ref_del: 3/3

Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Change-Id: Icb5c79df1f8ba248509b9d2561ac8843bb01f6af
Reviewed-on: http://review.whamcloud.com/9258
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4624 statahead: Improve statahead debug messages 60/9360/3
Christopher J. Morrone [Thu, 20 Feb 2014 19:08:44 +0000 (11:08 -0800)]
LU-4624 statahead: Improve statahead debug messages

The statahead debug messages include the pid of the current
process in their body.  This is both redudant (because all
lustre log messages contain the pid), and sometimes downright
misleading.  For instance the messages would say something like
"stopping statahead thread 3446".  One would probably think
that 3446 is the pid of the process that is being stopped,
but in fact it was the pid of the caller issuing the stop signal.

We remove all superfluous pids from the messages.

Next we have the ll_statahead_thread() and the ll_agl_thread() record
their respective pids in their respective ptlrpc_thread structures.
This allows to print the pid of the thread that we are trying to
stop (which is actually useful info) from other threads, such as those
calling ll_stop_statahead().

Change-Id: Id4def179e02e9097f3f22048192d45bdf15b0aa8
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/9360
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4778 llog: update catlog when plain log destroyed 02/9702/5
Niu Yawei [Tue, 18 Mar 2014 09:04:18 +0000 (05:04 -0400)]
LU-4778 llog: update catlog when plain log destroyed

When the empty plain log is destroyed while processing
catlog, we should call llog_cat_cleanup() to close the
plain log and update in catlog.

Intel-bug-id: INTL-64

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I97b1d5cc59e84fdb4888274b48f223a063293647
Reviewed-on: http://review.whamcloud.com/9702
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4200 mgs: fix counting of mgs exports 50/9650/3
Nathaniel Clark [Thu, 13 Mar 2014 19:31:41 +0000 (15:31 -0400)]
LU-4200 mgs: fix counting of mgs exports

In only_mgs_is_running iterate over mgs exports and only count
non-self and non MDS-MDS exports.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: I145d897fe2f222dae5e998de322ea58ac9f75375
Reviewed-on: http://review.whamcloud.com/9650
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-4028 quota: fix output of 'lfs quota' 07/8407/4
Niu Yawei [Wed, 27 Nov 2013 03:27:01 +0000 (22:27 -0500)]
LU-4028 quota: fix output of 'lfs quota'

Fix the output of 'lfs quota' when '-h' option is specified:
- total allocated block limit should be converted after calculation;
- show 1~3 digit after the decimal point;

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I90a8087dc15153c1b0b895c8081fe2882d6d01e6
Reviewed-on: http://review.whamcloud.com/8407
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-3489 osd-zfs: object iterator support 49/7149/27
Alex Zhuravlev [Sat, 27 Jul 2013 20:07:57 +0000 (00:07 +0400)]
LU-3489 osd-zfs: object iterator support

a trivial object iterator for ZFS using dmu_object_next().
the iterator skips all objects with no LMA EA. It does
implement simple prefetching algoright. It also enables
few tests in sanity-lfsck to be run with ZFS.

Test-Parameters: mdtfilesystemtype=zfs \
    ostfilesystemtype=zfs mdsfilesystemtype=zfs \
    testlist=sanity-scrub,sanity-lfsck
Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Change-Id: Icf02342ac351a163e23575963d3366761c59b02b
Reviewed-on: http://review.whamcloud.com/7149
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
10 years agoLU-4743 osp: continue llog processing 74/9574/3
Alex Zhuravlev [Tue, 11 Mar 2014 05:10:01 +0000 (09:10 +0400)]
LU-4743 osp: continue llog processing

when unexpected record type is met

Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Change-Id: I3dd45f501192bc6dd3bfddb550fd455ae319b923
Reviewed-on: http://review.whamcloud.com/9574
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
10 years agoLU-4624 llite: Avoid statahead thread start/stop deadlocks 58/9358/4
Christopher J. Morrone [Fri, 21 Feb 2014 22:46:47 +0000 (14:46 -0800)]
LU-4624 llite: Avoid statahead thread start/stop deadlocks

The statahead and statahead agl threads blindly set their
thread state to SVC_RUNNING without checking the state first.  If, for
instance, another thread sets the state to SVC_STOPPING that
stop signal will now have been lost.  Deadlock ensues.

We also partly improve the sai reference counting, because a race exists
where the ll_stop_statahead thread can drop the default reference, and
the statahead thread can exit and drop its reference as well.  With no
references on the sai, the final put will poison and free the buffer.  The
original do_statahead_enter() function may then continue to access
the buffer after it is freed because it did not take a reference of its
own.  We add a local reference to address that.

Change-Id: I531f17966d49ba1e6ebd99abe9cb8b128eeac4f9
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/9358
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4398 mdt: acquire an open lock for write or execute 63/9063/3
John L. Hammond [Thu, 30 Jan 2014 17:07:13 +0000 (11:07 -0600)]
LU-4398 mdt: acquire an open lock for write or execute

In mdt_object_open_lock() opens for write or execute will always
acquire an open lock of the appropriate mode so that any conflicting
cached open locks on other clients will be canceled. Add a regression
test to sanityn.sh.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I8092bca4c418ec99a25584abdfb635ffec19a26e
Reviewed-on: http://review.whamcloud.com/9063
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-2524 tests: enable conf-sanity/58 on ZFS 75/9675/2
Nathaniel Clark [Fri, 14 Mar 2014 20:39:21 +0000 (16:39 -0400)]
LU-2524 tests: enable conf-sanity/58 on ZFS

Fix mount/unmount of MDS so test runs correctly on ZFS MDS.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Ifb9bd12fdecdc38132dfc487f565b67f7ade4123
Reviewed-on: http://review.whamcloud.com/9675
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Isaac Huang <he.huang@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
10 years agoLU-4767 lfsck: sub-task thread should not change lc_link 61/9661/2
Fan Yong [Fri, 28 Feb 2014 20:35:09 +0000 (04:35 +0800)]
LU-4767 lfsck: sub-task thread should not change lc_link

The lfsck sub-task thread (for double scan) should not change the
"lfsck_component:lc_link" which may cause the master lfsck engine
thread to access some unexpected RAM space by race.

LFSCK should not return -ENODEV to avoid to misguide ptlrpc.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Ifb80eaf7c1c4ba9bf7fbd5213e9eae09efed7e28
Reviewed-on: http://review.whamcloud.com/9661
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4721 obdclass: handle local storage init/fini properly 73/9573/3
Fan Yong [Tue, 25 Feb 2014 18:43:26 +0000 (02:43 +0800)]
LU-4721 obdclass: handle local storage init/fini properly

1) In local_oid_storage_fini(), take the mutex on ls_device
   before decreasing the 'los' reference to avoid others to
   obtain the mutex earlier and freed the 'los' by race.

2) When llog init the local stroage for FID_SEQ_LLOG and
   FID_SEQ_LLOG_NAME, it should record the handlers which
   can be used to fini them to avoid releasing the handler
   which is in using by others.

3) NOT forget the llog_ctxt_put() if something wrong during
   the llog_osd_setup().

4) NOT put the object in lastid_compat_check() until all the
   usages on such object have been done.

Test-Parameters: envdefinitions=SLOW=yes,ENABLE_QUOTA=yes testlist=sanity-scrub,sanity-scrub,sanity-scrub,sanity-scrub
Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Ibf139cf9783d06276a6c0ed764c40dec6e3f70cb
Reviewed-on: http://review.whamcloud.com/9573
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3852 tests: disable test_251 from inside sanity-hsm 14/9014/4
Bruno Faccini [Mon, 27 Jan 2014 18:55:31 +0000 (19:55 +0100)]
LU-3852 tests: disable test_251 from inside sanity-hsm

Due to test_251 frequent failures, subtest has been disabled at
the autotests config level. To be able to work on a patch to fix
the root cause (likely to be a pure consequence when running on
a too small-sized Lustre filesystem), subtest will be disabled
from inside sanity-hsm to allow autotests config changes to be
reverted and to re-enable it on a per-patch basis.

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I7dfae4d278cba049062480c276f9cad10d22e0e9
Reviewed-on: http://review.whamcloud.com/9014
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-4704 test: enable acl 974 and 2561 series test 41/9541/4
Emoly Liu [Mon, 3 Mar 2014 04:19:05 +0000 (12:19 +0800)]
LU-4704 test: enable acl 974 and 2561 series test

Add acl/{974,974_remote,2561,2561_zfs}.test to the
lustre/tests/Makefile.am nobase_noinst_DATA list, and fix acl/run
test to fail if the test scripts are missing.
acl/2561_zfs.test is a newly created test file for zfs. Since zfs
allocates a 512 byte dnode for empty file, its "ls -s" result is
different from ldiskfs'.

Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Change-Id: I11be072eb1954fff3b7a19231b82345b3073a534
Reviewed-on: http://review.whamcloud.com/9541
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
10 years agoLU-4453 build: warn on deprecated cfs_* uses 85/9585/2
John L. Hammond [Tue, 11 Mar 2014 20:15:16 +0000 (15:15 -0500)]
LU-4453 build: warn on deprecated cfs_* uses

In contrib/scripts/checkpatch.pl, use static dictionaries of
deprecated identifiers and headers rather than reading from the
kernel's Documentation/feature-removal-schedule.txt file. Populate the
deprecated identifiers dictionary with the cfs_{atomic,hlist,list}_*
macros, some out of fashion typedefs, and a few unsafe functions.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I5af33e33693d6da59b98890ae2f27d95adcd8710
Reviewed-on: http://review.whamcloud.com/9585
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Peng Tao <bergwolf@gmail.com>
Reviewed-by: Li Xi <pkuelelixi@gmail.com>
Tested-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-4752 build: add gerrit_checkpatch.py to contrib/scripts/ 86/9586/3
John L. Hammond [Tue, 11 Mar 2014 20:45:17 +0000 (15:45 -0500)]
LU-4752 build: add gerrit_checkpatch.py to contrib/scripts/

Add a python script gerrit_checkpatch.py to contrib/scripts/ which
polls for recently updated changes, runs checkpatch.pl on them, and
pushes reviews back to gerrit.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I9e3c9990288b8adc8f507a6b2294f2a53991a0e8
Reviewed-on: http://review.whamcloud.com/9586
Tested-by: Jenkins
Reviewed-by: Richard Henwood <richard.henwood@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
10 years agoLU-4770 tests: tests scripts simplification 68/9668/4
Dmitry Eremin [Mon, 17 Mar 2014 20:33:19 +0000 (00:33 +0400)]
LU-4770 tests: tests scripts simplification

1. Xeon Phi don't support "mount -t lustre", we can use only
   "mount.lustre" utility.
2. A "head" utility don't support shortcut "-1" option.
   It should be specified as "-n 1".
3. A "sed" utility don't support expression "s/[-.]/ /3"

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: Ib5ba22451819772ebacb38706447403ae6668cc4
Reviewed-on: http://review.whamcloud.com/9668
Tested-by: Jenkins
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4719 mdt: Don't try to print non-existent objects 20/9520/3
Oleg Drokin [Thu, 6 Mar 2014 01:56:38 +0000 (20:56 -0500)]
LU-4719 mdt: Don't try to print non-existent objects

mdt_dump_lmm() needs to make sure it's not trying to print
objects for a default striping from a directory, since there
are not objects in this case.

Return early if the D_INFO debug mask is disenabled, so it
doesn't iterate through the LOV/LMV layout at all.  That is
just a waste of effort.

Change-Id: I2fffdaefad2a6b05247676441451fffdca620dcd
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/9520
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Reviewed-by: Matt Ezell <ezellma@ornl.gov>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
10 years agoLU-4252 osd: remove locking i_mutex in osd_punch 44/9644/3
yangsheng [Tue, 18 Mar 2014 14:57:59 +0000 (22:57 +0800)]
LU-4252 osd: remove locking i_mutex in osd_punch

This piece of code intent to calm down the kernel
WARN_ON messsage show up since 3.9 upstream. So we
can just remove it for now. We'll add a ldiskfs
patch to resolve this issue while 3.9 server support
come up.

Change-Id: Ied941b98d213e3aff1c5ba7ec4c6436bdef903c7
Signed-off-by: yang sheng <yang.sheng@intel.com>
Reviewed-on: http://review.whamcloud.com/9644
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-2675 cleanup: const correct FID/OSTID/... helpers 41/8641/5
John L. Hammond [Fri, 20 Dec 2013 20:01:58 +0000 (14:01 -0600)]
LU-2675 cleanup: const correct FID/OSTID/... helpers

Add a const qualifier wherever possible to the pointer parameters of
the inline helper functions in lustre_idl.h and lustre_fid.h. Change
the return type of several predicate functions from int to bool.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: Ibe590d7184470cfe8a154fe0935a7d6bea261669
Reviewed-on: http://review.whamcloud.com/8641
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoNew tag 2.6.57 2.5.57 2.6.57 v2_5_57 v2_5_57_0 v2_6_57 v2_6_57_0
Oleg Drokin [Wed, 19 Mar 2014 07:22:40 +0000 (03:22 -0400)]
New tag 2.6.57

Change-Id: I58633c93179d37500989b54ecd53e3b715e5f2b2

10 years agoLU-4753 endianness: Fix cpu_to_leXX size mismatch 37/9637/2
Swapnil Pimpale [Thu, 13 Mar 2014 06:46:41 +0000 (12:16 +0530)]
LU-4753 endianness: Fix cpu_to_leXX size mismatch

In lod_prep_md_striped_create() and lod_xattr_set_lmv we use
cpu_to_le32() to transfer __u16 values. This patch replaces
cpu_to_le32() with cpu_to_le16().

Signed-off-by: Swapnil Pimpale <spimpale@ddn.com>
Change-Id: Icc33e3fac711b63cc9d67fcec82dd1b4fdc10cce
Reviewed-on: http://review.whamcloud.com/9637
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
10 years agoLU-4748 test: get one single qos_threshold_rr number 80/9580/3
Emoly Liu [Tue, 11 Mar 2014 23:05:01 +0000 (07:05 +0800)]
LU-4748 test: get one single qos_threshold_rr number

In sanity.sh test_116b, if there are multiple MDTs on the same MDS,
we should get one single qos_threshold_rr number instead of the array,
otherwise it will cause resetting qos_threshold_rr failure.

Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Change-Id: Ie779769f7ee35cd118fb6412fe3352a03254b9d3
Reviewed-on: http://review.whamcloud.com/9580
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-3534 out: only start transaction for modified update 83/7983/27
wang di [Mon, 16 Dec 2013 17:21:16 +0000 (09:21 -0800)]
LU-3534 out: only start transaction for modified update

Only start transaction, if the update will modify the
filesystem.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I9c516b5fe6f6bc743e1dbc69ab04fd7062b2311d
Reviewed-on: http://review.whamcloud.com/7983
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3338 llite: Limit reply buffer size 39/6339/16
Brian Behlendorf [Tue, 14 May 2013 22:39:04 +0000 (15:39 -0700)]
LU-3338 llite: Limit reply buffer size

When allocating a reply buffer for the striping information don't
assume the unlikely worst case.  Instead, assume the common case
and size the buffer based on the observed default ea/cookie size.

The default size is initialized to a single stripe and allowed to
grow up to an entire page if needed.  This means that for smallish
filesystems (less than ~21 OSTs) where the worst case striping
information can fit in a single page there is effectively no
change.  Only for larger filesystem will the default be less than
the maximum.  This has a number of advantages.

* By limiting the default reply buffer size we avoid always
  vmalloc()'ing the buffer because it exceeds four pages in size
  and instead kmalloc() it.  This prevents the client from
  thrashing on the global vmalloc() spin lock.

* A reply buffer of exactly the right size (no larger) is allocated
  in the overflow case.  These larger reply buffers are still
  unlikely to exceed the 16k limit where a vmalloc() will occur.

* Saves memory in the common case.  Wide striped files exceeded
  the default are expected to be the exception.

The reason this patch works is because the ptlrpc layer is smart
enough to reallocate the reply buffer when an overflow occurs.
Therefore the client doesn't have to drop the incoming reply and
send a new request with a larger reply buffer.

It's also worth mentioning that the reply buffer always contains
a significant amount of extra padding because they are rounded up
to the nearest power of two.  This means that even files striped
wider than the default have a good chance of fitting in the
allocated reply buffer.

Also remove client eadatasize check in mdt xattr packing because
as said above client can handle -EOVERFLOW.

Change-Id: Ic6bab2aca208db1f4abcd87974a5879d06d0f2f1
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-on: http://review.whamcloud.com/6339
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
10 years agoLU-4769 tests: conf-sanity/38 fix regression 69/9669/2
Nathaniel Clark [Fri, 14 Mar 2014 14:09:46 +0000 (10:09 -0400)]
LU-4769 tests: conf-sanity/38 fix regression

stop_mds on zfs exports the pool.  Use mount_fstype that accounts for
importing pool if needed.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Id3fbfc61af032aaaca1030a5927bd509725a0f21
Reviewed-on: http://review.whamcloud.com/9669
Tested-by: Jenkins
Reviewed-by: Isaac Huang <he.huang@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-4728 mdt: fix NULL deference of mdt_fid_lock 43/9543/2
Li Xi [Fri, 7 Mar 2014 04:32:12 +0000 (12:32 +0800)]
LU-4728 mdt: fix NULL deference of mdt_fid_lock

When enabling hsm_control, mti_exp field of struct mdt_thread_info
could be NULL.  ldlm_cli_enqueue_local will crash the kernel when
dereference it.

Signed-off-by: Li Xi <lixi@ddn.com>
Change-Id: I4bdb8222aec378e396e7f544834f6fcf9fdaf777
Reviewed-on: http://review.whamcloud.com/9543
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3539 osp: Fix a series of UPDATE_OBJ endianness bugs 88/7088/34
Li Wei [Tue, 23 Jul 2013 15:19:49 +0000 (23:19 +0800)]
LU-3539 osp: Fix a series of UPDATE_OBJ endianness bugs

Current UPDATE_OBJ code have the following problems:

  - Fields in "struct update_buf", except for ub_bufs, are sent in
    senders' host endianness but expected to be little-endian by
    receivers.

  - Fields in "struct update", except for u_bufs, are sent in
    little endianness but used without swabbing by receivers.

  - Most u_bufs are sent in little endianness, but some are in
    senders' host endianness.

  - Sizes for a couple of string buffers in osp_md_declare_xattr_set()
    and osp_md_xattr_get() are off-by-one.

  - Error numbers in UPDATE_OBJ replies are not translated on both
    sides.

This patch fixes them by sending all data in UPDATE_OBJ requests and
replies in host endianness, following Lustre's usual practices.

Change-Id: Id3ffb248af181b4beff2b62c9cb46fc6d9f9e673
Signed-off-by: Li Wei <wei.g.li@intel.com>
Reviewed-on: http://review.whamcloud.com/7088
Tested-by: Jenkins
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4751 hsm: Fix sanity-hsm tests for non-mrsh $PDSH 87/9587/2
Michael MacDonald [Tue, 11 Mar 2014 04:37:14 +0000 (00:37 -0400)]
LU-4751 hsm: Fix sanity-hsm tests for non-mrsh $PDSH

The workaround for starting backgrounded copytool
monitors via pdsh -Rmrsh is not compatible with non-mrsh
values of $PDSH. This commit adds a branch such that
the workaround is only used when required by the test
cluster environment.

Signed-off-by: Michael MacDonald <michael.macdonald@intel.com>
Change-Id: I35a57d26a3836cfd1bbb698d267a8fe9f31f86c8
Reviewed-on: http://review.whamcloud.com/9587
Tested-by: Jenkins
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4320 mdt: fixup MDS_SWAP_LAYOUTS ELC handling 29/9329/2
John L. Hammond [Thu, 20 Feb 2014 15:58:51 +0000 (09:58 -0600)]
LU-4320 mdt: fixup MDS_SWAP_LAYOUTS ELC handling

In mdc_ioc_swap_layouts() cancel *any* unused locks with LAYOUT or
XATTR IBITS set on the two files. (This matches the locks acquired in
mdt_swap_layouts(). Previously only locks that conflicted with a CR
LAYOUT lock were cancelled.) Add HABEO_CLAVIS to the target handler
flags for MDS_SWAP_LAYOUTS and call ldlm_request_cancel() from
mdt_swap_layouts() to do the intended early lock cancellation before
the handler acquires its own locks.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I9d7ba9ac660b136dafa7e307177b92204a1257c3
Reviewed-on: http://review.whamcloud.com/9329
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4682 llite: a few fixes for migration. 22/9522/5
wang di [Fri, 28 Feb 2014 15:52:58 +0000 (07:52 -0800)]
LU-4682 llite: a few fixes for migration.

1. Clear the client dentry cache before migrating file/directory
to the remote MDT.

2. Do not return stripe information to client, it did not get
Layout lock.

3. A few cleanups from the review of 6662.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I209079dfa07241412878b30fd02e8152046c95c7
Reviewed-on: http://review.whamcloud.com/9522
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
10 years agoLU-4591 lov: cancel ungranted sub lock 24/9524/2
Jinshan Xiong [Thu, 6 Mar 2014 06:45:47 +0000 (22:45 -0800)]
LU-4591 lov: cancel ungranted sub lock

When the top lock is canceled due to error, we should cancel
ungranted sub lock otherwise the sublock state is undefined.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I5c1df5220ce77ff434463d6443135c625e79ea04
Reviewed-on: http://review.whamcloud.com/9524
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4703 tests: Add test to check setxattr fails when it should 08/9508/5
Nathaniel Clark [Wed, 5 Mar 2014 17:36:52 +0000 (12:36 -0500)]
LU-4703 tests: Add test to check setxattr fails when it should

Setxattr was not correctly checking permissions in all cases. This
adds a test to sanity to ensure that trying to set xattrs on a file
fails when it should.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Id95e13ec3bcbedb7cbb069c610d506d1f3d899a8
Reviewed-on: http://review.whamcloud.com/9508
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-4384 ofd: remove INCOMPAT_SUPP, ROCOMPAT_SUPP defines 75/9375/4
Mikhail Pershin [Tue, 25 Feb 2014 08:13:01 +0000 (12:13 +0400)]
LU-4384 ofd: remove INCOMPAT_SUPP, ROCOMPAT_SUPP defines

Removed ROCOMPAT/INCOMPAT_SUPP defines from MDT and OFD as
obsoleted. They are not used now. The tgt_server_data_init()
uses own way to set/check rocompat/incompat masks

Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: Ib4b7b4b948e0563d1cc89faae2d423245ed4df0e
Reviewed-on: http://review.whamcloud.com/9375
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
10 years agoLU-4545 hsm: Always report errors to coordinator. 10/9310/2
Henri Doreau [Wed, 19 Feb 2014 14:49:41 +0000 (15:49 +0100)]
LU-4545 hsm: Always report errors to coordinator.

Make sure feedback on processed items gets properly delivered to the
coordinator even if errors occur between action item delivery and
item processing initialization phase.

Signed-off-by: Henri Doreau <henri.doreau@cea.fr>
Change-Id: If1dfc88e4acb9fbd6bfb5b2d18ffdd4979944997
Reviewed-on: http://review.whamcloud.com/9310
Tested-by: Jenkins
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-2785 osc: remove unused obd methods 47/8547/5
John L. Hammond [Wed, 26 Feb 2014 23:48:13 +0000 (17:48 -0600)]
LU-2785 osc: remove unused obd methods

Remove the unused methods osc_punch(), osc_sync(), osc_brw(),
osc_enqueue(), osc_cancel(), osc_llog_init(), osc_llog_finish(), and
their supporting functions. Remove the file obd_ost.h, moving all of
the structures defined there to osc_request.c. Remove several orphaned
obd methods.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I4148547c52625cb7b173f1b835c9e6e47e19e4f6
Reviewed-on: http://review.whamcloud.com/8547
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4643 hsm: Improve sanity-hsm test_60 34/9534/2
Michael MacDonald [Thu, 6 Mar 2014 17:25:24 +0000 (12:25 -0500)]
LU-4643 hsm: Improve sanity-hsm test_60

Small fix to further reduce the chance of false failures.
Also cleans up example HSM events in comments to address style
warnings.

Signed-off-by: Michael MacDonald <michael.macdonald@intel.com>
Change-Id: Icecb69ddc417cd33f80b38c9df623ac5fc0cc466
Reviewed-on: http://review.whamcloud.com/9534
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4724 hsm: Safe copytool event logging 53/9553/5
Michael MacDonald [Fri, 7 Mar 2014 16:18:10 +0000 (11:18 -0500)]
LU-4724 hsm: Safe copytool event logging

Protect against concurrent event log writes by multiple
threads within a copytool process. Fixes sanity-hsm test_71
failures.

Signed-off-by: Michael MacDonald <michael.macdonald@intel.com>
Change-Id: Ie18f7368f386acf0949a038e6bdb2ba7dca5c3a3
Reviewed-on: http://review.whamcloud.com/9553
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3953 rpm: stop using unnecessary file lists 89/5489/5
James Simmons [Mon, 9 Dec 2013 17:14:52 +0000 (12:14 -0500)]
LU-3953 rpm: stop using unnecessary file lists

File lists are being generated for unconditonally packaged files.

RPM can handle both static and dynamic file lists, so let's use them.
It simplifies the spec file quite a bit.

There are also some files that are treated as being conditionally
included but the conditions are always true:

- lustre_types.h was removed in commit adde80ff (v1.9.50)
- libcfsutil.a was made unconditional in commit b279ac68 (v2.3.51)
- include/lustre/lustre_idl.h was added in commit 11330397 (v1.7.100)

I've removed the conditionals surrounding these and moved them into
the static file lists.

Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Signed-off-by: James Simmons <uja.ornl@gmail.com>
Change-Id: I3f08a40f3ffef468723b366848ed5645c4cb9de9
Reviewed-on: http://review.whamcloud.com/5489
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4708 ldiskfs: do not copy NUL terminator from direntry 10/9510/2
Andreas Dilger [Wed, 5 Mar 2014 18:59:30 +0000 (11:59 -0700)]
LU-4708 ldiskfs: do not copy NUL terminator from direntry

Do not try to copy a NUL terminator from the source dirent if there
is no dir_data for that record.  This can happen with 1.x filesystems
that do not have a dirdata field in the dirent to store the FID.

The target buffer is expected to be NUL terminated, and this is
handled by using kzalloc() to allocate it and zero out the buffer,
but the source buffer may not have a trailing NUL byte if it is a
multiple of 4 bytes in length.

If the dirent is aligned at the end of the directory block/page this
can cause an oops by accessing beyond the end of the page, or will
otherwise copy a garbage byte to the target buffer.

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: Iab52f916d7571b3d2587255280c72a52c60399c9
Reviewed-on: http://review.whamcloud.com/9510
Tested-by: Jenkins
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4381 lov: to not hold sub locks at initialization 52/9152/4
Jinshan Xiong [Thu, 6 Feb 2014 06:49:23 +0000 (22:49 -0800)]
LU-4381 lov: to not hold sub locks at initialization

Otherwise, it will cause deadlock because it essentially holds
some sub locks and then to request others in an arbitrary order.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I00d51677aa94ec41856402fd8a027e09355786ee
Reviewed-on: http://review.whamcloud.com/9152
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3274 osc: allow to call brw_commit() multiple times 15/8215/2
Jinshan Xiong [Fri, 8 Nov 2013 03:58:19 +0000 (19:58 -0800)]
LU-3274 osc: allow to call brw_commit() multiple times

Sometimes the rq_commit_cb of BRW RPC can be called twice if that RPC
has already committed at reply time. This will cause inaccuracy of
unstable pages accounting and then assertion.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: Ic596e1d44e2c27bf13701d2c6c9691562beb7e58
Reviewed-on: http://review.whamcloud.com/8215
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Prakash Surya <surya1@llnl.gov>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4627 llite: deed taking lli_trunc_sem during file write 67/9267/4
Bobi Jam [Thu, 13 Feb 2014 15:27:41 +0000 (23:27 +0800)]
LU-4627 llite: deed taking lli_trunc_sem during file write

File write before io loop will take lli_trun_sem read semaphore to
protect osc_extent, while after generic_file_aio_write() done, it
could possible need to kill suid or sgid, which will call
ll_setattr_raw() to change the inode's attribute, and it does not
involve size.

So the ll_truc_sem write semaphore should be constrained
around ll_setattr_ost() to not come across the lli_trunc_sem read
semaphore get from the normal file write path.

Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: Ic7f9cfb6d76dcf7ad08635efab154e7cdc392ce8
Reviewed-on: http://review.whamcloud.com/9267
Tested-by: Jenkins
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4702 nodemap: fix nm_rbtree_postorder_for_each_entry_safe() 00/9500/2
Niu Yawei [Wed, 5 Mar 2014 12:17:39 +0000 (07:17 -0500)]
LU-4702 nodemap: fix nm_rbtree_postorder_for_each_entry_safe()

It should check if the 'pos' && 'n' is NULL.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: Ibda34ec4cf1706f0651ed8c86a2e49e4a36cd2c0
Reviewed-on: http://review.whamcloud.com/9500
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Joshua Walgenbach <jjw@iu.edu>
10 years agoLU-4422 quota: fix s-q test_6 39/9339/3
Niu Yawei [Fri, 21 Feb 2014 03:07:14 +0000 (22:07 -0500)]
LU-4422 quota: fix s-q test_6

s-q test_6 should not fail by checking whether the file is
growing, because in most time, the test is waiting for quota
slave reconnecting to quota master.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I2332febf639bdbe033c588b97a2c7a1e1e2f51e2
Reviewed-on: http://review.whamcloud.com/9339
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-2524 tests: clean up conf-sanity test_38 for ZFS 84/9184/4
Andreas Dilger [Sat, 8 Feb 2014 01:02:57 +0000 (18:02 -0700)]
LU-2524 tests: clean up conf-sanity test_38 for ZFS

Clean up conf-sanity.sh test_38 so that it mounts the filesystem
locally instead of using debugfs.  That allows it to be run on
ZFS instead of being skipped.  Other minor style fixes.

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: I68090d2082b298b81518e5ffde847f15b47953b4
Reviewed-on: http://review.whamcloud.com/9184
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Reviewed-by: Isaac Huang <he.huang@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4388 llite: issue OST_SYNC for fsync() 84/8684/5
Bobi Jam [Tue, 31 Dec 2013 08:07:37 +0000 (16:07 +0800)]
LU-4388 llite: issue OST_SYNC for fsync()

The last parameter @datasync of fsync() has following indication:
* if datasync=0, we'd always flush data and metadata
* if datasync=1, we'd always flush data while does not flush modifed
  metadata unless that metadata is needed in order to allow a
  subsequent data retrieval to be correctly handled. For example, a
  change to the file size would require a metadata flush.

Lustre client can not tell the difference easily, and would issue
MDS_SYNC and OST_SYNC in all cases.

Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: I90fa8e761e91c8a04afba3fbfafe1f60f5839ad1
Reviewed-on: http://review.whamcloud.com/8684
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
10 years agoLU-4726 ptlrpc: vfs_rename api changed 37/9537/4
Bob Glossman [Thu, 6 Mar 2014 18:31:05 +0000 (10:31 -0800)]
LU-4726 ptlrpc: vfs_rename api changed

In newer kernels the vfs_rename api changed to take
more arguments. This patch creates a wrapper to let us adapt
to the different versions of vfs_rename in old and new kernels.

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: Ia5dafe64570fc404cd8a037fd442ca12e687ffc1
Reviewed-on: http://review.whamcloud.com/9537
Tested-by: Jenkins
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4199 libcfs: add wrapper of dump_trace() 72/8872/5
Li Xi [Thu, 27 Feb 2014 17:02:12 +0000 (12:02 -0500)]
LU-4199 libcfs: add wrapper of dump_trace()

dump_trace() is a X86 specific function. It will cause
compilation failure if the architecture is not X86. A more
general function dump_stack() should be called under that
environment.

Signed-off-by: Li Xi <lixi@ddn.com>
Signed-off-by: James Simmons <uja.ornl@gmail.com>
Change-Id: I8a5fffa6dec15dc8c779a22e24c10b364c77f9a0
Reviewed-on: http://review.whamcloud.com/8872
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-4704 acl: fix permission problem of setfacl 73/9473/3
Li Xi [Tue, 4 Mar 2014 08:48:43 +0000 (16:48 +0800)]
LU-4704 acl: fix permission problem of setfacl

Setxattr does not check the permission when setting ACL xattrs. This
will cause security problem because any user can walk around
permission checking by changing ACL rules.

Signed-off-by: Li Xi <lixi@ddn.com>
Change-Id: I1e5c44674f2e22ecbe29a589a219bed52d037b9b
Reviewed-on: http://review.whamcloud.com/9473
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4703 mdd: do not skip xattr sanity check for all cases 69/9469/2
Li Dongyang [Tue, 4 Mar 2014 06:10:49 +0000 (17:10 +1100)]
LU-4703 mdd: do not skip xattr sanity check for all cases

xattr sanity check should be done at all times.
Otherwise we are risking letting a non root user setting
access acl on any file.

Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au>
Change-Id: I5f44d38f2589f0758548d8ccae5efef27205f0a0
Reviewed-on: http://review.whamcloud.com/9469
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoLU-4020 hsm: allow copytool event monitoring with JSON 90/7790/15
Michael MacDonald [Wed, 26 Feb 2014 21:18:32 +0000 (16:18 -0500)]
LU-4020 hsm: allow copytool event monitoring with JSON

Adds hooks into various llapi_hsm_* functions to emit JSON-formatted
event messages for consumption by a monitoring agent. The copytool
needs to be supplied with an optional --event-fifo argument to
enable this feature.

Incorporates the following work done by Bruno Faccini:
* Put all JSON routines in a separate file/lib to allow for
  LGPL licensing.
* Major code cleanup to follow best practices and address review
  concerns.

Signed-off-by: Michael MacDonald <michael.macdonald@intel.com>
Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I1fecfb8e60ef091c6d37d16dc1faf40be45c5ee2
Reviewed-on: http://review.whamcloud.com/7790
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4602 utils: do not include <linux/fs.h> 90/9190/2
Alex Zhuravlev [Sun, 9 Feb 2014 09:04:57 +0000 (13:04 +0400)]
LU-4602 utils: do not include <linux/fs.h>

in some case (e.g. cross-compilation on OS/X) MS_* are
defined before linux/fs.h. so do not try to re-define
them.

Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Change-Id: I9ea8ea4865aa0380d7556b88604ec563acb0562b
Reviewed-on: http://review.whamcloud.com/9190
Tested-by: Jenkins
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4639 hsm: HSM requests not delivered 93/9393/8
James Nunez [Tue, 25 Feb 2014 22:34:46 +0000 (15:34 -0700)]
LU-4639 hsm: HSM requests not delivered

The total size of an HSM archive request may exceed the
desired (LNET) message. When this happens, it can hang
the client and not allow the archive request to succeed.

Before we know the total size of the hsm_action_items, we
need to limit the size of the reguest. Doing this limits
the number of items that can be sent in one archive request.
We’ve reduced the size allowed for the user archive request
to MDS_MAXREQSIZE/3.

sanity-hsm test 90 forms a list of files to archive. The
number of files in the list needed to be decreased to
match the limit described above.

Signed-off-by: James Nunez <james.a.nunez@intel.com>
Change-Id: I3c19851b7fedf62854a5a1b4a8f27b9c49d8b313
Reviewed-on: http://review.whamcloud.com/9393
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4557 ldiskfs: init statfs variables after journal 77/9277/3
Hongchao Zhang [Thu, 27 Feb 2014 14:00:11 +0000 (22:00 +0800)]
LU-4557 ldiskfs: init statfs variables after journal

in ext4_fill_super, the variables related to statfs
should be initialized after journal recovery is completed.
otherwise, if a large number of blocks were being allocated
before the filesystem crashed, then the blocks and inode
counters may become negative during use and report incorrect
values to statfs call.

Change-Id: Id7e3f61ce73f5499a6176c336c7931a47f6f76de
Signed-off-by: Hongchao Zhang <hongchao.zhang@intel.com>
Reviewed-on: http://review.whamcloud.com/9277
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Emoly Liu <emoly.liu@intel.com>
10 years agoLU-4658 fld: reset rc to 0 before resend fld lookup req 33/9333/2
wang di [Thu, 20 Feb 2014 14:47:38 +0000 (06:47 -0800)]
LU-4658 fld: reset rc to 0 before resend fld lookup req

Reset rc to 0 before resend fld lookup req, otherwise resend will
exit in fld_client_rpc before send request.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I030262615be3c360aeb399eae3f90736c15ebf98
Reviewed-on: http://review.whamcloud.com/9333
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4689 hsm: count NULL terminator in hai_first/hal_size 31/9431/2
Peng Tao [Thu, 27 Feb 2014 08:07:39 +0000 (16:07 +0800)]
LU-4689 hsm: count NULL terminator in hai_first/hal_size

If fsname is 8-byte aligned, hai_first fails to count the ending NULL
terminator causing hai to directly attached after fsname and future
hai_first will return a different position for first hai.

Signed-off-by: Peng Tao <bergwolf@gmail.com>
Change-Id: I5e9e1f48f99b4743b2d5b93397e06f6becabeb26
Reviewed-on: http://review.whamcloud.com/9431
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3951 lfsck: OST-object inconsistency self detect/repair 67/7667/30
Fan Yong [Mon, 17 Feb 2014 00:44:00 +0000 (08:44 +0800)]
LU-3951 lfsck: OST-object inconsistency self detect/repair

When client sends object-based RPC to the OST, the RPC service
thread on the OST needs to verify whether the given parent FID
in the client RPC matches the parent FID information stored in
the OST-object.

When the client given PFID does not match the OST local stored
PFID, then the OST will return "-EINPROGRESS" to the client for
retry later to avoid the RPC service thread to be blocked for
long time. On the other hand, there will be a dedicated thread
to talk with the LFSCK for the PFID verification. If the client
given parent FID information is incorrect, then deny the access;
otherwise, if the OST local stored PFID attribute is invalid,
then the OST local stored PFID xattr will be repaired.

Other fixes:
1) Hold update lock on the .lustre/lost+found/MDTxxxx object
   when add new name entry for handling orphan OST-object.
2) Hold dt_write_lock on the OST-object to be destroyed before
   transaction start, the same as normal ofd_object_destroy does.
3) Simplify the lfsck_layout_recreate_lovea() implementation.
4) Make sanity-lfsck test_18 to be workable under both DNE and
   non-DNE cases.
5) Other code cleanup.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Iefd26fe1782761ab16954a00aea0788c39534580
Reviewed-on: http://review.whamcloud.com/7667
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
10 years agoLU-4690 tests: disable test_4 in sanity.sh 40/9440/2
wang di [Fri, 28 Feb 2014 17:32:37 +0000 (09:32 -0800)]
LU-4690 tests: disable test_4 in sanity.sh

Disable test_4 in sanity.sh because of LU-4690.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I1acac5ad5c049eed7618aebf473b385a150316d7
Reviewed-on: http://review.whamcloud.com/9440
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
10 years agoRevert "LU-4659 mdd: rename forgets updating target linkea" 45/9445/2
Oleg Drokin [Sat, 1 Mar 2014 03:40:39 +0000 (03:40 +0000)]
Revert "LU-4659 mdd: rename forgets updating target linkea"

This now breaks the build due to conflict with some DNE patch.

This reverts commit f6c64625b87c06749e04a0a74960852bb9e50750.

Change-Id: Ie47a36b5e9df70183f3f27cec0f47402cebb102c
Reviewed-on: http://review.whamcloud.com/9445
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Tested-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoRevert "LU-4199 llite: Init lli_lmv_md field of struct ll_inode_info" 42/9442/2
Oleg Drokin [Sat, 1 Mar 2014 03:25:17 +0000 (03:25 +0000)]
Revert "LU-4199 llite: Init lli_lmv_md field of struct ll_inode_info"

In fact this member was already removed by some DNE patch.
So this causes build failures now.

This reverts commit c330f3c9d58ce507b2111ab3744dbf71353374bc.

Change-Id: I7d99d727fd2ef1f5b8f17ff6e3d9e9da79eae577
Reviewed-on: http://review.whamcloud.com/9442
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Tested-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3953 build: configure output improvments 09/9309/2
Dmitry Eremin [Wed, 19 Feb 2014 13:44:51 +0000 (17:44 +0400)]
LU-3953 build: configure output improvments

Cleanup from mess in configure output and multi-line messages.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: If90b0962f1b44f28af41e30015cc2ab253d6b83e
Reviewed-on: http://review.whamcloud.com/9309
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Brian J. Murrell <brian.murrell@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4300 ldlm: ELC picks locks in a safer policy 75/9175/3
Jinshan Xiong [Fri, 7 Feb 2014 07:03:25 +0000 (23:03 -0800)]
LU-4300 ldlm: ELC picks locks in a safer policy

Change the policy of ELC to pick locks that have no dirty pages,
no page in writeback state, and no locked pages.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: Ie73130c4100e3b91c211635f6a72fe5dad994426
Reviewed-on: http://review.whamcloud.com/9175
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3974 llite: invalidatepage api changed 29/7729/4
James Simmons [Thu, 13 Feb 2014 01:01:42 +0000 (20:01 -0500)]
LU-3974 llite: invalidatepage api changed

Until recently invalidating pages from the buffer cache
was dependent only on the page passed in and the start
in the page to invalidate. Starting with the 3.11 kernel
you can also specify the length of the data in the page
to invalidate. This patch enables us to handle the new
case.

Signed-off-by: James Simmons <uja.ornl@gmail.com>
Change-Id: Iedf458b20b2604bc3099d5ae38bf0ad07df83bd3
Reviewed-on: http://review.whamcloud.com/7729
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Peng Tao <bergwolf@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-3974 llite: use new struct dir_context 47/7747/14
James Simmons [Thu, 13 Feb 2014 00:51:44 +0000 (19:51 -0500)]
LU-3974 llite: use new struct dir_context

The readdir and nfs code over time has added more
parameters to be passed to be processed. For the 3.11
kernel a new struct dir_context was introduced to
minimize the impact of future expansion. This patch
addresses this change.

Signed-off-by: James Simmons <uja.ornl@gmail.com>
Change-Id: Ib42bf8cb06635a2a64e63b294d79e66ac82a1a5b
Reviewed-on: http://review.whamcloud.com/7747
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Peng Tao <bergwolf@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
10 years agoLU-4416 utils: loop_control device support 99/8799/3
yangsheng [Wed, 8 Jan 2014 11:44:15 +0000 (19:44 +0800)]
LU-4416 utils: loop_control device support

FC19 use loop_control device since 3.12.5 kernel.

Signed-off-by: yang sheng <yang.sheng@intel.com>
Change-Id: I40b241243507648b7dd9c6ddaf924c2324396e3f
Reviewed-on: http://review.whamcloud.com/8799
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Jenkins
Reviewed-by: Peng Tao <bergwolf@gmail.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>