Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 74309
b: refs/heads/master
c: cae2f9c
h: refs/heads/master
i:
  74307: 617d7fa
v: v3
  • Loading branch information
Linus Torvalds committed Nov 28, 2007
1 parent 35274b3 commit 5d9603a
Show file tree
Hide file tree
Showing 9 changed files with 24 additions and 12 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: 8118a859dc7abd873193986c77a8d9bdb877adc8
refs/heads/master: cae2f9c46d69edb1aee565917735d79aba3a3267
6 changes: 6 additions & 0 deletions trunk/fs/exec.c
Original file line number Diff line number Diff line change
Expand Up @@ -1780,6 +1780,12 @@ int do_coredump(long signr, int exit_code, struct pt_regs * regs)
but keep the previous behaviour for now. */
if (!ispipe && !S_ISREG(inode->i_mode))
goto close_fail;
/*
* Dont allow local users get cute and trick others to coredump
* into their pre-created files:
*/
if (inode->i_uid != current->fsuid)
goto close_fail;
if (!file->f_op)
goto close_fail;
if (!file->f_op->write)
Expand Down
4 changes: 4 additions & 0 deletions trunk/include/linux/sched.h
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,10 @@ static inline void touch_all_softlockup_watchdogs(void)

/* Attach to any functions which should be ignored in wchan output. */
#define __sched __attribute__((__section__(".sched.text")))

/* Linker adds these: start and end of __sched functions */
extern char __sched_text_start[], __sched_text_end[];

/* Is this address in the __sched functions? */
extern int in_sched_functions(unsigned long addr);

Expand Down
5 changes: 1 addition & 4 deletions trunk/kernel/sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -5466,7 +5466,7 @@ sd_alloc_ctl_domain_table(struct sched_domain *sd)
return table;
}

static ctl_table * sd_alloc_ctl_cpu_table(int cpu)
static ctl_table *sd_alloc_ctl_cpu_table(int cpu)
{
struct ctl_table *entry, *table;
struct sched_domain *sd;
Expand Down Expand Up @@ -6708,9 +6708,6 @@ void __init sched_init_smp(void)

int in_sched_functions(unsigned long addr)
{
/* Linker adds these: start and end of __sched functions */
extern char __sched_text_start[], __sched_text_end[];

return in_lock_functions(addr) ||
(addr >= (unsigned long)__sched_text_start
&& addr < (unsigned long)__sched_text_end);
Expand Down
8 changes: 5 additions & 3 deletions trunk/kernel/sched_debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -327,10 +327,12 @@ void proc_sched_show_task(struct task_struct *p, struct seq_file *m)
avg_atom = -1LL;

avg_per_cpu = p->se.sum_exec_runtime;
if (p->se.nr_migrations)
avg_per_cpu = div64_64(avg_per_cpu, p->se.nr_migrations);
else
if (p->se.nr_migrations) {
avg_per_cpu = div64_64(avg_per_cpu,
p->se.nr_migrations);
} else {
avg_per_cpu = -1LL;
}

__PN(avg_atom);
__PN(avg_per_cpu);
Expand Down
3 changes: 2 additions & 1 deletion trunk/kernel/sched_stats.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ static int show_schedstat(struct seq_file *seq, void *v)
sd->lb_nobusyq[itype],
sd->lb_nobusyg[itype]);
}
seq_printf(seq, " %u %u %u %u %u %u %u %u %u %u %u %u\n",
seq_printf(seq,
" %u %u %u %u %u %u %u %u %u %u %u %u\n",
sd->alb_count, sd->alb_failed, sd->alb_pushed,
sd->sbe_count, sd->sbe_balanced, sd->sbe_pushed,
sd->sbf_count, sd->sbf_balanced, sd->sbf_pushed,
Expand Down
2 changes: 2 additions & 0 deletions trunk/kernel/time/tick-sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,8 @@ void tick_nohz_update_jiffies(void)
if (!ts->tick_stopped)
return;

touch_softlockup_watchdog();

cpu_clear(cpu, nohz_cpu_mask);
now = ktime_get();

Expand Down
1 change: 0 additions & 1 deletion trunk/mm/page_alloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,6 @@ static inline void prep_zero_page(struct page *page, int order, gfp_t gfp_flags)
{
int i;

VM_BUG_ON((gfp_flags & (__GFP_WAIT | __GFP_HIGHMEM)) == __GFP_HIGHMEM);
/*
* clear_highpage() will use KM_USER0, so it's a bug to use __GFP_ZERO
* and __GFP_HIGHMEM from hard or soft interrupt context.
Expand Down
5 changes: 3 additions & 2 deletions trunk/mm/shmem.c
Original file line number Diff line number Diff line change
Expand Up @@ -1072,7 +1072,7 @@ shmem_alloc_page(gfp_t gfp, struct shmem_inode_info *info,
pvma.vm_policy = mpol_shared_policy_lookup(&info->policy, idx);
pvma.vm_pgoff = idx;
pvma.vm_end = PAGE_SIZE;
page = alloc_page_vma(gfp | __GFP_ZERO, &pvma, 0);
page = alloc_page_vma(gfp, &pvma, 0);
mpol_free(pvma.vm_policy);
return page;
}
Expand All @@ -1093,7 +1093,7 @@ shmem_swapin(struct shmem_inode_info *info,swp_entry_t entry,unsigned long idx)
static inline struct page *
shmem_alloc_page(gfp_t gfp,struct shmem_inode_info *info, unsigned long idx)
{
return alloc_page(gfp | __GFP_ZERO);
return alloc_page(gfp);
}
#endif

Expand Down Expand Up @@ -1306,6 +1306,7 @@ static int shmem_getpage(struct inode *inode, unsigned long idx,

info->alloced++;
spin_unlock(&info->lock);
clear_highpage(filepage);
flush_dcache_page(filepage);
SetPageUptodate(filepage);
}
Expand Down

0 comments on commit 5d9603a

Please sign in to comment.