Re: [osv-dev] OSv crash on pthread_start

2021-01-11 Thread Deepak Krishnan
On Monday, 11 January, 2021 at 3:56:51 pm UTC+5:30 Nadav Har'El wrote: > On Mon, Jan 11, 2021 at 11:43 AM Deepak Krishnan > wrote: > >> >> >> On Monday, 11 January, 2021 at 1:47:22 pm UTC+5:30 Nadav Har'El wrote: >> >> Interesting. Theoretically, there is no reason why we didn't reach >>> pre

Re: [osv-dev] mkdir() syscall not supported?

2021-01-11 Thread Nadav Har'El
On Mon, Jan 11, 2021 at 7:01 PM David Smith wrote: > Thanks for the quick reply. > > I can confirm that implementing just the mkdir fixes does not resolve my > issue, so I am currently attempting to implement the mkdirat function. I'm > no kernel dev. expert, but I have got something working, usi

Re: [osv-dev] mkdir() syscall not supported?

2021-01-11 Thread David Smith
Thanks for the quick reply. I can confirm that implementing just the mkdir fixes does not resolve my issue, so I am currently attempting to implement the mkdirat function. I'm no kernel dev. expert, but I have got something working, using extracts of code from openat() which is implemented and

Re: [osv-dev] OSv crash on pthread_start

2021-01-11 Thread Waldek Kozaczuk
On Monday, January 11, 2021 at 5:26:51 AM UTC-5 Nadav Har'El wrote: > On Mon, Jan 11, 2021 at 11:43 AM Deepak Krishnan > wrote: > >> >> >> On Monday, 11 January, 2021 at 1:47:22 pm UTC+5:30 Nadav Har'El wrote: >> >> Interesting. Theoretically, there is no reason why we didn't reach >>> preemp

Re: [osv-dev] mkdir() syscall not supported?

2021-01-11 Thread Nadav Har'El
On Mon, Jan 11, 2021 at 3:29 PM David Smith wrote: > I'm running my go application under OSv and I'm having an issue with the > mkdir() syscall (as accessed in go via os.Mkdir()). The issue appears to be > that OSv does not implement the mkdir() syscall. I've searched the > documentation and trie

[osv-dev] mkdir() syscall not supported?

2021-01-11 Thread David Smith
I'm running my go application under OSv and I'm having an issue with the mkdir() syscall (as accessed in go via os.Mkdir()). The issue appears to be that OSv does not implement the mkdir() syscall. I've searched the documentation and tried reviewing the source, but I have not been able to confi

Re: [osv-dev] OSv crash on pthread_start

2021-01-11 Thread Nadav Har'El
On Mon, Jan 11, 2021 at 11:43 AM Deepak Krishnan wrote: > > > On Monday, 11 January, 2021 at 1:47:22 pm UTC+5:30 Nadav Har'El wrote: > > Interesting. Theoretically, there is no reason why we didn't reach >> preempt_enable() and enabled preemption. If we didn't, there is one >> possible explanatio

[osv-dev] [PATCH] pthread_create() - prefault top of stack

2021-01-11 Thread Nadav Har'El
Since commit 695375f65303e13df1b9de798577ee9a4f8f9892, new threads start with preemption disabled, and then immediately (in thread_main_c()) enable preemption. However, this code runs on the thread's stack, which can be supplied by the user. If this stack is lazily allocated (not pre-populated, wit

Re: [osv-dev] OSv crash on pthread_start

2021-01-11 Thread Deepak Krishnan
On Monday, 11 January, 2021 at 1:47:22 pm UTC+5:30 Nadav Har'El wrote: > On Mon, Jan 11, 2021 at 9:37 AM Deepak Krishnan wrote: > >> Hi, >> >> Running OSv with some Linux binaries and had a crash that I couldn't >> completely understand: >> >> (gdb) where >> #0 processor::cli_hlt () at arch/x

Re: [osv-dev] OSv crash on pthread_start

2021-01-11 Thread Nadav Har'El
On Mon, Jan 11, 2021 at 9:37 AM Deepak Krishnan wrote: > Hi, > > Running OSv with some Linux binaries and had a crash that I couldn't > completely understand: > > (gdb) where > #0 processor::cli_hlt () at arch/x64/processor.hh:248 > #1 0x40208fe6 in arch::halt_no_interrupts () at > arch