From: Benjamin Beichler <Benjamin.Beichler@uni-rostock.de>
To: Johannes Berg <johannes@sipsolutions.net>,
<linux-um@lists.infradead.org>
Subject: Re: [PATCH 1/4] um: irqs: process outstanding IRQs when unblocking signals
Date: Fri, 20 Oct 2023 17:47:58 +0200 [thread overview]
Message-ID: <fe6dc227-44f4-466e-a99b-e5e9e6afe7aa@uni-rostock.de> (raw)
In-Reply-To: <2315dd8321a86c52e2c7226889568068ffafe9a7.camel@sipsolutions.net>
>> My mind model is, that simulation time advances in the controller are
>> only done, If all parts of the simulation reached the current
>> simulation time and are at the event processed/idle/wait state.
> Yeah that's a simpler model, and in what we implemented it's true if
> you do have the ACK messages. If don't have free-until, that's also
> possibly true, although we might have implementation bugs in a sense
> with time_travel_add_irq_event() since that looks at the current time.
> And also, if you request something the controller thinks is already in
> the past because the other side updated the controller due to
> free-until, the simulation just crashes. It's also possible that B (in
> the situation above) actually *does* ask the controller who should run
> next, and the controller simply doesn't yet know: B sends message to
> A's stdin (say at 1000) B requests to run at 2000 from controller B
> releases time to controller controller sets time to 2000 and tells B
> to run A requests scheduling at 1000 controller *crashes*
I think, I get now, why I don't have this Problem: My virtio simulation
and my controller/simulation-master are tightly coupled and indeed the
same process. When I create a new event for the UML-instance, it is
anticipated in the simulation master.
So my sequence is more like:
B sends message to A's stdin (say at 1000)
B tells the controller, that it activated A, and time should not advance
until A has sent a request for processing an interrupt and has gone back
to waiting state
B requests to run at 2000 from controller
B releases time to controller
...
I see that without further information from the device simulation to the
controller, it is quite harder.
Nonetheless, I'm not totally sure, how this interacts with the timing
semantics of the interrupts here. Either the solution of Benjamin Berg
or mine (with the trivial tt-handler have the same problem).
I will post my patches the next days, you may have a look on them, maybe
you also experienced some of my problems :-)
_______________________________________________
linux-um mailing list
linux-um@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-um
next prev parent reply other threads:[~2023-10-20 15:48 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-18 12:36 [PATCH 1/4] um: irqs: process outstanding IRQs when unblocking signals benjamin
2023-10-18 12:36 ` [PATCH 2/4] um: chan_user: catch EINTR when reading and writing benjamin
2023-10-18 12:36 ` [PATCH 3/4] um: chan_user: retry partial writes benjamin
2023-10-18 12:36 ` [PATCH 4/4] um: chan: use blocking IO for console output for time-travel benjamin
2023-10-20 9:15 ` [PATCH 1/4] um: irqs: process outstanding IRQs when unblocking signals Benjamin Beichler
2023-10-20 9:26 ` Anton Ivanov
2023-10-20 10:33 ` Benjamin Beichler
2023-10-20 9:59 ` Benjamin Berg
2023-10-20 10:38 ` Benjamin Beichler
2023-10-20 11:39 ` Johannes Berg
2023-10-20 12:06 ` Benjamin Beichler
2023-10-20 12:20 ` Johannes Berg
2023-10-20 12:23 ` Johannes Berg
2023-10-20 12:43 ` Benjamin Beichler
2023-10-20 12:58 ` Johannes Berg
2023-10-20 12:58 ` Benjamin Beichler
2023-10-20 13:39 ` Johannes Berg
2023-10-20 15:47 ` Benjamin Beichler [this message]
2023-10-20 15:51 ` Johannes Berg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fe6dc227-44f4-466e-a99b-e5e9e6afe7aa@uni-rostock.de \
--to=benjamin.beichler@uni-rostock.de \
--cc=johannes@sipsolutions.net \
--cc=linux-um@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox