Skip to content

Commit

Permalink
uapi: Implement new context functions
Browse files Browse the repository at this point in the history
  • Loading branch information
marv7000 committed Dec 27, 2024
1 parent fe6a697 commit 8bda3f1
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
13 changes: 13 additions & 0 deletions kernel/system/uapi/pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,16 @@ uapi_status uapi_kernel_pci_cfg_write(uapi_handle handle, uapi_size offset, uapi
}
return UAPI_STATUS_OK;
}

uapi_status uapi_kernel_pci_set_ctx(uapi_handle handle, void* ctx)
{
PciDevice* const device = handle;
device->dev->driver_data = ctx;
return UAPI_STATUS_OK;
}

void* uapi_kernel_pci_get_ctx(uapi_handle handle)
{
PciDevice* const device = handle;
return device->dev->driver_data;
}
2 changes: 1 addition & 1 deletion kernel/system/uapi/uapi
Submodule uapi updated 1 files
+8 −1 pci.h

0 comments on commit 8bda3f1

Please sign in to comment.