index e5275b725e3f78712283b49eeb4f20e390fc584b..d1ba031e92f4cb50489f2124eee30f95e4f6c7d8 100644 (file)
rpfxn->params[i].reserved = param->param.ptr.handle;
break;
+ case MmRpc_ParamType_OffPtr:
+ rpfxn->params[i].type = RPPC_PARAM_TYPE_PTR;
+ rpfxn->params[i].size = param->param.offPtr.size;
+ rpfxn->params[i].data = param->param.offPtr.base +
+ param->param.offPtr.offset;
+ rpfxn->params[i].base = param->param.offPtr.base;
+ rpfxn->params[i].reserved = param->param.offPtr.handle;
+ break;
+
#if 0 /* TBD */
case MmRpc_ParamType_Elem:
rpfxn->params[i].type = RPPC_PARAM_TYPE_PTR;
rpfxn->num_translations = ctx->num_xlts;
for (i = 0; i < ctx->num_xlts; i++) {
- rpfxn->translations[i].index = ctx->xltAry[i].index;
+ uint32_t index;
+ size_t ptr;
+
+ /* compute base value */
+ index = ctx->xltAry[i].index;
+ ptr = rpfxn->params[index].base + ctx->xltAry[i].offset;
+
+ /* pack the pointer translation entry */
+ rpfxn->translations[i].index = index;
rpfxn->translations[i].offset = ctx->xltAry[i].offset;
- rpfxn->translations[i].base = ctx->xltAry[i].base;
+ rpfxn->translations[i].base = (size_t)(*(void **)ptr);
rpfxn->translations[i].reserved = ctx->xltAry[i].handle;
}