Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 140718
b: refs/heads/master
c: b85fa01
h: refs/heads/master
v: v3
  • Loading branch information
Lai Jiangshan authored and Steven Rostedt committed Feb 10, 2009
1 parent f5e5805 commit ffc91a5
Show file tree
Hide file tree
Showing 59 changed files with 1,418 additions and 5,625 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: d524e03207591a6de7e6b5069aabc778e3f0f5f8
refs/heads/master: b85fa01ed958ca59523a2db3c2ee647b98745d6a
2 changes: 1 addition & 1 deletion trunk/arch/frv/mm/dma-alloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@
#include <linux/vmalloc.h>
#include <linux/init.h>
#include <linux/pci.h>
#include <linux/hardirq.h>

#include <asm/pgalloc.h>
#include <asm/io.h>
#include <asm/hardirq.h>
#include <asm/mmu_context.h>
#include <asm/pgtable.h>
#include <asm/mmu.h>
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/mips/include/asm/spinlock.h
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ static inline int __raw_spin_is_contended(raw_spinlock_t *lock)

return (((counters >> 14) - counters) & 0x1fff) > 1;
}
#define __raw_spin_is_contended __raw_spin_is_contended

static inline void __raw_spin_lock(raw_spinlock_t *lock)
{
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/x86/include/asm/paravirt.h
Original file line number Diff line number Diff line change
Expand Up @@ -1402,7 +1402,6 @@ static inline int __raw_spin_is_contended(struct raw_spinlock *lock)
{
return PVOP_CALL1(int, pv_lock_ops.spin_is_contended, lock);
}
#define __raw_spin_is_contended __raw_spin_is_contended

static __always_inline void __raw_spin_lock(struct raw_spinlock *lock)
{
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/x86/include/asm/spinlock.h
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,6 @@ static inline int __raw_spin_is_contended(raw_spinlock_t *lock)
{
return __ticket_spin_is_contended(lock);
}
#define __raw_spin_is_contended __raw_spin_is_contended

static __always_inline void __raw_spin_lock(raw_spinlock_t *lock)
{
Expand Down
28 changes: 6 additions & 22 deletions trunk/arch/x86/kernel/cpu/cpufreq/powernow-k8.c
Original file line number Diff line number Diff line change
Expand Up @@ -939,25 +939,10 @@ static void powernow_k8_cpu_exit_acpi(struct powernow_k8_data *data)
free_cpumask_var(data->acpi_data.shared_cpu_map);
}

static int get_transition_latency(struct powernow_k8_data *data)
{
int max_latency = 0;
int i;
for (i = 0; i < data->acpi_data.state_count; i++) {
int cur_latency = data->acpi_data.states[i].transition_latency
+ data->acpi_data.states[i].bus_master_latency;
if (cur_latency > max_latency)
max_latency = cur_latency;
}
/* value in usecs, needs to be in nanoseconds */
return 1000 * max_latency;
}

#else
static int powernow_k8_cpu_init_acpi(struct powernow_k8_data *data) { return -ENODEV; }
static void powernow_k8_cpu_exit_acpi(struct powernow_k8_data *data) { return; }
static void powernow_k8_acpi_pst_values(struct powernow_k8_data *data, unsigned int index) { return; }
static int get_transition_latency(struct powernow_k8_data *data) { return 0; }
#endif /* CONFIG_X86_POWERNOW_K8_ACPI */

/* Take a frequency, and issue the fid/vid transition command */
Expand Down Expand Up @@ -1188,13 +1173,7 @@ static int __cpuinit powernowk8_cpu_init(struct cpufreq_policy *pol)
if (rc) {
goto err_out;
}
/* Take a crude guess here.
* That guess was in microseconds, so multiply with 1000 */
pol->cpuinfo.transition_latency = (
((data->rvo + 8) * data->vstable * VST_UNITS_20US) +
((1 << data->irt) * 30)) * 1000;
} else /* ACPI _PSS objects available */
pol->cpuinfo.transition_latency = get_transition_latency(data);
}

/* only run on specific CPU from here on */
oldmask = current->cpus_allowed;
Expand Down Expand Up @@ -1225,6 +1204,11 @@ static int __cpuinit powernowk8_cpu_init(struct cpufreq_policy *pol)
cpumask_copy(pol->cpus, &per_cpu(cpu_core_map, pol->cpu));
data->available_cores = pol->cpus;

/* Take a crude guess here.
* That guess was in microseconds, so multiply with 1000 */
pol->cpuinfo.transition_latency = (((data->rvo + 8) * data->vstable * VST_UNITS_20US)
+ (3 * (1 << data->irt) * 10)) * 1000;

if (cpu_family == CPU_HW_PSTATE)
pol->cur = find_khz_freq_from_pstate(data->powernow_table, data->currpstate);
else
Expand Down
8 changes: 3 additions & 5 deletions trunk/arch/x86/kernel/ftrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -471,15 +471,13 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
"1: " _ASM_MOV " (%[parent_old]), %[old]\n"
"2: " _ASM_MOV " %[return_hooker], (%[parent_replaced])\n"
" movl $0, %[faulted]\n"
"3:\n"

".section .fixup, \"ax\"\n"
"4: movl $1, %[faulted]\n"
" jmp 3b\n"
"3: movl $1, %[faulted]\n"
".previous\n"

_ASM_EXTABLE(1b, 4b)
_ASM_EXTABLE(2b, 4b)
_ASM_EXTABLE(1b, 3b)
_ASM_EXTABLE(2b, 3b)

: [parent_replaced] "=r" (parent), [old] "=r" (old),
[faulted] "=r" (faulted)
Expand Down
6 changes: 1 addition & 5 deletions trunk/crypto/algapi.c
Original file line number Diff line number Diff line change
Expand Up @@ -149,9 +149,6 @@ static struct crypto_larval *__crypto_register_alg(struct crypto_alg *alg)
if (q == alg)
goto err;

if (crypto_is_moribund(q))
continue;

if (crypto_is_larval(q)) {
if (!strcmp(alg->cra_driver_name, q->cra_driver_name))
goto err;
Expand Down Expand Up @@ -200,7 +197,7 @@ void crypto_alg_tested(const char *name, int err)

down_write(&crypto_alg_sem);
list_for_each_entry(q, &crypto_alg_list, cra_list) {
if (crypto_is_moribund(q) || !crypto_is_larval(q))
if (!crypto_is_larval(q))
continue;

test = (struct crypto_larval *)q;
Expand All @@ -213,7 +210,6 @@ void crypto_alg_tested(const char *name, int err)
goto unlock;

found:
q->cra_flags |= CRYPTO_ALG_DEAD;
alg = test->adult;
if (err || list_empty(&alg->cra_list))
goto complete;
Expand Down
20 changes: 10 additions & 10 deletions trunk/crypto/api.c
Original file line number Diff line number Diff line change
Expand Up @@ -557,34 +557,34 @@ struct crypto_tfm *crypto_alloc_tfm(const char *alg_name,
return ERR_PTR(err);
}
EXPORT_SYMBOL_GPL(crypto_alloc_tfm);

/*
* crypto_destroy_tfm - Free crypto transform
* @mem: Start of tfm slab
* crypto_free_tfm - Free crypto transform
* @tfm: Transform to free
*
* This function frees up the transform and any associated resources,
* crypto_free_tfm() frees up the transform and any associated resources,
* then drops the refcount on the associated algorithm.
*/
void crypto_destroy_tfm(void *mem, struct crypto_tfm *tfm)
void crypto_free_tfm(struct crypto_tfm *tfm)
{
struct crypto_alg *alg;
int size;

if (unlikely(!mem))
if (unlikely(!tfm))
return;

alg = tfm->__crt_alg;
size = ksize(mem);
size = sizeof(*tfm) + alg->cra_ctxsize;

if (!tfm->exit && alg->cra_exit)
alg->cra_exit(tfm);
crypto_exit_ops(tfm);
crypto_mod_put(alg);
memset(mem, 0, size);
kfree(mem);
memset(tfm, 0, size);
kfree(tfm);
}
EXPORT_SYMBOL_GPL(crypto_destroy_tfm);

EXPORT_SYMBOL_GPL(crypto_free_tfm);

int crypto_has_alg(const char *name, u32 type, u32 mask)
{
Expand Down
3 changes: 1 addition & 2 deletions trunk/crypto/scatterwalk.c
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,7 @@ static void scatterwalk_pagedone(struct scatter_walk *walk, int out,
struct page *page;

page = sg_page(walk->sg) + ((walk->offset - 1) >> PAGE_SHIFT);
if (!PageSlab(page))
flush_dcache_page(page);
flush_dcache_page(page);
}

if (more) {
Expand Down
7 changes: 1 addition & 6 deletions trunk/crypto/shash.c
Original file line number Diff line number Diff line change
Expand Up @@ -388,15 +388,10 @@ static int crypto_init_shash_ops_compat(struct crypto_tfm *tfm)
struct shash_desc *desc = crypto_tfm_ctx(tfm);
struct crypto_shash *shash;

if (!crypto_mod_get(calg))
return -EAGAIN;

shash = __crypto_shash_cast(crypto_create_tfm(
calg, &crypto_shash_type));
if (IS_ERR(shash)) {
crypto_mod_put(calg);
if (IS_ERR(shash))
return PTR_ERR(shash);
}

desc->tfm = shash;
tfm->exit = crypto_exit_shash_ops_compat;
Expand Down
47 changes: 22 additions & 25 deletions trunk/drivers/cpufreq/cpufreq_ondemand.c
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,11 @@ static inline cputime64_t get_cpu_idle_time_jiffy(unsigned int cpu,
busy_time = cputime64_add(busy_time, kstat_cpu(cpu).cpustat.irq);
busy_time = cputime64_add(busy_time, kstat_cpu(cpu).cpustat.softirq);
busy_time = cputime64_add(busy_time, kstat_cpu(cpu).cpustat.steal);
busy_time = cputime64_add(busy_time, kstat_cpu(cpu).cpustat.nice);

if (!dbs_tuners_ins.ignore_nice) {
busy_time = cputime64_add(busy_time,
kstat_cpu(cpu).cpustat.nice);
}

idle_time = cputime64_sub(cur_wall_time, busy_time);
if (wall)
Expand All @@ -133,6 +137,23 @@ static inline cputime64_t get_cpu_idle_time(unsigned int cpu, cputime64_t *wall)
if (idle_time == -1ULL)
return get_cpu_idle_time_jiffy(cpu, wall);

if (dbs_tuners_ins.ignore_nice) {
cputime64_t cur_nice;
unsigned long cur_nice_jiffies;
struct cpu_dbs_info_s *dbs_info;

dbs_info = &per_cpu(cpu_dbs_info, cpu);
cur_nice = cputime64_sub(kstat_cpu(cpu).cpustat.nice,
dbs_info->prev_cpu_nice);
/*
* Assumption: nice time between sampling periods will be
* less than 2^32 jiffies for 32 bit sys
*/
cur_nice_jiffies = (unsigned long)
cputime64_to_jiffies64(cur_nice);
dbs_info->prev_cpu_nice = kstat_cpu(cpu).cpustat.nice;
return idle_time + jiffies_to_usecs(cur_nice_jiffies);
}
return idle_time;
}

Expand Down Expand Up @@ -298,9 +319,6 @@ static ssize_t store_ignore_nice_load(struct cpufreq_policy *policy,
dbs_info = &per_cpu(cpu_dbs_info, j);
dbs_info->prev_cpu_idle = get_cpu_idle_time(j,
&dbs_info->prev_cpu_wall);
if (dbs_tuners_ins.ignore_nice)
dbs_info->prev_cpu_nice = kstat_cpu(j).cpustat.nice;

}
mutex_unlock(&dbs_mutex);

Expand Down Expand Up @@ -401,23 +419,6 @@ static void dbs_check_cpu(struct cpu_dbs_info_s *this_dbs_info)
j_dbs_info->prev_cpu_idle);
j_dbs_info->prev_cpu_idle = cur_idle_time;

if (dbs_tuners_ins.ignore_nice) {
cputime64_t cur_nice;
unsigned long cur_nice_jiffies;

cur_nice = cputime64_sub(kstat_cpu(j).cpustat.nice,
j_dbs_info->prev_cpu_nice);
/*
* Assumption: nice time between sampling periods will
* be less than 2^32 jiffies for 32 bit sys
*/
cur_nice_jiffies = (unsigned long)
cputime64_to_jiffies64(cur_nice);

j_dbs_info->prev_cpu_nice = kstat_cpu(j).cpustat.nice;
idle_time += jiffies_to_usecs(cur_nice_jiffies);
}

if (unlikely(!wall_time || wall_time < idle_time))
continue;

Expand Down Expand Up @@ -574,10 +575,6 @@ static int cpufreq_governor_dbs(struct cpufreq_policy *policy,

j_dbs_info->prev_cpu_idle = get_cpu_idle_time(j,
&j_dbs_info->prev_cpu_wall);
if (dbs_tuners_ins.ignore_nice) {
j_dbs_info->prev_cpu_nice =
kstat_cpu(j).cpustat.nice;
}
}
this_dbs_info->cpu = cpu;
/*
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/gpu/drm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ config DRM_I915
select FB_CFB_FILLRECT
select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT
select FB
depends on FB
tristate "i915 driver"
help
Choose this option if you have a system that has Intel 830M, 845G,
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/gpu/drm/drm_irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,6 @@ int drm_irq_uninstall(struct drm_device * dev)
for (i = 0; i < dev->num_crtcs; i++) {
DRM_WAKEUP(&dev->vbl_queue[i]);
dev->vblank_enabled[i] = 0;
dev->last_vblank[i] = dev->driver->get_vblank_counter(dev, i);
}
spin_unlock_irqrestore(&dev->vbl_lock, irqflags);

Expand Down
7 changes: 1 addition & 6 deletions trunk/drivers/gpu/drm/drm_memory.c
Original file line number Diff line number Diff line change
Expand Up @@ -171,14 +171,9 @@ EXPORT_SYMBOL(drm_core_ioremap);

void drm_core_ioremap_wc(struct drm_map *map, struct drm_device *dev)
{
if (drm_core_has_AGP(dev) &&
dev->agp && dev->agp->cant_use_aperture && map->type == _DRM_AGP)
map->handle = agp_remap(map->offset, map->size, dev);
else
map->handle = ioremap_wc(map->offset, map->size);
map->handle = ioremap_wc(map->offset, map->size);
}
EXPORT_SYMBOL(drm_core_ioremap_wc);

void drm_core_ioremapfree(struct drm_map *map, struct drm_device *dev)
{
if (!map->handle || !map->size)
Expand Down
Loading

0 comments on commit ffc91a5

Please sign in to comment.