- May 08, 2014
-
-
Nadav Har'El authored
OSv is currently limited to 64 vCPUs, because we use a 64-bit bitmask for wakeups (see max_cpus in sched.cc). Having exactly 64 CPUs *should* work, but unfortunately didn't because of a bug: cpu_set::operator++ first incremented the index, and then called advance() to find the following one-bit. We had a bug when the index was 63: we then expect operator++ to return 64 (end(), signaling the end of the iteration), but what happened was that after it incremented the index to 64, advance() wrongly handled the case idx=64 (1<<64 returns 1, unexpectedly) and moved it back to idx=63. The patch fixes operator++ to not call advance when idx=64 is reached, so now it works correctly also for idx=63, and booting with 64 CPUs now works. Fixes #234. Signed-off-by:
Nadav Har'El <nyh@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Claudio Fontana authored
add include <osv/prio.hh>, this time at the beginning of the file. Signed-off-by:
Claudio Fontana <claudio.fontana@huawei.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Nadav Har'El authored
Implement three of the Linux functions we're still missing (see issue #77 for a list of more things to do). These are pretty easy to add, because we just need to correctly call the lower layer functions, sys_*, which already exist. This patch also adds tests for the three functions to tst-readdir.cc. Signed-off-by:
Nadav Har'El <nyh@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Nadav Har'El authored
Our readdir_r() and friends were implemented in libc/dir.cc, calling a function "ll_readdir()" from fs/vfs/main.cc. The name of this function was confusing ("ll_" seemed to imply lock-less, which it isn't), and the way it was "extern"ed was ugly, as a comment even admitted. Moreover, when we want to implement more missing functions like rewinddir() (see issue #77), we need to write more of these silly "ll_*" wrapper functions. Instead, let's just move the few dir.cc functions into main.cc. The latter already defines most of our filesystem system calls, so feels the right place anyway. This change allows us to get rid of the silly ll_readdir() layer, and makes implementing rewinddir() trivial (see next patch). Signed-off-by:
Nadav Har'El <nyh@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Claudio Fontana authored
remove a spurious include <osv/prio.hh> which seems to be a merge artifact. Signed-off-by:
Claudio Fontana <claudio.fontana@huawei.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Jaspal Singh Dhillon authored
This patch changes the definition of __assert_fail() in api/assert.h which would allow it and other header files which include it (such as debug.hh) to be used in mgmt submodules. Fixes conflict with declaration of __assert_fail() in external/x64/glibc.bin/usr/include/assert.h Signed-off-by:
Jaspal Singh Dhillon <jaspal.iiith@gmail.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
- May 07, 2014
-
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Tomasz Grabiec authored
This change moves syncache_head construction to its constructor so that the timer can be nicely embedded in the structure. Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Takuya ASADA authored
Now we enabled both VGA and serial, we nolonger need to add --vga cmdline for VMW/VBox. Reviewed-by:
Asias He <asias@cloudius-systems.com> Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Raphael S. Carvalho authored
According to the manual page, the nsec field from both it_value and it_interval must be checked, if wrong, return EINVAL. Reviewed-by:
Nadav Har'El <nyh@cloudius-systems.com> Signed-off-by:
Raphael S. Carvalho <raphaelsc@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Pawel Dziepak authored
The return values of LOCK() and UNLOCK() are never used. Besides, in the current Musl version these macros do not have return values at all. Reviewed-by:
Nadav Har'El <nyh@cloudius-systems.com> Signed-off-by:
Pawel Dziepak <pdziepak@quarnos.org> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Tomasz Grabiec authored
The script did not parse the response properly in case the symbol is unknown. That version of addr2line responds in two lines: ?? ??:0 but the script was assuming one line ?? ??:0, as returned by addr2line v2.24 Reported-by:
Asias He <asias@cloudius-systems.com> Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Tomasz Grabiec authored
The command shows a profile with amount of time threads were blocked on a mutex. This can be used to estimate lock contention. To use the profile the 'mutex_lock_wa*' tracepoints need to be enabled with backtrace. Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Claudio Fontana authored
implement simple GIC class for interacting with the GIC distributor and CPU interface. Signed-off-by:
Claudio Fontana <claudio.fontana@huawei.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Jani Kokkonen authored
the class construction of the page_table_root must happen before priority "mempool", or all the work in arch-setup will be destroyed by the class constructor. Problem noticed while working on the page fault handler for AArch64. Signed-off-by:
Jani Kokkonen <jani.kokkonen@huawei.com> Signed-off-by:
Claudio Fontana <claudio.fontana@huawei.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Gleb Natapov authored
dentry object represents a directory, vnode represent a file, so it is better to use vnode in the page cache. Signed-off-by:
Gleb Natapov <gleb@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Gleb Natapov authored
Elevated vnode reference count should not prevent rename() from working. Signed-off-by:
Gleb Natapov <gleb@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Gleb Natapov authored
It was accidentally changed to "write" by 4658e563. Signed-off-by:
Gleb Natapov <gleb@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Claudio Fontana authored
includes an implementation of arch_early_console for x64 using isa-serial, and an implementation for aarch64 using the (for now write-only) pl011. This restores output functionality for AArch64 lost in commit 9bbbe9dc. Signed-off-by:
Claudio Fontana <claudio.fontana@huawei.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
- May 06, 2014
-
-
Pawel Dziepak authored
There is already defined (but unused before this patch) function that extracts binding type from Elf_Sym::st_info. Signed-off-by:
Pawel Dziepak <pdziepak@quarnos.org> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Tomasz Grabiec authored
It's just cluttering the backtrace. Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Tomasz Grabiec authored
Fixes #255. The default OSv build has plenty of inlined functions. The tracing tool is using 'addr2line -Cfp' to resolve symbols. That mode of operation of addr2line yields one line per symbol and that line will only show the inlined function, even though the information about "logical" callers is also available. Example: $ addr2line -Cfp -e build/release/loader.elf 0x32963d lock_guard at (...) There is the '-i' switch we could use to also see code locations into which this function was inlined: $ addr2line -Cfpi -e build/release/loader.elf 0x32963d lock_guard at (...) (inlined by) lock_guard_for_with_lock at (...) (inlined by) mmu::vm_fault(unsigned long, exception_frame*) at (...) In this case, 'mmu::vm_fault' is much more interesting than lock_guard and thus we would like to show it in the backtrace. This change allows symbol resolvers to return multiple source addresses per raw address and changes the default implementation to return inlined-by functions by default. The new behavior can be suppressed with --no-inlined-by. Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Boqun Feng authored
According to http://gcc.gnu.org/gcc-4.9/porting_to.html , gcc now warns about unused right-hand side of a comma expression that contains no side effects. Rewrite LOCK/UNCLOCK using inline funciton instead of comma expression. Signed-off-by:
Boqun Feng <boqun.feng@linux.vnet.ibm.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Boqun Feng authored
-Werror=unused-function complains symbol_binding is unused, add an attribute of unused to mark this function unused. Signed-off-by:
Boqun Feng <boqun.feng@linux.vnet.ibm.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Boqun Feng authored
-Werror=sign-compare complains about when comparing (unsigned)level with page_mapper.nr_page_sizes(). Since nr_page_sizes() is meaningful only when it's non-negative and the mmu::nr_page_sizes is unsigned, changing the return types of all nr_page_sizes functions to unsigned is reasonable. Signed-off-by:
Boqun Feng <boqun.feng@linux.vnet.ibm.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
- May 05, 2014
-
-
Tomasz Grabiec authored
The test fails when the problem described in issue #283 exists. Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Tomasz Grabiec authored
The synchronizer allows any thread to block on it until it is unlocked. It is unlocked once count_down() has been called given number of times. Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Tomasz Grabiec authored
Fixes #283. When backlog is full upon receiving ACK, keep the entry in SYN cache. The client will eventually retransmit unacknowledged data and the connection state promotion will be retried at later time. Dropping of SYN cache entries was causing connection resets on the client side. The entry will be dropped when either of these occurs: * The connection is successfully ACK'ed * Invalid packet is received for that connection * SYN+ACK retransmission limit is exceeded * SYN cache hashmap bucket fills up - oldest entry is removed. We could also implement yet another protection mechanism, as a next step. We could drop SYN requests when we know the backlog is full, but this patch makes the biggest difference. SYN-dropping might be needed to avoid resets when the number of sudden connections is so large that SYN cache buckets fill up. Assuming connection hashing is good, that's quite a lot of connections - the hash map has 512 entries with buckets of up to 30 elements. Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Tomasz Grabiec authored
This fixes lock order inversion problem mentioned in #287 for SYN cache. This problem may affect all places which use callout_init_mtx() or callout_init_rw(). The only place which is left after this change is in in_lltable_new(), which is creating a timer for expiring ARP entries. Signed-off-by:
Tomasz Grabiec <tgrabiec@cloudius-systems.com> Signed-off-by:
Avi Kivity <avi@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Reviewed-by:
Tomasz Grabiec <tgrabiec@gmail.com> Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-
Takuya ASADA authored
Signed-off-by:
Takuya ASADA <syuu@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
-