L4Re Operating System Framework
Interface and Usage Documentation
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
vcon
Go to the documentation of this file.
1// vi:set ft=cpp: -*- Mode: C++ -*-
6/*
7 * (c) 2008-2009 Adam Lackorzynski <adam@os.inf.tu-dresden.de>,
8 * Alexander Warg <warg@os.inf.tu-dresden.de>,
9 * Torsten Frenzel <frenzel@os.inf.tu-dresden.de>
10 * economic rights: Technische Universität Dresden (Germany)
11 *
12 * License: see LICENSE.spdx (in this directory or the directories above)
13 */
14#pragma once
15
16#include <l4/sys/icu>
17#include <l4/sys/vcon.h>
18#include <l4/sys/capability>
19
20namespace L4 {
21
45class Vcon :
46 public Kobject_t<Vcon, Icu, L4_PROTO_LOG>
47{
48public:
65 send(char const *buf, unsigned size, l4_utcb_t *utcb = l4_utcb()) const noexcept
66 { return l4_vcon_send_u(cap(), buf, size, utcb); }
67
78 long
79 write(char const *buf, unsigned size, l4_utcb_t *utcb = l4_utcb()) const noexcept
80 { return l4_vcon_write_u(cap(), buf, size, utcb); }
81
97 int
98 read(char *buf, unsigned size, l4_utcb_t *utcb = l4_utcb()) const noexcept
99 { return l4_vcon_read_u(cap(), buf, size, utcb); }
100
124 int
125 read_with_flags(char *buf, unsigned size, l4_utcb_t *utcb = l4_utcb()) const noexcept
126 { return l4_vcon_read_with_flags_u(cap(), buf, size, utcb); }
127
138 set_attr(l4_vcon_attr_t const *attr, l4_utcb_t *utcb = l4_utcb()) const noexcept
139 { return l4_vcon_set_attr_u(cap(), attr, utcb); }
140
151 get_attr(l4_vcon_attr_t *attr, l4_utcb_t *utcb = l4_utcb()) const noexcept
152 { return l4_vcon_get_attr_u(cap(), attr, utcb); }
153
154 typedef L4::Typeid::Raw_ipc<Vcon> Rpcs;
155};
156
157}
L4::Cap related definitions.
Helper class to create an L4Re interface class that is derived from a single base class.
Definition __typeinfo.h:750
C++ L4 Vcon interface, see Virtual Console for the C interface.
Definition vcon:47
l4_msgtag_t get_attr(l4_vcon_attr_t *attr, l4_utcb_t *utcb=l4_utcb()) const noexcept
Get attributes of this virtual console.
Definition vcon:151
int read_with_flags(char *buf, unsigned size, l4_utcb_t *utcb=l4_utcb()) const noexcept
Read data from this virtual console which also returns flags.
Definition vcon:125
long write(char const *buf, unsigned size, l4_utcb_t *utcb=l4_utcb()) const noexcept
Write data to this virtual console.
Definition vcon:79
l4_msgtag_t set_attr(l4_vcon_attr_t const *attr, l4_utcb_t *utcb=l4_utcb()) const noexcept
Set the attributes of this virtual console.
Definition vcon:138
int read(char *buf, unsigned size, l4_utcb_t *utcb=l4_utcb()) const noexcept
Read data from this virtual console.
Definition vcon:98
l4_msgtag_t send(char const *buf, unsigned size, l4_utcb_t *utcb=l4_utcb()) const noexcept
Send data to this virtual console.
Definition vcon:65
struct l4_utcb_t l4_utcb_t
Opaque type for the UTCB.
Definition utcb.h:56
l4_utcb_t * l4_utcb(void) L4_NOTHROW L4_PURE
Get the UTCB address.
Definition utcb.h:346
l4_msgtag_t l4_vcon_send_u(l4_cap_idx_t vcon, char const *buf, unsigned size, l4_utcb_t *utcb) L4_NOTHROW
Send data to this virtual console.
Definition vcon.h:300
l4_msgtag_t l4_vcon_set_attr_u(l4_cap_idx_t vcon, l4_vcon_attr_t const *attr, l4_utcb_t *utcb) L4_NOTHROW
Set the attributes of this virtual console.
Definition vcon.h:395
long l4_vcon_write_u(l4_cap_idx_t vcon, char const *buf, unsigned size, l4_utcb_t *utcb) L4_NOTHROW
Write data to this virtual console.
Definition vcon.h:319
int l4_vcon_read_u(l4_cap_idx_t vcon, char *buf, unsigned size, l4_utcb_t *utcb) L4_NOTHROW
Read data from this virtual console.
Definition vcon.h:379
l4_msgtag_t l4_vcon_get_attr_u(l4_cap_idx_t vcon, l4_vcon_attr_t *attr, l4_utcb_t *utcb) L4_NOTHROW
Get attributes of this virtual console.
Definition vcon.h:415
Interrupt controller.
L4 low-level kernel interface.
RPCs list for passing raw incoming IPC to the server object.
Definition __typeinfo.h:413
Message tag data structure.
Definition types.h:153
Vcon attribute structure.
Definition vcon.h:186
Virtual console interface.