On Wed, Jun 23, 2010 at 03:14:54PM -0400, Jason Baron wrote:
> On Wed, Jun 23, 2010 at 11:16:44AM -0400, Steven Rostedt wrote:
> > On Wed, 2010-06-23 at 20:02 +1000, Ian Munsie wrote:
> > > From: Jason Baron
> > >
> > > In preparation for compat syscall tracing support, let's store the enabled
>
On Wed, Jun 23, 2010 at 11:16:44AM -0400, Steven Rostedt wrote:
> On Wed, 2010-06-23 at 20:02 +1000, Ian Munsie wrote:
> > From: Jason Baron
> >
> > In preparation for compat syscall tracing support, let's store the enabled
> > syscalls, with the struct syscall_metadata itself. That way we don't
On Wed, Jun 23, 2010 at 08:03:20PM +1000, Ian Munsie wrote:
> From: Ian Munsie
>
> This patch cleans up the preprocessor macros defining system calls by
> standidising on the parameters passing around the system call name, with
> and without it's prefix.
>
> Overall this makes the preprocessor c
On Wed, 2010-06-23 at 15:34 -0400, Jason Baron wrote:
> Actually, looking at this further, what we probably want to do change
> the "int nb_args" field, which is already in syscall_metadata into a bit
> field. nb_args I think can be at most 6, or 3 bits, and we only need 4
> bits for storing the e
On 06/23/2010 04:41 AM, Frederic Weisbecker wrote:
> On Wed, Jun 23, 2010 at 12:46:04PM +0200, Christoph Hellwig wrote:
>> On Wed, Jun 23, 2010 at 12:36:21PM +0200, Frederic Weisbecker wrote:
>>> I think we wanted that to keep the sys32_ prefixed based naming, to avoid
>>> collisions with generic c
On 06/23/2010 04:38 AM, Frederic Weisbecker wrote:
>
> I haven't heard any complains about existing syscalls wrappers.
>
Then you truly haven't been listening.
-hpa
--
H. Peter Anvin, Intel Open Source Technology Center
I work for Intel. I don't speak on their behalf.
__
On Wed, Jun 23, 2010 at 11:26:26AM -0400, Steven Rostedt wrote:
> On Wed, 2010-06-23 at 20:02 +1000, Ian Munsie wrote:
> > From: Jason Baron
> >
> > Add core support to event tracing for compat syscalls. The basic idea is
> > that we
> > check if we have a compat task via 'is_compat_task()'. If
Create sysfs interface to export data from H_BEST_ENERGY hcall
that can be used by administrative tools on supported pseries
platforms for energy management optimizations.
/sys/device/system/cpu/pseries_(de)activate_hint_list and
/sys/device/system/cpu/cpuN/
These APIs take logical cpu number as input
Change cpu_first_thread_in_core() to cpu_leftmost_thread_sibling()
Change cpu_last_thread_in_core() to cpu_rightmost_thread_sibling()
These APIs convert core number (index) to logical cpu/thread numbers
Add cpu_first_thread_of_core(int core)
Changed cpu_
Hi Ben,
The following series adds a kernel module for powerpc pseries platforms in
order to export platform energy management capabilities.
The module exports data from a new hypervisor call H_BEST_ENERGY.
Comments and suggestions made on the previous iteration of the patch
has been incorporated
On Wed, 2010-06-23 at 20:02 +1000, Ian Munsie wrote:
> From: Jason Baron
>
> Add core support to event tracing for compat syscalls. The basic idea is that
> we
> check if we have a compat task via 'is_compat_task()'. If so, we lookup in the
> new compat_syscalls_metadata table, the corresponding
On Wed, 2010-06-23 at 20:02 +1000, Ian Munsie wrote:
> From: Jason Baron
>
> In preparation for compat syscall tracing support, let's store the enabled
> syscalls, with the struct syscall_metadata itself. That way we don't duplicate
> enabled information when the compat table points to an entry i
On Wed, 2010-06-23 at 20:02 +1000, Ian Munsie wrote:
> From: Ian Munsie
>
> FTRACE_SYSCALLS would create events for each and every system call, even
> if it had failed to map the system call's name with it's number. This
> resulted in a number of events being created that would not behave as
> ex
unsubscribe
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev
On Wed, Jun 23, 2010 at 02:35:38PM +0200, Andi Kleen wrote:
> >I haven't heard any complains about existing syscalls wrappers.
>
> At least for me they always interrupt my grepping.
>
> >
> >What kind of annotations could solve that?
>
> If you put the annotation in a separate macro and leave th
I haven't heard any complains about existing syscalls wrappers.
At least for me they always interrupt my grepping.
What kind of annotations could solve that?
If you put the annotation in a separate macro and leave the original
prototype alone. Then C parsers could still parse it.
-Andi
On Wed, Jun 23, 2010 at 12:37:44PM +0200, Andi Kleen wrote:
> , Frederic Weisbecker wrote:
>> On Wed, Jun 23, 2010 at 12:19:38PM +0200, Andi Kleen wrote:
>>> , Ian Munsie wrote:
From: Ian Munsie
This patch converts numerous trivial compat syscalls through the generic
kernel code
> , Ian Munsie wrote:
> > From: Ian Munsie
> >
> > This patch converts numerous trivial compat syscalls through the generic
> > kernel code to use the COMPAT_SYSCALL_DEFINE family of macros.
>
> Why? This just makes the code look uglier and the functions harder
> to grep for.
I guess trace-syscal
On Wed, Jun 23, 2010 at 12:46:04PM +0200, Christoph Hellwig wrote:
> On Wed, Jun 23, 2010 at 12:36:21PM +0200, Frederic Weisbecker wrote:
> > I think we wanted that to keep the sys32_ prefixed based naming, to avoid
> > collisions with generic compat handler names.
>
> For native syscalls we do th
, Frederic Weisbecker wrote:
On Wed, Jun 23, 2010 at 12:19:38PM +0200, Andi Kleen wrote:
, Ian Munsie wrote:
From: Ian Munsie
This patch converts numerous trivial compat syscalls through the generic
kernel code to use the COMPAT_SYSCALL_DEFINE family of macros.
Why? This just makes the code
On Wed, Jun 23, 2010 at 12:36:21PM +0200, Frederic Weisbecker wrote:
> I think we wanted that to keep the sys32_ prefixed based naming, to avoid
> collisions with generic compat handler names.
For native syscalls we do this by adding a arch prefix inside the
syscall name, e.g.:
arch/s390/kernel/s
, Ian Munsie wrote:
From: Ian Munsie
This patch converts numerous trivial compat syscalls through the generic
kernel code to use the COMPAT_SYSCALL_DEFINE family of macros.
Why? This just makes the code look uglier and the functions harder
to grep for.
-Andi
__
On Wed, Jun 23, 2010 at 12:19:38PM +0200, Andi Kleen wrote:
> , Ian Munsie wrote:
>> From: Ian Munsie
>>
>> This patch converts numerous trivial compat syscalls through the generic
>> kernel code to use the COMPAT_SYSCALL_DEFINE family of macros.
>
> Why? This just makes the code look uglier and th
On Wed, Jun 23, 2010 at 12:14:02PM +0200, Christoph Hellwig wrote:
> Any reason we need to differenciate between COMPAT_SYSCALL_DEFINE and
> ARCH_COMPAT_SYSCALL_DEFINE? We don't need this for native system calls,
> so I can't see the reason to do it for compat system calls.
>
I think we wanted
From: Ian Munsie
This patch converts numerous trivial compat syscalls through the generic
kernel code to use the COMPAT_SYSCALL_DEFINE family of macros.
Signed-off-by: Ian Munsie
---
fs/compat.c|2 +-
fs/compat_ioctl.c |4 ++--
ipc/compat_mq.c| 24 +++
Any reason we need to differenciate between COMPAT_SYSCALL_DEFINE and
ARCH_COMPAT_SYSCALL_DEFINE? We don't need this for native system calls,
so I can't see the reason to do it for compat system calls.
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.oz
From: Ian Munsie
This patch adds support for syscalls using the SYSCALL_DEFINE macro
(i.e. ones that require a specialised syscall wrapper) to record their
meta-data for system call tracing.
The semantics of the SYSCALL_DEFINE macro therefore change to include
the number of arguments to the sysc
From: Ian Munsie
Several of the PowerPC system call implementations are used as both the
32bit compat version on PPC64 and the 32bit native version on PPC32.
Previousely these used the preprocessor to change the function names on
PPC64 to add the compat_ prefix.
This patch converts these system
From: Ian Munsie
This patch cleans up the preprocessor macros defining system calls by
standidising on the parameters passing around the system call name, with
and without it's prefix.
Overall this makes the preprocessor code easier to understand and
follow and less likely to introduce bugs due
From: Ian Munsie
This patch converts the PowerPC system calls with return types other
than long to use the various *SYSCALL_DEFINEx_RET family of macros so
their metadata is recorded for tracing.
This patch also renamed the ppc_rtas syscall to sys_rtas to fit in with
the naming convention of the
From: Ian Munsie
Many system calls are unimplemented and mapped to sys_ni_syscall, but at
boot ftrace would still search through every syscall metadata entry for
a match which wouldn't be there.
This patch adds causes the search to terminate early if the system call
is not mapped.
Signed-off-by
From: Ian Munsie
Since the ftrace event initialisation routine now verifies that either
the syscall number or the compat syscall number is valid and will not
create events for unmapped syscalls, it is unnecessary to explicitly
search for them, so remove it.
Signed-off-by: Ian Munsie
---
kernel
From: Ian Munsie
This patch will print out implemented but unmapped system calls at boot
to help quickly identify remaining unmapped system calls.
Signed-off-by: Ian Munsie
---
kernel/trace/trace_syscalls.c |1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/kernel/trace/t
From: Ian Munsie
This patch converts a number of syscalls from the generic code that had
return types other than long to use the new COMPAT_SYSCALL_DEFINEx_RET
macros so their metadata is recorded for tracing.
Signed-off-by: Ian Munsie
---
fs/compat.c | 24
ipc/c
From: Ian Munsie
A number of syscalls have return types other than long, which the
existing SYSCALL_DEFINE macros assumed. This patch adds aditional macros
that specify the return types (semantics of existing high level macros are
unchanged) for use with system calls with other return types.
Sig
From: Ian Munsie
This patch coverts a number of system calls on PowerPC to use the new
PPC_REGS_SYSCALL_DEFINE class of macros, to record their metadata but
still use the correct syntax to access the registers through the 7th
parameter.
Signed-off-by: Ian Munsie
---
arch/powerpc/include/asm/sy
From: Ian Munsie
This patch converts the remaining system calls from kernel/compat.c to
use the COMPAT_SYSCALL_DEFINE family of macros.
The particular system calls in question did not originally have the
asmlinkage tag which will be added by this conversion.
Signed-off-by: Ian Munsie
---
kern
From: Ian Munsie
This patch renames the 32bit compat syscalls prefixed with ppc32_ to
sys32_ and uses the ARCH_COMPAT_SYSCALL_DEFINE macros to record their
metadata for tracing.
Signed-off-by: Ian Munsie
---
arch/powerpc/include/asm/systbl.h |4 ++--
arch/powerpc/kernel/sys_ppc32.c |
From: Ian Munsie
Convert the remaining trivial 32bit compat syscalls to use the
COMPAT_SYSCALL_DEFINE family of macros.
The syscalls addressed by this commit were lacking the asmlinkage flag,
which will be added by the COMPAT_SYSCALL_DEFINE macros. This should not
be an issue as asmlinkage has n
From: Ian Munsie
Certain system calls on PowerPC access to the registers through a 7th
parameter, which will not fit into the model of the existing
SYSCALL_DEFINE macros.
This patch a new class of macros to handle this situation, recording the
metadata required for ftrace syscalls but still usin
From: Ian Munsie
This patchs adds the COMPAT_SYSCALL_DEFINE0 macros for compat syscalls
that do not take any arguments.
Signed-off-by: Ian Munsie
---
include/linux/syscalls.h |4
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/include/linux/syscalls.h b/include/linux/sy
From: Ian Munsie
The syscall metadata creation macros are a bit convoluted with some
duplicated code - particularly the duplication in SYSCALL_DEFINE0 with
SYSCALL_METADATA and related macros.
As demonstrated by the compat syscalls, there may be needs to introduce
additional high level *_SYSCALL
From: Ian Munsie
This patch alters the trivial syscalls (with a return type of long) in
PPC to use the SYSCALL_DEFINE family of macros to record their metadata
for ftrace syscalls.
It does not alter any non-trivial syscalls with different return types.
Several of the syscalls with a ppc_ prefix
From: Ian Munsie
Convert all the trivial 32bit PowerPC compat syscalls to use the
COMPAT_SYSCALL_DEFINE family of macros. This commit only converts the
syscalls with a return type of long for safety, syscalls with differing
return types will be dealt with in a separate commit.
This patch also al
From: Ian Munsie
This patch adds the necessary infrastructure to trace 32bit compat
syscalls on PowerPC64.
Signed-off-by: Ian Munsie
---
arch/powerpc/Kconfig |1 +
arch/powerpc/include/asm/unistd.h |4
arch/powerpc/kernel/ftrace.c |7 +++
3 files changed,
From: Ian Munsie
With the new compat syscall tracing, either syscall_nr or
compat_syscall_nr may be set, so test both before assuming that the
initialisation failed.
Signed-off-by: Ian Munsie
---
kernel/trace/trace_syscalls.c |6 --
1 files changed, 4 insertions(+), 2 deletions(-)
dif
From: Jason Baron
move the logic for enabling compat syscalls to common arch/Kconfig, where
config_compat_ftrace_syscalls depends on CONFIG_COMPAT, CONFIG_FTRACE_SYSCALLS,
and a per-arch CONFIG_HAVE_COMPAT_FTRACE_SYSCALLS. In this way arches that
want to add support for compat syscalls, can reque
From: Ian Munsie
With the ftrace events now checking if the syscall_nr is valid upon
initialisation, there is no need to verify it when registering and
unregistering the events, so remove the check.
Signed-off-by: Ian Munsie
---
kernel/trace/trace_syscalls.c | 18 --
1 files
From: Jason Baron
Create a new "compat_syscalls" subsys for tracing
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
include/linux/syscalls.h | 40 +---
kernel/trace/trace_syscalls.c | 16
2 files changed, 37 insertions(+),
From: Jason Baron
make tags.sh recognize the new syscall macros:
COMPAT_SYSCALL_DEFINE#N()
ARCH_COMPAT_SYSCALL_DEFINE#N()
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
scripts/tags.sh |8 ++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/scripts/tags.sh b
From: Jason Baron
convert kernel/compat.c to use the new COMPAT_SYSCALL_DEFINE#N macro. Thus,
tying these syscalls into the syscall event layer.
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
kernel/compat.c | 106 ++
1 files chan
From: Jason Baron
convert the fs/compat.c file to use the COMPAT_SYSCALL_DEFINE#N() macros to tie
them into the generic compat layer.
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
fs/compat.c | 147 +--
1 files changed, 72 in
From: Jason Baron
Add core support to event tracing for compat syscalls. The basic idea is that we
check if we have a compat task via 'is_compat_task()'. If so, we lookup in the
new compat_syscalls_metadata table, the corresponding struct syscall_metadata,
to
check syscall arguments and whether
From: Jason Baron
Make use of the new ARCH_COMPAT_SYSCALL_DEFINE#N() macros to tie the compat
syscalls into the event tracer.
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
arch/x86/ia32/sys_ia32.c | 102 +++---
1 files changed, 51 insertions
From: Jason Baron
Add COMPAT_SYSCALL_DEFINE#N() macro define common compat syscalls that
are not arch specific. Prepends "compat_sys_" to the syscall name to identify
it.
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
include/linux/syscalls.h |7 +++
1 files changed, 7 inser
From: Jason Baron
Add ARCH_COMPAT_SYSCALL_DEFINE#N() macro which prepends "sys32_" to
arch specific compat syscall names. Identifies the 'compat' syscalls.
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
include/linux/syscalls.h | 50 ++---
1
From: Jason Baron
trace_syscalls.c uses __start_ftrace_events and __stop_ftrace_events in order
to prune compat syscall ftrace events that are not referenced by the compat
syscall table. So move the 'extern' definitions to a common header file.
Signed-off-by: Jason Baron
Signed-off-by: Ian Muns
From: Jason Baron
In preparation for compat syscall tracing support, let's store the enabled
syscalls, with the struct syscall_metadata itself. That way we don't duplicate
enabled information when the compat table points to an entry in the regular
syscall table. Also, allows us to remove the bitm
From: Heiko Carstens
add generic is_compat_task()
Signed-off-by: Jason Baron
Signed-off-by: Heiko Carstens
Signed-off-by: Ian Munsie
---
arch/s390/include/asm/compat.h |7 ---
arch/s390/kernel/ptrace.c |2 +-
arch/s390/kernel/setup.c|2 +-
arch/s390/mm/mmap.c
From: Jason Baron
Add arch_compat_syscall_addr(int nr) for x86_64. This is in preparation for
adding
compat syscall support to the event tracer.
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
arch/x86/include/asm/syscall.h |5 +
arch/x86/kernel/ftrace.c |8 +++
From: Jason Baron
Add 'NR_syscalls_compat' global for x86. Also, make 'ia32_sys_call_table' into a
global.
Signed-off-by: Jason Baron
Signed-off-by: Ian Munsie
---
arch/x86/ia32/ia32entry.S |3 +++
arch/x86/include/asm/compat.h |2 ++
2 files changed, 5 insertions(+), 0 deletions(
From: Ian Munsie
This patch implements the raw syscall tracepoints on PowerPC and exports
them for ftrace syscalls to use.
To minimise reworking existing code, I slightly re-ordered the thread
info flags such that the new TIF_SYSCALL_TRACEPOINT bit would still fit
within the 16 bits of the andi.
From: Ian Munsie
Some architectures have unusual symbol names and the generic code to
match the symbol name with the function name for the syscall metadata
will fail. For example, symbols on PPC64 start with a period and the
generic code will fail to match them.
This patch splits out the match l
From: Ian Munsie
Some architectures use non-trivial system call tables and will not work
with the generic arch_syscall_addr code. For example, PowerPC64 uses a
table of twin long longs.
This patch makes the generic arch_syscall_addr weak to allow
architectures with non-trivial system call tables
From: Ian Munsie
FTRACE_SYSCALLS would create events for each and every system call, even
if it had failed to map the system call's name with it's number. This
resulted in a number of events being created that would not behave as
expected.
This could happen, for example, on architectures who's s
This patch series implements ftrace syscall tracing on PowerPC. All PPC 32bit,
64bit and 32bit compat syscalls are supported along with all the missing
generic compat syscalls.
This patch series includes Jason Baron's Compat Syscall Support v3 patches
rebased atop the current tip tree as patches 0
66 matches
Mail list logo