linux-um archives
 help / color / mirror / Atom feed
From: Blaisorblade <blaisorblade@yahoo.it>
To: Jeff Dike <jdike@addtoit.com>
Cc: user-mode-linux-devel@lists.sourceforge.net
Subject: [uml-devel] About "jiffies" patch
Date: Thu, 13 Jan 2005 06:12:34 +0100	[thread overview]
Message-ID: <200501130612.34417.blaisorblade@yahoo.it> (raw)

Well, effectively your reasoning holds, apart for one point: the code should 
not hang because of that large INITIAL_JIFFIES. What we care about are only 
the value of jiffies relative to INITIAL_JIFFIES, indeed.

In fact, that code works on 64-bit arch's. But INITIAL_JIFFIES is not 0 to 
make sure it wraps 5 minutes after the boot, to make sure the wrapping 
mechanism is debugged. And this, currently, does not happen likely.

While on 32-bit  archs that construct is like "(unsigned int) (-300*HZ)", on 
64-bit archs to get a negative number we'd need something like:

(unsigned long)(long)(-300*HZ)

or

(unsigned long)(-300L*HZ)

so that the number is first sign-extended and then casted to unsigned.
-- 
Paolo Giarrusso, aka Blaisorblade
Linux registered user n. 292729
http://www.user-mode-linux.org/~blaisorblade


-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues
Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

             reply	other threads:[~2005-01-13  5:10 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-01-13  5:12 Blaisorblade [this message]
2005-01-15  2:06 ` [uml-devel] About "jiffies" patch Blaisorblade

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=200501130612.34417.blaisorblade@yahoo.it \
    --to=blaisorblade@yahoo.it \
    --cc=jdike@addtoit.com \
    --cc=user-mode-linux-devel@lists.sourceforge.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