Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 26031
b: refs/heads/master
c: 949b211
h: refs/heads/master
i:
  26029: c4f07eb
  26027: ffd72d9
  26023: 9fa6202
  26015: 8fa7350
v: v3
  • Loading branch information
Linus Torvalds committed Apr 19, 2006
1 parent e04ab4a commit ae07693
Show file tree
Hide file tree
Showing 69 changed files with 587 additions and 436 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: a5f9145bc9c340bda743ad51e09bdea60fa3ddfa
refs/heads/master: 949b211235cf301790ef4fb903af65d71be29b2a
11 changes: 10 additions & 1 deletion trunk/Documentation/vm/hugetlbpage.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,16 @@ The output of "cat /proc/meminfo" will have lines like:
.....
HugePages_Total: xxx
HugePages_Free: yyy
Hugepagesize: zzz KB
HugePages_Rsvd: www
Hugepagesize: zzz kB

where:
HugePages_Total is the size of the pool of hugepages.
HugePages_Free is the number of hugepages in the pool that are not yet
allocated.
HugePages_Rsvd is short for "reserved," and is the number of hugepages
for which a commitment to allocate from the pool has been made, but no
allocation has yet been made. It's vaguely analogous to overcommit.

/proc/filesystems should also show a filesystem of type "hugetlbfs" configured
in the kernel.
Expand Down
23 changes: 22 additions & 1 deletion trunk/README
Original file line number Diff line number Diff line change
Expand Up @@ -165,10 +165,31 @@ CONFIGURING the kernel:
"make xconfig" X windows (Qt) based configuration tool.
"make gconfig" X windows (Gtk) based configuration tool.
"make oldconfig" Default all questions based on the contents of
your existing ./.config file.
your existing ./.config file and asking about
new config symbols.
"make silentoldconfig"
Like above, but avoids cluttering the screen
with questions already answered.
"make defconfig" Create a ./.config file by using the default
symbol values from arch/$ARCH/defconfig.
"make allyesconfig"
Create a ./.config file by setting symbol
values to 'y' as much as possible.
"make allmodconfig"
Create a ./.config file by setting symbol
values to 'm' as much as possible.
"make allnoconfig" Create a ./.config file by setting symbol
values to 'n' as much as possible.
"make randconfig" Create a ./.config file by setting symbol
values to random values.

The allyesconfig/allmodconfig/allnoconfig/randconfig variants can
also use the environment variable KCONFIG_ALLCONFIG to specify a
filename that contains config options that the user requires to be
set to a specific value. If KCONFIG_ALLCONFIG=filename is not used,
"make *config" checks for a file named "all{yes/mod/no/random}.config"
for symbol values that are to be forced. If this file is not found,
it checks for a file named "all.config" to contain forced values.

NOTES on "make config":
- having unnecessary drivers will make the kernel bigger, and can
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/i386/kernel/apm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1079,7 +1079,7 @@ static int apm_console_blank(int blank)
break;
}

if (error == APM_NOT_ENGAGED && state != APM_STATE_READY) {
if (error == APM_NOT_ENGAGED) {
static int tried;
int eng_error;
if (tried++ == 0) {
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/i386/kernel/cpuid.c
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ static int cpuid_class_device_create(int i)
return err;
}

static int __devinit cpuid_class_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu)
static int cpuid_class_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu)
{
unsigned int cpu = (unsigned long)hcpu;

Expand Down
18 changes: 9 additions & 9 deletions trunk/arch/i386/kernel/kprobes.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ DEFINE_PER_CPU(struct kprobe *, current_kprobe) = NULL;
DEFINE_PER_CPU(struct kprobe_ctlblk, kprobe_ctlblk);

/* insert a jmp code */
static inline void set_jmp_op(void *from, void *to)
static __always_inline void set_jmp_op(void *from, void *to)
{
struct __arch_jmp_op {
char op;
Expand All @@ -57,7 +57,7 @@ static inline void set_jmp_op(void *from, void *to)
/*
* returns non-zero if opcodes can be boosted.
*/
static inline int can_boost(kprobe_opcode_t opcode)
static __always_inline int can_boost(kprobe_opcode_t opcode)
{
switch (opcode & 0xf0 ) {
case 0x70:
Expand Down Expand Up @@ -88,7 +88,7 @@ static inline int can_boost(kprobe_opcode_t opcode)
/*
* returns non-zero if opcode modifies the interrupt flag.
*/
static inline int is_IF_modifier(kprobe_opcode_t opcode)
static int __kprobes is_IF_modifier(kprobe_opcode_t opcode)
{
switch (opcode) {
case 0xfa: /* cli */
Expand Down Expand Up @@ -138,23 +138,23 @@ void __kprobes arch_remove_kprobe(struct kprobe *p)
mutex_unlock(&kprobe_mutex);
}

static inline void save_previous_kprobe(struct kprobe_ctlblk *kcb)
static void __kprobes save_previous_kprobe(struct kprobe_ctlblk *kcb)
{
kcb->prev_kprobe.kp = kprobe_running();
kcb->prev_kprobe.status = kcb->kprobe_status;
kcb->prev_kprobe.old_eflags = kcb->kprobe_old_eflags;
kcb->prev_kprobe.saved_eflags = kcb->kprobe_saved_eflags;
}

static inline void restore_previous_kprobe(struct kprobe_ctlblk *kcb)
static void __kprobes restore_previous_kprobe(struct kprobe_ctlblk *kcb)
{
__get_cpu_var(current_kprobe) = kcb->prev_kprobe.kp;
kcb->kprobe_status = kcb->prev_kprobe.status;
kcb->kprobe_old_eflags = kcb->prev_kprobe.old_eflags;
kcb->kprobe_saved_eflags = kcb->prev_kprobe.saved_eflags;
}

static inline void set_current_kprobe(struct kprobe *p, struct pt_regs *regs,
static void __kprobes set_current_kprobe(struct kprobe *p, struct pt_regs *regs,
struct kprobe_ctlblk *kcb)
{
__get_cpu_var(current_kprobe) = p;
Expand All @@ -164,7 +164,7 @@ static inline void set_current_kprobe(struct kprobe *p, struct pt_regs *regs,
kcb->kprobe_saved_eflags &= ~IF_MASK;
}

static inline void prepare_singlestep(struct kprobe *p, struct pt_regs *regs)
static void __kprobes prepare_singlestep(struct kprobe *p, struct pt_regs *regs)
{
regs->eflags |= TF_MASK;
regs->eflags &= ~IF_MASK;
Expand Down Expand Up @@ -507,7 +507,7 @@ static void __kprobes resume_execution(struct kprobe *p,
* Interrupts are disabled on entry as trap1 is an interrupt gate and they
* remain disabled thoroughout this function.
*/
static inline int post_kprobe_handler(struct pt_regs *regs)
static int __kprobes post_kprobe_handler(struct pt_regs *regs)
{
struct kprobe *cur = kprobe_running();
struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
Expand Down Expand Up @@ -543,7 +543,7 @@ static inline int post_kprobe_handler(struct pt_regs *regs)
return 1;
}

static inline int kprobe_fault_handler(struct pt_regs *regs, int trapnr)
static int __kprobes kprobe_fault_handler(struct pt_regs *regs, int trapnr)
{
struct kprobe *cur = kprobe_running();
struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/i386/kernel/msr.c
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ static int msr_class_device_create(int i)
return err;
}

static int __devinit msr_class_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu)
static int msr_class_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu)
{
unsigned int cpu = (unsigned long)hcpu;

Expand Down
1 change: 0 additions & 1 deletion trunk/arch/i386/mach-voyager/voyager_cat.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,6 @@ static struct resource qic_res = {
* It writes num_bits of the data buffer in msg starting at start_bit.
* Note: This function assumes that any unused bit in the data stream
* is set to zero so that the ors will work correctly */
#define BITS_PER_BYTE 8
static void
cat_pack(__u8 *msg, const __u16 start_bit, __u8 *data, const __u16 num_bits)
{
Expand Down
10 changes: 5 additions & 5 deletions trunk/arch/ia64/kernel/kprobes.c
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ static void __kprobes prepare_break_inst(uint template, uint slot,
update_kprobe_inst_flag(template, slot, major_opcode, kprobe_inst, p);
}

static inline void get_kprobe_inst(bundle_t *bundle, uint slot,
static void __kprobes get_kprobe_inst(bundle_t *bundle, uint slot,
unsigned long *kprobe_inst, uint *major_opcode)
{
unsigned long kprobe_inst_p0, kprobe_inst_p1;
Expand All @@ -278,7 +278,7 @@ static inline void get_kprobe_inst(bundle_t *bundle, uint slot,
}

/* Returns non-zero if the addr is in the Interrupt Vector Table */
static inline int in_ivt_functions(unsigned long addr)
static int __kprobes in_ivt_functions(unsigned long addr)
{
return (addr >= (unsigned long)__start_ivt_text
&& addr < (unsigned long)__end_ivt_text);
Expand Down Expand Up @@ -308,19 +308,19 @@ static int __kprobes valid_kprobe_addr(int template, int slot,
return 0;
}

static inline void save_previous_kprobe(struct kprobe_ctlblk *kcb)
static void __kprobes save_previous_kprobe(struct kprobe_ctlblk *kcb)
{
kcb->prev_kprobe.kp = kprobe_running();
kcb->prev_kprobe.status = kcb->kprobe_status;
}

static inline void restore_previous_kprobe(struct kprobe_ctlblk *kcb)
static void __kprobes restore_previous_kprobe(struct kprobe_ctlblk *kcb)
{
__get_cpu_var(current_kprobe) = kcb->prev_kprobe.kp;
kcb->kprobe_status = kcb->prev_kprobe.status;
}

static inline void set_current_kprobe(struct kprobe *p,
static void __kprobes set_current_kprobe(struct kprobe *p,
struct kprobe_ctlblk *kcb)
{
__get_cpu_var(current_kprobe) = p;
Expand Down
55 changes: 22 additions & 33 deletions trunk/arch/m32r/kernel/entry.S
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
* Stack layout in 'ret_from_system_call':
* ptrace needs to have all regs on the stack.
* if the order here is changed, it needs to be
* updated in fork.c:copy_process, signal.c:do_signal,
* updated in fork.c:copy_thread, signal.c:do_signal,
* ptrace.c and ptrace.h
*
* M32Rx/M32R2 M32R
Expand All @@ -41,18 +41,17 @@
* @(0x38,sp) - syscall_nr ditto
* @(0x3c,sp) - acc0h @(0x3c,sp) - acch
* @(0x40,sp) - acc0l @(0x40,sp) - accl
* @(0x44,sp) - acc1h @(0x44,sp) - psw
* @(0x48,sp) - acc1l @(0x48,sp) - bpc
* @(0x4c,sp) - psw @(0x4c,sp) - bbpsw
* @(0x50,sp) - bpc @(0x50,sp) - bbpc
* @(0x54,sp) - bbpsw @(0x54,sp) - spu (cr3)
* @(0x58,sp) - bbpc @(0x58,sp) - fp (r13)
* @(0x5c,sp) - spu (cr3) @(0x5c,sp) - lr (r14)
* @(0x60,sp) - fp (r13) @(0x60,sp) - spi (cr12)
* @(0x64,sp) - lr (r14) @(0x64,sp) - orig_r0
* @(0x68,sp) - spi (cr2)
* @(0x6c,sp) - orig_r0
*
* @(0x44,sp) - acc1h @(0x44,sp) - dummy_acc1h
* @(0x48,sp) - acc1l @(0x48,sp) - dummy_acc1l
* @(0x4c,sp) - psw ditto
* @(0x50,sp) - bpc ditto
* @(0x54,sp) - bbpsw ditto
* @(0x58,sp) - bbpc ditto
* @(0x5c,sp) - spu (cr3) ditto
* @(0x60,sp) - fp (r13) ditto
* @(0x64,sp) - lr (r14) ditto
* @(0x68,sp) - spi (cr2) ditto
* @(0x6c,sp) - orig_r0 ditto
*/

#include <linux/config.h>
Expand Down Expand Up @@ -102,6 +101,12 @@
#define ACC0L(reg) @(0x40,reg)
#define ACC1H(reg) @(0x44,reg)
#define ACC1L(reg) @(0x48,reg)
#elif defined(CONFIG_ISA_M32R2) || defined(CONFIG_ISA_M32R)
#define ACCH(reg) @(0x3C,reg)
#define ACCL(reg) @(0x40,reg)
#else
#error unknown isa configuration
#endif
#define PSW(reg) @(0x4C,reg)
#define BPC(reg) @(0x50,reg)
#define BBPSW(reg) @(0x54,reg)
Expand All @@ -111,21 +116,6 @@
#define LR(reg) @(0x64,reg)
#define SP(reg) @(0x68,reg)
#define ORIG_R0(reg) @(0x6C,reg)
#elif defined(CONFIG_ISA_M32R2) || defined(CONFIG_ISA_M32R)
#define ACCH(reg) @(0x3C,reg)
#define ACCL(reg) @(0x40,reg)
#define PSW(reg) @(0x44,reg)
#define BPC(reg) @(0x48,reg)
#define BBPSW(reg) @(0x4C,reg)
#define BBPC(reg) @(0x50,reg)
#define SPU(reg) @(0x54,reg)
#define FP(reg) @(0x58,reg) /* FP = R13 */
#define LR(reg) @(0x5C,reg)
#define SP(reg) @(0x60,reg)
#define ORIG_R0(reg) @(0x64,reg)
#else
#error unknown isa configuration
#endif

CF_MASK = 0x00000001
TF_MASK = 0x00000100
Expand All @@ -142,7 +132,7 @@ VM_MASK = 0x00020000
#endif

ENTRY(ret_from_fork)
ld r0, @sp+
pop r0
bl schedule_tail
GET_THREAD_INFO(r8)
bra syscall_exit
Expand Down Expand Up @@ -231,7 +221,7 @@ restore_all:
RESTORE_ALL

# perform work that needs to be done immediately before resumption
# r9 : frags
# r9 : flags
ALIGN
work_pending:
and3 r4, r9, #_TIF_NEED_RESCHED
Expand Down Expand Up @@ -320,7 +310,7 @@ ENTRY(ei_handler)
; GET_ICU_STATUS;
seth r0, #shigh(M32R_ICU_ISTS_ADDR)
ld r0, @(low(M32R_ICU_ISTS_ADDR),r0)
st r0, @-sp
push r0
#if defined(CONFIG_SMP)
/*
* If IRQ == 0 --> Nothing to do, Not write IMASK
Expand Down Expand Up @@ -557,7 +547,7 @@ check_end:
#endif /* CONFIG_PLAT_M32104UT */
bl do_IRQ
#endif /* CONFIG_SMP */
ld r14, @sp+
pop r14
seth r0, #shigh(M32R_ICU_IMASK_ADDR)
st r14, @(low(M32R_ICU_IMASK_ADDR),r0)
#else
Expand Down Expand Up @@ -1015,4 +1005,3 @@ ENTRY(sys_call_table)
.long sys_waitid

syscall_table_size=(.-sys_call_table)

4 changes: 4 additions & 0 deletions trunk/arch/m32r/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,10 @@ void cpu_idle (void)

void machine_restart(char *__unused)
{
#if defined(CONFIG_PLAT_MAPPI3)
outw(1, (unsigned long)PLD_REBOOT);
#endif

printk("Please push reset button!\n");
while (1)
cpu_relax();
Expand Down
4 changes: 4 additions & 0 deletions trunk/arch/m32r/kernel/signal.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@ restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc,
#elif defined(CONFIG_ISA_M32R2) || defined(CONFIG_ISA_M32R)
COPY(acch);
COPY(accl);
COPY(dummy_acc1h);
COPY(dummy_acc1l);
#else
#error unknown isa configuration
#endif
Expand Down Expand Up @@ -203,6 +205,8 @@ setup_sigcontext(struct sigcontext __user *sc, struct pt_regs *regs,
#elif defined(CONFIG_ISA_M32R2) || defined(CONFIG_ISA_M32R)
COPY(acch);
COPY(accl);
COPY(dummy_acc1h);
COPY(dummy_acc1l);
#else
#error unknown isa configuration
#endif
Expand Down
Loading

0 comments on commit ae07693

Please sign in to comment.