summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-02-20staging/lustre/libcfs: reformat cfs_tcd_for_each_type_lock defineOleg Drokin
Avoid using leading spaces that make checkpatch unhappy. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/libcfs: style change to add missing spaces for operationsOleg Drokin
This fixes checkpatch messages about "spaces preferred around that '-' (ctx:VxV)" Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/libcfs: Move EXPORT_SYMBOLs under function/variableOleg Drokin
Found with checkpatch Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/libcfs: Cleanup: parenthesis alignment adjustmentsOleg Drokin
Adjust alignment of argments that were pushed to next lines to conform to kernel code style. Found with checkpatch. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre: Remove the "write to FSF to get a copy of GPL" wordingOleg Drokin
Checkpatch highlighted that some of our Lustre files carry this extra paragraph and indeed it does seem somewhat redundant, so remove it. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/ptlrpc: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/osc: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/obdecho: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/obdclass: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/mgc: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/mdc: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/include: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/lclient: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/fld: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/fid: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/lmv: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/ldlm: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also remove some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/llite: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" The only exception is ll_update_inode where dropping != NULL in the construction below would break the logic. I guess we could change lsm != NULL to !!lsm, but that's uglier. (lsm != NULL) == ((body->valid & OBD_MD_FLEASIZE) != 0) Also removed some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/lov: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also removed some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/libcfs: Adjust NULL comparison codestyleOleg Drokin
All instances of "x == NULL" are changed to "!x" and "x != NULL" to "x" Also removed some redundant assertions. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/osc: Remove commented out osc_page_protected()Oleg Drokin
The complicated version of osc_page_protected and osc_page_is_dlocked are unsafe and were commented out for ages, so probably no point in carrying them on. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre: Remove commented out lock_lock_multi_matchOleg Drokin
lock_lock_multi_match stayed commented out unused for ages now, so let's just remove it. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre: Remove server code from class_get_type()Oleg Drokin
class_get_type has some references to various server modules that could not exist on the server, so get rid of them. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre: Remove server code from client_obd_setup()Oleg Drokin
In client_obd_setup references to LUSTRE_OSP_NAME could only happen on metadata servers, so remove them as never true Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre: Remove unused osc_on_mdt functionOleg Drokin
This only makes sense on metadata server, so get rid of it. Also remove now unused MDS_OSC_MAX_RIF_DEFAULT define Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre: Remove unused function oti_initOleg Drokin
All the users seems to have disappeared. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/lov: Get rid of /proc references in commentsOleg Drokin
Now that the sysfs conversion is complete, also convert all the remaining comments Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/llite: Get rid of /proc references in commentsOleg Drokin
Now that the sysfs conversion is complete, also convert all the remaining comments Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/libcfs: Get rid of /proc references in commentsOleg Drokin
Now that the sysfs conversion is complete, also convert all the remaining comments Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/obdclass: Get rid of /proc references in comments.Oleg Drokin
Now that the sysfs conversion is complete, also convert all the remaining comments Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging/lustre/ptlrpc: Get rid of /proc references in commentsOleg Drokin
Now that the sysfs conversion is complete, also convert all the remaining comments Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: DLC Feature dynamic net configAmir Shehata
This is the third patch of a set of patches that enables DLC. This patch adds the following features to LNET. Currently these features are not driven by user space. - Adding/Deleting Networks dynamically Two new functions were added: - lnet_dyn_add_ni() add an NI. if the NI is already added then fail with appropriate error code - lnet_dyn_del_ni() delete an existing NI. If NI doesn't exist fail with appropriate failure code. These functions shall be called from IOCTL. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2456 Reviewed-on: http://review.whamcloud.com/9832 Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Liang Zhen <liang.zhen@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: Dynamic LNet Configuration (DLC) dynamic routingAmir Shehata
This is the second patch of a set of patches that enables DLC. This patch adds the following features to LNET. Currently these features are not driven by user space. - Enabling Routing on Demand. The default number of router buffers are allocated. - Disable Routing on demand. Unused router buffers are freed and used router buffers are freed when they are no longer in use. The following time routing is enabled the default router buffer values are used. It has been decided that remembering the user set router buffer values should be remembered and re-set by user space scripts. - Increase the number of router buffers on demand, by allocating new ones. - Decrease the number of router buffers. Exccess buffers are freed if they are not in use. Otherwise they are freed once they are no longer in use. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2456 Change-Id: Id07d4ad424d8f5ba72475d4149380afe2ac54e77 Reviewed-on: http://review.whamcloud.com/9831 Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Liang Zhen <liang.zhen@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: Dynamic LNet Configuration (DLC)Amir Shehata
This is the first patch of a set of patches that enables DLC. This patch adds some cleanup in the config.c as well as some preparatory changes in peer.c to enable dynamic network configuration Signed-off-by: Amir Shehata <amir.shehata@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2456 Change-Id: I8c8bbf3b55acf4d76f22a8be587b553a70d31889 Reviewed-on: http://review.whamcloud.com/9830 Reviewed-by: Liang Zhen <liang.zhen@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: do not memset after LIBCFS_ALLOCFrank Zago
LIBCFS_ALLOC already zero out the memory allocated, so there is no need to zero out the memory again. Signed-off-by: Frank Zago <fzago@cray.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5304 Reviewed-on: http://review.whamcloud.com/11012 Reviewed-by: Patrick Farrell <paf@cray.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: return +ve for blocked lnet messageLiang Zhen
returned value of lnet_post_send_locked and lnet_post_routed_recv_locked are changed to -ve by: http://review.whamcloud.com/#/c/9369/ this is wrong because callers rely on +ve to identify blocked message which is not a failure. To respect linux kernel coding style and not use positive error code, this patch adds two macros as non-error returned values of these functions: LNET_CREDIT_OK has credit for message LNET_CREDIT_WAIT no credit and message is blocked both these functions will return these two values instead of 0 and EAGAIN Signed-off-by: Liang Zhen <liang.zhen@intel.com> Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5151 Reviewed-on: http://review.whamcloud.com/10625 Reviewed-by: Chris Horn <hornc@cray.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: remove uses of IS_ERR_VALUE()John L. Hammond
Remove most uses of IS_ERR_VALUE(). This macro was often given an int argument coming from PTR_ERR(). This invokes implementation defined behavior since the long value gotten by applying PTR_ERR() to a kernel pointer will usually not be representable as an int. Moreover it may be just plain wrong to do this since the expressions IS_ERR(p) and IS_ERR_VALUE((int) PTR_ERR(p)) are not equivalent for a general pointer p. Signed-off-by: John L. Hammond <john.hammond@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3498 Reviewed-on: http://review.whamcloud.com/6759 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: eliminate obsolete Cray SeaStar supportJames Simmons
Remove the bulk of code for the no longer supported SeaStar interconnect found on older Cray systems. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-1422 Reviewed-on: http://review.whamcloud.com/7469 Reviewed-by: Liang Zhen <liang.zhen@intel.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Chuck Fossen <chuckf@cray.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: fix failure handle of create replyLiang Zhen
error handler of lnet_create_reply_msg() didn't release lnet_res_lock if lnet_msg_alloc() failed. It can be fixed by moving validation check of msg out from lock. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2745 Reviewed-on: http://review.whamcloud.com/5542 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Isaac Huang <he.huang@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: reflect down routes in /proc/sys/lnet/routesChris Horn
We consider routes "down" if the router is down or the router NI for the target network is down. This should be reflected in the output of /proc/sys/lnet/routes Signed-off-by: Chris Horn <hornc@cray.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3679 Reviewed-on: http://review.whamcloud.com/7857 Reviewed-by: Cory Spitz <spitzcor@cray.com> Reviewed-by: Isaac Huang <he.huang@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: lustre: rename variables in lnet_find_route_lockedChris Horn
Rename several variables in lnet_find_route_locked to make the code easier to understand. Broken out of patch 7857. Signed-off-by: Chris Horn <hornc@cray.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3679 Reviewed-on: http://review.whamcloud.com/7857 Reviewed-by: Cory Spitz <spitzcor@cray.com> Reviewed-by: Isaac Huang <he.huang@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20Staging: wilc1000: Remove and rename struct typedefsBhumika Goyal
This patch gets rid of struct typedefs wilc_cfg_byte_t, wilc_cfg_hword_t, wilc_cfg_word_t and wilc_cfg_str_t as as linux kernel coding style guidelines suggest not using typdefs for structure types. Also drop '_t' from the names. Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: wilc1000: Return correct error codesAmitoj Kaur Chawla
This change has been made with the goal that kernel functions should return something more descriptive than -1 on failure. The return value on an alloc_etherdev failure should be -ENOMEM, and not -1. This was found using Coccinelle. A simplified version of the semantic patch used is: //<smpl> @@ expression *e; identifier l1; @@ e = alloc_etherdev(...); if (e == NULL) { ... return - -1 + -ENOMEM ; } //</smpl Furthermore, introduced `ret` variable to store and return the corresponding error code returned by register_netdev on failure. The two call sites store the return value in a variable which only checks that the value is non-zero, hence no change is required at the call sites. Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: wilc1000: Rearrange statement to respect 80 char limitJanani Ravichandran
Split statement across multiple lines as the line modified is over 80 chars in length. Signed-off-by: Janani Ravichandran <janani.rvchndrn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: wilc1000: Use kmalloc_array instead of kmallocJanani Ravichandran
Use kmalloc_array instead of kmalloc for arrays to prevent integer overflows. Signed-off-by: Janani Ravichandran <janani.rvchndrn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: wilc1000: Modify tcp_process to return void rather than intJanani Ravichandran
tcp_process() returns int, which is not used anywhere. So, change function header to return void intead of int and remove all uses of the local variable ret, which is used as a return variable in the function. Signed-off-by: Janani Ravichandran <janani.rvchndrn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: wilc1000: Remove unused functionAmitoj Kaur Chawla
Remove wilc_wlan_global_reset function since it is not used anywhere in this driver. This also silences the following sparse warning: drivers/staging/wilc1000/wilc_wlan.c:1120:6: warning: symbol 'wilc_wlan_global_reset' was not declared. Should it be static? Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: wilc1000: Removed braces from single block statementsRoger H. Newell
This patch corrects warnings generated by checkpatch.pl by removing braces from single block statements. Signed-off-by: Roger H. Newell <newell.roger@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: wilc1000: Whitespaces removed from function callRoger H. Newell
This patch corrects errors generated by checkpatch.pl by removing whitespace between parameters passed to dev_err() Signed-off-by: Roger H. Newell <newell.roger@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20staging: wilc1000: handle_set_mac_address: use netdev_errChaehyun Lim
This patch uses netdev_err instead of PRINT_ER that is a custom debug print. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>