From: Giacomo Tesio <giacomo@tesio.it>
To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net>
Subject: [9fans] double lock in proc.c
Date: Mon, 24 Jul 2017 18:03:04 +0200 [thread overview]
Message-ID: <CAHL7psGUA0Qf4OBcuBSPmECAXCcS683L7uCzo1uF_XPrH7Utuw@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 537 bytes --]
In /sys/src/9/port/proc.c a comment state:
/*
* Expects that only one process can call wakeup for any given Rendez.
* We hold both locks to ensure that r->p and p->r remain consistent.
* Richard Miller has a better solution that doesn't require both to
* be held simultaneously, but I'm a paranoid - presotto.
*/
(see
https://github.com/0intro/plan9/blob/master/sys/src/9/port/proc.c#L882-L887)
I'd like to know a bit more about Miller's solution as I'd like to simplify
postnote.
Any hint or source code?
Giacomo
[-- Attachment #2: Type: text/html, Size: 750 bytes --]
next reply other threads:[~2017-07-24 16:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-24 16:03 Giacomo Tesio [this message]
2017-07-24 16:39 ` Erik Quanstrom
2017-07-24 19:13 ` Fran. J Ballesteros
2017-07-25 18:51 ` Richard Miller
2017-07-25 22:23 ` David du Colombier
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=CAHL7psGUA0Qf4OBcuBSPmECAXCcS683L7uCzo1uF_XPrH7Utuw@mail.gmail.com \
--to=giacomo@tesio.it \
--cc=9fans@9fans.net \
/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;
as well as URLs for NNTP newsgroup(s).