PatchworkOS  19e446b
A non-POSIX operating system.
Loading...
Searching...
No Matches
local.c File Reference
#include "local.h"
#include "local_conn.h"
#include "local_listen.h"
#include <kernel/fs/filesystem.h>
#include <kernel/fs/netfs.h>
#include <kernel/fs/path.h>
#include <kernel/log/log.h>
#include <kernel/log/panic.h>
#include <kernel/module/module.h>
#include <kernel/sched/wait.h>
#include <kernel/sync/lock.h>
#include <kernel/utils/fifo.h>
#include <kernel/utils/ref.h>
#include <stdlib.h>
#include <sys/fs.h>
#include <sys/list.h>
Include dependency graph for local.c:

Go to the source code of this file.

Functions

static local_listen_tlocal_socket_get_listen (local_socket_t *data)
 
static local_conn_tlocal_socket_get_conn (local_socket_t *data)
 
static uint64_t local_socket_init (socket_t *sock)
 
static void local_socket_deinit (socket_t *sock)
 
static uint64_t local_socket_bind (socket_t *sock)
 
static uint64_t local_socket_listen (socket_t *sock, uint32_t backlog)
 
static uint64_t local_socket_connect (socket_t *sock)
 
static uint64_t local_socket_accept (socket_t *sock, socket_t *newSock, mode_t mode)
 
static size_t local_socket_send (socket_t *sock, const void *buffer, size_t count, size_t *offset, mode_t mode)
 
static size_t local_socket_recv (socket_t *sock, void *buffer, size_t count, size_t *offset, mode_t mode)
 
static wait_queue_tlocal_socket_poll (socket_t *sock, poll_events_t *revents)
 
uint64_t _module_procedure (const module_event_t *event)
 
 MODULE_INFO ("Local Networking", "Kai Norberg", "Local networking module", OS_VERSION, "MIT", "BOOT_ALWAYS")
 

Variables

static netfs_family_t local
 

Function Documentation

◆ local_socket_get_listen()

static local_listen_t * local_socket_get_listen ( local_socket_t data)
static

Definition at line 21 of file local.c.

Here is the caller graph for this function:

◆ local_socket_get_conn()

static local_conn_t * local_socket_get_conn ( local_socket_t data)
static

Definition at line 31 of file local.c.

Here is the caller graph for this function:

◆ local_socket_init()

static uint64_t local_socket_init ( socket_t sock)
static

Definition at line 41 of file local.c.

Here is the call graph for this function:

◆ local_socket_deinit()

static void local_socket_deinit ( socket_t sock)
static

Definition at line 58 of file local.c.

Here is the call graph for this function:

◆ local_socket_bind()

static uint64_t local_socket_bind ( socket_t sock)
static

Definition at line 94 of file local.c.

Here is the call graph for this function:

◆ local_socket_listen()

static uint64_t local_socket_listen ( socket_t sock,
uint32_t  backlog 
)
static

Definition at line 119 of file local.c.

◆ local_socket_connect()

static uint64_t local_socket_connect ( socket_t sock)
static

Definition at line 145 of file local.c.

Here is the call graph for this function:

◆ local_socket_accept()

static uint64_t local_socket_accept ( socket_t sock,
socket_t newSock,
mode_t  mode 
)
static

Definition at line 199 of file local.c.

Here is the call graph for this function:

◆ local_socket_send()

static size_t local_socket_send ( socket_t sock,
const void *  buffer,
size_t  count,
size_t offset,
mode_t  mode 
)
static

Definition at line 264 of file local.c.

Here is the call graph for this function:

◆ local_socket_recv()

static size_t local_socket_recv ( socket_t sock,
void *  buffer,
size_t  count,
size_t offset,
mode_t  mode 
)
static

Definition at line 332 of file local.c.

Here is the call graph for this function:

◆ local_socket_poll()

static wait_queue_t * local_socket_poll ( socket_t sock,
poll_events_t revents 
)
static

Definition at line 409 of file local.c.

Here is the call graph for this function:

◆ _module_procedure()

uint64_t _module_procedure ( const module_event_t event)

Definition at line 492 of file local.c.

Here is the call graph for this function:

◆ MODULE_INFO()

MODULE_INFO ( "Local Networking"  ,
"Kai Norberg"  ,
"Local networking module"  ,
OS_VERSION  ,
"MIT"  ,
"BOOT_ALWAYS"   
)

Variable Documentation

◆ local

netfs_family_t local
static
Initial value:
= {
.name = "local",
}
static uint64_t local_socket_accept(socket_t *sock, socket_t *newSock, mode_t mode)
Definition local.c:199
static uint64_t local_socket_connect(socket_t *sock)
Definition local.c:145
static size_t local_socket_send(socket_t *sock, const void *buffer, size_t count, size_t *offset, mode_t mode)
Definition local.c:264
static void local_socket_deinit(socket_t *sock)
Definition local.c:58
static uint64_t local_socket_init(socket_t *sock)
Definition local.c:41
static wait_queue_t * local_socket_poll(socket_t *sock, poll_events_t *revents)
Definition local.c:409
static uint64_t local_socket_listen(socket_t *sock, uint32_t backlog)
Definition local.c:119
static size_t local_socket_recv(socket_t *sock, void *buffer, size_t count, size_t *offset, mode_t mode)
Definition local.c:332
static uint64_t local_socket_bind(socket_t *sock)
Definition local.c:94

Definition at line 479 of file local.c.