From: Chris Wilson <chris@chris-wilson.co.uk>
To: Ben Widawsky <ben@bwidawsk.net>
Cc: intel-gfx@lists.freedesktop.org,
Ben Widawsky <benjamin.widawsky@intel.com>
Subject: Re: [PATCH] drm/i915: rc6 residency (fix the fix)
Date: Sun, 22 Apr 2012 19:11:16 +0100 [thread overview]
Message-ID: <1335118302_21631@CP5-2952> (raw)
In-Reply-To: <20120422110232.4d52a440@bwidawsk.net>
On Sun, 22 Apr 2012 11:02:32 -0700, Ben Widawsky <ben@bwidawsk.net> wrote:
> Does div_round64 work for you? I think that is the best solution.
Only exists in drivers/cpuidle/governors/menu.c, and still would need a
do_div to avoid the subsequent 64-bit division.
The choice appears to be either perform the divide by 1000 using do_div,
or note that a u32 * 128 / 1000 is also a u32 and so cast the result of
DIV_ROUND_UP_ULL back to u32.
-Chris
--
Chris Wilson, Intel Open Source Technology Centre
next prev parent reply other threads:[~2012-04-22 18:11 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-04-20 18:50 [PATCH] drm/i915: rc6 residency (fix the fix) Ben Widawsky
2012-04-20 19:24 ` Chris Wilson
2012-04-20 19:27 ` Daniel Vetter
2012-04-22 15:49 ` Chris Wilson
2012-04-22 17:35 ` Ben Widawsky
2012-04-22 17:39 ` Chris Wilson
2012-04-22 18:02 ` Ben Widawsky
2012-04-22 18:11 ` Chris Wilson [this message]
2012-04-23 2:57 ` Ben Widawsky
2012-04-23 7:38 ` Daniel Vetter
-- strict thread matches above, loose matches on Subject: below --
2012-04-22 18:27 Ben Widawsky
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=1335118302_21631@CP5-2952 \
--to=chris@chris-wilson.co.uk \
--cc=ben@bwidawsk.net \
--cc=benjamin.widawsky@intel.com \
--cc=intel-gfx@lists.freedesktop.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