From c2a8c485746b099d601a9ee7ca1d90deb16b6825 Mon Sep 17 00:00:00 2001 From: Norman Feske Date: Thu, 24 Jan 2013 11:35:27 +0100 Subject: [PATCH] Coding style fixes --- base/src/core/cpu_session_component.cc | 2 +- base/src/core/include/cap_root.h | 3 ++- base/src/core/include/cpu_root.h | 10 +++++----- base/src/core/include/dataspace_component.h | 8 +++++--- base/src/core/include/signal_root.h | 1 + base/src/core/io_mem_session_component.cc | 1 + base/src/core/multiboot_info.cc | 3 +-- base/src/core/rm_session_component.cc | 1 - base/src/core/signal_session_component.cc | 4 +++- base/src/core/signal_source_component.cc | 1 + 10 files changed, 20 insertions(+), 14 deletions(-) diff --git a/base/src/core/cpu_session_component.cc b/base/src/core/cpu_session_component.cc index df6e1b85a..9e2fab0fe 100644 --- a/base/src/core/cpu_session_component.cc +++ b/base/src/core/cpu_session_component.cc @@ -1,4 +1,4 @@ -/** +/* * \brief Core implementation of the CPU session/thread interfaces * \author Christian Helmuth * \date 2006-07-17 diff --git a/base/src/core/include/cap_root.h b/base/src/core/include/cap_root.h index dc147d49b..86a5547e4 100644 --- a/base/src/core/include/cap_root.h +++ b/base/src/core/include/cap_root.h @@ -25,7 +25,8 @@ namespace Genode { class Cap_root : public Root_component { private: - Allocator *_md_alloc; + + Allocator *_md_alloc; protected: diff --git a/base/src/core/include/cpu_root.h b/base/src/core/include/cpu_root.h index f16905f91..74954502b 100644 --- a/base/src/core/include/cpu_root.h +++ b/base/src/core/include/cpu_root.h @@ -36,11 +36,11 @@ namespace Genode { return new (md_alloc()) Cpu_session_component(_thread_ep, _pager_ep, _md_alloc, args); } - void _upgrade_session(Cpu_session_component *cpu, const char *args) - { - size_t ram_quota = Arg_string::find_arg(args, "ram_quota").long_value(0); - cpu->upgrade_ram_quota(ram_quota); - } + void _upgrade_session(Cpu_session_component *cpu, const char *args) + { + size_t ram_quota = Arg_string::find_arg(args, "ram_quota").long_value(0); + cpu->upgrade_ram_quota(ram_quota); + } public: diff --git a/base/src/core/include/dataspace_component.h b/base/src/core/include/dataspace_component.h index 1fc2a8454..309f4b793 100644 --- a/base/src/core/include/dataspace_component.h +++ b/base/src/core/include/dataspace_component.h @@ -46,11 +46,13 @@ namespace Genode { RAM uncacheable respectively */ bool const _writable; /* false if dataspace is read-only */ - List _regions; /* regions this is attached to */ + List _regions; /* regions this is attached to */ Lock _lock; - /* Holds the dataspace owner if a distinction between owner and - * others is necessary on the dataspace, otherwise it is 0 */ + /* + * Holds the dataspace owner if a distinction between owner and + * others is necessary on the dataspace, otherwise it is 0. + */ Dataspace_owner const * _owner; protected: diff --git a/base/src/core/include/signal_root.h b/base/src/core/include/signal_root.h index 79e21c6dd..064e4dac5 100644 --- a/base/src/core/include/signal_root.h +++ b/base/src/core/include/signal_root.h @@ -38,6 +38,7 @@ namespace Genode { Rpc_entrypoint *entrypoint() { return &_ep; } }; + class Signal_root : private Signal_handler, public Root_component { diff --git a/base/src/core/io_mem_session_component.cc b/base/src/core/io_mem_session_component.cc index fe6737309..cc073c4ae 100644 --- a/base/src/core/io_mem_session_component.cc +++ b/base/src/core/io_mem_session_component.cc @@ -99,6 +99,7 @@ Io_mem_session_component::~Io_mem_session_component() { if (verbose) PDBG("I/O mem free [%lx,%lx)", _ds.phys_addr(), _ds.phys_addr() + _ds.size()); + /* dissolve IO_MEM dataspace from service entry point */ _ds_ep->dissolve(&_ds); diff --git a/base/src/core/multiboot_info.cc b/base/src/core/multiboot_info.cc index 7aae76f89..51e9f4c91 100644 --- a/base/src/core/multiboot_info.cc +++ b/base/src/core/multiboot_info.cc @@ -1,4 +1,4 @@ -/** +/* * \brief GRUB multi-boot information handling * \author Christian Helmuth * \date 2006-05-10 @@ -34,7 +34,6 @@ void Multiboot_info::print_debug() printf(" mem_lower = %xu\n", mbi->mem_lower); printf(" mem_upper = %xu\n", mbi->mem_upper); printf(" boot_device = %x\n", mbi->boot_device); -// printf(" cmdline = %08p \"%s\"\n", mbi->cmdline, (char *)mbi->cmdline); printf(" mods_count = %d\n", mbi->mods_count); printf(" mods_addr = %xu\n", mbi->mods_addr); diff --git a/base/src/core/rm_session_component.cc b/base/src/core/rm_session_component.cc index d56a21671..02186fca2 100644 --- a/base/src/core/rm_session_component.cc +++ b/base/src/core/rm_session_component.cc @@ -44,7 +44,6 @@ namespace Genode { addr_t _upper_bound() const { return (_size_log2 == ~0UL) ? ~0 : (_base + (1 << _size_log2) - 1); } - /** * Default constructor, constructs invalid fault area */ diff --git a/base/src/core/signal_session_component.cc b/base/src/core/signal_session_component.cc index db0fc3828..6778b545f 100644 --- a/base/src/core/signal_session_component.cc +++ b/base/src/core/signal_session_component.cc @@ -101,7 +101,9 @@ void Signal_session_component::submit(Signal_context_capability context_cap, context->source()->submit(context, _ipc_ostream, cnt); } -Signal_context_component::~Signal_context_component() { + +Signal_context_component::~Signal_context_component() +{ if (is_enqueued() && _source) _source->release(this); } diff --git a/base/src/core/signal_source_component.cc b/base/src/core/signal_source_component.cc index b84c1220c..57ad6d6ad 100644 --- a/base/src/core/signal_source_component.cc +++ b/base/src/core/signal_source_component.cc @@ -31,6 +31,7 @@ void Signal_source_component::release(Signal_context_component *context) _signal_queue.remove(context); } + void Signal_source_component::submit(Signal_context_component *context, Ipc_ostream *ostream, int cnt)