#define WIRE_ATTR __packed
/* Packed version of lnet_process_id_t to transfer via network */
-typedef struct {
+struct lnet_process_id_packed {
/* node id / process id */
lnet_nid_t nid;
lnet_pid_t pid;
-} WIRE_ATTR lnet_process_id_packed_t;
+} WIRE_ATTR;
/*
* The wire handle's interface cookie only matches one network interface in
return 0;
}
-static lnet_process_id_packed_t *
+static struct lnet_process_id_packed *
lstcon_next_id(int idx, int nkiov, lnet_kiov_t *kiov)
{
- lnet_process_id_packed_t *pid;
+ struct lnet_process_id_packed *pid;
int i;
i = idx / SFW_ID_PER_PAGE;
LASSERT(i < nkiov);
- pid = (lnet_process_id_packed_t *)page_address(kiov[i].bv_page);
+ pid = (struct lnet_process_id_packed *)page_address(kiov[i].bv_page);
return &pid[idx % SFW_ID_PER_PAGE];
}
lstcon_dstnodes_prep(struct lstcon_group *grp, int idx,
int dist, int span, int nkiov, lnet_kiov_t *kiov)
{
- lnet_process_id_packed_t *pid;
+ struct lnet_process_id_packed *pid;
struct lstcon_ndlink *ndl;
struct lstcon_node *nd;
int start;
npg = sfw_id_pages(test->tes_span);
nob = !(feats & LST_FEAT_BULK_LEN) ?
npg * PAGE_SIZE :
- sizeof(lnet_process_id_packed_t) * test->tes_span;
+ sizeof(struct lnet_process_id_packed) * test->tes_span;
}
rc = lstcon_rpc_prep(nd, SRPC_SERVICE_TEST, feats, npg, nob, crpc);
LASSERT(bk);
LASSERT(bk->bk_niov * SFW_ID_PER_PAGE >= (unsigned int)ndest);
LASSERT((unsigned int)bk->bk_len >=
- sizeof(lnet_process_id_packed_t) * ndest);
+ sizeof(struct lnet_process_id_packed) * ndest);
sfw_unpack_addtest_req(msg);
memcpy(&tsi->tsi_u, &req->tsr_u, sizeof(tsi->tsi_u));
for (i = 0; i < ndest; i++) {
- lnet_process_id_packed_t *dests;
- lnet_process_id_packed_t id;
+ struct lnet_process_id_packed *dests;
+ struct lnet_process_id_packed id;
int j;
dests = page_address(bk->bk_iovs[i / SFW_ID_PER_PAGE].bv_page);
len = npg * PAGE_SIZE;
} else {
- len = sizeof(lnet_process_id_packed_t) *
+ len = sizeof(struct lnet_process_id_packed) *
request->tsr_ndest;
}
* pages are not used
*/
#define SFW_MAX_CONCUR LST_MAX_CONCUR
-#define SFW_ID_PER_PAGE (PAGE_SIZE / sizeof(lnet_process_id_packed_t))
+#define SFW_ID_PER_PAGE (PAGE_SIZE / sizeof(struct lnet_process_id_packed))
#define SFW_MAX_NDESTS (LNET_MAX_IOV * SFW_ID_PER_PAGE)
#define sfw_id_pages(n) (((n) + SFW_ID_PER_PAGE - 1) / SFW_ID_PER_PAGE)