Voxia OS v0.0.1
Hobby Project Operating System Targeting x86-64
Loading...
Searching...
No Matches
ioforge.c File Reference
#include "hal/acpi/hpet.h"
#include "ioforge/ioforge_pci.h"
#include "memory/kalloc.h"
#include "memory/memory_utils.h"
#include "memory/phys_base_allocator.h"
#include "memory/vm_manager.h"
#include <console/console.h>
#include <hal/pci/pci.h>
#include <ioforge/ioforge.h>
#include <ioforge/ioforge_usb.h>
#include <libk/serial.h>
#include <str.h>
#include "hal/apic/ioapic.h"
#include "hal/cpu/interrupt.h"
#include "hal/cpu/paging.h"
#include "hal/timer/timer.h"
#include "init/init.h"
#include "libk/debug/debug.h"
#include "type.h"
#include <hal/cpu/core.h>

Go to the source code of this file.

Functions

void __attribute__ ((used, visibility("default"), section(".export")))
 This function handles memory allocation for a new dentry using the slab allocator.
 
 INIT (ioforge)
 
bool ioforge_can_contain_pci (IoForgeType type)
 
 __attribute__ ((deprecated("This function is deprecated and may be " "removed in future versions.")))
 
 __attribute__ ((deprecated("deprecated")))
 

Variables

static struct ioforge_deviceroot = 0
 
static struct ioforge_devicepci_root = 0
 
static struct ioforge_deviceusb_controller_root = 0
 
static struct ioforge_deviceusb_devices_root = 0
 
static struct ioforge_deviceblock_devices_root = 0
 

Function Documentation

◆ __attribute__() [1/3]

__attribute__ ( (deprecated("deprecated")) )

◆ __attribute__() [2/3]

__attribute__ ( (deprecated("This function is deprecated and may be " "removed in future versions.")) )

Definition at line 192 of file ioforge.c.

References DEPRECATED, kalloc(), KERNEL_API, and size.

◆ __attribute__() [3/3]

void __attribute__ ( (used, visibility("default"), section(".export")) )

This function handles memory allocation for a new dentry using the slab allocator.

It also links the dentry to its corresponding VNode (if provided).

Note
This function performs lazy initialization of the dentry slab cache if it does not exist yet.
Parameters
nameThe name of the file or directory.
vnodePointer to the associated VNode (inode data). Pass NULL if the VNode is not yet available.
Returns
dentry_ptr A pointer to the newly allocated and initialized dentry.

Definition at line 31 of file ioforge.c.

References ioforge_usb_device::base, ioforge_pci_device::device_id, ioforge_device::first_child, IOFORGE_PCI, IOFORGE_USB_DEVICE, IOFORGE_VIRTIO, KERNEL_API, ioforge_device::name, ioforge_device::next_sibling, print_device_tree(), serial2_printf(), ioforge_usb_device::serial_number, ioforge_device::type, and ioforge_pci_device::vendor_id.

◆ INIT()

◆ ioforge_can_contain_pci()

bool ioforge_can_contain_pci ( IoForgeType type)

Definition at line 149 of file ioforge.c.

References IOFORGE_ACPI, IOFORGE_PCI, IOFORGE_PCI_BUS, IOFORGE_ROOT, and type.

Variable Documentation

◆ block_devices_root

struct ioforge_device* block_devices_root = 0
static

Definition at line 29 of file ioforge.c.

Referenced by INIT().

◆ pci_root

struct ioforge_device* pci_root = 0
static

Definition at line 26 of file ioforge.c.

Referenced by INIT(), and INIT().

◆ root

◆ usb_controller_root

struct ioforge_device* usb_controller_root = 0
static

Definition at line 27 of file ioforge.c.

Referenced by INIT().

◆ usb_devices_root

struct ioforge_device* usb_devices_root = 0
static

Definition at line 28 of file ioforge.c.

Referenced by INIT().