public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: David Mosberger <davidm@napali.hpl.hp.com>
To: linux-ia64@vger.kernel.org
Subject: Re: [PATCH] Fix show_mem panic
Date: Fri, 12 Mar 2004 18:00:29 +0000	[thread overview]
Message-ID: <16465.64189.848251.504020@napali.hpl.hp.com> (raw)
In-Reply-To: <200403121424.i2CEO2a21024@udlkern.fc.hp.com>

>>>>> On Fri, 12 Mar 2004 07:24:02 -0700 (MST), John Marvin <jsm@udlkern.fc.hp.com> said:

  John> ia64_pfn_valid (unsigned long pfn)
  John> {
  John> char byte;
  John> +	struct page *page = pfn_to_page(pfn);
 
  John> -	return __get_user(byte, (char *) pfn_to_page(pfn)) = 0;
  John> +	return     (__get_user(byte, (char *) page) = 0)
  John> +		&& (__get_user(byte, (char *) (page + 1) - 1) = 0);
  John> }

Would it make sense to do only the first __get_user() _unless_ the
"struct page" crosses a page?

	--david

      reply	other threads:[~2004-03-12 18:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-12 14:24 [PATCH] Fix show_mem panic John Marvin
2004-03-12 18:00 ` David Mosberger [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=16465.64189.848251.504020@napali.hpl.hp.com \
    --to=davidm@napali.hpl.hp.com \
    --cc=linux-ia64@vger.kernel.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