linux.kernel - 26 new messages in 21 topics - digest
linux.kernel
http://groups.google.com/group/linux.kernel?hl=en
Today's topics:
* acerhdf: BIOS product mismatch due to whitespace - 3 messages, 2 authors
http://groups.google.com/group/linux.kernel/t/ae6d4cac1682e8ed?hl=en
* Unable to use tools/perf sched and timechart correctly - 1 messages, 1
author
http://groups.google.com/group/linux.kernel/t/9da002544ae8f440?hl=en
* FS-Cache: Avoid maybe-used-uninitialised warning on variable - 1 messages, 1
author
http://groups.google.com/group/linux.kernel/t/3bd97e9dc0c989ff?hl=en
* Network-related warnings with 2.6.31.6 - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/5225816797564d85?hl=en
* lockstat: Fix min, max times in /proc/lock_stats - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/8bfb8225eb11f1e0?hl=en
* lockstat: Add usage info to Documentation/lockstat.txt - 1 messages, 1
author
http://groups.google.com/group/linux.kernel/t/8123a34723327827?hl=en
* tracing: Fix trace_marker output - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/59b320cbcd591edd?hl=en
* tree with htc dream support - 2 messages, 1 author
http://groups.google.com/group/linux.kernel/t/5b3704c66ba56bcc?hl=en
* [2/2] perf: allow installing as perf-versionnumber - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/abf4a276d3b2d030?hl=en
* [1/2] perf: Make location of kernel source configurable - 1 messages, 1
author
http://groups.google.com/group/linux.kernel/t/3a8de4c4bebc0a9a?hl=en
* [3/3] Fix unwind annotations for 64bit kernel - 2 messages, 1 author
http://groups.google.com/group/linux.kernel/t/731a61cd0f9f1cc1?hl=en
* [1/3] x86: Improve CONFIG_KEXEC_JUMP description - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/0da9e9d5ff7f23c2?hl=en
* Constify struct super_operations for 2.6.32 v1 - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/a9348bc8ee8e2c83?hl=en
* (none) - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/9abaed68cf317095?hl=en
* perf DEBUG=1 build fails due to perl bindings - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/6cbc190536f1c8f2?hl=en
* Patch for MSP430 and SOC audio support for Neuros OSD2 platform code. - 1
messages, 1 author
http://groups.google.com/group/linux.kernel/t/e458b1ac082181dd?hl=en
* Introduce __page_check_address - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/7e4a37dd73cba3b0?hl=en
* copy_signal cleanup: clean tty_audit_fork() - 2 messages, 2 authors
http://groups.google.com/group/linux.kernel/t/476d80345960e6f3?hl=en
* PM updates for 2.6.33 - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/744b2baf61c0ac2a?hl=en
* scsi: megaraid_sas - Zero pad_0 in mfi structure - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/efe639a29079f246?hl=en
* Gratulerer - End Of Year Promotion - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/87697d0562dfeb70?hl=en
==============================================================================
TOPIC: acerhdf: BIOS product mismatch due to whitespace
http://groups.google.com/group/linux.kernel/t/ae6d4cac1682e8ed?hl=en
==============================================================================
== 1 of 3 ==
Date: Sun, Dec 6 2009 4:30 am
From: Peter Feuerer
Ian E. Morgan writes:
> Peter,
>
> Having just upgraded my AOA150 to 2.6.32, acerhdf was complaining:
>
> acerhdf: Acer Aspire One Fan driver, v.0.5.18
> acerhdf: unknown (unsupported) BIOS version Acer/AOA150
> /v0.3310, please report, aborting!
>
> DMI reports the product as "AOA150 " (i.e. 9 spaces after the
> 6-character model name). This causes the product match to fail, so I
> had to use force_product="AOA150".
>
> acerhdf: Acer Aspire One Fan driver, v.0.5.18
> acerhdf: forcing BIOS product: AOA150
>
> Then all was happy again. Any chance you could strip leading/trailing
> whitespace in the product match to avoid this issue?
Hi Ian,
thanks for reporting, will take care about this issue.
kind regards,
--peter
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
== 2 of 3 ==
Date: Sun, Dec 6 2009 6:40 am
From: Peter Feuerer
Hi Ian,
Ian E. Morgan writes:
> Having just upgraded my AOA150 to 2.6.32, acerhdf was complaining:
>
> acerhdf: Acer Aspire One Fan driver, v.0.5.18
> acerhdf: unknown (unsupported) BIOS version Acer/AOA150
> /v0.3310, please report, aborting!
>
> DMI reports the product as "AOA150 " (i.e. 9 spaces after the
> 6-character model name). This causes the product match to fail, so I
> had to use force_product="AOA150".
>
> acerhdf: Acer Aspire One Fan driver, v.0.5.18
> acerhdf: forcing BIOS product: AOA150
could you please be so kind and test:
http://piie.net/files/acerhdf_kmod-0.5.22.tar.gz
Thank you!
kind regards,
--peter
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
== 3 of 3 ==
Date: Sun, Dec 6 2009 7:20 am
From: "Ian E. Morgan"
On Sun, Dec 6, 2009 at 09:37, Peter Feuerer <peter@piie.net> wrote:
>
> could you please be so kind and test:
> http://piie.net/files/acerhdf_kmod-0.5.22.tar.gz
Yep, that does the trick nicely. Thanks. Are you submitting that for .32-stable?
--
Ian Morgan
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: Unable to use tools/perf sched and timechart correctly
http://groups.google.com/group/linux.kernel/t/9da002544ae8f440?hl=en
==============================================================================
== 1 of 1 ==
Date: Sun, Dec 6 2009 5:00 am
From: Török Edwin
On 2009-12-06 12:41, Xiao Guangrong wrote:
> Török Edwin wrote:
>
>> Hi,
>>
>> I installed 2.6.32 and tried its tools/perf.
>> I noticed two problems so far, please tell me if I am doing anything
>> wrong here:
>>
>> 1. 'perf sched replay' segfaults on any recorded workload
>> I tested like this:
>> $ sudo ./perf sched record
>> ^C[ perf record: Woken up 1 times to write data ]
>> [ perf record: Captured and wrote 0.295 MB perf.data (~12869 samples) ]
>> $ sudo perf sched replay
>> run measurement overhead: 1258 nsecs
>> sleep measurement overhead: 55232 nsecs
>> the run test took 999778 nsecs
>> the sleep test took 1055791 nsecs
>> nr_run_events: 182
>> nr_sleep_events: 209
>> nr_wakeup_events: 103
>> target-less wakeups: 12
>> [...]
>> task 25 ( icedove-bin: 8757), nr_events: 3
>> task 26 ( events/0: 15), nr_events: 3
>> ------------------------------------------------------------
>> Segmentation fault
>>
>
> You should enable "CONFIG_SCHED_DEBUG", because we use
> "/proc/<pid>/sched" file to get the task's cpu usage.
>
Thanks, that got rid of the segfault, and perf sched replay runs without
crashing now.
Am I missing a config option for 'perf timechart' to work?
I tried running 4 infloop executables (on a 4-core box), the last one as
argument to perf timechart record.
Only one of those processes has shown up, as using CPU for 26.5ms, and
then sleeping (when in fact it was running the entire time).
The CPU graphs are mostly white, with a thicker blue line where a.out
shown up, and some scarce thin blue lines.
Best regards,
--Edwin
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: FS-Cache: Avoid maybe-used-uninitialised warning on variable
http://groups.google.com/group/linux.kernel/t/3bd97e9dc0c989ff?hl=en
==============================================================================
== 1 of 1 ==
Date: Sun, Dec 6 2009 5:00 am
From: David Howells
Andrew Morton's compiler sees the following warning in FS-Cache:
fs/fscache/object-list.c: In function 'fscache_objlist_lookup':
fs/fscache/object-list.c:94: warning: 'obj' may be used uninitialized in this function
which my compiler doesn't. This is a false positive as obj can only be used
in the comparison against minobj if minobj has been set to something other
than NULL, but for that to happen, obj has to be first set to something.
Deal with this by preclearing obj too.
Reported-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David Howells <dhowells@redhat.com>
---
fs/fscache/object-list.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/fs/fscache/object-list.c b/fs/fscache/object-list.c
index e590242..3221a0c 100644
--- a/fs/fscache/object-list.c
+++ b/fs/fscache/object-list.c
@@ -91,7 +91,7 @@ EXPORT_SYMBOL(fscache_object_destroy);
*/
static struct fscache_object *fscache_objlist_lookup(loff_t *_pos)
{
- struct fscache_object *pobj, *obj, *minobj = NULL;
+ struct fscache_object *pobj, *obj = NULL, *minobj = NULL;
struct rb_node *p;
unsigned long pos;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: Network-related warnings with 2.6.31.6
http://groups.google.com/group/linux.kernel/t/5225816797564d85?hl=en
==============================================================================
== 1 of 1 ==
Date: Sun, Dec 6 2009 5:10 am
From: Chris Rankin
Hi,
I tried applying the sunrpc/UDP patch you suggested, just in case that bug was scribbling into memory somewhere. However, I still had a complete PC freeze last night during a period of heavy surfing so I suspect there's a nasty network-related bug in 2.6.31.x somewhere.
Is there anything else in the -stable queue that might help, please? Come to think of it, it's been almost a *month* since the last -stable patch. Has 2.6.31.x been "wound down" already in favour of 2.6.32.x?
Cheers,
Chris
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: lockstat: Fix min, max times in /proc/lock_stats
http://groups.google.com/group/linux.kernel/t/8bfb8225eb11f1e0?hl=en
==============================================================================
== 1 of 1 ==
Date: Sun, Dec 6 2009 5:10 am
From: tip-bot for Frank Rowand
Commit-ID: 109d71c6dd52ec08878c2c67eb4c0bd67fcbc80b
Gitweb: http://git.kernel.org/tip/109d71c6dd52ec08878c2c67eb4c0bd67fcbc80b
Author: Frank Rowand <frank.rowand@am.sony.com>
AuthorDate: Thu, 19 Nov 2009 13:42:06 -0800
Committer: Ingo Molnar <mingo@elte.hu>
CommitDate: Sun, 6 Dec 2009 13:20:00 +0100
lockstat: Fix min, max times in /proc/lock_stats
Fix min, max times in /proc/lock_stats
(1) When collecting lock hold and wait times, if the current minimum
time is zero, it will be replaced by the next time.
(2) When aggregating minimum and maximum lock hold and wait times
accross cpus, the values are added, instead of selecting the
minimum and maximum.
Signed-off-by: Frank Rowand <frank.rowand@am.sony.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <4B05BBAE.2050005@am.sony.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
kernel/lockdep.c | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/kernel/lockdep.c b/kernel/lockdep.c
index f5dcd36..7a3ae56 100644
--- a/kernel/lockdep.c
+++ b/kernel/lockdep.c
@@ -168,7 +168,7 @@ static void lock_time_inc(struct lock_time *lt, u64 time)
if (time > lt->max)
lt->max = time;
- if (time < lt->min || !lt->min)
+ if (time < lt->min || !lt->nr)
lt->min = time;
lt->total += time;
@@ -177,8 +177,15 @@ static void lock_time_inc(struct lock_time *lt, u64 time)
static inline void lock_time_add(struct lock_time *src, struct lock_time *dst)
{
- dst->min += src->min;
- dst->max += src->max;
+ if (!src->nr)
+ return;
+
+ if (src->max > dst->max)
+ dst->max = src->max;
+
+ if (src->min < dst->min || !dst->nr)
+ dst->min = src->min;
+
dst->total += src->total;
dst->nr += src->nr;
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: lockstat: Add usage info to Documentation/lockstat.txt
http://groups.google.com/group/linux.kernel/t/8123a34723327827?hl=en
==============================================================================
== 1 of 1 ==
Date: Sun, Dec 6 2009 5:10 am
From: tip-bot for Frank Rowand
Commit-ID: f5754bfd107b08edddaf871d676ec6fe0792d07a
Gitweb: http://git.kernel.org/tip/f5754bfd107b08edddaf871d676ec6fe0792d07a
Author: Frank Rowand <frank.rowand@am.sony.com>
AuthorDate: Thu, 19 Nov 2009 13:54:05 -0800
Committer: Ingo Molnar <mingo@elte.hu>
CommitDate: Sun, 6 Dec 2009 13:20:02 +0100
lockstat: Add usage info to Documentation/lockstat.txt
Add usage info to Documentation/lockstat.txt
Signed-off-by: Frank Rowand <frank.rowand@am.sony.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <4B05BE7D.30500@am.sony.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
Documentation/lockstat.txt | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/Documentation/lockstat.txt b/Documentation/lockstat.txt
index 9cb9138..65f4c79 100644
--- a/Documentation/lockstat.txt
+++ b/Documentation/lockstat.txt
@@ -62,8 +62,20 @@ applicable).
It also tracks 4 contention points per class. A contention point is a call site
that had to wait on lock acquisition.
+ - CONFIGURATION
+
+Lock statistics are enabled via CONFIG_LOCK_STATS.
+
- USAGE
+Enable collection of statistics:
+
+# echo 1 >/proc/sys/kernel/lock_stat
+
+Disable collection of statistics:
+
+# echo 0 >/proc/sys/kernel/lock_stat
+
Look at the current lock statistics:
( line numbers not part of actual output, done for clarity in the explanation
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: tracing: Fix trace_marker output
http://groups.google.com/group/linux.kernel/t/59b320cbcd591edd?hl=en
==============================================================================
== 1 of 1 ==
Date: Sun, Dec 6 2009 5:20 am
From: Carsten Emde
Olof,
> On Sun, Nov 22, 2009 at 10:24:48AM +0000, tip-bot for Carsten Emde wrote:
>> Commit-ID: c13d2f7c3231e873f30db92b96c8caa48f100f33
>> Gitweb: http://git.kernel.org/tip/c13d2f7c3231e873f30db92b96c8caa48f100f33
>> Author: Carsten Emde <Carsten.Emde@osadl.org>
>> AuthorDate: Mon, 16 Nov 2009 20:56:13 +0100
>> Committer: Steven Rostedt <rostedt@goodmis.org>
>> CommitDate: Tue, 17 Nov 2009 09:19:06 -0500
>>
>> tracing: Fix trace_marker output
>>
>> When a string was written to <debugfs>/tracing/trace_marker, some
>> strange characters appeared in the trace output instead of the
>> string, since a vprint function erroneously called a vararg print
>> function with a va_list argument. This patch fixes the problem and
>> simplifies the related code.
>
> [...]
>
>> diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
>> index 03c7fd5..12b49ca 100644
>> --- a/kernel/trace/trace.c
>> +++ b/kernel/trace/trace.c
>> @@ -1361,10 +1361,11 @@ int trace_array_vprintk(struct trace_array *tr,
>> pause_graph_tracing();
>> raw_local_irq_save(irq_flags);
>> __raw_spin_lock(&trace_buf_lock);
>> - len = vsnprintf(trace_buf, TRACE_BUF_SIZE, fmt, args);
>> -
>> - len = min(len, TRACE_BUF_SIZE-1);
>> - trace_buf[len] = 0;
>> + if (args == NULL) {
>> + strncpy(trace_buf, fmt, TRACE_BUF_SIZE);
>> + len = strlen(trace_buf);
>> + } else
>> + len = vsnprintf(trace_buf, TRACE_BUF_SIZE, fmt, args);
>
>
> Comparing a va_list with NULL is bogus. It's supposed to be treated like
> an opaque type and only be manipulated with va_* accessors.
>
> I wouldn't really care much, but it broke builds on some ARM platforms:
>
> kernel/trace/trace.c: In function 'trace_array_vprintk':
> kernel/trace/trace.c:1364: error: invalid operands to binary == (have 'va_list' and 'void *')
> kernel/trace/trace.c: In function 'tracing_mark_write':
> kernel/trace/trace.c:3349: error: incompatible type for argument 3 of 'trace_vprintk'
Having looked at other possible solutions, I find that the best thing to do
is to revert this part of the patch. Sorry that I didn't check it on ARM
platforms.
Carsten.
-=-
This patch partly reverts c13d2f7c3231e873f30db92b96c8caa48f100f33 and
re-installs Steven's original mark_printk() mechanism.
Signed-off-by: Carsten Emde <C.Emde@osadl.org>
Index: linux-2.6-tip/kernel/trace/trace.c
===================================================================
--- linux-2.6-tip.orig/kernel/trace/trace.c
+++ linux-2.6-tip/kernel/trace/trace.c
@@ -1361,11 +1361,7 @@ int trace_array_vprintk(struct trace_arr
pause_graph_tracing();
raw_local_irq_save(irq_flags);
__raw_spin_lock(&trace_buf_lock);
- if (args == NULL) {
- strncpy(trace_buf, fmt, TRACE_BUF_SIZE);
- len = strlen(trace_buf);
- } else
- len = vsnprintf(trace_buf, TRACE_BUF_SIZE, fmt, args);
+ len = vsnprintf(trace_buf, TRACE_BUF_SIZE, fmt, args);
size = sizeof(*entry) + len + 1;
buffer = tr->buffer;
@@ -3320,6 +3316,16 @@ tracing_entries_write(struct file *filp,
return cnt;
}
+static int mark_printk(const char *fmt, ...)
+{
+ int ret;
+ va_list args;
+ va_start(args, fmt);
+ ret = trace_vprintk(0, fmt, args);
+ va_end(args);
+ return ret;
+}
+
static ssize_t
tracing_mark_write(struct file *filp, const char __user *ubuf,
size_t cnt, loff_t *fpos)
@@ -3346,7 +3352,7 @@ tracing_mark_write(struct file *filp, co
} else
buf[cnt] = '\0';
- cnt = trace_vprintk(0, buf, NULL);
+ cnt = mark_printk("%s", buf);
kfree(buf);
*fpos += cnt;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: tree with htc dream support
http://groups.google.com/group/linux.kernel/t/5b3704c66ba56bcc?hl=en
==============================================================================
== 1 of 2 ==
Date: Sun, Dec 6 2009 6:00 am
From: Daniel Walker
On Sat, 2009-12-05 at 16:38 -0800, Brian Swetland wrote:
> On Sat, Dec 5, 2009 at 3:12 PM, Daniel Walker <dwalker@codeaurora.org>
> wrote:
> https://www.codeaurora.org/gitweb/quic/kernel/?p=dwalker/linux-msm.git;a=shortlog;h=refs/heads/testing
>
> It's been in Linux-next for maybe two weeks .. I've been
> trying to
> decide if I should submit it for 2.6.33. I'm going to be
> adding boat
> loads of additional msm code and doing a fairly large merge
> for
> 2.6.34 .. So your code would get better testing if we wait for
> that.
>
> However, If you really want it in 2.6.33 I'll try to
> accommodate you.
>
> Arve's about to take our common and msm trees and rebase them over
> the .32, which may be useful for reference -- at least as a snapshot
> of a fully functional set of patches that android donut and eclair run
> on, on production hardware. We'll make that available as soon as we
> have something that's bootable.
Ok .. I'm mainly working with a small subset of a full Android tree.
It's just isolated to the arch/arm/mach-msm/ directory (some in
arch/arm/) .. If you guys have changes to that area just let me know
where they are and I'll try to move them forward.
Daniel
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
== 2 of 2 ==
Date: Sun, Dec 6 2009 6:00 am
From: Daniel Walker
On Sun, 2009-12-06 at 08:41 +0100, Pavel Machek wrote:
> Hi!
>
> > > Where is the tree with HTC Dream support? I thought it was
> > >
> > > http://git.kernel.org/?p=linux/kernel/git/dwalker/linux-msm.git;a=summary
> > >
> > > but it does not seem to contain basic dream support (board file and
> > > serial console) and I thought that was going to linus for 2.6.33...?
> >
> > It's here
> >
> > git://codeaurora.org/quic/kernel/dwalker/linux-msm.git
> ...
> > It's been in Linux-next for maybe two weeks .. I've been trying to
> > decide if I should submit it for 2.6.33. I'm going to be adding boat
> > loads of additional msm code and doing a fairly large merge for
> > 2.6.34 .. So your code would get better testing if we wait for that.
> >
> > However, If you really want it in 2.6.33 I'll try to accommodate you.
>
> It would be good to get it in 2.6.33, so that we can build on it, and
> so that you are marked as official maintainer etc. I do not think that
> code would benefit from any additional delays...
Ok. Fine with me, unless someone else has a specific objection .
Daniel
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: [2/2] perf: allow installing as perf-versionnumber
http://groups.google.com/group/linux.kernel/t/abf4a276d3b2d030?hl=en
==============================================================================
== 1 of 1 ==
Date: Sun, Dec 6 2009 6:10 am
From: Andi Kleen
Right now installing a given perf binary as perf-versionnumber doesn't
work because perf internally tries to dispatch a "versionnumber" command.
Add a special case to not dispatch commands starting with a digit.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
---
tools/perf/perf.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
Index: linux-2.6.32-ak/tools/perf/perf.c
===================================================================
--- linux-2.6.32-ak.orig/tools/perf/perf.c
+++ linux-2.6.32-ak/tools/perf/perf.c
@@ -441,8 +441,11 @@ int main(int argc, const char **argv)
*
* So we just directly call the internal command handler, and
* die if that one cannot handle it.
+ *
+ * A special case is a digit option: this might be perf-versionnumber
+ * Just ignore that.
*/
- if (!prefixcmp(cmd, "perf-")) {
+ if (!prefixcmp(cmd, "perf-") && !isdigit(cmd[5])) {
cmd += 5;
argv[0] = cmd;
handle_internal_command(argc, argv);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: [1/2] perf: Make location of kernel source configurable
http://groups.google.com/group/linux.kernel/t/3a8de4c4bebc0a9a?hl=en
==============================================================================
== 1 of 1 ==
Date: Sun, Dec 6 2009 6:10 am
From: Andi Kleen
tools/perf has no support for separate object directories
and lots of hard coded paths assuming that the kernel source
is always in ../..
As a first step of compiling it separately without messing
up clean source trees allow to configure the kernel source
location using a KERNELSRC variable
This allows at least to copy the whole tools/perf
directory elsewhere and build it separately.
The default is still ../.., so for a standard build
nothing changes
This also removes a lot of ugly ../.. from the source.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
---
tools/perf/Makefile | 12 +++++++-----
tools/perf/perf.h | 16 ++++++++--------
tools/perf/util/header.h | 2 +-
tools/perf/util/include/linux/list.h | 2 +-
tools/perf/util/include/linux/poison.h | 2 +-
tools/perf/util/include/linux/rbtree.h | 2 +-
tools/perf/util/util.h | 2 +-
7 files changed, 20 insertions(+), 18 deletions(-)
Index: linux-2.6.32-ak/tools/perf/Makefile
===================================================================
--- linux-2.6.32-ak.orig/tools/perf/Makefile
+++ linux-2.6.32-ak/tools/perf/Makefile
@@ -146,6 +146,8 @@ all::
# your external grep (e.g., if your system lacks grep, if its grep is
# broken, or spawning external process is slower than built-in grep perf has).
+KERNELSRC := ../..
+
PERF-VERSION-FILE: .FORCE-PERF-VERSION-FILE
@$(SHELL_PATH) util/PERF-VERSION-GEN
-include PERF-VERSION-FILE
@@ -259,7 +261,7 @@ SPARSE_FLAGS = -D__BIG_ENDIAN__ -D__powe
# Those must not be GNU-specific; they are shared with perl/ which may
# be built by a different compiler. (Note that this is an artifact now
# but it still might be nice to keep that distinction.)
-BASIC_CFLAGS = -Iutil/include
+BASIC_CFLAGS = -Iutil/include -I $(KERNELSRC)
BASIC_LDFLAGS =
# Guard against environment variables
@@ -324,9 +326,9 @@ export PERL_PATH
LIB_FILE=libperf.a
-LIB_H += ../../include/linux/perf_event.h
-LIB_H += ../../include/linux/rbtree.h
-LIB_H += ../../include/linux/list.h
+LIB_H += $(KERNELSRC)/include/linux/perf_event.h
+LIB_H += $(KERNELSRC)/include/linux/rbtree.h
+LIB_H += $(KERNELSRC)/include/linux/list.h
LIB_H += util/include/linux/list.h
LIB_H += perf.h
LIB_H += util/types.h
@@ -784,7 +786,7 @@ builtin-init-db.o: builtin-init-db.c PER
util/config.o: util/config.c PERF-CFLAGS
$(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) -DETC_PERFCONFIG='"$(ETC_PERFCONFIG_SQ)"' $<
-util/rbtree.o: ../../lib/rbtree.c PERF-CFLAGS
+util/rbtree.o: $(KERNELSRC)/lib/rbtree.c PERF-CFLAGS
$(QUIET_CC)$(CC) -o util/rbtree.o -c $(ALL_CFLAGS) -DETC_PERFCONFIG='"$(ETC_PERFCONFIG_SQ)"' $<
perf-%$X: %.o $(PERFLIBS)
Index: linux-2.6.32-ak/tools/perf/perf.h
===================================================================
--- linux-2.6.32-ak.orig/tools/perf/perf.h
+++ linux-2.6.32-ak/tools/perf/perf.h
@@ -2,31 +2,31 @@
#define _PERF_PERF_H
#if defined(__i386__)
-#include "../../arch/x86/include/asm/unistd.h"
+#include "arch/x86/include/asm/unistd.h"
#define rmb() asm volatile("lock; addl $0,0(%%esp)" ::: "memory")
#define cpu_relax() asm volatile("rep; nop" ::: "memory");
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home