public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: Elimar Riesebieter <riesebie@lxtec.de>
Cc: linux-pm@lists.linux-foundation.org
Subject: Re: 2.6.22-rc2 built on ppc (1)
Date: Sat, 9 Jun 2007 15:55:33 +0200	[thread overview]
Message-ID: <20070609135533.GB3397@elf.ucw.cz> (raw)
In-Reply-To: <20070520110625.GC3253@aragorn.home.lxtec.de>

Hi!

> FYI, building 2.6.22-rc2 with
> gcc (GCC) 4.1.3 20070514 (prerelease) (Debian 4.1.2-7)
> on my powerbook (PPC) gives:
> 
> ...
> kernel/power/swsusp.c: In function 'swsusp_show_speed':
> kernel/power/swsusp.c:193: warning: comparison of distinct pointer types lacks a cast
> ...
> 
> 
> If more info is needed, please contact me via PM, as I am not
> subscribed.

void swsusp_show_speed(struct timeval *start, struct timeval *stop,
			unsigned nr_pages, char *msg)
{
	s64 elapsed_centisecs64;
	int centisecs;
	int k;
	int kps;

	elapsed_centisecs64 = timeval_to_ns(stop) - timeval_to_ns(start);
	do_div(elapsed_centisecs64, NSEC_PER_SEC / 100);
	centisecs = elapsed_centisecs64;
	if (centisecs == 0)
		centisecs = 1;	/* avoid div-by-zero */

Hmm, which line triggers that? do_div? Can you add some casts to work
around this?



-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

      parent reply	other threads:[~2007-06-09 13:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-20 11:06 2.6.22-rc2 built on ppc (1) Elimar Riesebieter
2007-05-20 11:36 ` Rafael J. Wysocki
2007-05-20 11:43   ` Johannes Berg
2007-06-09 14:14     ` Pavel Machek
2007-06-09 17:06       ` Elimar Riesebieter
2007-06-11  8:26       ` Johannes Berg
2007-06-09 13:55 ` Pavel Machek [this message]

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=20070609135533.GB3397@elf.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=riesebie@lxtec.de \
    /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