linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: John Levon <levon@movementarian.org>
To: Zwane Mwaikambo <zwane@fsmlabs.com>
Cc: Linux Kernel <linux-kernel@vger.kernel.org>,
	Andrew Morton <akpm@osdl.org>
Subject: Re: [PATCH] OProfile: Fix oops on undetected CPU type
Date: Sat, 29 Jan 2005 14:04:23 +0000	[thread overview]
Message-ID: <20050129140423.GA71581@compsoc.man.ac.uk> (raw)
In-Reply-To: <Pine.LNX.4.61.0501281146150.22906@montezuma.fsmlabs.com>

On Fri, Jan 28, 2005 at 12:06:19PM -0700, Zwane Mwaikambo wrote:

> ===== drivers/oprofile/oprofile_files.c 1.7 vs edited =====
> --- 1.7/drivers/oprofile/oprofile_files.c	2005-01-04 19:48:23 -07:00
> +++ edited/drivers/oprofile/oprofile_files.c	2005-01-28 11:36:25 -07:00
> @@ -63,7 +63,9 @@ static struct file_operations pointer_si
>  
>  static ssize_t cpu_type_read(struct file * file, char __user * buf, size_t count, loff_t * offset)
>  {
> -	return oprofilefs_str_to_user(oprofile_ops.cpu_type, buf, count, offset);
> +	if (oprofile_ops.cpu_type)
> +		return oprofilefs_str_to_user(oprofile_ops.cpu_type, buf, count, offset);
> +	return -EIO;

This is wrong: you need to investigate why .cpu_type isn't set: in
particular, it should have fallen back to timer mode.
oprofile_arch_init() should have returned -ENODEV, and that should have
set timer mode.

Unfortunately bkcvs seems out of date so I can't even look at this
myself.

john

  reply	other threads:[~2005-01-29 14:04 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-01-28 19:06 [PATCH] OProfile: Fix oops on undetected CPU type Zwane Mwaikambo
2005-01-29 14:04 ` John Levon [this message]
2005-01-29 16:47   ` Zwane Mwaikambo
2005-01-29 21:36     ` John Levon
2005-01-29 22:01       ` Zwane Mwaikambo

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=20050129140423.GA71581@compsoc.man.ac.uk \
    --to=levon@movementarian.org \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=zwane@fsmlabs.com \
    /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).