Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 178160
b: refs/heads/master
c: 925cc71
h: refs/heads/master
v: v3
  • Loading branch information
Robert Jennings authored and Benjamin Herrenschmidt committed Dec 18, 2009
1 parent 6c43524 commit 7f06531
Show file tree
Hide file tree
Showing 174 changed files with 2,111 additions and 2,848 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7801edb0b8b66e83c13623b483bc2e846c007c9d
refs/heads/master: 925cc71e512a29e2594bcc17dc58d0a0e9c4d524
14 changes: 7 additions & 7 deletions trunk/Documentation/trace/events-kmem.txt
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
Subsystem Trace Points: kmem

The kmem tracing system captures events related to object and page allocation
within the kernel. Broadly speaking there are five major subheadings.
The tracing system kmem captures events related to object and page allocation
within the kernel. Broadly speaking there are four major subheadings.

o Slab allocation of small objects of unknown type (kmalloc)
o Slab allocation of small objects of known type
o Page allocation
o Per-CPU Allocator Activity
o External Fragmentation

This document describes what each of the tracepoints is and why they
This document will describe what each of the tracepoints are and why they
might be useful.

1. Slab allocation of small objects of unknown type
Expand All @@ -34,7 +34,7 @@ kmem_cache_free call_site=%lx ptr=%p
These events are similar in usage to the kmalloc-related events except that
it is likely easier to pin the event down to a specific cache. At the time
of writing, no information is available on what slab is being allocated from,
but the call_site can usually be used to extrapolate that information.
but the call_site can usually be used to extrapolate that information

3. Page allocation
==================
Expand Down Expand Up @@ -80,9 +80,9 @@ event indicating whether it is for a percpu_refill or not.
When the per-CPU list is too full, a number of pages are freed, each one
which triggers a mm_page_pcpu_drain event.

The individual nature of the events is so that pages can be tracked
The individual nature of the events are so that pages can be tracked
between allocation and freeing. A number of drain or refill pages that occur
consecutively imply the zone->lock being taken once. Large amounts of per-CPU
consecutively imply the zone->lock being taken once. Large amounts of PCP
refills and drains could imply an imbalance between CPUs where too much work
is being concentrated in one place. It could also indicate that the per-CPU
lists should be a larger size. Finally, large amounts of refills on one CPU
Expand All @@ -102,6 +102,6 @@ is important.

Large numbers of this event implies that memory is fragmenting and
high-order allocations will start failing at some time in the future. One
means of reducing the occurrence of this event is to increase the size of
means of reducing the occurange of this event is to increase the size of
min_free_kbytes in increments of 3*pageblock_size*nr_online_nodes where
pageblock_size is usually the size of the default hugepage size.
7 changes: 0 additions & 7 deletions trunk/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,6 @@ NAME = Man-Eating Seals of Antiquity
# o print "Entering directory ...";
MAKEFLAGS += -rR --no-print-directory

# Avoid funny character set dependencies
unexport LC_ALL
LC_CTYPE=C
LC_COLLATE=C
LC_NUMERIC=C
export LC_CTYPE LC_COLLATE LC_NUMERIC

# We are using a recursive build, so we need to do a little thinking
# to get the ordering right.
#
Expand Down
4 changes: 3 additions & 1 deletion trunk/arch/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,9 @@ config HAVE_DEFAULT_NO_SPIN_MUTEXES

config HAVE_HW_BREAKPOINT
bool
depends on PERF_EVENTS
depends on HAVE_PERF_EVENTS
select ANON_INODES
select PERF_EVENTS

config HAVE_USER_RETURN_NOTIFIER
bool
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/alpha/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ config ALPHA
select HAVE_IDE
select HAVE_OPROFILE
select HAVE_SYSCALL_WRAPPERS
select HAVE_PERF_EVENTS
help
The Alpha is a 64-bit general-purpose processor designed and
marketed by the Digital Equipment Corporation of blessed memory,
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/alpha/include/asm/bug.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@
"call_pal %0 # bugchk\n\t" \
".long %1\n\t.8byte %2" \
: : "i"(PAL_bugchk), "i"(__LINE__), "i"(__FILE__)); \
unreachable(); \
} while (0)
for ( ; ; ); } while (0)

#define HAVE_ARCH_BUG
#endif
Expand Down
9 changes: 0 additions & 9 deletions trunk/arch/alpha/include/asm/perf_event.h

This file was deleted.

17 changes: 1 addition & 16 deletions trunk/arch/alpha/include/asm/unistd.h
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,6 @@
#define __IGNORE_pause
#define __IGNORE_time
#define __IGNORE_utime
#define __IGNORE_umount2

/*
* Linux-specific system calls begin at 300
Expand Down Expand Up @@ -435,24 +434,10 @@
#define __NR_timerfd 477
#define __NR_eventfd 478
#define __NR_recvmmsg 479
#define __NR_fallocate 480
#define __NR_timerfd_create 481
#define __NR_timerfd_settime 482
#define __NR_timerfd_gettime 483
#define __NR_signalfd4 484
#define __NR_eventfd2 485
#define __NR_epoll_create1 486
#define __NR_dup3 487
#define __NR_pipe2 488
#define __NR_inotify_init1 489
#define __NR_preadv 490
#define __NR_pwritev 491
#define __NR_rt_tgsigqueueinfo 492
#define __NR_perf_event_open 493

#ifdef __KERNEL__

#define NR_SYSCALLS 494
#define NR_SYSCALLS 480

#define __ARCH_WANT_IPC_PARSE_VERSION
#define __ARCH_WANT_OLD_READDIR
Expand Down
16 changes: 1 addition & 15 deletions trunk/arch/alpha/kernel/systbls.S
Original file line number Diff line number Diff line change
Expand Up @@ -495,23 +495,9 @@ sys_call_table:
.quad sys_epoll_pwait
.quad sys_utimensat /* 475 */
.quad sys_signalfd
.quad sys_ni_syscall /* sys_timerfd */
.quad sys_ni_syscall
.quad sys_eventfd
.quad sys_recvmmsg
.quad sys_fallocate /* 480 */
.quad sys_timerfd_create
.quad sys_timerfd_settime
.quad sys_timerfd_gettime
.quad sys_signalfd4
.quad sys_eventfd2 /* 485 */
.quad sys_epoll_create1
.quad sys_dup3
.quad sys_pipe2
.quad sys_inotify_init1
.quad sys_preadv /* 490 */
.quad sys_pwritev
.quad sys_rt_tgsigqueueinfo
.quad sys_perf_event_open

.size sys_call_table, . - sys_call_table
.type sys_call_table, @object
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/s390/crypto/aes_s390.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ static int fallback_init_cip(struct crypto_tfm *tfm)
if (IS_ERR(sctx->fallback.cip)) {
pr_err("Allocating AES fallback algorithm %s failed\n",
name);
return PTR_ERR(sctx->fallback.cip);
return PTR_ERR(sctx->fallback.blk);
}

return 0;
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/s390/hypfs/hypfs_diag.c
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ static inline void part_hdr__part_name(enum diag204_format type, void *hdr,
LPAR_NAME_LEN);
EBCASC(name, LPAR_NAME_LEN);
name[LPAR_NAME_LEN] = 0;
strim(name);
strstrip(name);
}

struct cpu_info {
Expand Down Expand Up @@ -523,7 +523,7 @@ static int diag224_idx2name(int index, char *name)
memcpy(name, diag224_cpu_names + ((index + 1) * CPU_NAME_LEN),
CPU_NAME_LEN);
name[CPU_NAME_LEN] = 0;
strim(name);
strstrip(name);
return 0;
}

Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/s390/hypfs/hypfs_vm.c
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ static int hpyfs_vm_create_guest(struct super_block *sb,
/* guest dir */
memcpy(guest_name, data->guest_name, NAME_LEN);
EBCASC(guest_name, NAME_LEN);
strim(guest_name);
strstrip(guest_name);
guest_dir = hypfs_mkdir(sb, systems_dir, guest_name);
if (IS_ERR(guest_dir))
return PTR_ERR(guest_dir);
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/s390/include/asm/unistd.h
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,7 @@
#define __NR_pwritev 329
#define __NR_rt_tgsigqueueinfo 330
#define __NR_perf_event_open 331
#define __NR_recvmmsg 332
#define NR_syscalls 333
#define NR_syscalls 332

/*
* There are some system calls that are not present on 64 bit, some
Expand Down
9 changes: 0 additions & 9 deletions trunk/arch/s390/kernel/compat_wrapper.S
Original file line number Diff line number Diff line change
Expand Up @@ -1853,12 +1853,3 @@ sys32_execve_wrapper:
llgtr %r3,%r3 # compat_uptr_t *
llgtr %r4,%r4 # compat_uptr_t *
jg sys32_execve # branch to system call

.globl compat_sys_recvmmsg_wrapper
compat_sys_recvmmsg_wrapper:
lgfr %r2,%r2 # int
llgtr %r3,%r3 # struct compat_mmsghdr *
llgfr %r4,%r4 # unsigned int
llgfr %r5,%r5 # unsigned int
llgtr %r6,%r6 # struct compat_timespec *
jg compat_sys_recvmmsg
6 changes: 3 additions & 3 deletions trunk/arch/s390/kernel/ipl.c
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ static ssize_t sys_##_prefix##_##_name##_store(struct kobject *kobj, \
const char *buf, size_t len) \
{ \
strncpy(_value, buf, sizeof(_value) - 1); \
strim(_value); \
strstrip(_value); \
return len; \
} \
static struct kobj_attribute sys_##_prefix##_##_name##_attr = \
Expand Down Expand Up @@ -472,7 +472,7 @@ static ssize_t ipl_ccw_loadparm_show(struct kobject *kobj,
return sprintf(page, "#unknown#\n");
memcpy(loadparm, &sclp_ipl_info.loadparm, LOADPARM_LEN);
EBCASC(loadparm, LOADPARM_LEN);
strim(loadparm);
strstrip(loadparm);
return sprintf(page, "%s\n", loadparm);
}

Expand Down Expand Up @@ -776,7 +776,7 @@ static void reipl_get_ascii_loadparm(char *loadparm,
memcpy(loadparm, ibp->ipl_info.ccw.load_parm, LOADPARM_LEN);
EBCASC(loadparm, LOADPARM_LEN);
loadparm[LOADPARM_LEN] = 0;
strim(loadparm);
strstrip(loadparm);
}

static ssize_t reipl_generic_loadparm_show(struct ipl_parameter_block *ipb,
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/s390/kernel/ptrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -959,7 +959,7 @@ static const struct user_regset s390_compat_regsets[] = {
.set = s390_fpregs_set,
},
[REGSET_GENERAL_EXTENDED] = {
.core_note_type = NT_S390_HIGH_GPRS,
.core_note_type = NT_PRXSTATUS,
.n = sizeof(s390_compat_regs_high) / sizeof(compat_long_t),
.size = sizeof(compat_long_t),
.align = sizeof(compat_long_t),
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/s390/kernel/syscalls.S
Original file line number Diff line number Diff line change
Expand Up @@ -340,4 +340,3 @@ SYSCALL(sys_preadv,sys_preadv,compat_sys_preadv_wrapper)
SYSCALL(sys_pwritev,sys_pwritev,compat_sys_pwritev_wrapper)
SYSCALL(sys_rt_tgsigqueueinfo,sys_rt_tgsigqueueinfo,compat_sys_rt_tgsigqueueinfo_wrapper) /* 330 */
SYSCALL(sys_perf_event_open,sys_perf_event_open,sys_perf_event_open_wrapper)
SYSCALL(sys_recvmmsg,sys_recvmmsg,compat_sys_recvmmsg_wrapper)
6 changes: 3 additions & 3 deletions trunk/arch/s390/kernel/traps.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#include <linux/kernel.h>
#include <linux/string.h>
#include <linux/errno.h>
#include <linux/tracehook.h>
#include <linux/ptrace.h>
#include <linux/timer.h>
#include <linux/mm.h>
#include <linux/smp.h>
Expand Down Expand Up @@ -382,7 +382,7 @@ void __kprobes do_single_step(struct pt_regs *regs)
SIGTRAP) == NOTIFY_STOP){
return;
}
if (tracehook_consider_fatal_signal(current, SIGTRAP))
if ((current->ptrace & PT_PTRACED) != 0)
force_sig(SIGTRAP, current);
}

Expand Down Expand Up @@ -483,7 +483,7 @@ static void illegal_op(struct pt_regs * regs, long interruption_code)
if (get_user(*((__u16 *) opcode), (__u16 __user *) location))
return;
if (*((__u16 *) opcode) == S390_BREAKPOINT_U16) {
if (tracehook_consider_fatal_signal(current, SIGTRAP))
if (current->ptrace & PT_PTRACED)
force_sig(SIGTRAP, current);
else
signal = SIGILL;
Expand Down
2 changes: 0 additions & 2 deletions trunk/arch/x86/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,6 @@ config X86
select HAVE_KERNEL_BZIP2
select HAVE_KERNEL_LZMA
select HAVE_HW_BREAKPOINT
select PERF_EVENTS
select ANON_INODES
select HAVE_ARCH_KMEMCHECK
select HAVE_USER_RETURN_NOTIFIER

Expand Down
1 change: 0 additions & 1 deletion trunk/arch/x86/include/asm/cpufeature.h
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,6 @@
#define X86_FEATURE_SSE5 (6*32+11) /* SSE-5 */
#define X86_FEATURE_SKINIT (6*32+12) /* SKINIT/STGI instructions */
#define X86_FEATURE_WDT (6*32+13) /* Watchdog timer */
#define X86_FEATURE_NODEID_MSR (6*32+19) /* NodeId MSR */

/*
* Auxiliary flags: Linux defined - For features scattered in various
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/x86/include/asm/hw_irq.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,7 @@ extern int assign_irq_vector(int, struct irq_cfg *, const struct cpumask *);
extern void send_cleanup_vector(struct irq_cfg *);

struct irq_desc;
extern unsigned int set_desc_affinity(struct irq_desc *, const struct cpumask *,
unsigned int *dest_id);
extern unsigned int set_desc_affinity(struct irq_desc *, const struct cpumask *);
extern int IO_APIC_get_PCI_irq_vector(int bus, int devfn, int pin, struct io_apic_irq_attr *irq_attr);
extern void setup_ioapic_dest(void);

Expand Down
2 changes: 0 additions & 2 deletions trunk/arch/x86/include/asm/msr-index.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#define MSR_FS_BASE 0xc0000100 /* 64bit FS base */
#define MSR_GS_BASE 0xc0000101 /* 64bit GS base */
#define MSR_KERNEL_GS_BASE 0xc0000102 /* SwapGS GS shadow */
#define MSR_TSC_AUX 0xc0000103 /* Auxiliary TSC */

/* EFER bits: */
#define _EFER_SCE 0 /* SYSCALL/SYSRET */
Expand Down Expand Up @@ -124,7 +123,6 @@
#define FAM10H_MMIO_CONF_BUSRANGE_SHIFT 2
#define FAM10H_MMIO_CONF_BASE_MASK 0xfffffff
#define FAM10H_MMIO_CONF_BASE_SHIFT 20
#define MSR_FAM10H_NODE_ID 0xc001100c

/* K8 MSRs */
#define MSR_K8_TOP_MEM1 0xc001001a
Expand Down
16 changes: 2 additions & 14 deletions trunk/arch/x86/include/asm/msr.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,18 +27,6 @@ struct msr {
};
};

struct msr_info {
u32 msr_no;
struct msr reg;
struct msr *msrs;
int err;
};

struct msr_regs_info {
u32 *regs;
int err;
};

static inline unsigned long long native_read_tscp(unsigned int *aux)
{
unsigned long low, high;
Expand Down Expand Up @@ -252,9 +240,9 @@ do { \
#define checking_wrmsrl(msr, val) wrmsr_safe((msr), (u32)(val), \
(u32)((val) >> 32))

#define write_tsc(val1, val2) wrmsr(MSR_IA32_TSC, (val1), (val2))
#define write_tsc(val1, val2) wrmsr(0x10, (val1), (val2))

#define write_rdtscp_aux(val) wrmsr(MSR_TSC_AUX, (val), 0)
#define write_rdtscp_aux(val) wrmsr(0xc0000103, (val), 0)

struct msr *msrs_alloc(void);
void msrs_free(struct msr *msrs);
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/x86/include/asm/processor.h
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ static inline void native_cpuid(unsigned int *eax, unsigned int *ebx,
unsigned int *ecx, unsigned int *edx)
{
/* ecx is often an input as well as an output. */
asm volatile("cpuid"
asm("cpuid"
: "=a" (*eax),
"=b" (*ebx),
"=c" (*ecx),
Expand Down
Loading

0 comments on commit 7f06531

Please sign in to comment.