Skip to content

Commit a3463e6

Browse files
jamesasimmonsgregkh
authored andcommitted
staging: lustre: ptlrpc : remove userland usage from ptlrpc
The reason for __REQ_LAYOUT_USER__ was to expose a section of code in layout.c to userland for a utility similar to wireshark. This was done before wireshark existed but now that it does we no longer need to do this type of hack. This also reduces lustre_acl.h to strictly a kernel header now. Signed-off-by: James Simmons <[email protected]> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-8945 Reviewed-on: https://review.whamcloud.com/24396 Reviewed-by: Dmitry Eremin <[email protected]> Reviewed-by: Andreas Dilger <[email protected]> Reviewed-by: Oleg Drokin <[email protected]> Signed-off-by: James Simmons <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 86df598 commit a3463e6

File tree

2 files changed

+2
-17
lines changed

2 files changed

+2
-17
lines changed

drivers/staging/lustre/lustre/include/lustre_req_layout.h

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@
3939
#ifndef _LUSTRE_REQ_LAYOUT_H__
4040
#define _LUSTRE_REQ_LAYOUT_H__
4141

42+
#include <linux/types.h>
43+
4244
/** \defgroup req_layout req_layout
4345
*
4446
* @{
@@ -66,11 +68,6 @@ struct req_capsule {
6668
__u32 rc_area[RCL_NR][REQ_MAX_FIELD_NR];
6769
};
6870

69-
#if !defined(__REQ_LAYOUT_USER__)
70-
71-
/* struct ptlrpc_request, lustre_msg* */
72-
#include "lustre_net.h"
73-
7471
void req_capsule_init(struct req_capsule *pill, struct ptlrpc_request *req,
7572
enum req_location location);
7673
void req_capsule_fini(struct req_capsule *pill);
@@ -120,9 +117,6 @@ void req_capsule_shrink(struct req_capsule *pill,
120117
int req_layout_init(void);
121118
void req_layout_fini(void);
122119

123-
/* __REQ_LAYOUT_USER__ */
124-
#endif
125-
126120
extern struct req_format RQF_OBD_PING;
127121
extern struct req_format RQF_OBD_SET_INFO;
128122
extern struct req_format RQF_SEC_CTX;

drivers/staging/lustre/lustre/ptlrpc/layout.c

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,6 @@
4242
* of the format that the request conforms to.
4343
*/
4444

45-
#if !defined(__REQ_LAYOUT_USER__)
46-
4745
#define DEBUG_SUBSYSTEM S_RPC
4846

4947
#include <linux/module.h>
@@ -57,8 +55,6 @@
5755
#include "../include/obd.h"
5856
#include "../include/obd_support.h"
5957

60-
/* __REQ_LAYOUT_USER__ */
61-
#endif
6258
/* struct ptlrpc_request, lustre_msg* */
6359
#include "../include/lustre_req_layout.h"
6460
#include "../include/lustre_acl.h"
@@ -1558,8 +1554,6 @@ struct req_format RQF_OST_GET_INFO_FIEMAP =
15581554
ost_get_fiemap_server);
15591555
EXPORT_SYMBOL(RQF_OST_GET_INFO_FIEMAP);
15601556

1561-
#if !defined(__REQ_LAYOUT_USER__)
1562-
15631557
/* Convenience macro */
15641558
#define FMT_FIELD(fmt, i, j) (fmt)->rf_fields[(i)].d[(j)]
15651559

@@ -2238,6 +2232,3 @@ void req_capsule_shrink(struct req_capsule *pill,
22382232
1);
22392233
}
22402234
EXPORT_SYMBOL(req_capsule_shrink);
2241-
2242-
/* __REQ_LAYOUT_USER__ */
2243-
#endif

0 commit comments

Comments
 (0)