From: Mike Rapoport Date: Tue, 13 Oct 2015 13:03:41 +0000 (+0300) Subject: staging: lustre: remove multiple blank lines X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=106495c41fb24901bd1c192373c3085961378297;p=openwrt%2Fstaging%2Fblogic.git staging: lustre: remove multiple blank lines Fixes checkpatch.pl CHECK:LINE_SPACING: Please don't use multiple blank lines. The patch is generated using checkpatch.pl --fix-inplace: for f in $(find drivers/staging/lustre/ -type f) ; do ./scripts/checkpatch.pl --types "LINE_SPACING" --test-only=multiple \ --fix-inplace -f $f done Signed-off-by: Mike Rapoport Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/lustre/include/linux/libcfs/linux/libcfs.h b/drivers/staging/lustre/include/linux/libcfs/linux/libcfs.h index 3e2502a69bbd..aac59008ad1a 100644 --- a/drivers/staging/lustre/include/linux/libcfs/linux/libcfs.h +++ b/drivers/staging/lustre/include/linux/libcfs/linux/libcfs.h @@ -41,7 +41,6 @@ #error Do not #include this file directly. #include instead #endif - #include #include #include @@ -86,7 +85,6 @@ #include "linux-time.h" #include "linux-mem.h" - #define LUSTRE_TRACE_SIZE (THREAD_SIZE >> 5) #if !defined(__x86_64__) @@ -142,5 +140,4 @@ typedef long long_ptr_t; #define WITH_WATCHDOG #endif - #endif /* _LINUX_LIBCFS_H */ diff --git a/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h b/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h index eb08400cc7d6..5f78b42b427a 100644 --- a/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h +++ b/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h @@ -848,7 +848,6 @@ kiblnd_rd_msg_size(kib_rdma_desc_t *rd, int msgtype, int n) offsetof(kib_putack_msg_t, ibpam_rd.rd_frags[n]); } - static inline __u64 kiblnd_dma_mapping_error(struct ib_device *dev, u64 dma_addr) { @@ -905,7 +904,6 @@ static inline unsigned int kiblnd_sg_dma_len(struct ib_device *dev, #define KIBLND_CONN_PARAM(e) ((e)->param.conn.private_data) #define KIBLND_CONN_PARAM_LEN(e) ((e)->param.conn.private_data_len) - struct ib_mr *kiblnd_find_rd_dma_mr(kib_hca_dev_t *hdev, kib_rdma_desc_t *rd); struct ib_mr *kiblnd_find_dma_mr(kib_hca_dev_t *hdev, diff --git a/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c b/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c index 3ffffbe22ca7..f1799aa1fdad 100644 --- a/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c +++ b/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c @@ -655,7 +655,6 @@ static int kiblnd_map_tx(lnet_ni_t *ni, kib_tx_t *tx, kib_rdma_desc_t *rd, return -EINVAL; } - static int kiblnd_setup_rd_iov(lnet_ni_t *ni, kib_tx_t *tx, kib_rdma_desc_t *rd, unsigned int niov, struct kvec *iov, int offset, int nob) diff --git a/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c b/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c index b3d1b5d627cb..1d4e7efb53d4 100644 --- a/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c +++ b/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c @@ -135,7 +135,6 @@ static int dev_failover; module_param(dev_failover, int, 0444); MODULE_PARM_DESC(dev_failover, "HCA failover for bonding (0 off, 1 on, other values reserved)"); - static int require_privileged_port; module_param(require_privileged_port, int, 0644); MODULE_PARM_DESC(require_privileged_port, "require privileged port when accepting connection"); diff --git a/drivers/staging/lustre/lnet/klnds/socklnd/socklnd.c b/drivers/staging/lustre/lnet/klnds/socklnd/socklnd.c index 1b472f493a62..1967c21aefe9 100644 --- a/drivers/staging/lustre/lnet/klnds/socklnd/socklnd.c +++ b/drivers/staging/lustre/lnet/klnds/socklnd/socklnd.c @@ -2445,7 +2445,6 @@ ksocknal_base_startup(void) ksocknal_data.ksnd_connd_starting++; spin_unlock_bh(&ksocknal_data.ksnd_connd_lock); - snprintf(name, sizeof(name), "socknal_cd%02d", i); rc = ksocknal_thread_start(ksocknal_connd, (void *)((ulong_ptr_t)i), name); @@ -2836,7 +2835,6 @@ ksocknal_startup(lnet_ni_t *ni) return -ENETDOWN; } - static void __exit ksocknal_module_fini(void) { diff --git a/drivers/staging/lustre/lnet/klnds/socklnd/socklnd_cb.c b/drivers/staging/lustre/lnet/klnds/socklnd/socklnd_cb.c index 8fbd89e7226e..477b385f15e0 100644 --- a/drivers/staging/lustre/lnet/klnds/socklnd/socklnd_cb.c +++ b/drivers/staging/lustre/lnet/klnds/socklnd/socklnd_cb.c @@ -89,7 +89,6 @@ ksocknal_alloc_tx_noop(__u64 cookie, int nonblk) return tx; } - void ksocknal_free_tx (ksock_tx_t *tx) { @@ -773,7 +772,6 @@ ksocknal_queue_tx_locked (ksock_tx_t *tx, ksock_conn_t *conn) spin_unlock_bh(&sched->kss_lock); } - ksock_route_t * ksocknal_find_connectable_route_locked (ksock_peer_t *peer) { @@ -2396,7 +2394,6 @@ ksocknal_send_keepalive_locked(ksock_peer_t *peer) return -EIO; } - static void ksocknal_check_peer_timeouts (int idx) { diff --git a/drivers/staging/lustre/lnet/klnds/socklnd/socklnd_modparams.c b/drivers/staging/lustre/lnet/klnds/socklnd/socklnd_modparams.c index c3ac67698125..fdb2b23e2ef0 100644 --- a/drivers/staging/lustre/lnet/klnds/socklnd/socklnd_modparams.c +++ b/drivers/staging/lustre/lnet/klnds/socklnd/socklnd_modparams.c @@ -134,7 +134,6 @@ static unsigned int zc_recv_min_nfrags = 16; module_param(zc_recv_min_nfrags, int, 0644); MODULE_PARM_DESC(zc_recv_min_nfrags, "minimum # of fragments to enable ZC recv"); - #if SOCKNAL_VERSION_DEBUG static int protocol = 3; module_param(protocol, int, 0644); diff --git a/drivers/staging/lustre/lnet/lnet/acceptor.c b/drivers/staging/lustre/lnet/lnet/acceptor.c index 99f8396f3822..92ca1dd64076 100644 --- a/drivers/staging/lustre/lnet/lnet/acceptor.c +++ b/drivers/staging/lustre/lnet/lnet/acceptor.c @@ -202,7 +202,6 @@ lnet_connect(struct socket **sockp, lnet_nid_t peer_nid, } EXPORT_SYMBOL(lnet_connect); - /* Below is the code common for both kernel and MT user-space */ static int @@ -447,7 +446,6 @@ lnet_acceptor_start(void) if (rc != 0) return rc; - init_completion(&lnet_acceptor_state.pta_signal); rc = accept2secure(accept_type, &secure); if (rc <= 0) diff --git a/drivers/staging/lustre/lnet/lnet/api-ni.c b/drivers/staging/lustre/lnet/lnet/api-ni.c index c368cf561b9d..53ad5ef4cde4 100644 --- a/drivers/staging/lustre/lnet/lnet/api-ni.c +++ b/drivers/staging/lustre/lnet/lnet/api-ni.c @@ -45,7 +45,6 @@ lnet_t the_lnet; /* THE state of the network */ EXPORT_SYMBOL(the_lnet); - static char *ip2nets = ""; module_param(ip2nets, charp, 0444); MODULE_PARM_DESC(ip2nets, "LNET network <- IP table"); @@ -529,7 +528,6 @@ lnet_res_lh_initialize(struct lnet_res_container *rec, lnet_libhandle_t *lh) list_add(&lh->lh_hash_chain, &rec->rec_lh_hash[hash]); } - int lnet_unprepare(void); static int diff --git a/drivers/staging/lustre/lnet/lnet/lib-eq.c b/drivers/staging/lustre/lnet/lnet/lib-eq.c index 8b843c5e71a5..60889ebd2f2b 100644 --- a/drivers/staging/lustre/lnet/lnet/lib-eq.c +++ b/drivers/staging/lustre/lnet/lnet/lib-eq.c @@ -318,7 +318,6 @@ LNetEQWait(lnet_handle_eq_t eventq, lnet_event_t *event) } EXPORT_SYMBOL(LNetEQWait); - static int lnet_eq_wait_locked(int *timeout_ms) __must_hold(&the_lnet.ln_eq_wait_lock) @@ -357,8 +356,6 @@ __must_hold(&the_lnet.ln_eq_wait_lock) return wait; } - - /** * Block the calling process until there's an event from a set of EQs or * timeout happens. diff --git a/drivers/staging/lustre/lnet/lnet/lib-move.c b/drivers/staging/lustre/lnet/lnet/lib-move.c index 6badfec4c6a0..5631f60a39bc 100644 --- a/drivers/staging/lustre/lnet/lnet/lib-move.c +++ b/drivers/staging/lustre/lnet/lnet/lib-move.c @@ -275,7 +275,6 @@ lnet_extract_iov(int dst_niov, struct kvec *dst, } EXPORT_SYMBOL(lnet_extract_iov); - unsigned int lnet_kiov_nob(unsigned int niov, lnet_kiov_t *kiov) { @@ -727,7 +726,6 @@ lnet_peer_is_alive(lnet_peer_t *lp, unsigned long now) return alive; } - /* NB: returns 1 when alive, 0 when dead, negative when error; * may drop the lnet_net_lock */ static int @@ -867,7 +865,6 @@ lnet_post_send_locked(lnet_msg_t *msg, int do_send) return 0; } - static lnet_rtrbufpool_t * lnet_msg2bufpool(lnet_msg_t *msg) { diff --git a/drivers/staging/lustre/lnet/lnet/router.c b/drivers/staging/lustre/lnet/lnet/router.c index 0357b051401f..4b5677025cd5 100644 --- a/drivers/staging/lustre/lnet/lnet/router.c +++ b/drivers/staging/lustre/lnet/lnet/router.c @@ -162,7 +162,6 @@ lnet_ni_notify_locked(lnet_ni_t *ni, lnet_peer_t *lp) lp->lp_notifying = 0; } - static void lnet_rtr_addref_locked(lnet_peer_t *lp) { diff --git a/drivers/staging/lustre/lnet/selftest/conrpc.c b/drivers/staging/lustre/lnet/selftest/conrpc.c index b70680b8bdbe..0060ff64f88e 100644 --- a/drivers/staging/lustre/lnet/selftest/conrpc.c +++ b/drivers/staging/lustre/lnet/selftest/conrpc.c @@ -40,7 +40,6 @@ * Author: Liang Zhen */ - #include "../../include/linux/libcfs/libcfs.h" #include "../../include/linux/lnet/lib-lnet.h" #include "timer.h" diff --git a/drivers/staging/lustre/lnet/selftest/conrpc.h b/drivers/staging/lustre/lnet/selftest/conrpc.h index ae7ed75573b9..95c832ff7375 100644 --- a/drivers/staging/lustre/lnet/selftest/conrpc.h +++ b/drivers/staging/lustre/lnet/selftest/conrpc.h @@ -140,5 +140,4 @@ void lstcon_rpc_cleanup_wait(void); int lstcon_rpc_module_init(void); void lstcon_rpc_module_fini(void); - #endif diff --git a/drivers/staging/lustre/lnet/selftest/console.c b/drivers/staging/lustre/lnet/selftest/console.c index 024aaee76b7f..d315dd44ae3b 100644 --- a/drivers/staging/lustre/lnet/selftest/console.c +++ b/drivers/staging/lustre/lnet/selftest/console.c @@ -40,7 +40,6 @@ * Author: Liang Zhen */ - #include "../../include/linux/libcfs/libcfs.h" #include "../../include/linux/lnet/lib-lnet.h" #include "console.h" @@ -2021,7 +2020,6 @@ lstcon_console_init(void) for (i = 0; i < LST_GLOBAL_HASHSIZE; i++) INIT_LIST_HEAD(&console_session.ses_ndl_hash[i]); - /* initialize acceptor service table */ lstcon_init_acceptor_service(); diff --git a/drivers/staging/lustre/lnet/selftest/console.h b/drivers/staging/lustre/lnet/selftest/console.h index acd131218dd9..3f3286c0c7bf 100644 --- a/drivers/staging/lustre/lnet/selftest/console.h +++ b/drivers/staging/lustre/lnet/selftest/console.h @@ -43,7 +43,6 @@ #ifndef __LST_CONSOLE_H__ #define __LST_CONSOLE_H__ - #include "../../include/linux/libcfs/libcfs.h" #include "../../include/linux/lnet/lnet.h" #include "../../include/linux/lnet/lib-types.h" diff --git a/drivers/staging/lustre/lnet/selftest/framework.c b/drivers/staging/lustre/lnet/selftest/framework.c index 177beaf496c4..f18e50036809 100644 --- a/drivers/staging/lustre/lnet/selftest/framework.c +++ b/drivers/staging/lustre/lnet/selftest/framework.c @@ -237,7 +237,6 @@ sfw_deactivate_session(void) spin_lock(&sfw_data.fw_lock); } - static void sfw_session_expired(void *data) { @@ -1633,7 +1632,6 @@ extern srpc_service_t brw_test_service; extern void brw_init_test_client(void); extern void brw_init_test_service(void); - int sfw_startup(void) { @@ -1643,7 +1641,6 @@ sfw_startup(void) srpc_service_t *sv; sfw_test_case_t *tsc; - if (session_timeout < 0) { CERROR("Session timeout must be non-negative: %d\n", session_timeout); diff --git a/drivers/staging/lustre/lnet/selftest/module.c b/drivers/staging/lustre/lnet/selftest/module.c index 09b8f4649796..46cbdf0456cc 100644 --- a/drivers/staging/lustre/lnet/selftest/module.c +++ b/drivers/staging/lustre/lnet/selftest/module.c @@ -150,7 +150,6 @@ error: return rc; } - MODULE_DESCRIPTION("LNet Selftest"); MODULE_LICENSE("GPL"); MODULE_VERSION("0.9.0"); diff --git a/drivers/staging/lustre/lnet/selftest/rpc.c b/drivers/staging/lustre/lnet/selftest/rpc.c index 9fc3ce33ec7b..162f9d330496 100644 --- a/drivers/staging/lustre/lnet/selftest/rpc.c +++ b/drivers/staging/lustre/lnet/selftest/rpc.c @@ -1354,7 +1354,6 @@ srpc_post_rpc(srpc_client_rpc_t *rpc) return; } - int srpc_send_reply(struct srpc_server_rpc *rpc) { @@ -1580,7 +1579,6 @@ srpc_lnet_ev_handler(lnet_event_t *ev) } } - int srpc_startup(void) { diff --git a/drivers/staging/lustre/lnet/selftest/rpc.h b/drivers/staging/lustre/lnet/selftest/rpc.h index b7b00c6b1004..6b4a32a90857 100644 --- a/drivers/staging/lustre/lnet/selftest/rpc.h +++ b/drivers/staging/lustre/lnet/selftest/rpc.h @@ -65,7 +65,6 @@ typedef enum { SRPC_MSG_JOIN_REPLY = 17, } srpc_msg_type_t; - /* CAVEAT EMPTOR: * All srpc_*_reqst_t's 1st field must be matchbits of reply buffer, * and 2nd field matchbits of bulk buffer if any. diff --git a/drivers/staging/lustre/lnet/selftest/selftest.h b/drivers/staging/lustre/lnet/selftest/selftest.h index 48322539a3a3..8a77d3fdfa54 100644 --- a/drivers/staging/lustre/lnet/selftest/selftest.h +++ b/drivers/staging/lustre/lnet/selftest/selftest.h @@ -56,7 +56,6 @@ #define MADE_WITHOUT_COMPROMISE #endif - #define SWI_STATE_NEWBORN 0 #define SWI_STATE_REPLY_SUBMITTED 1 #define SWI_STATE_REPLY_SENT 2 @@ -497,7 +496,6 @@ swi_deschedule_workitem(swi_workitem_t *swi) return cfs_wi_deschedule(swi->swi_sched, &swi->swi_workitem); } - int sfw_startup(void); int srpc_startup(void); void sfw_shutdown(void); @@ -583,7 +581,6 @@ swi_state2str (int state) schedule_timeout(cfs_time_seconds(1) / 10); \ } while (0) - #define lst_wait_until(cond, lock, fmt, ...) \ do { \ int __I = 2; \ diff --git a/drivers/staging/lustre/lnet/selftest/timer.c b/drivers/staging/lustre/lnet/selftest/timer.c index ebd5f79126c9..b98c08a10606 100644 --- a/drivers/staging/lustre/lnet/selftest/timer.c +++ b/drivers/staging/lustre/lnet/selftest/timer.c @@ -42,7 +42,6 @@ #include "selftest.h" - /* * Timers are implemented as a sorted queue of expiry times. The queue * is slotted, with each slot holding timers which expire in a @@ -167,7 +166,6 @@ stt_check_timers(unsigned long *last) return expired; } - static int stt_timer_main(void *arg) { @@ -204,7 +202,6 @@ stt_start_timer_thread(void) return 0; } - int stt_startup(void) { diff --git a/drivers/staging/lustre/lustre/include/cl_object.h b/drivers/staging/lustre/lustre/include/cl_object.h index 75c59dfd73d0..b463bc614d64 100644 --- a/drivers/staging/lustre/lustre/include/cl_object.h +++ b/drivers/staging/lustre/lustre/include/cl_object.h @@ -2020,7 +2020,6 @@ struct cl_io_slice { struct list_head cis_linkage; }; - /** * Per-layer io operations. * \see vvp_io_ops, lov_io_ops, lovsub_io_ops, osc_io_ops @@ -2294,7 +2293,6 @@ struct cl_io_rw_common { int crw_nonblock; }; - /** * State for io. * @@ -2858,7 +2856,6 @@ int cl_page_flush (const struct lu_env *env, struct cl_io *io, /** @} transfer */ - /** * \name helper routines * Functions to discard, delete and export a cl_page. diff --git a/drivers/staging/lustre/lustre/include/lclient.h b/drivers/staging/lustre/lustre/include/lclient.h index be5499c82504..36e7a6767e71 100644 --- a/drivers/staging/lustre/lustre/include/lclient.h +++ b/drivers/staging/lustre/lustre/include/lclient.h @@ -71,7 +71,6 @@ enum ccc_setattr_lock_type { SETATTR_MATCH_LOCK }; - /** * IO state private to vvp or slp layers. */ diff --git a/drivers/staging/lustre/lustre/include/linux/lustre_compat25.h b/drivers/staging/lustre/lustre/include/linux/lustre_compat25.h index 6b14406b2920..79d8f93075d1 100644 --- a/drivers/staging/lustre/lustre/include/linux/lustre_compat25.h +++ b/drivers/staging/lustre/lustre/include/linux/lustre_compat25.h @@ -61,7 +61,6 @@ #define module_init(a) late_initcall(a) #endif - #define LTIME_S(time) (time.tv_sec) #ifndef QUOTA_OK diff --git a/drivers/staging/lustre/lustre/include/linux/lustre_lite.h b/drivers/staging/lustre/lustre/include/linux/lustre_lite.h index f5d83ebe2fdd..3420cfd1278d 100644 --- a/drivers/staging/lustre/lustre/include/linux/lustre_lite.h +++ b/drivers/staging/lustre/lustre/include/linux/lustre_lite.h @@ -39,7 +39,6 @@ #error Do not #include this file directly. #include instead #endif - #include #include @@ -93,5 +92,4 @@ enum { LPROC_LL_FILE_OPCODES }; - #endif diff --git a/drivers/staging/lustre/lustre/include/linux/lustre_patchless_compat.h b/drivers/staging/lustre/lustre/include/linux/lustre_patchless_compat.h index ebe8d68ed813..33e0b99e1fb4 100644 --- a/drivers/staging/lustre/lustre/include/linux/lustre_patchless_compat.h +++ b/drivers/staging/lustre/lustre/include/linux/lustre_patchless_compat.h @@ -43,7 +43,6 @@ #include #include - #define ll_delete_from_page_cache(page) delete_from_page_cache(page) static inline void diff --git a/drivers/staging/lustre/lustre/include/linux/obd.h b/drivers/staging/lustre/lustre/include/linux/obd.h index 1d6750067f2f..468bc28be895 100644 --- a/drivers/staging/lustre/lustre/include/linux/obd.h +++ b/drivers/staging/lustre/lustre/include/linux/obd.h @@ -114,7 +114,6 @@ static inline void client_obd_list_unlock(client_obd_lock_t *lock) spin_unlock(&lock->lock); } - static inline void client_obd_list_lock_init(client_obd_lock_t *lock) { spin_lock_init(&lock->lock); diff --git a/drivers/staging/lustre/lustre/include/lprocfs_status.h b/drivers/staging/lustre/lustre/include/lprocfs_status.h index 6d127a0c1829..99fe03213dda 100644 --- a/drivers/staging/lustre/lustre/include/lprocfs_status.h +++ b/drivers/staging/lustre/lustre/include/lprocfs_status.h @@ -302,7 +302,6 @@ static inline int opcode_offset(__u32 opc) } } - #define LUSTRE_MAX_OPCODES (OPC_RANGE(OST) + \ OPC_RANGE(MDS) + \ OPC_RANGE(LDLM) + \ @@ -638,7 +637,6 @@ int lprocfs_seq_release(struct inode *, struct file *); #define LPROCFS_CLIMP_EXIT(obd) \ up_read(&(obd)->u.cli.cl_sem) - /* write the name##_seq_show function, call LPROC_SEQ_FOPS_RO for read-only proc entries; otherwise, you will define name##_seq_write function also for a read-write proc entry, and then call LPROC_SEQ_SEQ instead. Finally, diff --git a/drivers/staging/lustre/lustre/include/lu_object.h b/drivers/staging/lustre/lustre/include/lu_object.h index 7dafc28efea4..fa78689748a9 100644 --- a/drivers/staging/lustre/lustre/include/lu_object.h +++ b/drivers/staging/lustre/lustre/include/lu_object.h @@ -814,7 +814,6 @@ void lu_object_header_print(const struct lu_env *env, void *cookie, */ int lu_object_invariant(const struct lu_object *o); - /** * Check whether object exists, no matter on local or remote storage. * Note: LOHA_EXISTS will be set once some one created the object, @@ -1160,7 +1159,6 @@ void *lu_context_key_get (const struct lu_context *ctx, void lu_context_key_quiesce (struct lu_context_key *key); void lu_context_key_revive (struct lu_context_key *key); - /* * LU_KEY_INIT_GENERIC() has to be a macro to correctly determine an * owning module. @@ -1210,8 +1208,6 @@ void lu_context_key_revive (struct lu_context_key *key); } \ struct __##mod##_dummy_type_stop {; } - - #define LU_TYPE_INIT_FINI(mod, ...) \ LU_TYPE_INIT(mod, __VA_ARGS__); \ LU_TYPE_FINI(mod, __VA_ARGS__); \ diff --git a/drivers/staging/lustre/lustre/include/lu_ref.h b/drivers/staging/lustre/lustre/include/lu_ref.h index b451a888ca3a..97cd157dd35a 100644 --- a/drivers/staging/lustre/lustre/include/lu_ref.h +++ b/drivers/staging/lustre/lustre/include/lu_ref.h @@ -107,7 +107,6 @@ * @{ */ - /* * dummy data structures/functions to pass compile for now. * We need to reimplement them with kref. diff --git a/drivers/staging/lustre/lustre/include/lustre/ll_fiemap.h b/drivers/staging/lustre/lustre/include/lustre/ll_fiemap.h index ad253c6deadd..06ce8c9ae9ad 100644 --- a/drivers/staging/lustre/lustre/include/lustre/ll_fiemap.h +++ b/drivers/staging/lustre/lustre/include/lustre/ll_fiemap.h @@ -43,8 +43,6 @@ #ifndef _LUSTRE_FIEMAP_H #define _LUSTRE_FIEMAP_H - - struct ll_fiemap_extent { __u64 fe_logical; /* logical offset in bytes for the start of * the extent from the beginning of the file */ @@ -94,7 +92,6 @@ struct ll_user_fiemap { * support extents. Result * merged for efficiency. */ - static inline size_t fiemap_count_to_size(size_t extent_count) { return (sizeof(struct ll_user_fiemap) + extent_count * diff --git a/drivers/staging/lustre/lustre/include/lustre/lustre_idl.h b/drivers/staging/lustre/lustre/include/lustre/lustre_idl.h index a9c60ffbe795..f2f6b7b47a3b 100644 --- a/drivers/staging/lustre/lustre/include/lustre/lustre_idl.h +++ b/drivers/staging/lustre/lustre/include/lustre/lustre_idl.h @@ -294,7 +294,6 @@ static inline int range_compare_loc(const struct lu_seq_range *r1, (range)->lsr_index, \ fld_range_is_mdt(range) ? "mdt" : "ost" - /** \defgroup lu_fid lu_fid * @{ */ @@ -960,7 +959,6 @@ struct luda_type { #define DTTOIF(dirtype) ((dirtype) << IFSHIFT) #endif - struct lu_dirpage { __u64 ldp_hash_start; __u64 ldp_hash_end; @@ -1274,7 +1272,6 @@ void lustre_swab_ptlrpc_body(struct ptlrpc_body *pb); #define OCD_HAS_FLAG(ocd, flg) \ (!!((ocd)->ocd_connect_flags & OBD_CONNECT_##flg)) - #define LRU_RESIZE_CONNECT_FLAG OBD_CONNECT_LRU_RESIZE #define MDT_CONNECT_SUPPORTED (OBD_CONNECT_RDONLY | OBD_CONNECT_VERSION | \ @@ -1399,7 +1396,6 @@ struct obd_connect_data { * the matching OBD_CONNECT flag, so that can be approved and landed easily to * reserve the flag for future use. */ - void lustre_swab_connect(struct obd_connect_data *ocd); /* @@ -2051,7 +2047,6 @@ typedef enum { #define MDS_FIRST_OPC MDS_GETATTR - /* opcodes for object update */ typedef enum { UPDATE_OBJ = 1000, @@ -2117,7 +2112,6 @@ void lustre_swab_generic_32s(__u32 *val); /* This FULL lock is useful to take on unlink sort of operations */ #define MDS_INODELOCK_FULL ((1<<(MDS_INODELOCK_MAXSHIFT+1))-1) - /* NOTE: until Lustre 1.8.7/2.1.1 the fid_ver() was packed into name[2], * but was moved into name[1] along with the OID to avoid consuming the * name[2,3] fields that need to be used for the quota id (also a FID). */ diff --git a/drivers/staging/lustre/lustre/include/lustre/lustre_user.h b/drivers/staging/lustre/lustre/include/lustre/lustre_user.h index 77d987a18e0b..27e31c431d5c 100644 --- a/drivers/staging/lustre/lustre/include/lustre/lustre_user.h +++ b/drivers/staging/lustre/lustre/include/lustre/lustre_user.h @@ -261,7 +261,6 @@ struct ost_id { #define LL_IOC_OBD_STATFS IOC_OBD_STATFS #define IOC_MDC_GETSTRIPE IOC_MDC_GETFILESTRIPE - #define MAX_OBD_NAME 128 /* If this changes, a NEW ioctl must be added */ /* Define O_LOV_DELAY_CREATE to be a mask that is not useful for regular @@ -488,7 +487,6 @@ static inline void obd_uuid2fsname(char *buf, char *uuid, int buflen) &((fid)->f_oid), \ &((fid)->f_ver) - /********* Quotas **********/ /* these must be explicitly translated into linux Q_* in ll_dir_ioctl */ @@ -630,7 +628,6 @@ struct lustre_swap_layouts { __u64 sl_dv2; }; - /********* Changelogs **********/ /** Changelog record types */ enum changelog_rec_type { @@ -845,7 +842,6 @@ struct ioc_data_version { #define dot_lustre_name ".lustre" - /********* HSM **********/ /** HSM per-file state diff --git a/drivers/staging/lustre/lustre/include/lustre_cfg.h b/drivers/staging/lustre/lustre/include/lustre_cfg.h index fcc7401c90d8..eb6b292b7b25 100644 --- a/drivers/staging/lustre/lustre/include/lustre_cfg.h +++ b/drivers/staging/lustre/lustre/include/lustre_cfg.h @@ -224,7 +224,6 @@ static inline int lustre_cfg_len(__u32 bufcount, __u32 *buflens) return cfs_size_round(len); } - #include "obd_support.h" static inline struct lustre_cfg *lustre_cfg_new(int cmd, diff --git a/drivers/staging/lustre/lustre/include/lustre_disk.h b/drivers/staging/lustre/lustre/include/lustre_disk.h index d06ce3234e0b..5e1ac129a681 100644 --- a/drivers/staging/lustre/lustre/include/lustre_disk.h +++ b/drivers/staging/lustre/lustre/include/lustre_disk.h @@ -107,7 +107,6 @@ struct lustre_mount_data { #define lmd_is_client(x) ((x)->lmd_flags & LMD_FLG_CLIENT) - /****************** last_rcvd file *********************/ /** version recovery epoch */ @@ -373,7 +372,6 @@ struct lustre_sb_info { #define get_mount_flags(sb) (s2lsi(sb)->lsi_lmd->lmd_flags) #define get_mntdev_name(sb) (s2lsi(sb)->lsi_lmd->lmd_dev) - /****************** mount lookup info *********************/ struct lustre_mount_info { @@ -393,7 +391,6 @@ void lustre_register_client_fill_super(int (*cfs)(struct super_block *sb, void lustre_register_kill_super_cb(void (*cfs)(struct super_block *sb)); int lustre_common_put_super(struct super_block *sb); - int mgc_fsname2resid(char *fsname, struct ldlm_res_id *res_id, int type); /** @} disk */ diff --git a/drivers/staging/lustre/lustre/include/lustre_dlm.h b/drivers/staging/lustre/lustre/include/lustre_dlm.h index dfc49e10c294..7fb22af18f14 100644 --- a/drivers/staging/lustre/lustre/include/lustre_dlm.h +++ b/drivers/staging/lustre/lustre/include/lustre_dlm.h @@ -1275,7 +1275,6 @@ int ldlm_cli_cancel_list(struct list_head *head, int count, int intent_disposition(struct ldlm_reply *rep, int flag); void intent_set_disposition(struct ldlm_reply *rep, int flag); - /* ioctls for trying requests */ #define IOC_LDLM_TYPE 'f' #define IOC_LDLM_MIN_NR 40 diff --git a/drivers/staging/lustre/lustre/include/lustre_eacl.h b/drivers/staging/lustre/lustre/include/lustre_eacl.h index 499f9c8e1ae1..fee4d2c75506 100644 --- a/drivers/staging/lustre/lustre/include/lustre_eacl.h +++ b/drivers/staging/lustre/lustre/include/lustre_eacl.h @@ -70,7 +70,6 @@ typedef struct { #define CFS_ACL_XATTR_COUNT(size, prefix) \ (((size) - sizeof(prefix ## _header)) / sizeof(prefix ## _entry)) - extern ext_acl_xattr_header * lustre_posix_acl_xattr_2ext(posix_acl_xattr_header *header, int size); extern int diff --git a/drivers/staging/lustre/lustre/include/lustre_fld.h b/drivers/staging/lustre/lustre/include/lustre_fld.h index ff7230e18940..d8b3db9cdeba 100644 --- a/drivers/staging/lustre/lustre/include/lustre_fld.h +++ b/drivers/staging/lustre/lustre/include/lustre_fld.h @@ -61,7 +61,6 @@ enum { LUSTRE_CLI_FLD_HASH_RRB }; - struct lu_fld_target { struct list_head ft_chain; struct obd_export *ft_exp; diff --git a/drivers/staging/lustre/lustre/include/lustre_ha.h b/drivers/staging/lustre/lustre/include/lustre_ha.h index f3ae02b3eef3..49dfbb14f381 100644 --- a/drivers/staging/lustre/lustre/include/lustre_ha.h +++ b/drivers/staging/lustre/lustre/include/lustre_ha.h @@ -47,7 +47,6 @@ struct obd_export; struct obd_device; struct ptlrpc_request; - int ptlrpc_replay(struct obd_import *imp); int ptlrpc_resend(struct obd_import *imp); void ptlrpc_free_committed(struct obd_import *imp); diff --git a/drivers/staging/lustre/lustre/include/lustre_handles.h b/drivers/staging/lustre/lustre/include/lustre_handles.h index 4d51c8ac3906..3813055b9ffb 100644 --- a/drivers/staging/lustre/lustre/include/lustre_handles.h +++ b/drivers/staging/lustre/lustre/include/lustre_handles.h @@ -50,7 +50,6 @@ #include "../../include/linux/libcfs/libcfs.h" - struct portals_handle_ops { void (*hop_addref)(void *object); void (*hop_free)(void *object, int size); diff --git a/drivers/staging/lustre/lustre/include/lustre_import.h b/drivers/staging/lustre/lustre/include/lustre_import.h index 660d29032ad4..c1b8c175224c 100644 --- a/drivers/staging/lustre/lustre/include/lustre_import.h +++ b/drivers/staging/lustre/lustre/include/lustre_import.h @@ -50,7 +50,6 @@ #include "lustre_handles.h" #include "lustre/lustre_idl.h" - /** * Adaptive Timeout stuff * @@ -85,7 +84,6 @@ struct imp_at { struct adaptive_timeout iat_service_estimate[IMP_AT_MAX_PORTALS]; }; - /** @} */ /** Possible import states */ diff --git a/drivers/staging/lustre/lustre/include/lustre_lib.h b/drivers/staging/lustre/lustre/include/lustre_lib.h index cc3e8d1dc092..745b53d8d007 100644 --- a/drivers/staging/lustre/lustre/include/lustre_lib.h +++ b/drivers/staging/lustre/lustre/include/lustre_lib.h @@ -185,7 +185,6 @@ static inline int obd_ioctl_packlen(struct obd_ioctl_data *data) return len; } - static inline int obd_ioctl_is_invalid(struct obd_ioctl_data *data) { if (data->ioc_len > OBD_MAX_IOCTL_BUFFER) { @@ -249,7 +248,6 @@ static inline int obd_ioctl_is_invalid(struct obd_ioctl_data *data) return 0; } - #include "obd_support.h" /* function defined in lustre/obdclass//-module.c */ @@ -289,7 +287,6 @@ static inline void obd_ioctl_freedata(char *buf, int len) #define OBD_IOC_READ _IOWR('f', 109, OBD_IOC_DATA_TYPE) #define OBD_IOC_WRITE _IOWR('f', 110, OBD_IOC_DATA_TYPE) - #define OBD_IOC_STATFS _IOWR('f', 113, OBD_IOC_DATA_TYPE) #define OBD_IOC_SYNC _IOW ('f', 114, OBD_IOC_DATA_TYPE) #define OBD_IOC_READ2 _IOWR('f', 115, OBD_IOC_DATA_TYPE) @@ -523,7 +520,6 @@ struct l_wait_info { sigmask(SIGTERM) | sigmask(SIGQUIT) | \ sigmask(SIGALRM)) - /* * wait for @condition to become true, but no longer than timeout, specified * by @info. @@ -604,8 +600,6 @@ do { \ remove_wait_queue(&wq, &__wait); \ } while (0) - - #define l_wait_event(wq, condition, info) \ ({ \ int __ret; \ diff --git a/drivers/staging/lustre/lustre/include/lustre_lite.h b/drivers/staging/lustre/lustre/include/lustre_lite.h index df557c22abbe..f6d7aae3a0b8 100644 --- a/drivers/staging/lustre/lustre/include/lustre_lite.h +++ b/drivers/staging/lustre/lustre/include/lustre_lite.h @@ -55,7 +55,6 @@ #include "lustre/lustre_user.h" - struct lustre_rw_params { int lrp_lock_mode; ldlm_policy_data_t lrp_policy; diff --git a/drivers/staging/lustre/lustre/include/lustre_mdc.h b/drivers/staging/lustre/lustre/include/lustre_mdc.h index b1b05c8a371a..3da373315856 100644 --- a/drivers/staging/lustre/lustre/include/lustre_mdc.h +++ b/drivers/staging/lustre/lustre/include/lustre_mdc.h @@ -163,7 +163,6 @@ static inline void mdc_update_max_ea_from_body(struct obd_export *exp, } } - struct mdc_cache_waiter { struct list_head mcw_entry; wait_queue_head_t mcw_waitq; diff --git a/drivers/staging/lustre/lustre/include/lustre_net.h b/drivers/staging/lustre/lustre/include/lustre_net.h index 93a039dffcc9..90edbff5ed0b 100644 --- a/drivers/staging/lustre/lustre/include/lustre_net.h +++ b/drivers/staging/lustre/lustre/include/lustre_net.h @@ -46,7 +46,6 @@ * @{ */ - #ifndef _LUSTRE_NET_H #define _LUSTRE_NET_H @@ -2830,7 +2829,6 @@ int import_set_conn_priority(struct obd_import *imp, struct obd_uuid *uuid); void client_destroy_import(struct obd_import *imp); /** @} */ - /* ptlrpc/pinger.c */ /** * Pinger API (client side only) diff --git a/drivers/staging/lustre/lustre/include/lustre_param.h b/drivers/staging/lustre/lustre/include/lustre_param.h index 26f558e83755..8f6c0b26cfab 100644 --- a/drivers/staging/lustre/lustre/include/lustre_param.h +++ b/drivers/staging/lustre/lustre/include/lustre_param.h @@ -59,8 +59,6 @@ int class_find_param(char *buf, char *key, char **valp); int class_parse_nid(char *buf, lnet_nid_t *nid, char **endh); int class_parse_nid_quiet(char *buf, lnet_nid_t *nid, char **endh); - - /****************** User-settable parameter keys *********************/ /* e.g. tunefs.lustre --param="failover.node=192.168.0.13@tcp0" /dev/sda diff --git a/drivers/staging/lustre/lustre/include/lustre_sec.h b/drivers/staging/lustre/lustre/include/lustre_sec.h index 76b3a84a9342..aaadf098989f 100644 --- a/drivers/staging/lustre/lustre/include/lustre_sec.h +++ b/drivers/staging/lustre/lustre/include/lustre_sec.h @@ -342,7 +342,6 @@ void sptlrpc_conf_client_adapt(struct obd_device *obd); */ #define SPTLRPC_MAX_PAYLOAD (1024) - struct vfs_cred { uint32_t vc_uid; uint32_t vc_gid; @@ -830,7 +829,6 @@ static inline int sec_is_rootonly(struct ptlrpc_sec *sec) return (sec->ps_flvr.sf_flags & PTLRPC_SEC_FL_ROOTONLY); } - struct ptlrpc_svc_ctx { atomic_t sc_refcount; struct ptlrpc_sec_policy *sc_policy; @@ -882,7 +880,6 @@ struct ptlrpc_bulk_sec_desc { __u8 bsd_data[0]; /* policy-specific token */ }; - /* * round size up to next power of 2, for slab allocation. * @size must be sane (can't overflow after round up) @@ -1026,7 +1023,6 @@ void sptlrpc_req_put_ctx(struct ptlrpc_request *req, int sync); int sptlrpc_req_refresh_ctx(struct ptlrpc_request *req, long timeout); void sptlrpc_req_set_flavor(struct ptlrpc_request *req, int opcode); - /* gc */ void sptlrpc_gc_add_sec(struct ptlrpc_sec *sec); void sptlrpc_gc_del_sec(struct ptlrpc_sec *sec); @@ -1084,7 +1080,6 @@ int sptlrpc_current_user_desc_size(void); int sptlrpc_pack_user_desc(struct lustre_msg *msg, int offset); int sptlrpc_unpack_user_desc(struct lustre_msg *req, int offset, int swabbed); - #define CFS_CAP_CHOWN_MASK (1 << CFS_CAP_CHOWN) #define CFS_CAP_SYS_RESOURCE_MASK (1 << CFS_CAP_SYS_RESOURCE) diff --git a/drivers/staging/lustre/lustre/include/obd_cache.h b/drivers/staging/lustre/lustre/include/obd_cache.h index c8249fbb0d72..b5e1155e5cd3 100644 --- a/drivers/staging/lustre/lustre/include/obd_cache.h +++ b/drivers/staging/lustre/lustre/include/obd_cache.h @@ -35,5 +35,4 @@ #ifndef _OBD_CACHE_H__ #define _OBD_CACHE_H__ - #endif diff --git a/drivers/staging/lustre/lustre/include/obd_cksum.h b/drivers/staging/lustre/lustre/include/obd_cksum.h index 3a63462aa943..a0099d71773a 100644 --- a/drivers/staging/lustre/lustre/include/obd_cksum.h +++ b/drivers/staging/lustre/lustre/include/obd_cksum.h @@ -156,7 +156,6 @@ static inline cksum_type_t cksum_types_supported_server(void) return ret; } - /* Select the best checksum algorithm among those supplied in the cksum_types * input. * diff --git a/drivers/staging/lustre/lustre/include/obd_class.h b/drivers/staging/lustre/lustre/include/obd_class.h index 47230345fa90..f1bcc3cb3b14 100644 --- a/drivers/staging/lustre/lustre/include/obd_class.h +++ b/drivers/staging/lustre/lustre/include/obd_class.h @@ -36,7 +36,6 @@ #ifndef __CLASS_OBD_H #define __CLASS_OBD_H - #include "obd_support.h" #include "lustre_import.h" #include "lustre_net.h" @@ -353,7 +352,6 @@ static inline int obd_check_dev_active(struct obd_device *obd) (export)->exp_md_stats, coffset); \ } - #define OBD_CHECK_MD_OP(obd, op, err) \ do { \ if (!OBT(obd) || !MDP((obd), op)) { \ @@ -382,7 +380,6 @@ do { \ } \ } while (0) - #define OBD_CHECK_DT_OP(obd, op, err) \ do { \ if (!OBT(obd) || !OBP((obd), op)) { \ @@ -1744,7 +1741,6 @@ static inline int md_revalidate_lock(struct obd_export *exp, return rc; } - /* OBD Metadata Support */ int obd_init_caches(void); @@ -1763,7 +1759,6 @@ do { \ OBD_SLAB_FREE_PTR((ptr), obdo_cachep); \ } while (0) - static inline void obdo2fid(struct obdo *oa, struct lu_fid *fid) { /* something here */ diff --git a/drivers/staging/lustre/lustre/include/obd_support.h b/drivers/staging/lustre/lustre/include/obd_support.h index 80ab85d7ec3c..ec14b72c0327 100644 --- a/drivers/staging/lustre/lustre/include/obd_support.h +++ b/drivers/staging/lustre/lustre/include/obd_support.h @@ -472,7 +472,6 @@ extern char obd_jobid_var[]; #define OBD_FAIL_UPDATE_OBJ_NET 0x1700 #define OBD_FAIL_UPDATE_OBJ_NET_REP 0x1701 - /* Assign references to moved code to reduce code changes */ #define OBD_FAIL_PRECHECK(id) CFS_FAIL_PRECHECK(id) #define OBD_FAIL_CHECK(id) CFS_FAIL_CHECK(id) diff --git a/drivers/staging/lustre/lustre/lclient/lcommon_cl.c b/drivers/staging/lustre/lustre/lclient/lcommon_cl.c index 8764df9a1db3..ef2e2667cabd 100644 --- a/drivers/staging/lustre/lustre/lclient/lcommon_cl.c +++ b/drivers/staging/lustre/lustre/lclient/lcommon_cl.c @@ -161,7 +161,6 @@ struct lu_context_key ccc_session_key = { .lct_fini = ccc_session_key_fini }; - /* type constructor/destructor: ccc_type_{init,fini,start,stop}(). */ /* LU_TYPE_INIT_FINI(ccc, &ccc_key, &ccc_session_key); */ diff --git a/drivers/staging/lustre/lustre/lclient/lcommon_misc.c b/drivers/staging/lustre/lustre/lclient/lcommon_misc.c index 01bf894d4a87..8389a0edad36 100644 --- a/drivers/staging/lustre/lustre/lclient/lcommon_misc.c +++ b/drivers/staging/lustre/lustre/lclient/lcommon_misc.c @@ -45,7 +45,6 @@ #include "../include/lustre_lite.h" - /* Initialize the default and maximum LOV EA and cookie sizes. This allows * us to make MDS RPCs with large enough reply buffers to hold the * maximum-sized (= maximum striped) EA and cookie without having to diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_extent.c b/drivers/staging/lustre/lustre/ldlm/ldlm_extent.c index 05bc4f381a62..57b997dc42f5 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_extent.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_extent.c @@ -58,7 +58,6 @@ #include "../include/lustre_lib.h" #include "ldlm_internal.h" - /* When a lock is cancelled by a client, the KMS may undergo change if this * is the "highest lock". This function returns the new KMS value. * Caller must hold lr_lock already. diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c b/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c index 0c46a06818f8..4310154e1728 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c @@ -580,7 +580,6 @@ void ldlm_flock_policy_wire18_to_local(const ldlm_wire_policy_data_t *wpolicy, lpolicy->l_flock.owner = wpolicy->l_flock.lfw_pid; } - void ldlm_flock_policy_wire21_to_local(const ldlm_wire_policy_data_t *wpolicy, ldlm_policy_data_t *lpolicy) { diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_inodebits.c b/drivers/staging/lustre/lustre/ldlm/ldlm_inodebits.c index 40d3338506ae..b1bed1e17d32 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_inodebits.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_inodebits.c @@ -58,7 +58,6 @@ #include "../include/lustre_lib.h" #include "ldlm_internal.h" - void ldlm_ibits_policy_wire_to_local(const ldlm_wire_policy_data_t *wpolicy, ldlm_policy_data_t *lpolicy) { diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c b/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c index b8402005b560..ccce1e503120 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c @@ -626,7 +626,6 @@ out_disconnect: } EXPORT_SYMBOL(client_disconnect_export); - /** * Packs current SLV and Limit into \a req. */ diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_lock.c b/drivers/staging/lustre/lustre/ldlm/ldlm_lock.c index f39375c24773..658c878cacce 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_lock.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_lock.c @@ -154,7 +154,6 @@ EXPORT_SYMBOL(ldlm_it2str); * REFCOUNTED LOCK OBJECTS */ - /** * Get a reference on a lock. * @@ -1562,7 +1561,6 @@ out: return rc; } - /** * Process a call to blocking AST callback for a lock in ast_work list */ diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c b/drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c index 152bdaacc218..f00e3ba49ffe 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c @@ -443,7 +443,6 @@ static int ldlm_bl_to_thread(struct ldlm_namespace *ns, } } - int ldlm_bl_to_thread_lock(struct ldlm_namespace *ns, struct ldlm_lock_desc *ld, struct ldlm_lock *lock) { @@ -695,7 +694,6 @@ static int ldlm_callback_handler(struct ptlrpc_request *req) return 0; } - static struct ldlm_bl_work_item *ldlm_bl_get_work(struct ldlm_bl_pool *blp) { struct ldlm_bl_work_item *blwi = NULL; @@ -837,7 +835,6 @@ static int ldlm_bl_thread_main(void *arg) return 0; } - static int ldlm_setup(void); static int ldlm_cleanup(void); @@ -989,7 +986,6 @@ static int ldlm_setup(void) goto out; } - blp = kzalloc(sizeof(*blp), GFP_NOFS); if (!blp) { rc = -ENOMEM; diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_plain.c b/drivers/staging/lustre/lustre/ldlm/ldlm_plain.c index a1fe2c161e38..0c1965ddabb9 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_plain.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_plain.c @@ -58,7 +58,6 @@ #include "ldlm_internal.h" - void ldlm_plain_policy_wire_to_local(const ldlm_wire_policy_data_t *wpolicy, ldlm_policy_data_t *lpolicy) { diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_pool.c b/drivers/staging/lustre/lustre/ldlm/ldlm_pool.c index a4ee591d4e37..b85e2d699761 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_pool.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_pool.c @@ -104,7 +104,6 @@ #include "../include/obd_support.h" #include "ldlm_internal.h" - /* * 50 ldlm locks for 1MB of RAM. */ diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_request.c b/drivers/staging/lustre/lustre/ldlm/ldlm_request.c index 250cc3762f71..fdf81b87aad7 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_request.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_request.c @@ -1795,7 +1795,6 @@ static int replay_lock_interpret(const struct lu_env *env, if (rc != ELDLM_OK) goto out; - reply = req_capsule_server_get(&req->rq_pill, &RMF_DLM_REP); if (reply == NULL) { rc = -EPROTO; diff --git a/drivers/staging/lustre/lustre/libcfs/libcfs_lock.c b/drivers/staging/lustre/lustre/libcfs/libcfs_lock.c index 29308ba85393..94bc00785000 100644 --- a/drivers/staging/lustre/lustre/libcfs/libcfs_lock.c +++ b/drivers/staging/lustre/lustre/libcfs/libcfs_lock.c @@ -34,7 +34,6 @@ #include "../../include/linux/libcfs/libcfs.h" - /** destroy cpu-partition lock, see libcfs_private.h for more detail */ void cfs_percpt_lock_free(struct cfs_percpt_lock *pcl) @@ -146,7 +145,6 @@ cfs_percpt_unlock(struct cfs_percpt_lock *pcl, int index) } EXPORT_SYMBOL(cfs_percpt_unlock); - /** free cpu-partition refcount */ void cfs_percpt_atomic_free(atomic_t **refs) diff --git a/drivers/staging/lustre/lustre/libcfs/linux/linux-crypto-adler.c b/drivers/staging/lustre/lustre/libcfs/linux/linux-crypto-adler.c index 5e185fa5942a..026994a1e3bf 100644 --- a/drivers/staging/lustre/lustre/libcfs/linux/linux-crypto-adler.c +++ b/drivers/staging/lustre/lustre/libcfs/linux/linux-crypto-adler.c @@ -129,7 +129,6 @@ static struct shash_alg alg = { } }; - int cfs_crypto_adler32_register(void) { return crypto_register_shash(&alg); diff --git a/drivers/staging/lustre/lustre/libcfs/linux/linux-crypto.c b/drivers/staging/lustre/lustre/libcfs/linux/linux-crypto.c index f6de3600d5f3..5230654b1caf 100644 --- a/drivers/staging/lustre/lustre/libcfs/linux/linux-crypto.c +++ b/drivers/staging/lustre/lustre/libcfs/linux/linux-crypto.c @@ -36,8 +36,6 @@ */ static int cfs_crypto_hash_speeds[CFS_HASH_ALG_MAX]; - - static int cfs_crypto_hash_alloc(unsigned char alg_id, const struct cfs_crypto_hash_type **type, struct hash_desc *desc, unsigned char *key, diff --git a/drivers/staging/lustre/lustre/libcfs/linux/linux-module.c b/drivers/staging/lustre/lustre/libcfs/linux/linux-module.c index 64a984b42845..70a99cf019de 100644 --- a/drivers/staging/lustre/lustre/libcfs/linux/linux-module.c +++ b/drivers/staging/lustre/lustre/libcfs/linux/linux-module.c @@ -62,7 +62,6 @@ int libcfs_ioctl_getdata(char *buf, char *end, void *arg) return -EINVAL; } - if (hdr->ioc_len < sizeof(struct libcfs_ioctl_data)) { CERROR("PORTALS: user buffer too small for ioctl\n"); return -EINVAL; diff --git a/drivers/staging/lustre/lustre/libcfs/module.c b/drivers/staging/lustre/lustre/libcfs/module.c index 379b2dba6b04..0d9b223e71d6 100644 --- a/drivers/staging/lustre/lustre/libcfs/module.c +++ b/drivers/staging/lustre/lustre/libcfs/module.c @@ -338,7 +338,6 @@ out: return err; } - struct cfs_psdev_ops libcfs_psdev_ops = { libcfs_psdev_open, libcfs_psdev_release, diff --git a/drivers/staging/lustre/lustre/libcfs/tracefile.c b/drivers/staging/lustre/lustre/libcfs/tracefile.c index ff6c2c55b2e7..973c7c209dfc 100644 --- a/drivers/staging/lustre/lustre/libcfs/tracefile.c +++ b/drivers/staging/lustre/lustre/libcfs/tracefile.c @@ -39,7 +39,6 @@ * Author: Phil Schwan */ - #define DEBUG_SUBSYSTEM S_LNET #define LUSTRE_TRACEFILE_PRIVATE #include "tracefile.h" diff --git a/drivers/staging/lustre/lustre/libcfs/tracefile.h b/drivers/staging/lustre/lustre/libcfs/tracefile.h index e931f6d98de9..cb7a3963589f 100644 --- a/drivers/staging/lustre/lustre/libcfs/tracefile.h +++ b/drivers/staging/lustre/lustre/libcfs/tracefile.h @@ -65,8 +65,6 @@ void cfs_trace_stop_thread(void); int cfs_tracefile_init(int max_pages); void cfs_tracefile_exit(void); - - int cfs_trace_copyin_string(char *knl_buffer, int knl_buffer_nob, const char __user *usr_buffer, int usr_buffer_nob); int cfs_trace_copyout_string(char __user *usr_buffer, int usr_buffer_nob, @@ -309,7 +307,6 @@ cfs_trace_put_tcd (struct cfs_trace_cpu_data *tcd) int cfs_trace_refill_stock(struct cfs_trace_cpu_data *tcd, gfp_t gfp, struct list_head *stock); - int cfs_tcd_owns_tage(struct cfs_trace_cpu_data *tcd, struct cfs_trace_page *tage); diff --git a/drivers/staging/lustre/lustre/libcfs/workitem.c b/drivers/staging/lustre/lustre/libcfs/workitem.c index 02d18f558fdf..e1143a566ac4 100644 --- a/drivers/staging/lustre/lustre/libcfs/workitem.c +++ b/drivers/staging/lustre/lustre/libcfs/workitem.c @@ -115,7 +115,6 @@ cfs_wi_sched_cansleep(struct cfs_wi_sched *sched) return 1; } - /* XXX: * 0. it only works when called from wi->wi_action. * 1. when it returns no one shall try to schedule the workitem. @@ -217,7 +216,6 @@ cfs_wi_schedule(struct cfs_wi_sched *sched, cfs_workitem_t *wi) } EXPORT_SYMBOL(cfs_wi_schedule); - static int cfs_wi_scheduler (void *arg) { @@ -258,7 +256,6 @@ cfs_wi_scheduler (void *arg) wi->wi_running = 1; wi->wi_scheduled = 0; - cfs_wi_sched_unlock(sched); nloops++; @@ -302,7 +299,6 @@ cfs_wi_scheduler (void *arg) return 0; } - void cfs_wi_sched_destroy(struct cfs_wi_sched *sched) { diff --git a/drivers/staging/lustre/lustre/llite/dcache.c b/drivers/staging/lustre/lustre/llite/dcache.c index b86685912d28..80cba0448499 100644 --- a/drivers/staging/lustre/lustre/llite/dcache.c +++ b/drivers/staging/lustre/lustre/llite/dcache.c @@ -344,7 +344,6 @@ static int ll_revalidate_nd(struct dentry *dentry, unsigned int flags) return ll_revalidate_dentry(dentry, flags); } - static void ll_d_iput(struct dentry *de, struct inode *inode) { LASSERT(inode); diff --git a/drivers/staging/lustre/lustre/llite/dir.c b/drivers/staging/lustre/lustre/llite/dir.c index cc6f0f596ffe..0fe0c7135b73 100644 --- a/drivers/staging/lustre/lustre/llite/dir.c +++ b/drivers/staging/lustre/lustre/llite/dir.c @@ -907,7 +907,6 @@ static int ll_ioc_copy_start(struct super_block *sb, struct hsm_copy *copy) hpk.hpk_errval = 0; hpk.hpk_data_version = 0; - /* For archive request, we need to read the current file version. */ if (copy->hc_hai.hai_action == HSMA_ARCHIVE) { struct inode *inode; @@ -1047,7 +1046,6 @@ progress: return rc; } - static int copy_and_ioctl(int cmd, struct obd_export *exp, const void __user *data, size_t size) { diff --git a/drivers/staging/lustre/lustre/llite/file.c b/drivers/staging/lustre/lustre/llite/file.c index 51b6bc5d4d3a..ad02f2b9e590 100644 --- a/drivers/staging/lustre/lustre/llite/file.c +++ b/drivers/staging/lustre/lustre/llite/file.c @@ -1891,7 +1891,6 @@ int ll_hsm_release(struct inode *inode) __u64 data_version = 0; int rc; - CDEBUG(D_INODE, "%s: Releasing file "DFID".\n", ll_get_fsname(inode->i_sb, NULL, 0), PFID(&ll_i2info(inode)->lli_fid)); @@ -1923,7 +1922,6 @@ int ll_hsm_release(struct inode *inode) &data_version); och = NULL; - out: if (och != NULL && !IS_ERR(och)) /* close the file */ ll_lease_close(och, inode, NULL); @@ -2145,7 +2143,6 @@ static int ll_hsm_import(struct inode *inode, struct file *file, struct iattr *attr = NULL; int rc; - if (!S_ISREG(inode->i_mode)) return -EINVAL; @@ -2505,7 +2502,6 @@ ll_file_ioctl(struct file *file, unsigned int cmd, unsigned long arg) } } - static loff_t ll_file_seek(struct file *file, loff_t offset, int origin) { struct inode *inode = file_inode(file); @@ -3071,7 +3067,6 @@ struct posix_acl *ll_get_acl(struct inode *inode, int type) return acl; } - int ll_inode_permission(struct inode *inode, int mask) { int rc = 0; @@ -3169,7 +3164,6 @@ static struct llioc_ctl_data { LIST_HEAD_INIT(llioc.ioc_head) }; - struct llioc_data { struct list_head iocd_list; unsigned int iocd_size; diff --git a/drivers/staging/lustre/lustre/llite/llite_internal.h b/drivers/staging/lustre/lustre/llite/llite_internal.h index d294145ec57d..9096d311e45d 100644 --- a/drivers/staging/lustre/lustre/llite/llite_internal.h +++ b/drivers/staging/lustre/lustre/llite/llite_internal.h @@ -818,7 +818,6 @@ struct ll_close_queue { struct ccc_object *cl_inode2ccc(struct inode *inode); - void vvp_write_pending (struct ccc_object *club, struct ccc_page *page); void vvp_write_complete(struct ccc_object *club, struct ccc_page *page); @@ -1273,7 +1272,6 @@ typedef enum llioc_iter (*llioc_callback_t)(struct inode *inode, void *ll_iocontrol_register(llioc_callback_t cb, int count, unsigned int *cmd); void ll_iocontrol_unregister(void *magic); - /* lclient compat stuff */ #define cl_inode_info ll_inode_info #define cl_i2info(info) ll_i2info(info) diff --git a/drivers/staging/lustre/lustre/llite/llite_mmap.c b/drivers/staging/lustre/lustre/llite/llite_mmap.c index a90214bb84dd..7df978371c9a 100644 --- a/drivers/staging/lustre/lustre/llite/llite_mmap.c +++ b/drivers/staging/lustre/lustre/llite/llite_mmap.c @@ -258,8 +258,6 @@ out: return result; } - - static inline int to_fault_error(int result) { switch (result) { diff --git a/drivers/staging/lustre/lustre/llite/llite_rmtacl.c b/drivers/staging/lustre/lustre/llite/llite_rmtacl.c index c8a450b5cb18..b27c3f2fcd02 100644 --- a/drivers/staging/lustre/lustre/llite/llite_rmtacl.c +++ b/drivers/staging/lustre/lustre/llite/llite_rmtacl.c @@ -178,7 +178,6 @@ void rct_fini(struct rmtacl_ctl_table *rct) spin_unlock(&rct->rct_lock); } - static struct eacl_entry *ee_alloc(pid_t key, struct lu_fid *fid, int type, ext_acl_xattr_header *header) { diff --git a/drivers/staging/lustre/lustre/llite/lloop.c b/drivers/staging/lustre/lustre/llite/lloop.c index 90b4233df376..e6974c36276d 100644 --- a/drivers/staging/lustre/lustre/llite/lloop.c +++ b/drivers/staging/lustre/lustre/llite/lloop.c @@ -315,7 +315,6 @@ static unsigned int loop_get_bio(struct lloop_device *lo, struct bio **req) if (page_count + (*bio)->bi_vcnt > LLOOP_MAX_SEGMENTS) break; - page_count += (*bio)->bi_vcnt; count++; bio = &(*bio)->bi_next; @@ -370,7 +369,6 @@ err: bio_io_error(old_bio); } - static inline void loop_handle_bio(struct lloop_device *lo, struct bio *bio) { int ret; diff --git a/drivers/staging/lustre/lustre/llite/lproc_llite.c b/drivers/staging/lustre/lustre/llite/lproc_llite.c index e7b94f4ca6bc..5bd9fb542506 100644 --- a/drivers/staging/lustre/lustre/llite/lproc_llite.c +++ b/drivers/staging/lustre/lustre/llite/lproc_llite.c @@ -960,7 +960,6 @@ int ldebugfs_register_mountpoint(struct dentry *parent, char name[MAX_STRING_SIZE + 1], *ptr; int err, id, len, rc; - name[MAX_STRING_SIZE] = '\0'; LASSERT(sbi != NULL); @@ -1050,7 +1049,6 @@ int ldebugfs_register_mountpoint(struct dentry *parent, if (err) goto out; - err = ldebugfs_add_vars(sbi->ll_debugfs_entry, lprocfs_llite_obd_vars, sb); if (err) diff --git a/drivers/staging/lustre/lustre/llite/namei.c b/drivers/staging/lustre/lustre/llite/namei.c index a22e25285621..2ee7d31d78ae 100644 --- a/drivers/staging/lustre/lustre/llite/namei.c +++ b/drivers/staging/lustre/lustre/llite/namei.c @@ -100,7 +100,6 @@ static int ll_set_inode(struct inode *inode, void *opaque) return 0; } - /* * Get an inode by inode number (already instantiated by the intent lookup). * Returns inode or NULL @@ -674,7 +673,6 @@ out_release: return rc; } - /* We depend on "mode" being set with the proper file type/umask by now */ static struct inode *ll_create_node(struct inode *dir, struct lookup_intent *it) { diff --git a/drivers/staging/lustre/lustre/llite/vvp_dev.c b/drivers/staging/lustre/lustre/llite/vvp_dev.c index b8f6a8779fd3..9f7449fadb80 100644 --- a/drivers/staging/lustre/lustre/llite/vvp_dev.c +++ b/drivers/staging/lustre/lustre/llite/vvp_dev.c @@ -40,7 +40,6 @@ #define DEBUG_SUBSYSTEM S_LLITE - #include "../include/obd.h" #include "../include/lustre_lite.h" #include "llite_internal.h" @@ -113,7 +112,6 @@ static void vvp_session_key_fini(const struct lu_context *ctx, OBD_SLAB_FREE_PTR(session, vvp_session_kmem); } - struct lu_context_key vvp_key = { .lct_tags = LCT_CL_THREAD, .lct_init = vvp_key_init, @@ -187,7 +185,6 @@ void vvp_global_fini(void) lu_kmem_fini(vvp_caches); } - /***************************************************************************** * * mirror obd-devices into cl devices. diff --git a/drivers/staging/lustre/lustre/llite/vvp_internal.h b/drivers/staging/lustre/lustre/llite/vvp_internal.h index 2162bf6c08a7..b5a6661d47d5 100644 --- a/drivers/staging/lustre/lustre/llite/vvp_internal.h +++ b/drivers/staging/lustre/lustre/llite/vvp_internal.h @@ -39,7 +39,6 @@ #ifndef VVP_INTERNAL_H #define VVP_INTERNAL_H - #include "../include/cl_object.h" #include "llite_internal.h" diff --git a/drivers/staging/lustre/lustre/llite/vvp_io.c b/drivers/staging/lustre/lustre/llite/vvp_io.c index 41947ac39690..37773c181729 100644 --- a/drivers/staging/lustre/lustre/llite/vvp_io.c +++ b/drivers/staging/lustre/lustre/llite/vvp_io.c @@ -41,7 +41,6 @@ #define DEBUG_SUBSYSTEM S_LLITE - #include "../include/obd.h" #include "../include/lustre_lite.h" @@ -643,7 +642,6 @@ static int vvp_io_kernel_fault(struct vvp_fault_io *cfio) return -EINVAL; } - static int vvp_io_fault_start(const struct lu_env *env, const struct cl_io_slice *ios) { @@ -702,7 +700,6 @@ static int vvp_io_fault_start(const struct lu_env *env, goto out; } - if (fio->ft_mkwrite) { pgoff_t last_index; /* diff --git a/drivers/staging/lustre/lustre/llite/vvp_lock.c b/drivers/staging/lustre/lustre/llite/vvp_lock.c index f354e82d4ae7..f7b1144aadee 100644 --- a/drivers/staging/lustre/lustre/llite/vvp_lock.c +++ b/drivers/staging/lustre/lustre/llite/vvp_lock.c @@ -38,7 +38,6 @@ #define DEBUG_SUBSYSTEM S_LLITE - #include "../include/obd.h" #include "../include/lustre_lite.h" diff --git a/drivers/staging/lustre/lustre/llite/vvp_object.c b/drivers/staging/lustre/lustre/llite/vvp_object.c index cb2811b9aae7..e13afb7e8dca 100644 --- a/drivers/staging/lustre/lustre/llite/vvp_object.c +++ b/drivers/staging/lustre/lustre/llite/vvp_object.c @@ -40,7 +40,6 @@ #define DEBUG_SUBSYSTEM S_LLITE - #include "../../include/linux/libcfs/libcfs.h" #include "../include/obd.h" diff --git a/drivers/staging/lustre/lustre/llite/vvp_page.c b/drivers/staging/lustre/lustre/llite/vvp_page.c index a3cf5ad20c60..92f60c350f35 100644 --- a/drivers/staging/lustre/lustre/llite/vvp_page.c +++ b/drivers/staging/lustre/lustre/llite/vvp_page.c @@ -41,7 +41,6 @@ #define DEBUG_SUBSYSTEM S_LLITE - #include "../include/obd.h" #include "../include/lustre_lite.h" diff --git a/drivers/staging/lustre/lustre/llite/xattr_cache.c b/drivers/staging/lustre/lustre/llite/xattr_cache.c index 9e763ce244e3..819d3867183c 100644 --- a/drivers/staging/lustre/lustre/llite/xattr_cache.c +++ b/drivers/staging/lustre/lustre/llite/xattr_cache.c @@ -58,7 +58,6 @@ void ll_xattr_fini(void) static void ll_xattr_cache_init(struct ll_inode_info *lli) { - LASSERT(lli != NULL); INIT_LIST_HEAD(&lli->lli_xattrs); @@ -80,8 +79,6 @@ static int ll_xattr_cache_find(struct list_head *cache, { struct ll_xattr_entry *entry; - - list_for_each_entry(entry, cache, xe_list) { /* xattr_name == NULL means look for any entry */ if (xattr_name == NULL || @@ -113,8 +110,6 @@ static int ll_xattr_cache_add(struct list_head *cache, { struct ll_xattr_entry *xattr; - - if (ll_xattr_cache_find(cache, xattr_name, &xattr) == 0) { CDEBUG(D_CACHE, "duplicate xattr: [%s]\n", xattr_name); return -EPROTO; @@ -164,8 +159,6 @@ static int ll_xattr_cache_del(struct list_head *cache, { struct ll_xattr_entry *xattr; - - CDEBUG(D_CACHE, "del xattr: %s\n", xattr_name); if (ll_xattr_cache_find(cache, xattr_name, &xattr) == 0) { @@ -197,8 +190,6 @@ static int ll_xattr_cache_list(struct list_head *cache, struct ll_xattr_entry *xattr, *tmp; int xld_tail = 0; - - list_for_each_entry_safe(xattr, tmp, cache, xe_list) { CDEBUG(D_CACHE, "list: buffer=%p[%d] name=%s\n", xld_buffer, xld_tail, xattr->xe_name); @@ -240,7 +231,6 @@ static int ll_xattr_cache_valid(struct ll_inode_info *lli) static int ll_xattr_cache_destroy_locked(struct ll_inode_info *lli) { - if (!ll_xattr_cache_valid(lli)) return 0; @@ -256,8 +246,6 @@ int ll_xattr_cache_destroy(struct inode *inode) struct ll_inode_info *lli = ll_i2info(inode); int rc; - - down_write(&lli->lli_xattrs_list_rwsem); rc = ll_xattr_cache_destroy_locked(lli); up_write(&lli->lli_xattrs_list_rwsem); @@ -292,8 +280,6 @@ static int ll_xattr_find_get_lock(struct inode *inode, struct obd_export *exp = sbi->ll_md_exp; int rc; - - mutex_lock(&lli->lli_xattrs_enq_lock); /* inode may have been shrunk and recreated, so data is gone, match lock * only when data exists. */ @@ -359,8 +345,6 @@ static int ll_xattr_cache_refill(struct inode *inode, struct lookup_intent *oit) __u32 *xsizes; int rc, i; - - rc = ll_xattr_find_get_lock(inode, oit, &req); if (rc) goto out_no_unlock; @@ -495,8 +479,6 @@ int ll_xattr_cache_get(struct inode *inode, struct ll_inode_info *lli = ll_i2info(inode); int rc = 0; - - LASSERT(!!(valid & OBD_MD_FLXATTR) ^ !!(valid & OBD_MD_FLXATTRLS)); down_read(&lli->lli_xattrs_list_rwsem); diff --git a/drivers/staging/lustre/lustre/lmv/lmv_obd.c b/drivers/staging/lustre/lustre/lmv/lmv_obd.c index 397cf812ba7a..635a93cc94de 100644 --- a/drivers/staging/lustre/lustre/lmv/lmv_obd.c +++ b/drivers/staging/lustre/lustre/lmv/lmv_obd.c @@ -863,9 +863,6 @@ static int lmv_hsm_ct_register(struct lmv_obd *lmv, unsigned int cmd, int len, return rc; } - - - static int lmv_iocontrol(unsigned int cmd, struct obd_export *exp, int len, void *karg, void *uarg) { @@ -1588,7 +1585,6 @@ static int lmv_find_cbdata(struct obd_export *exp, const struct lu_fid *fid, return rc; } - static int lmv_close(struct obd_export *exp, struct md_op_data *op_data, struct md_open_data *mod, struct ptlrpc_request **request) { diff --git a/drivers/staging/lustre/lustre/lov/lov_cl_internal.h b/drivers/staging/lustre/lustre/lov/lov_cl_internal.h index 9a9156ec1777..1c0fe65243e1 100644 --- a/drivers/staging/lustre/lustre/lov/lov_cl_internal.h +++ b/drivers/staging/lustre/lustre/lov/lov_cl_internal.h @@ -438,7 +438,6 @@ struct lovsub_page { struct cl_page_slice lsb_cl; }; - struct lov_thread_info { struct cl_object_conf lti_stripe_conf; struct lu_fid lti_fid; @@ -611,7 +610,6 @@ int lov_sublock_modify(const struct lu_env *env, struct lov_lock *lov, struct lovsub_lock *sublock, const struct cl_lock_descr *d, int idx); - int lov_page_init(const struct lu_env *env, struct cl_object *ob, struct cl_page *page, struct page *vmpage); int lovsub_page_init(const struct lu_env *env, struct cl_object *ob, diff --git a/drivers/staging/lustre/lustre/lov/lov_dev.c b/drivers/staging/lustre/lustre/lov/lov_dev.c index 10317e0c3150..6f89c194d51f 100644 --- a/drivers/staging/lustre/lustre/lov/lov_dev.c +++ b/drivers/staging/lustre/lustre/lov/lov_dev.c @@ -46,7 +46,6 @@ #include "lov_cl_internal.h" #include "lov_internal.h" - struct kmem_cache *lov_lock_kmem; struct kmem_cache *lov_object_kmem; struct kmem_cache *lov_thread_kmem; diff --git a/drivers/staging/lustre/lustre/lov/lov_internal.h b/drivers/staging/lustre/lustre/lov/lov_internal.h index 0de39cc0c43e..bdee0a6f3d4e 100644 --- a/drivers/staging/lustre/lustre/lov/lov_internal.h +++ b/drivers/staging/lustre/lustre/lov/lov_internal.h @@ -269,5 +269,4 @@ static inline bool lov_oinfo_is_dummy(const struct lov_oinfo *loi) return false; } - #endif diff --git a/drivers/staging/lustre/lustre/lov/lov_io.c b/drivers/staging/lustre/lustre/lov/lov_io.c index 62360d874cd6..a5838b7ea18e 100644 --- a/drivers/staging/lustre/lustre/lov/lov_io.c +++ b/drivers/staging/lustre/lustre/lov/lov_io.c @@ -271,7 +271,6 @@ struct lov_io_sub *lov_page_subio(const struct lu_env *env, struct lov_io *lio, return lov_sub_get(env, lio, stripe); } - static int lov_io_subio_init(const struct lu_env *env, struct lov_io *lio, struct cl_io *io) { @@ -545,7 +544,6 @@ static void lov_io_unlock(const struct lu_env *env, LASSERT(rc == 0); } - static struct cl_page_list *lov_io_submit_qin(struct lov_device *ld, struct cl_page_list *qin, int idx, int alloc) diff --git a/drivers/staging/lustre/lustre/lov/lov_lock.c b/drivers/staging/lustre/lustre/lov/lov_lock.c index 173ae840950a..1a26496d844b 100644 --- a/drivers/staging/lustre/lustre/lov/lov_lock.c +++ b/drivers/staging/lustre/lustre/lov/lov_lock.c @@ -678,7 +678,6 @@ static int lov_lock_unuse(const struct lu_env *env, return result; } - static void lov_lock_cancel(const struct lu_env *env, const struct cl_lock_slice *slice) { @@ -1196,5 +1195,4 @@ static struct cl_lock_closure *lov_closure_get(const struct lu_env *env, return closure; } - /** @} lov */ diff --git a/drivers/staging/lustre/lustre/lov/lov_obd.c b/drivers/staging/lustre/lustre/lov/lov_obd.c index c8657076a96d..c3be0b5ca627 100644 --- a/drivers/staging/lustre/lustre/lov/lov_obd.c +++ b/drivers/staging/lustre/lustre/lov/lov_obd.c @@ -122,7 +122,6 @@ static int lov_set_osc_active(struct obd_device *obd, struct obd_uuid *uuid, static int lov_notify(struct obd_device *obd, struct obd_device *watched, enum obd_notify_event ev, void *data); - #define MAX_STRING_SIZE 128 int lov_connect_obd(struct obd_device *obd, __u32 index, int activate, struct obd_connect_data *data) @@ -170,7 +169,6 @@ int lov_connect_obd(struct obd_device *obd, __u32 index, int activate, return rc; } - if (imp->imp_invalid) { CDEBUG(D_CONFIG, "not connecting OSC %s; administratively disabled\n", obd_uuid2str(tgt_uuid)); diff --git a/drivers/staging/lustre/lustre/lov/lov_pack.c b/drivers/staging/lustre/lustre/lov/lov_pack.c index 05651ac6074a..2fb1e974cc70 100644 --- a/drivers/staging/lustre/lustre/lov/lov_pack.c +++ b/drivers/staging/lustre/lustre/lov/lov_pack.c @@ -253,7 +253,6 @@ __u16 lov_get_stripecnt(struct lov_obd *lov, __u32 magic, __u16 stripe_count) return stripe_count; } - static int lov_verify_lmm(void *lmm, int lmm_bytes, __u16 *stripe_count) { int rc; @@ -327,7 +326,6 @@ int lov_free_memmd(struct lov_stripe_md **lsmp) return refc; } - /* Unpack LOV object metadata from disk storage. It is packed in LE byte * order and is opaque to the networking layer. */ diff --git a/drivers/staging/lustre/lustre/lov/lov_page.c b/drivers/staging/lustre/lustre/lov/lov_page.c index c4596e8e5783..463cadbd9d40 100644 --- a/drivers/staging/lustre/lustre/lov/lov_page.c +++ b/drivers/staging/lustre/lustre/lov/lov_page.c @@ -208,7 +208,6 @@ out: return rc; } - static const struct cl_page_operations lov_empty_page_ops = { .cpo_fini = lov_empty_page_fini, .cpo_print = lov_page_print @@ -228,5 +227,4 @@ int lov_page_init_empty(const struct lu_env *env, struct cl_object *obj, return 0; } - /** @} lov */ diff --git a/drivers/staging/lustre/lustre/lov/lov_pool.c b/drivers/staging/lustre/lustre/lov/lov_pool.c index d3c6aa7645c7..2234321025d5 100644 --- a/drivers/staging/lustre/lustre/lov/lov_pool.c +++ b/drivers/staging/lustre/lustre/lov/lov_pool.c @@ -397,7 +397,6 @@ int lov_ost_pool_free(struct ost_pool *op) return 0; } - int lov_pool_new(struct obd_device *obd, char *poolname) { struct lov_obd *lov; @@ -509,7 +508,6 @@ int lov_pool_del(struct obd_device *obd, char *poolname) return 0; } - int lov_pool_add(struct obd_device *obd, char *poolname, char *ostname) { struct obd_uuid ost_uuid; @@ -526,7 +524,6 @@ int lov_pool_add(struct obd_device *obd, char *poolname, char *ostname) obd_str2uuid(&ost_uuid, ostname); - /* search ost in lov array */ obd_getref(obd); for (lov_idx = 0; lov_idx < lov->desc.ld_tgt_count; lov_idx++) { diff --git a/drivers/staging/lustre/lustre/lov/lovsub_dev.c b/drivers/staging/lustre/lustre/lov/lovsub_dev.c index 90d9ec386a1a..8cbbfb03c849 100644 --- a/drivers/staging/lustre/lustre/lov/lovsub_dev.c +++ b/drivers/staging/lustre/lustre/lov/lovsub_dev.c @@ -205,5 +205,4 @@ struct lu_device_type lovsub_device_type = { .ldt_ctx_tags = LCT_CL_THREAD }; - /** @} lov */ diff --git a/drivers/staging/lustre/lustre/lov/lovsub_object.c b/drivers/staging/lustre/lustre/lov/lovsub_object.c index 57e3629fccee..f2d885212f19 100644 --- a/drivers/staging/lustre/lustre/lov/lovsub_object.c +++ b/drivers/staging/lustre/lustre/lov/lovsub_object.c @@ -120,8 +120,6 @@ static int lovsub_object_glimpse(const struct lu_env *env, return cl_object_glimpse(env, &los->lso_super->lo_cl, lvb); } - - static const struct cl_object_operations lovsub_ops = { .coo_page_init = lovsub_page_init, .coo_lock_init = lovsub_lock_init, diff --git a/drivers/staging/lustre/lustre/mdc/mdc_lib.c b/drivers/staging/lustre/lustre/mdc/mdc_lib.c index ce0bcdfacb0e..227fc9ee0dcf 100644 --- a/drivers/staging/lustre/lustre/mdc/mdc_lib.c +++ b/drivers/staging/lustre/lustre/mdc/mdc_lib.c @@ -39,7 +39,6 @@ #include "../include/lustre/lustre_idl.h" #include "mdc_internal.h" - static void __mdc_pack_body(struct mdt_body *b, __u32 suppgid) { LASSERT(b != NULL); @@ -120,7 +119,6 @@ void mdc_create_pack(struct ptlrpc_request *req, struct md_op_data *op_data, CLASSERT(sizeof(struct mdt_rec_reint) == sizeof(struct mdt_rec_create)); rec = req_capsule_client_get(&req->rq_pill, &RMF_REC_REINT); - rec->cr_opcode = REINT_CREATE; rec->cr_fsuid = uid; rec->cr_fsgid = gid; diff --git a/drivers/staging/lustre/lustre/mdc/mdc_locks.c b/drivers/staging/lustre/lustre/mdc/mdc_locks.c index 5c34130ab69a..e0b81eea9486 100644 --- a/drivers/staging/lustre/lustre/mdc/mdc_locks.c +++ b/drivers/staging/lustre/lustre/mdc/mdc_locks.c @@ -363,8 +363,6 @@ mdc_intent_getxattr_pack(struct obd_export *exp, int rc, count = 0, maxdata; LIST_HEAD(cancels); - - req = ptlrpc_request_alloc(class_exp2cliimp(exp), &RQF_LDLM_INTENT_GETXATTR); if (req == NULL) diff --git a/drivers/staging/lustre/lustre/mdc/mdc_request.c b/drivers/staging/lustre/lustre/mdc/mdc_request.c index dc234a775942..16a5a10d371e 100644 --- a/drivers/staging/lustre/lustre/mdc/mdc_request.c +++ b/drivers/staging/lustre/lustre/mdc/mdc_request.c @@ -785,7 +785,6 @@ static int mdc_close(struct obd_export *exp, struct md_op_data *op_data, int rc; int saved_rc = 0; - req_fmt = &RQF_MDS_CLOSE; if (op_data->op_bias & MDS_HSM_RELEASE) { req_fmt = &RQF_MDS_RELEASE_CLOSE; @@ -961,7 +960,6 @@ static int mdc_done_writing(struct obd_export *exp, struct md_op_data *op_data, return rc; } - static int mdc_readpage(struct obd_export *exp, struct md_op_data *op_data, struct page **pages, struct ptlrpc_request **request) { @@ -2426,7 +2424,6 @@ static int mdc_process_config(struct obd_device *obd, u32 len, void *buf) return rc; } - /* get remote permission for current user on fid */ static int mdc_get_remote_perm(struct obd_export *exp, const struct lu_fid *fid, __u32 suppgid, struct ptlrpc_request **request) diff --git a/drivers/staging/lustre/lustre/mgc/mgc_request.c b/drivers/staging/lustre/lustre/mgc/mgc_request.c index 76b16f4f95c4..780ea81064ba 100644 --- a/drivers/staging/lustre/lustre/mgc/mgc_request.c +++ b/drivers/staging/lustre/lustre/mgc/mgc_request.c @@ -1558,7 +1558,6 @@ int mgc_process_log(struct obd_device *mgc, struct config_llog_data *cld) config_log_get(cld); } - if (cld_is_recover(cld)) { rc = 0; /* this is not a fatal error for recover log */ if (rcl == 0) @@ -1579,7 +1578,6 @@ int mgc_process_log(struct obd_device *mgc, struct config_llog_data *cld) return rc; } - /** Called from lustre_process_log. * LCFG_LOG_START gets the config log from the MGS, processes it to start * any services, and adds it to the list logs to watch (follow). diff --git a/drivers/staging/lustre/lustre/obdclass/acl.c b/drivers/staging/lustre/lustre/obdclass/acl.c index 1dace1419530..2e20cf635b27 100644 --- a/drivers/staging/lustre/lustre/obdclass/acl.c +++ b/drivers/staging/lustre/lustre/obdclass/acl.c @@ -92,7 +92,6 @@ static inline void lustre_posix_acl_cpu_to_le(posix_acl_xattr_entry *d, d->e_id = cpu_to_le32(s->e_id); } - /* if "new_count == 0", then "new = {a_version, NULL}", NOT NULL. */ static int lustre_posix_acl_xattr_reduce_space(posix_acl_xattr_header **header, int old_count, int new_count) diff --git a/drivers/staging/lustre/lustre/obdclass/cl_io.c b/drivers/staging/lustre/lustre/obdclass/cl_io.c index 6b1043548d85..e67cea758405 100644 --- a/drivers/staging/lustre/lustre/obdclass/cl_io.c +++ b/drivers/staging/lustre/lustre/obdclass/cl_io.c @@ -1040,7 +1040,6 @@ void cl_io_slice_add(struct cl_io *io, struct cl_io_slice *slice, } EXPORT_SYMBOL(cl_io_slice_add); - /** * Initializes page list. */ diff --git a/drivers/staging/lustre/lustre/obdclass/cl_object.c b/drivers/staging/lustre/lustre/obdclass/cl_object.c index cf752aa96347..a29540360fd5 100644 --- a/drivers/staging/lustre/lustre/obdclass/cl_object.c +++ b/drivers/staging/lustre/lustre/obdclass/cl_object.c @@ -547,7 +547,6 @@ static void cl_env_init0(struct cl_env *cle, void *debug) CL_ENV_INC(busy); } - /* * The implementation of using hash table to connect cl_env and thread */ @@ -646,7 +645,6 @@ static void cl_env_store_fini(void) cfs_hash_putref(cl_env_hash); } - static inline struct cl_env *cl_env_detach(struct cl_env *cle) { if (cle == NULL) diff --git a/drivers/staging/lustre/lustre/obdclass/cl_page.c b/drivers/staging/lustre/lustre/obdclass/cl_page.c index e27062d38a45..2f569edd0811 100644 --- a/drivers/staging/lustre/lustre/obdclass/cl_page.c +++ b/drivers/staging/lustre/lustre/obdclass/cl_page.c @@ -441,7 +441,6 @@ struct cl_page *cl_page_find(const struct lu_env *env, struct cl_object *o, } EXPORT_SYMBOL(cl_page_find); - struct cl_page *cl_page_find_sub(const struct lu_env *env, struct cl_object *o, pgoff_t idx, struct page *vmpage, struct cl_page *parent) @@ -903,7 +902,6 @@ int cl_page_own_try(const struct lu_env *env, struct cl_io *io, } EXPORT_SYMBOL(cl_page_own_try); - /** * Assume page ownership. * diff --git a/drivers/staging/lustre/lustre/obdclass/class_obd.c b/drivers/staging/lustre/lustre/obdclass/class_obd.c index a1a492ff62fc..3e9c24684690 100644 --- a/drivers/staging/lustre/lustre/obdclass/class_obd.c +++ b/drivers/staging/lustre/lustre/obdclass/class_obd.c @@ -47,7 +47,6 @@ #include "../include/cl_object.h" #include "llog_internal.h" - struct obd_device *obd_devs[MAX_OBD_DEVICES]; EXPORT_SYMBOL(obd_devs); struct list_head obd_types; @@ -534,7 +533,6 @@ static int __init init_obdclass(void) if (err != 0) return err; - err = llog_info_init(); if (err) return err; diff --git a/drivers/staging/lustre/lustre/obdclass/genops.c b/drivers/staging/lustre/lustre/obdclass/genops.c index e0b8150db71d..73044c3fa300 100644 --- a/drivers/staging/lustre/lustre/obdclass/genops.c +++ b/drivers/staging/lustre/lustre/obdclass/genops.c @@ -1109,7 +1109,6 @@ void (*class_export_dump_hook)(struct obd_export *) = NULL; EXPORT_SYMBOL(class_export_dump_hook); #endif - /* Total amount of zombies to be destroyed */ static int zombies_count; @@ -1258,7 +1257,6 @@ void obd_zombie_barrier(void) } EXPORT_SYMBOL(obd_zombie_barrier); - /** * destroy zombie export/import thread. */ @@ -1288,7 +1286,6 @@ static int obd_zombie_impexp_thread(void *unused) return 0; } - /** * start destroy zombie import/export thread */ diff --git a/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c b/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c index 245ac2e9b2dd..a055cbb4f162 100644 --- a/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c +++ b/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c @@ -213,7 +213,6 @@ struct miscdevice obd_psdev = { .fops = &obd_psdev_fops, }; - static ssize_t version_show(struct kobject *kobj, struct attribute *attr, char *buf) { diff --git a/drivers/staging/lustre/lustre/obdclass/llog.c b/drivers/staging/lustre/lustre/obdclass/llog.c index a941518e463d..7cb55ef79737 100644 --- a/drivers/staging/lustre/lustre/obdclass/llog.c +++ b/drivers/staging/lustre/lustre/obdclass/llog.c @@ -47,7 +47,6 @@ #define DEBUG_SUBSYSTEM S_LOG - #include "../include/obd_class.h" #include "../include/lustre_log.h" #include "llog_internal.h" diff --git a/drivers/staging/lustre/lustre/obdclass/llog_cat.c b/drivers/staging/lustre/lustre/obdclass/llog_cat.c index c63b720172b4..c442cae5fd37 100644 --- a/drivers/staging/lustre/lustre/obdclass/llog_cat.c +++ b/drivers/staging/lustre/lustre/obdclass/llog_cat.c @@ -48,7 +48,6 @@ #define DEBUG_SUBSYSTEM S_LOG - #include "../include/obd_class.h" #include "llog_internal.h" diff --git a/drivers/staging/lustre/lustre/obdclass/llog_obd.c b/drivers/staging/lustre/lustre/obdclass/llog_obd.c index 2b4a70b6c8d4..3900b9d4007e 100644 --- a/drivers/staging/lustre/lustre/obdclass/llog_obd.c +++ b/drivers/staging/lustre/lustre/obdclass/llog_obd.c @@ -36,7 +36,6 @@ #define DEBUG_SUBSYSTEM S_LOG - #include "../include/obd_class.h" #include "../include/lustre_log.h" #include "llog_internal.h" diff --git a/drivers/staging/lustre/lustre/obdclass/llog_swab.c b/drivers/staging/lustre/lustre/obdclass/llog_swab.c index 054fd31bb1c4..9354f75b5cab 100644 --- a/drivers/staging/lustre/lustre/obdclass/llog_swab.c +++ b/drivers/staging/lustre/lustre/obdclass/llog_swab.c @@ -42,7 +42,6 @@ #define DEBUG_SUBSYSTEM S_LOG - #include "../include/lustre_log.h" static void print_llogd_body(struct llogd_body *d) diff --git a/drivers/staging/lustre/lustre/obdclass/lprocfs_status.c b/drivers/staging/lustre/lustre/obdclass/lprocfs_status.c index ba56187b4c88..07727dbe6bff 100644 --- a/drivers/staging/lustre/lustre/obdclass/lprocfs_status.c +++ b/drivers/staging/lustre/lustre/obdclass/lprocfs_status.c @@ -40,7 +40,6 @@ #define DEBUG_SUBSYSTEM S_CLASS - #include "../include/obd_class.h" #include "../include/lprocfs_status.h" #include "../include/lustre/lustre_idl.h" diff --git a/drivers/staging/lustre/lustre/obdclass/lu_object.c b/drivers/staging/lustre/lustre/obdclass/lu_object.c index 6a6ddb4c34dc..0d15bd5b05b7 100644 --- a/drivers/staging/lustre/lustre/obdclass/lu_object.c +++ b/drivers/staging/lustre/lustre/obdclass/lu_object.c @@ -1225,8 +1225,6 @@ struct lu_object *lu_object_locate(struct lu_object_header *h, } EXPORT_SYMBOL(lu_object_locate); - - /** * Finalize and free devices in the device stack. * @@ -1732,7 +1730,6 @@ static void lu_site_stats_get(struct cfs_hash *hs, } } - /* * lu_cache_shrink_count returns the number of cached objects that are * candidates to be freed by shrink_slab(). A counter, which tracks diff --git a/drivers/staging/lustre/lustre/obdclass/lustre_handles.c b/drivers/staging/lustre/lustre/obdclass/lustre_handles.c index b526e7ef0c0e..fb9147cc607f 100644 --- a/drivers/staging/lustre/lustre/obdclass/lustre_handles.c +++ b/drivers/staging/lustre/lustre/obdclass/lustre_handles.c @@ -44,7 +44,6 @@ #include "../include/lustre_handles.h" #include "../include/lustre_lib.h" - static __u64 handle_base; #define HANDLE_INCR 7 static spinlock_t handle_base_lock; diff --git a/drivers/staging/lustre/lustre/obdclass/obd_config.c b/drivers/staging/lustre/lustre/obdclass/obd_config.c index 68cb3dff985f..64e2d1b368be 100644 --- a/drivers/staging/lustre/lustre/obdclass/obd_config.c +++ b/drivers/staging/lustre/lustre/obdclass/obd_config.c @@ -722,7 +722,6 @@ static int class_set_global(char *ptr, int val, struct lustre_cfg *lcfg) return 0; } - /* We can't call ll_process_config or lquota_process_config directly because * it lives in a module that must be loaded after this one. */ static int (*client_process_config)(struct lustre_cfg *lcfg); @@ -748,7 +747,6 @@ static int process_param2_config(struct lustre_cfg *lcfg) ktime_t end; int rc; - /* Add upcall processing here. Now only lctl is supported */ if (strcmp(upcall, LCTL_UPCALL) != 0) { CERROR("Unsupported upcall %s\n", upcall); @@ -1156,7 +1154,6 @@ int class_config_llog_handler(const struct lu_env *env, } } - if (clli->cfg_flags & CFG_F_EXCLUDE) { CDEBUG(D_CONFIG, "cmd: %x marked EXCLUDED\n", lcfg->lcfg_command); diff --git a/drivers/staging/lustre/lustre/obdclass/obd_mount.c b/drivers/staging/lustre/lustre/obdclass/obd_mount.c index 0c4dbb1304ee..0d324cc28243 100644 --- a/drivers/staging/lustre/lustre/obdclass/obd_mount.c +++ b/drivers/staging/lustre/lustre/obdclass/obd_mount.c @@ -40,7 +40,6 @@ * Author: Nathan Rutman */ - #define DEBUG_SUBSYSTEM S_CLASS #define D_MOUNT (D_SUPER|D_CONFIG/*|D_WARNING */) #define PRINT_CMD CDEBUG @@ -1146,7 +1145,6 @@ out: return rc; } - /* We can't call ll_fill_super by name because it lives in a module that must be loaded after this one. */ void lustre_register_client_fill_super(int (*cfs)(struct super_block *sb, diff --git a/drivers/staging/lustre/lustre/obdecho/echo_client.c b/drivers/staging/lustre/lustre/obdecho/echo_client.c index ec9ccff86648..87f1b3adeee7 100644 --- a/drivers/staging/lustre/lustre/obdecho/echo_client.c +++ b/drivers/staging/lustre/lustre/obdecho/echo_client.c @@ -98,7 +98,6 @@ static int echo_client_setup(const struct lu_env *env, struct lustre_cfg *lcfg); static int echo_client_cleanup(struct obd_device *obddev); - /** \defgroup echo_helpers Helper functions * @{ */ @@ -1202,7 +1201,6 @@ static int cl_echo_object_brw(struct echo_object *eco, int rw, u64 offset, goto out; LASSERT(rc == 0); - rc = cl_echo_enqueue0(env, eco, offset, offset + npages * PAGE_CACHE_SIZE - 1, rw == READ ? LCK_PR : LCK_PW, &lh.cookie, @@ -1261,7 +1259,6 @@ out: } /** @} echo_exports */ - static u64 last_object_id; static int @@ -1304,7 +1301,6 @@ echo_copyin_lsm(struct echo_device *ed, struct lov_stripe_md *lsm, ((__u64)lsm->lsm_stripe_size * lsm->lsm_stripe_count > ~0UL)) return -EINVAL; - for (i = 0; i < lsm->lsm_stripe_count; i++) { if (copy_from_user(lsm->lsm_oinfo[i], ((struct lov_stripe_md *)ulsm)-> \ diff --git a/drivers/staging/lustre/lustre/obdecho/echo_internal.h b/drivers/staging/lustre/lustre/obdecho/echo_internal.h index 8e9dbc2351e7..69063fa65d35 100644 --- a/drivers/staging/lustre/lustre/obdecho/echo_internal.h +++ b/drivers/staging/lustre/lustre/obdecho/echo_internal.h @@ -43,5 +43,4 @@ /* block size to use for data verification */ #define OBD_ECHO_BLOCK_SIZE (4<<10) - #endif diff --git a/drivers/staging/lustre/lustre/osc/osc_cache.c b/drivers/staging/lustre/lustre/osc/osc_cache.c index 4d235972e5cc..b552a5611fdf 100644 --- a/drivers/staging/lustre/lustre/osc/osc_cache.c +++ b/drivers/staging/lustre/lustre/osc/osc_cache.c @@ -306,7 +306,6 @@ out: __res; \ }) - /** * sanity check - to make sure there is no overlapped extent in the tree. */ @@ -1028,7 +1027,6 @@ static int osc_extent_truncate(struct osc_extent *ext, pgoff_t trunc_index, int chunks = (ext->oe_end >> ppc_bits) - trunc_chunk; pgoff_t last_index; - /* if there is no pages in this chunk, we can also free grants * for the last chunk */ if (pages_in_chunk == 0) { @@ -1781,7 +1779,6 @@ static void osc_process_ar(struct osc_async_rc *ar, __u64 xid, ar->ar_force_sync = 0; } - /* this must be called holding the loi list lock to give coverage to exit_cache, * async_flag maintenance, and oap_request */ static void osc_ap_completion(const struct lu_env *env, struct client_obd *cli, diff --git a/drivers/staging/lustre/lustre/osc/osc_cl_internal.h b/drivers/staging/lustre/lustre/osc/osc_cl_internal.h index 75bfda6e4ad3..d2d68452d382 100644 --- a/drivers/staging/lustre/lustre/osc/osc_cl_internal.h +++ b/drivers/staging/lustre/lustre/osc/osc_cl_internal.h @@ -329,7 +329,6 @@ struct osc_lock { struct osc_io *ols_owner; }; - /** * Page state private for osc layer. */ diff --git a/drivers/staging/lustre/lustre/osc/osc_io.c b/drivers/staging/lustre/lustre/osc/osc_io.c index 8d7eab0856a0..3a4200fa8b6f 100644 --- a/drivers/staging/lustre/lustre/osc/osc_io.c +++ b/drivers/staging/lustre/lustre/osc/osc_io.c @@ -78,7 +78,6 @@ static struct osc_page *osc_cl_page_osc(struct cl_page *page) return cl2osc_page(slice); } - /***************************************************************************** * * io operations. @@ -788,7 +787,6 @@ static const struct cl_req_operations osc_req_ops = { .cro_completion = osc_req_completion }; - int osc_io_init(const struct lu_env *env, struct cl_object *obj, struct cl_io *io) { diff --git a/drivers/staging/lustre/lustre/osc/osc_object.c b/drivers/staging/lustre/lustre/osc/osc_object.c index c628a250ebd6..acffab954ad7 100644 --- a/drivers/staging/lustre/lustre/osc/osc_object.c +++ b/drivers/staging/lustre/lustre/osc/osc_object.c @@ -148,7 +148,6 @@ static int osc_object_print(const struct lu_env *env, void *cookie, return 0; } - static int osc_attr_get(const struct lu_env *env, struct cl_object *obj, struct cl_attr *attr) { @@ -193,7 +192,6 @@ static int osc_object_glimpse(const struct lu_env *env, return 0; } - void osc_object_set_contended(struct osc_object *obj) { obj->oo_contention_time = cfs_time_current(); diff --git a/drivers/staging/lustre/lustre/osc/osc_page.c b/drivers/staging/lustre/lustre/osc/osc_page.c index d696b321a659..61eaf7172fdf 100644 --- a/drivers/staging/lustre/lustre/osc/osc_page.c +++ b/drivers/staging/lustre/lustre/osc/osc_page.c @@ -347,7 +347,6 @@ static int osc_page_fail(const struct lu_env *env, return 0; } - static const char *osc_list(struct list_head *head) { return list_empty(head) ? "-" : "+"; diff --git a/drivers/staging/lustre/lustre/osc/osc_request.c b/drivers/staging/lustre/lustre/osc/osc_request.c index e3808c97043f..a3a63749a0fc 100644 --- a/drivers/staging/lustre/lustre/osc/osc_request.c +++ b/drivers/staging/lustre/lustre/osc/osc_request.c @@ -38,7 +38,6 @@ #include "../../include/linux/libcfs/libcfs.h" - #include "../include/lustre_dlm.h" #include "../include/lustre_net.h" #include "../include/lustre/lustre_user.h" @@ -2592,7 +2591,6 @@ static int osc_getstripe(struct lov_stripe_md *lsm, struct lov_user_md *lump) return rc; } - static int osc_iocontrol(unsigned int cmd, struct obd_export *exp, int len, void *karg, void *uarg) { diff --git a/drivers/staging/lustre/lustre/ptlrpc/events.c b/drivers/staging/lustre/lustre/ptlrpc/events.c index 183e4156950d..9c2fd34e2eb9 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/events.c +++ b/drivers/staging/lustre/lustre/ptlrpc/events.c @@ -415,7 +415,6 @@ void reply_out_callback(lnet_event_t *ev) } } - static void ptlrpc_master_callback(lnet_event_t *ev) { struct ptlrpc_cb_id *cbid = ev->md.user_ptr; @@ -560,7 +559,6 @@ static int ptlrpc_ni_init(void) return -ENOMEM; } - int ptlrpc_init_portals(void) { int rc = ptlrpc_ni_init(); diff --git a/drivers/staging/lustre/lustre/ptlrpc/import.c b/drivers/staging/lustre/lustre/ptlrpc/import.c index 23d45e8c67b3..bfa410f7e773 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/import.c +++ b/drivers/staging/lustre/lustre/ptlrpc/import.c @@ -103,7 +103,6 @@ do { \ spin_unlock(&imp->imp_lock); \ } while (0) - static int ptlrpc_connect_interpret(const struct lu_env *env, struct ptlrpc_request *request, void *data, int rc); @@ -942,7 +941,6 @@ static int ptlrpc_connect_interpret(const struct lu_env *env, request->rq_repmsg)->cookie); } - imp->imp_remote_handle = *lustre_msg_get_handle(request->rq_repmsg); diff --git a/drivers/staging/lustre/lustre/ptlrpc/layout.c b/drivers/staging/lustre/lustre/ptlrpc/layout.c index 36876a803b41..637fd2af81d3 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/layout.c +++ b/drivers/staging/lustre/lustre/ptlrpc/layout.c @@ -578,7 +578,6 @@ static const struct req_msg_field *ost_destroy_client[] = { &RMF_CAPA1 }; - static const struct req_msg_field *ost_brw_client[] = { &RMF_PTLRPC_BODY, &RMF_OST_BODY, diff --git a/drivers/staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c b/drivers/staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c index 593613276c8f..05270e18d106 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c +++ b/drivers/staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c @@ -35,7 +35,6 @@ */ #define DEBUG_SUBSYSTEM S_CLASS - #include "../include/obd_support.h" #include "../include/obd.h" #include "../include/lprocfs_status.h" @@ -44,7 +43,6 @@ #include "../include/obd_class.h" #include "ptlrpc_internal.h" - static struct ll_rpc_opcode { __u32 opcode; const char *opname; @@ -326,7 +324,6 @@ ptlrpc_lprocfs_req_history_max_seq_write(struct file *file, } LPROC_SEQ_FOPS(ptlrpc_lprocfs_req_history_max); - static ssize_t threads_min_show(struct kobject *kobj, struct attribute *attr, char *buf) { diff --git a/drivers/staging/lustre/lustre/ptlrpc/niobuf.c b/drivers/staging/lustre/lustre/ptlrpc/niobuf.c index d93c6b2524b9..09ddeef6ba48 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/niobuf.c +++ b/drivers/staging/lustre/lustre/ptlrpc/niobuf.c @@ -106,7 +106,6 @@ static void mdunlink_iterate_helper(lnet_handle_md_t *bd_mds, int count) LNetMDUnlink(bd_mds[i]); } - /** * Register bulk at the sender for later transfer. * Returns 0 on success or error code. diff --git a/drivers/staging/lustre/lustre/ptlrpc/nrs.c b/drivers/staging/lustre/lustre/ptlrpc/nrs.c index 3fe96a183401..7044e1ff6692 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/nrs.c +++ b/drivers/staging/lustre/lustre/ptlrpc/nrs.c @@ -1573,7 +1573,6 @@ out: return rc; } - /* ptlrpc/nrs_fifo.c */ extern struct ptlrpc_nrs_pol_conf nrs_conf_fifo; @@ -1595,7 +1594,6 @@ int ptlrpc_nrs_init(void) if (rc != 0) goto fail; - return rc; fail: /** diff --git a/drivers/staging/lustre/lustre/ptlrpc/pack_generic.c b/drivers/staging/lustre/lustre/ptlrpc/pack_generic.c index ef33c5b7e852..f3cb5184fa85 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/pack_generic.c +++ b/drivers/staging/lustre/lustre/ptlrpc/pack_generic.c @@ -1057,7 +1057,6 @@ __u64 lustre_msg_get_slv(struct lustre_msg *msg) } EXPORT_SYMBOL(lustre_msg_get_slv); - void lustre_msg_set_slv(struct lustre_msg *msg, __u64 slv) { switch (msg->lm_magic) { @@ -1097,7 +1096,6 @@ __u32 lustre_msg_get_limit(struct lustre_msg *msg) } EXPORT_SYMBOL(lustre_msg_get_limit); - void lustre_msg_set_limit(struct lustre_msg *msg, __u64 limit) { switch (msg->lm_magic) { @@ -1402,7 +1400,6 @@ void lustre_msg_set_cksum(struct lustre_msg *msg, __u32 cksum) } } - void ptlrpc_request_set_replen(struct ptlrpc_request *req) { int count = req_capsule_filled_sizes(&req->rq_pill, RCL_SERVER); diff --git a/drivers/staging/lustre/lustre/ptlrpc/pers.c b/drivers/staging/lustre/lustre/ptlrpc/pers.c index e1334c24ebe3..2a2a9fb6549c 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/pers.c +++ b/drivers/staging/lustre/lustre/ptlrpc/pers.c @@ -42,7 +42,6 @@ #include "ptlrpc_internal.h" - void ptlrpc_fill_bulk_md(lnet_md_t *md, struct ptlrpc_bulk_desc *desc, int mdidx) { diff --git a/drivers/staging/lustre/lustre/ptlrpc/ptlrpc_module.c b/drivers/staging/lustre/lustre/ptlrpc/ptlrpc_module.c index d12e95bc9dce..9deeb244166f 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/ptlrpc_module.c +++ b/drivers/staging/lustre/lustre/ptlrpc/ptlrpc_module.c @@ -36,7 +36,6 @@ #define DEBUG_SUBSYSTEM S_RPC - #include "../include/obd_support.h" #include "../include/obd_class.h" #include "../include/lustre_net.h" diff --git a/drivers/staging/lustre/lustre/ptlrpc/sec.c b/drivers/staging/lustre/lustre/ptlrpc/sec.c index a587c9461e95..34d133075302 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/sec.c +++ b/drivers/staging/lustre/lustre/ptlrpc/sec.c @@ -2165,7 +2165,6 @@ int sptlrpc_cli_unwrap_bulk_write(struct ptlrpc_request *req, } EXPORT_SYMBOL(sptlrpc_cli_unwrap_bulk_write); - /**************************************** * user descriptor helpers * ****************************************/ diff --git a/drivers/staging/lustre/lustre/ptlrpc/sec_bulk.c b/drivers/staging/lustre/lustre/ptlrpc/sec_bulk.c index c89973c0e3a2..baf063efb79e 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/sec_bulk.c +++ b/drivers/staging/lustre/lustre/ptlrpc/sec_bulk.c @@ -58,7 +58,6 @@ * bulk encryption page pools * ****************************************/ - #define POINTERS_PER_PAGE (PAGE_CACHE_SIZE / sizeof(void *)) #define PAGES_PER_POOL (POINTERS_PER_PAGE) @@ -448,7 +447,6 @@ void sptlrpc_enc_pool_fini(void) } } - static int cfs_hash_alg_id[] = { [BULK_HASH_ALG_NULL] = CFS_HASH_ALG_NULL, [BULK_HASH_ALG_ADLER32] = CFS_HASH_ALG_ADLER32, diff --git a/drivers/staging/lustre/lustre/ptlrpc/sec_gc.c b/drivers/staging/lustre/lustre/ptlrpc/sec_gc.c index 520329f88465..07cf2fef4462 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/sec_gc.c +++ b/drivers/staging/lustre/lustre/ptlrpc/sec_gc.c @@ -51,7 +51,6 @@ #define SEC_GC_INTERVAL (30 * 60) - static struct mutex sec_gc_mutex; static LIST_HEAD(sec_gc_list); static spinlock_t sec_gc_list_lock; @@ -62,7 +61,6 @@ static spinlock_t sec_gc_ctx_list_lock; static struct ptlrpc_thread sec_gc_thread; static atomic_t sec_gc_wait_del = ATOMIC_INIT(0); - void sptlrpc_gc_add_sec(struct ptlrpc_sec *sec) { LASSERT(sec->ps_policy->sp_cops->gc_ctx); diff --git a/drivers/staging/lustre/lustre/ptlrpc/sec_null.c b/drivers/staging/lustre/lustre/ptlrpc/sec_null.c index 8a6abbc06e1b..ebfa6092be14 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/sec_null.c +++ b/drivers/staging/lustre/lustre/ptlrpc/sec_null.c @@ -40,7 +40,6 @@ #define DEBUG_SUBSYSTEM S_SEC - #include "../include/obd_support.h" #include "../include/obd_cksum.h" #include "../include/obd_class.h" diff --git a/drivers/staging/lustre/lustre/ptlrpc/sec_plain.c b/drivers/staging/lustre/lustre/ptlrpc/sec_plain.c index d905b77b758b..f448b4567af0 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/sec_plain.c +++ b/drivers/staging/lustre/lustre/ptlrpc/sec_plain.c @@ -40,7 +40,6 @@ #define DEBUG_SUBSYSTEM S_SEC - #include "../include/obd_support.h" #include "../include/obd_cksum.h" #include "../include/obd_class.h" diff --git a/drivers/staging/lustre/lustre/ptlrpc/service.c b/drivers/staging/lustre/lustre/ptlrpc/service.c index 2652fc81f66a..3f6f07002726 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/service.c +++ b/drivers/staging/lustre/lustre/ptlrpc/service.c @@ -58,7 +58,6 @@ MODULE_PARM_DESC(at_early_margin, "How soon before an RPC deadline to send an ea module_param(at_extra, int, 0644); MODULE_PARM_DESC(at_extra, "How much extra time to give with each early reply"); - /* forward ref */ static int ptlrpc_server_post_idle_rqbds(struct ptlrpc_service_part *svcpt); static void ptlrpc_server_hpreq_fini(struct ptlrpc_request *req); @@ -143,7 +142,6 @@ ptlrpc_grow_req_bufs(struct ptlrpc_service_part *svcpt, int post) svcpt->scp_rqbd_allocating++; spin_unlock(&svcpt->scp_lock); - for (i = 0; i < svc->srv_nbuf_per_group; i++) { /* NB: another thread might have recycled enough rqbds, we * need to make sure it wouldn't over-allocate, see LU-1212. */ @@ -1848,7 +1846,6 @@ ptlrpc_handle_rs(struct ptlrpc_reply_state *rs) return 1; } - static void ptlrpc_check_rqbd_pool(struct ptlrpc_service_part *svcpt) { @@ -2553,7 +2550,6 @@ void ptlrpc_hr_fini(void) ptlrpc_hr.hr_partitions = NULL; } - /** * Wait until all already scheduled replies are processed. */