aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/lustre (follow)
AgeCommit message (Collapse)AuthorFilesLines
2014-12-26[regression] braino in "lustre: use is_root_inode()"Al Viro1-1/+1
In one of the places (ll_md_blocking_ast()) we had open-coded !is_root_inode(inode) and replaced it with is_root_inode(inode). See the last chunk of f76c23: - inode != inode->i_sb->s_root->d_inode) + is_root_inode(inode)) should've been + !is_root_inode(inode)) obviously... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-12-17lustre: get rid of playing with ->fsAl Viro3-41/+2
* removed several pieces of dead code in lustre_compat25.h * don't open-code current_umask() (and BTW, 0755 & (S_IRWXUGO | S_ISVTX) is better spelled as 0755) * fix broken attempt to get the pathname by dentry - abusing d_path() for that is simply wrong. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-12-15Merge tag 'staging-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/stagingLinus Torvalds131-1730/+1316
Pull staging driver updates from Greg KH: "Here's the big staging tree pull request for 3.19-rc1. We continued to delete more lines than were added, always a good thing, but not at a huge rate this release, only about 70k lines removed overall mostly from removing the horrid bcm driver. Lots of normal staging driver cleanups and fixes all over the place, well over a thousand of them, the shortlog shows all the horrid details. The "contentious" thing here is the movement of the Android binder code out of staging into the "real" part of the kernel. This is code that has been stable for a few years now and is working as-is in the tens of millions of devices with no issues. Yes, the code is horrid, and the userspace api leaves a lot to be desired, but it's not going to change due to legacy issues that we have no control over. Because so many devices and companies rely on this, and the code is stable, might as well promote it out of staging. This was all discussed at the Linux Plumbers conference, and everyone participating agreed that this was the best way forward. There is work happening to replace the binder code with something new that is happening right now, but I don't expect to see the results of that work for another year at the earliest. If that ever happens, and Android switches over to it, I'll gladly remove this version. As for maintainers, I'll be glad to maintain this code, I've been doing it for the past few years with no problems. I'll send a MAINTAINERS entry for it before 3.19-final is out, still need to talk to the Google developers about if they are willing to help with it or not, last I checked they were, which was good. All of these patches have been in linux-next for a while with no reported issues" * tag 'staging-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (1382 commits) Staging: slicoss: Fix long line issues in slicoss.c staging: rtl8712: remove unnecessary else after return staging: comedi: change some printk calls to pr_err staging: rtl8723au: hal: Removed the extra semicolon lustre: Deletion of unnecessary checks before three function calls staging: lustre: fix sparse warnings: static function declaration staging: lustre: fixed sparse warnings related to static declarations staging: unisys: remove duplicate header staging: unisys: remove unneeded structure staging: ft1000 : replace __attribute ((__packed__) with __packed drivers: staging: rtl8192e: Include "asm/unaligned.h" instead of "access_ok.h" in "rtl819x_BAProc.c" Drivers:staging:rtl8192e: Fixed checkpatch warning Drivers:staging:clocking-wizard: Added a newline staging: clocking-wizard: check for a valid clk_name pointer staging: rtl8723au: Hal_InitPGData() avoid unnecessary typecasts staging: rtl8723au: _DisableAnalog(): Avoid zero-init variables unnecessarily staging: rtl8723au: Remove unnecessary wrapper _ResetDigitalProcedure1() staging: rtl8723au: _ResetDigitalProcedure1_92C() reduce code obfuscation staging: rtl8723au: Remove unnecessary wrapper _DisableRFAFEAndResetBB() staging: rtl8723au: _DisableRFAFEAndResetBB8192C(): Reduce code obfuscation ...
2014-12-02lustre: Deletion of unnecessary checks before three function callsMarkus Elfring2-5/+3
The functions free_ll_remote_perm(), free_rmtperm_hash() and iput() test whether their argument is NULL and then return immediately. Thus the test around their calls is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02staging: lustre: fix sparse warnings: static function declarationVincenzo Scotti1-1/+1
Signed-off-by: Vincenzo Scotti <vinc94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02staging: lustre: fixed sparse warnings related to static declarationsJanet Liu1-6/+6
drivers/staging/lustre/lustre/mdc/mdc_request.c:63:5: warning: symbol 'mdc_unpack_capa' was not declared. Should it be static? drivers/staging/lustre/lustre/mdc/mdc_request.c:150:5: warning: symbol 'mdc_getstatus' was not declared. Should it be static? drivers/staging/lustre/lustre/mdc/mdc_request.c:217:5: warning: symbol 'mdc_getattr' was not declared. Should it be static? drivers/staging/lustre/lustre/mdc/mdc_request.c:261:5: warning: symbol 'mdc_getattr_name' was not declared. Should it be static? drivers/staging/lustre/lustre/mdc/mdc_request.c:444:5: warning: symbol 'mdc_setxattr' was not declared. Should it be static? drivers/staging/lustre/lustre/mdc/mdc_request.c:455:5: warning: symbol 'mdc_getxattr' was not declared. Should it be static? Signed-off-by: Janet Liu <jianhua.ljh@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Remove space before braces for defined() checkAndreas Ruprecht2-2/+2
checkpatch complains about two places where a space is prohibited before the braces for in "#if defined()" check. This patch removes these warnings. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Remove unnecessary braces at ifsAndreas Ruprecht2-7/+4
checkpatch complains about three places where braces are not necessary. This patch removes the braces. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Remove unnecessary line continuationsAndreas Ruprecht1-2/+2
checkpatch finds two unnecessary line continuations in ldlm_lockd.c which are removed by this patch. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Fix warning about unneeded return statementAndreas Ruprecht1-1/+0
checkpatch complains about an unneeded return statement in the function search_granted_lock(), which is removed by this patch. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Fix initialization of static variablesAndreas Ruprecht2-2/+2
checkpatch complains about static variables being initialized to 0 which is unnecessary. This patch removes the initialization. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Fix indentation errors for switch-caseAndreas Ruprecht2-25/+25
checkpatch complains about two indentation errors where the case statements are on a higher indentation level than the corresponding switch statement. This patch removes these errors. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Fix warning about missing spacesAndreas Ruprecht3-7/+8
checkpatch.pl complains about a number of places where spaces were missing. This patch fixes all of these errors. For better readability, the warning of hitting the 80 character per line limit in line 1349 introduced by this change is ignored deliberately. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Fix overlong linesAndreas Ruprecht8-30/+49
checkpatch complains about a number of lines which are over the 80 character line limit. This patch changes most of them to comply, the few remaining lines with warnings are not changed for readability reasons. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: ldlm: Add missing newlines after declarationsAndreas Ruprecht9-1/+29
checkpatch.pl complains about a number of missing newlines after declarations. This patch gets rid of these warnings. Signed-off-by: Andreas Ruprecht <rupran@einserver.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: lustre: Fix sparse warnings for lnet/lnet/router.cGiedrius Statkevicius1-9/+9
Fix the following sparse errors: drivers/staging/lustre/lnet/lnet/router.c:756:1: warning: symbol 'lnet_wait_known_routerstate' was not declared. Should it be static? drivers/staging/lustre/lnet/lnet/router.c:788:1: warning: symbol 'lnet_update_ni_status_locked' was not declared. Should it be static? drivers/staging/lustre/lnet/lnet/router.c:828:1: warning: symbol 'lnet_destroy_rc_data' was not declared. Should it be static? drivers/staging/lustre/lnet/lnet/router.c:848:16: warning: symbol 'lnet_create_rc_data_locked' was not declared. Should it be static? drivers/staging/lustre/lnet/lnet/router.c:1228:1: warning: symbol 'lnet_destroy_rtrbuf' was not declared. Should it be static? drivers/staging/lustre/lnet/lnet/router.c:1238:15: warning: symbol 'lnet_new_rtrbuf' was not declared. Should it be static? drivers/staging/lustre/lnet/lnet/router.c:1274:1: warning: symbol 'lnet_rtrpool_free_bufs' was not declared. Should it be static? drivers/staging/lustre/lnet/lnet/router.c:1303:1: warning: symbol 'lnet_rtrpool_alloc_bufs' was not declared. Should it be static? drivers/staging/lustre/lnet/lnet/router.c:1337:1: warning: symbol 'lnet_rtrpool_init' was not declared. Should it be static? Signed-off-by: Giedrius Statkevicius <giedriuswork@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-23staging: lustre: Coalesce string fragmentsJoe Perches88-1013/+688
Join the string fragments to make it easier to grep. Ignored all the 80+ column lines. Added many missing spaces when coalescing formats. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22staging: lustre: mdc: use __FMODE_EXEC macroJuston Li2-6/+2
FMODE_EXEC is type fmode_t but is used in operations with integers which leads to sparse warnings: drivers/staging/lustre/lustre/mdc/mdc_lib.c:198:21: warning: restricted fmode_t degrades to integer drivers/staging/lustre/lustre/mdc/mdc_locks.c:300:49: warning: restricted fmode_t degrades to integer Fix by using __FMODE_EXEC macro defined in fs.h. Note the same warnings occurs with other fmode flags here but they don't have a corresponding int macro. Changes since v1: remove ifdefs. FMODE_EXEC and __FMODE_EXEC should always be defined in fs.h Signed-off-by: Juston Li <juston.h.li@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22drivers: staging: lustre: lnet: api-nc.c: Fix Style WarningsThomas Wood1-2/+1
Remove an unecessary return statement in a void function. Remove an unecessary space between a function name and the parentheses. Signed-off-by: Thomas Wood <tommyandrena@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22staging: lustre: lustre: ptlrpc: Remove unnecessary bracesBalavasu Kuppusammyprathaban1-3/+1
Fixes the following checkpatch warning: WARNING: braces {} are not necessary for single statement blocks Signed-off-by: Balavasu Kuppusammyprathaban <kp.balavasu@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22staging: lustre: libcfs_debug.h: remove final uses of the GOTO macroJulia Lawall1-12/+0
Remove the GOTO macro, as it is no longer used. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22staging: lustre: libcfs: remove final uses of the GOTO macroJulia Lawall1-8/+0
Remove the goto logging function, as it is no longer used. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22staging: lustre: osc: remove final uses of the GOTO macroJulia Lawall1-58/+110
The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ identifier lbl; identifier rc; constant c; @@ - GOTO(lbl,\(rc\|c\)); + goto lbl; @@ identifier lbl; expression rc; @@ - GOTO(lbl,rc); + rc; + goto lbl; // </smpl> In one case (OES_INV), consecutive gotos were factorized and a break was removed. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22drivers: staging: lustre: Kconfig: Let LUSTRE_LLITE_LLOOP depend on all !"*_64K*" pageChen Gang1-1/+1
It does not support 64K page, so let it disabled for 64K page under all architectures. The related error (with allmodconfig under tile): CC [M] drivers/staging/lustre/lustre/llite/lloop.o In file included from drivers/staging/lustre/lustre/llite/../include/../../include/linux/libcfs/libcfs.h:160:0, from drivers/staging/lustre/lustre/llite/../include/lustre_lib.h:52, from drivers/staging/lustre/lustre/llite/lloop.c:106: drivers/staging/lustre/lustre/llite/lloop.c: In function 'loop_set_fd': drivers/staging/lustre/lustre/llite/../include/../../include/linux/libcfs/libcfs_private.h:411:54: error: duplicate case value #define CLASSERT(cond) do {switch (42) {case (cond): case 0: break; } } while (0) ^ drivers/staging/lustre/lustre/llite/lloop.c:525:2: note: in expansion of macro 'CLASSERT' CLASSERT(PAGE_CACHE_SIZE < (1 << (sizeof(unsigned short) * 8))); ^ drivers/staging/lustre/lustre/llite/../include/../../include/linux/libcfs/libcfs_private.h:411:41: error: previously used here #define CLASSERT(cond) do {switch (42) {case (cond): case 0: break; } } while (0) ^ drivers/staging/lustre/lustre/llite/lloop.c:525:2: note: in expansion of macro 'CLASSERT' CLASSERT(PAGE_CACHE_SIZE < (1 << (sizeof(unsigned short) * 8))); ^ Use "find ./ | grep Kconfig | xargs grep --color 64K" to find all 64K page macros. Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22staging: lustre: Remove unnecessary parentheses.Masanari Iida1-1/+1
This patch remove unnecessary parentheses. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-22staging: lustre: Remove unnecessary semicolonMasanari Iida1-2/+2
This patch remove unnecessary semicolons from macro. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-19Merge branch 'for-lustre' into for-nextAl Viro12-376/+265
2014-11-19kill f_dentry usesAl Viro1-9/+3
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03Staging: lustre: Use put_unaligned_le64Vaishali Thakkar1-7/+5
This patch introduces the use of function put_unaligned_le64. This is done using Coccinelle and semantic patch used is as follows: @@ identifier tmp; expression ptr; expression y,e; type T; @@ - tmp = cpu_to_le64(y); <+... when != tmp - memcpy(ptr, (T)&tmp, ...); + put_unaligned_le64(y,ptr); ...+> ? tmp = e @@ type T; identifier tmp; @@ - T tmp; ...when != tmp Signed-off-by: Vaishali Thakkar <vthakkar1994@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-03Staging: lustre: lnet: Improve 'incarnation' stampTina Ruchandani1-8/+3
ksock_net_t uses a __u64 quantity as an 'incarnation' timestamp. This is also passed on in hello messages and used to detect if a reboot has occurred. This 'incarnation' is obtained using do_gettimeofday.It is only used in equality checks, so the absolute value does not matter. This patch replaces do_gettimeofday with ktime_get_ns for the following reasons: 1. ktime_get_ns returns a __u64 which is safer than 'struct timeval' which will overflow on 32-bit systems in year 2038 and beyond. 2. Reduced compute: ktime_get_ns is faster than the multiply/add combination used in this function Signed-off-by: Tina Ruchandani <ruchandani.tina@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-03lustre: use is_root_inode()Al Viro3-11/+9
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03lustre: get rid of duplicate mountpoint checksAl Viro1-35/+0
VFS has already done them Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03kill ll_link_generic()Al Viro1-32/+27
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03ll_get_child_fid(): callers already have the childAl Viro1-17/+7
no need to bother with d_lookup() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03kill ll_rename_generic()Al Viro1-48/+35
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03kill ll_unlink_generic()Al Viro1-42/+38
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03kill ll_rmdir_generic()Al Viro1-32/+28
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03ll_new_inode(): don't bother with name - it's always &dentry->d_nameAl Viro1-15/+15
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03kill ll_symlink_generic()Al Viro1-19/+13
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03kill ll_mkdir_generic()Al Viro1-21/+14
fold into ll_mkdir() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03kill ll_mknod_generic()Al Viro1-14/+8
just fold into ll_mknod() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03lustre: switch ll_release_openhandle() to struct inode *Al Viro3-9/+8
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03lustre: use file_inode()Al Viro7-31/+29
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03lustre: use %p[dD]Al Viro7-51/+47
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03lustre: opened file can't have negative dentryAl Viro1-30/+21
... and ll_md_close() gets inode already equal to file_inode(file), along with ll_file_release() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03ll_setxattr(): get rid of struct file on stackAl Viro3-11/+11
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03lustre: switch ll_intent_file_open() to struct dentry *Al Viro1-15/+12
... because fake struct file is wrong. ll_prep_inode() in there is an atrocity - despite passing a pointer to inode by address, it actually only uses the value when that value is non-NULL, as it will be here. Oh, and ->d_parent of anything is never NULL. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-11-03move d_rcu from overlapping d_child to overlapping d_aliasAl Viro3-6/+6
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-10-31vfs: make first argument of dir_context.actor typedMiklos Szeredi1-3/+5
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2014-10-30Staging: lustre: lnet: lnet: Better cookie genTina Ruchandani1-11/+4
api-ni.c uses do_gettimeofday to get a 'cookie' or timestamp. This patch replaces it with ktime_get_ns for the following reasons: 1. ktime_get_ns returns a __u64 which is safer than 'struct timeval' which will overflow on 32-bit systems in year 2038 and beyond. 2. Improved resolution: nsecs instead of usecs. 3. Reduced compute: ktime_get_ns is faster than the multiply/add combination used in this function Signed-off-by: Tina Ruchandani <ruchandani.tina@gmail.com> Suggested-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>