mirror of
https://github.com/NVIDIA/open-gpu-kernel-modules.git
synced 2026-02-24 17:03:58 +00:00
550.40.07
This commit is contained in:
@@ -137,10 +137,6 @@ static void __nvoc_thunk_RmResource_hdacodecControl_Epilogue(struct Hdacodec *pR
|
||||
rmresControl_Epilogue((struct RmResource *)(((unsigned char *)pResource) + __nvoc_rtti_Hdacodec_RmResource.offset), pCallContext, pParams);
|
||||
}
|
||||
|
||||
static NV_STATUS __nvoc_thunk_RsResource_hdacodecControlLookup(struct Hdacodec *pResource, struct RS_RES_CONTROL_PARAMS_INTERNAL *pParams, const struct NVOC_EXPORTED_METHOD_DEF **ppEntry) {
|
||||
return resControlLookup((struct RsResource *)(((unsigned char *)pResource) + __nvoc_rtti_Hdacodec_RsResource.offset), pParams, ppEntry);
|
||||
}
|
||||
|
||||
static NvHandle __nvoc_thunk_GpuResource_hdacodecGetInternalObjectHandle(struct Hdacodec *pGpuResource) {
|
||||
return gpuresGetInternalObjectHandle((struct GpuResource *)(((unsigned char *)pGpuResource) + __nvoc_rtti_Hdacodec_GpuResource.offset));
|
||||
}
|
||||
@@ -173,6 +169,10 @@ static NvBool __nvoc_thunk_RsResource_hdacodecCanCopy(struct Hdacodec *pResource
|
||||
return resCanCopy((struct RsResource *)(((unsigned char *)pResource) + __nvoc_rtti_Hdacodec_RsResource.offset));
|
||||
}
|
||||
|
||||
static NvBool __nvoc_thunk_RsResource_hdacodecIsPartialUnmapSupported(struct Hdacodec *pResource) {
|
||||
return resIsPartialUnmapSupported((struct RsResource *)(((unsigned char *)pResource) + __nvoc_rtti_Hdacodec_RsResource.offset));
|
||||
}
|
||||
|
||||
static void __nvoc_thunk_RsResource_hdacodecPreDestruct(struct Hdacodec *pResource) {
|
||||
resPreDestruct((struct RsResource *)(((unsigned char *)pResource) + __nvoc_rtti_Hdacodec_RsResource.offset));
|
||||
}
|
||||
@@ -253,8 +253,6 @@ static void __nvoc_init_funcTable_Hdacodec_1(Hdacodec *pThis) {
|
||||
|
||||
pThis->__hdacodecControl_Epilogue__ = &__nvoc_thunk_RmResource_hdacodecControl_Epilogue;
|
||||
|
||||
pThis->__hdacodecControlLookup__ = &__nvoc_thunk_RsResource_hdacodecControlLookup;
|
||||
|
||||
pThis->__hdacodecGetInternalObjectHandle__ = &__nvoc_thunk_GpuResource_hdacodecGetInternalObjectHandle;
|
||||
|
||||
pThis->__hdacodecControl__ = &__nvoc_thunk_GpuResource_hdacodecControl;
|
||||
@@ -271,6 +269,8 @@ static void __nvoc_init_funcTable_Hdacodec_1(Hdacodec *pThis) {
|
||||
|
||||
pThis->__hdacodecCanCopy__ = &__nvoc_thunk_RsResource_hdacodecCanCopy;
|
||||
|
||||
pThis->__hdacodecIsPartialUnmapSupported__ = &__nvoc_thunk_RsResource_hdacodecIsPartialUnmapSupported;
|
||||
|
||||
pThis->__hdacodecPreDestruct__ = &__nvoc_thunk_RsResource_hdacodecPreDestruct;
|
||||
|
||||
pThis->__hdacodecIsDuplicate__ = &__nvoc_thunk_RsResource_hdacodecIsDuplicate;
|
||||
@@ -298,21 +298,26 @@ void __nvoc_init_Hdacodec(Hdacodec *pThis) {
|
||||
__nvoc_init_funcTable_Hdacodec(pThis);
|
||||
}
|
||||
|
||||
NV_STATUS __nvoc_objCreate_Hdacodec(Hdacodec **ppThis, Dynamic *pParent, NvU32 createFlags, struct CALL_CONTEXT * arg_pCallContext, struct RS_RES_ALLOC_PARAMS_INTERNAL * arg_pParams) {
|
||||
NV_STATUS __nvoc_objCreate_Hdacodec(Hdacodec **ppThis, Dynamic *pParent, NvU32 createFlags, struct CALL_CONTEXT * arg_pCallContext, struct RS_RES_ALLOC_PARAMS_INTERNAL * arg_pParams)
|
||||
{
|
||||
NV_STATUS status;
|
||||
Object *pParentObj;
|
||||
Object *pParentObj = NULL;
|
||||
Hdacodec *pThis;
|
||||
|
||||
// Assign `pThis`, allocating memory unless suppressed by flag.
|
||||
status = __nvoc_handleObjCreateMemAlloc(createFlags, sizeof(Hdacodec), (void**)&pThis, (void**)ppThis);
|
||||
if (status != NV_OK)
|
||||
return status;
|
||||
|
||||
// Zero is the initial value for everything.
|
||||
portMemSet(pThis, 0, sizeof(Hdacodec));
|
||||
|
||||
// Initialize runtime type information.
|
||||
__nvoc_initRtti(staticCast(pThis, Dynamic), &__nvoc_class_def_Hdacodec);
|
||||
|
||||
pThis->__nvoc_base_GpuResource.__nvoc_base_RmResource.__nvoc_base_RsResource.__nvoc_base_Object.createFlags = createFlags;
|
||||
|
||||
// Link the child into the parent if there is one unless flagged not to do so.
|
||||
if (pParent != NULL && !(createFlags & NVOC_OBJ_CREATE_FLAGS_PARENT_HALSPEC_ONLY))
|
||||
{
|
||||
pParentObj = dynamicCast(pParent, Object);
|
||||
@@ -327,16 +332,25 @@ NV_STATUS __nvoc_objCreate_Hdacodec(Hdacodec **ppThis, Dynamic *pParent, NvU32 c
|
||||
status = __nvoc_ctor_Hdacodec(pThis, arg_pCallContext, arg_pParams);
|
||||
if (status != NV_OK) goto __nvoc_objCreate_Hdacodec_cleanup;
|
||||
|
||||
// Assignment has no effect if NVOC_OBJ_CREATE_FLAGS_IN_PLACE_CONSTRUCT is set.
|
||||
*ppThis = pThis;
|
||||
|
||||
return NV_OK;
|
||||
|
||||
__nvoc_objCreate_Hdacodec_cleanup:
|
||||
// do not call destructors here since the constructor already called them
|
||||
|
||||
// Unlink the child from the parent if it was linked above.
|
||||
if (pParentObj != NULL)
|
||||
objRemoveChild(pParentObj, &pThis->__nvoc_base_GpuResource.__nvoc_base_RmResource.__nvoc_base_RsResource.__nvoc_base_Object);
|
||||
|
||||
// Do not call destructors here since the constructor already called them.
|
||||
if (createFlags & NVOC_OBJ_CREATE_FLAGS_IN_PLACE_CONSTRUCT)
|
||||
portMemSet(pThis, 0, sizeof(Hdacodec));
|
||||
else
|
||||
{
|
||||
portMemFree(pThis);
|
||||
*ppThis = NULL;
|
||||
}
|
||||
|
||||
// coverity[leaked_storage:FALSE]
|
||||
return status;
|
||||
|
||||
Reference in New Issue
Block a user