Skip to content

Commit

Permalink
Merge branch 'linus' into perf/core
Browse files Browse the repository at this point in the history
Merge reason: pick up fixes that are upstream, we need them
              because we'll apply dependent patches.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Ingo Molnar committed Jan 27, 2012
2 parents 939ddcf + 74ea15d commit 801493c
Show file tree
Hide file tree
Showing 28 changed files with 145 additions and 114 deletions.
8 changes: 4 additions & 4 deletions arch/m68k/atari/config.c
Original file line number Diff line number Diff line change
Expand Up @@ -414,9 +414,9 @@ void __init config_atari(void)
* FDC val = 4 -> Supervisor only */
asm volatile ("\n"
" .chip 68030\n"
" pmove %0@,%/tt1\n"
" pmove %0,%/tt1\n"
" .chip 68k"
: : "a" (&tt1_val));
: : "m" (tt1_val));
} else {
asm volatile ("\n"
" .chip 68040\n"
Expand Down Expand Up @@ -569,10 +569,10 @@ static void atari_reset(void)
: "d0");
} else
asm volatile ("\n"
" pmove %0@,%%tc\n"
" pmove %0,%%tc\n"
" jmp %1@"
: /* no outputs */
: "a" (&tc_val), "a" (reset_addr));
: "m" (tc_val), "a" (reset_addr));
}


Expand Down
13 changes: 0 additions & 13 deletions arch/m68k/include/asm/irq.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,19 +50,6 @@

#define IRQ_USER 8

/*
* various flags for request_irq() - the Amiga now uses the standard
* mechanism like all other architectures - IRQF_DISABLED and
* IRQF_SHARED are your friends.
*/
#ifndef MACH_AMIGA_ONLY
#define IRQ_FLG_LOCK (0x0001) /* handler is not replaceable */
#define IRQ_FLG_REPLACE (0x0002) /* replace existing handler */
#define IRQ_FLG_FAST (0x0004)
#define IRQ_FLG_SLOW (0x0008)
#define IRQ_FLG_STD (0x8000) /* internally used */
#endif

struct irq_data;
struct irq_chip;
struct irq_desc;
Expand Down
2 changes: 1 addition & 1 deletion arch/m68k/kernel/process_mm.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ void flush_thread(void)

current->thread.fs = __USER_DS;
if (!FPU_IS_EMU)
asm volatile ("frestore %0@" : : "a" (&zero) : "memory");
asm volatile("frestore %0": :"m" (zero));
}

/*
Expand Down
4 changes: 2 additions & 2 deletions arch/m68k/kernel/process_no.c
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,8 @@ void flush_thread(void)
#ifdef CONFIG_FPU
if (!FPU_IS_EMU)
asm volatile (".chip 68k/68881\n\t"
"frestore %0@\n\t"
".chip 68k" : : "a" (&zero));
"frestore %0\n\t"
".chip 68k" : : "m" (zero));
#endif
}

Expand Down
36 changes: 17 additions & 19 deletions arch/m68k/kernel/traps.c
Original file line number Diff line number Diff line change
Expand Up @@ -552,13 +552,13 @@ static inline void bus_error030 (struct frame *fp)

#ifdef DEBUG
asm volatile ("ptestr %3,%2@,#7,%0\n\t"
"pmove %%psr,%1@"
: "=a&" (desc)
: "a" (&temp), "a" (addr), "d" (ssw));
"pmove %%psr,%1"
: "=a&" (desc), "=m" (temp)
: "a" (addr), "d" (ssw));
#else
asm volatile ("ptestr %2,%1@,#7\n\t"
"pmove %%psr,%0@"
: : "a" (&temp), "a" (addr), "d" (ssw));
"pmove %%psr,%0"
: "=m" (temp) : "a" (addr), "d" (ssw));
#endif
mmusr = temp;

Expand Down Expand Up @@ -605,20 +605,18 @@ static inline void bus_error030 (struct frame *fp)
!(ssw & RW) ? "write" : "read", addr,
fp->ptregs.pc, ssw);
asm volatile ("ptestr #1,%1@,#0\n\t"
"pmove %%psr,%0@"
: /* no outputs */
: "a" (&temp), "a" (addr));
"pmove %%psr,%0"
: "=m" (temp)
: "a" (addr));
mmusr = temp;

printk ("level 0 mmusr is %#x\n", mmusr);
#if 0
asm volatile ("pmove %%tt0,%0@"
: /* no outputs */
: "a" (&tlong));
asm volatile ("pmove %%tt0,%0"
: "=m" (tlong));
printk("tt0 is %#lx, ", tlong);
asm volatile ("pmove %%tt1,%0@"
: /* no outputs */
: "a" (&tlong));
asm volatile ("pmove %%tt1,%0"
: "=m" (tlong));
printk("tt1 is %#lx\n", tlong);
#endif
#ifdef DEBUG
Expand Down Expand Up @@ -668,13 +666,13 @@ static inline void bus_error030 (struct frame *fp)

#ifdef DEBUG
asm volatile ("ptestr #1,%2@,#7,%0\n\t"
"pmove %%psr,%1@"
: "=a&" (desc)
: "a" (&temp), "a" (addr));
"pmove %%psr,%1"
: "=a&" (desc), "=m" (temp)
: "a" (addr));
#else
asm volatile ("ptestr #1,%1@,#7\n\t"
"pmove %%psr,%0@"
: : "a" (&temp), "a" (addr));
"pmove %%psr,%0"
: "=m" (temp) : "a" (addr));
#endif
mmusr = temp;

Expand Down
6 changes: 3 additions & 3 deletions arch/m68k/mm/cache.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@ static unsigned long virt_to_phys_slow(unsigned long vaddr)
unsigned long *descaddr;

asm volatile ("ptestr %3,%2@,#7,%0\n\t"
"pmove %%psr,%1@"
: "=a&" (descaddr)
: "a" (&mmusr), "a" (vaddr), "d" (get_fs().seg));
"pmove %%psr,%1"
: "=a&" (descaddr), "=m" (mmusr)
: "a" (vaddr), "d" (get_fs().seg));
if (mmusr & (MMU_I|MMU_B|MMU_L))
return 0;
descaddr = phys_to_virt((unsigned long)descaddr);
Expand Down
3 changes: 3 additions & 0 deletions arch/sparc/kernel/sun4m_irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,9 @@ static void __init sun4m_init_timers(irq_handler_t counter_fn)
timers_global = (void __iomem *)
(unsigned long) addr[num_cpu_timers];

/* Every per-cpu timer works in timer mode */
sbus_writel(0x00000000, &timers_global->timer_config);

sbus_writel((((1000000/HZ) + 1) << 10), &timers_global->l10_limit);

master_l10_counter = &timers_global->l10_count;
Expand Down
1 change: 0 additions & 1 deletion arch/x86/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,6 @@ config X86_NUMACHIP
depends on NUMA
depends on SMP
depends on X86_X2APIC
depends on !EDAC_AMD64
---help---
Adds support for Numascale NumaChip large-SMP systems. Needed to
enable more than ~168 cores.
Expand Down
2 changes: 2 additions & 0 deletions arch/x86/boot/compressed/misc.c
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,8 @@ static void parse_elf(void *output)
default: /* Ignore other PT_* */ break;
}
}

free(phdrs);
}

asmlinkage void decompress_kernel(void *rmode, memptr heap,
Expand Down
1 change: 1 addition & 0 deletions arch/x86/include/asm/cpufeature.h
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@
#define X86_FEATURE_WDT (6*32+13) /* Watchdog timer */
#define X86_FEATURE_LWP (6*32+15) /* Light Weight Profiling */
#define X86_FEATURE_FMA4 (6*32+16) /* 4 operands MAC instructions */
#define X86_FEATURE_TCE (6*32+17) /* translation cache extension */
#define X86_FEATURE_NODEID_MSR (6*32+19) /* NodeId MSR */
#define X86_FEATURE_TBM (6*32+21) /* trailing bit manipulations */
#define X86_FEATURE_TOPOEXT (6*32+22) /* topology extensions CPUID leafs */
Expand Down
4 changes: 2 additions & 2 deletions arch/x86/include/asm/uv/uv_hub.h
Original file line number Diff line number Diff line change
Expand Up @@ -318,13 +318,13 @@ uv_gpa_in_mmr_space(unsigned long gpa)
/* UV global physical address --> socket phys RAM */
static inline unsigned long uv_gpa_to_soc_phys_ram(unsigned long gpa)
{
unsigned long paddr = gpa & uv_hub_info->gpa_mask;
unsigned long paddr;
unsigned long remap_base = uv_hub_info->lowmem_remap_base;
unsigned long remap_top = uv_hub_info->lowmem_remap_top;

gpa = ((gpa << uv_hub_info->m_shift) >> uv_hub_info->m_shift) |
((gpa >> uv_hub_info->n_lshift) << uv_hub_info->m_val);
gpa = gpa & uv_hub_info->gpa_mask;
paddr = gpa & uv_hub_info->gpa_mask;
if (paddr >= remap_base && paddr < remap_base + remap_top)
paddr -= remap_base;
return paddr;
Expand Down
24 changes: 22 additions & 2 deletions arch/x86/kernel/microcode_amd.c
Original file line number Diff line number Diff line change
Expand Up @@ -311,13 +311,33 @@ generic_load_microcode(int cpu, const u8 *data, size_t size)
return state;
}

/*
* AMD microcode firmware naming convention, up to family 15h they are in
* the legacy file:
*
* amd-ucode/microcode_amd.bin
*
* This legacy file is always smaller than 2K in size.
*
* Starting at family 15h they are in family specific firmware files:
*
* amd-ucode/microcode_amd_fam15h.bin
* amd-ucode/microcode_amd_fam16h.bin
* ...
*
* These might be larger than 2K.
*/
static enum ucode_state request_microcode_amd(int cpu, struct device *device)
{
const char *fw_name = "amd-ucode/microcode_amd.bin";
char fw_name[36] = "amd-ucode/microcode_amd.bin";
const struct firmware *fw;
enum ucode_state ret = UCODE_NFOUND;
struct cpuinfo_x86 *c = &cpu_data(cpu);

if (c->x86 >= 0x15)
snprintf(fw_name, sizeof(fw_name), "amd-ucode/microcode_amd_fam%.2xh.bin", c->x86);

if (request_firmware(&fw, fw_name, device)) {
if (request_firmware(&fw, (const char *)fw_name, device)) {
pr_err("failed to load file %s\n", fw_name);
goto out;
}
Expand Down
2 changes: 2 additions & 0 deletions arch/x86/platform/uv/tlb_uv.c
Original file line number Diff line number Diff line change
Expand Up @@ -1851,6 +1851,8 @@ static void __init init_per_cpu_tunables(void)
bcp->cong_reps = congested_reps;
bcp->cong_period = congested_period;
bcp->clocks_per_100_usec = usec_2_cycles(100);
spin_lock_init(&bcp->queue_lock);
spin_lock_init(&bcp->uvhub_lock);
}
}

Expand Down
2 changes: 1 addition & 1 deletion arch/x86/platform/uv/uv_irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ struct uv_irq_2_mmr_pnode{
int irq;
};

static spinlock_t uv_irq_lock;
static DEFINE_SPINLOCK(uv_irq_lock);
static struct rb_root uv_irq_root;

static int uv_set_irq_affinity(struct irq_data *, const struct cpumask *, bool);
Expand Down
11 changes: 9 additions & 2 deletions drivers/media/dvb/dvb-usb/anysee.c
Original file line number Diff line number Diff line change
Expand Up @@ -887,8 +887,7 @@ static int anysee_frontend_attach(struct dvb_usb_adapter *adap)

/* attach demod */
adap->fe_adap[state->fe_id].fe = dvb_attach(cxd2820r_attach,
&anysee_cxd2820r_config, &adap->dev->i2c_adap,
NULL);
&anysee_cxd2820r_config, &adap->dev->i2c_adap);

state->has_ci = true;

Expand Down Expand Up @@ -1189,6 +1188,14 @@ static int anysee_ci_init(struct dvb_usb_device *d)
if (ret)
return ret;

ret = anysee_wr_reg_mask(d, REG_IOD, (0 << 2)|(0 << 1)|(0 << 0), 0x07);
if (ret)
return ret;

ret = anysee_wr_reg_mask(d, REG_IOD, (1 << 2)|(1 << 1)|(1 << 0), 0x07);
if (ret)
return ret;

ret = dvb_ca_en50221_init(&d->adapter[0].dvb_adap, &state->ci, 0, 1);
if (ret)
return ret;
Expand Down
7 changes: 4 additions & 3 deletions drivers/media/dvb/dvb-usb/cinergyT2-fe.c
Original file line number Diff line number Diff line change
Expand Up @@ -276,14 +276,15 @@ static int cinergyt2_fe_set_frontend(struct dvb_frontend *fe)
param.flags = 0;

switch (fep->bandwidth_hz) {
default:
case 8000000:
param.bandwidth = 0;
param.bandwidth = 8;
break;
case 7000000:
param.bandwidth = 1;
param.bandwidth = 7;
break;
case 6000000:
param.bandwidth = 2;
param.bandwidth = 6;
break;
}

Expand Down
6 changes: 2 additions & 4 deletions drivers/media/dvb/frontends/cxd2820r.h
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,12 @@ struct cxd2820r_config {
(defined(CONFIG_DVB_CXD2820R_MODULE) && defined(MODULE))
extern struct dvb_frontend *cxd2820r_attach(
const struct cxd2820r_config *config,
struct i2c_adapter *i2c,
struct dvb_frontend *fe
struct i2c_adapter *i2c
);
#else
static inline struct dvb_frontend *cxd2820r_attach(
const struct cxd2820r_config *config,
struct i2c_adapter *i2c,
struct dvb_frontend *fe
struct i2c_adapter *i2c
)
{
printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
Expand Down
20 changes: 15 additions & 5 deletions drivers/media/dvb/frontends/cxd2820r_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -482,10 +482,19 @@ static enum dvbfe_search cxd2820r_search(struct dvb_frontend *fe)

/* switch between DVB-T and DVB-T2 when tune fails */
if (priv->last_tune_failed) {
if (priv->delivery_system == SYS_DVBT)
if (priv->delivery_system == SYS_DVBT) {
ret = cxd2820r_sleep_t(fe);
if (ret)
goto error;

c->delivery_system = SYS_DVBT2;
else if (priv->delivery_system == SYS_DVBT2)
} else if (priv->delivery_system == SYS_DVBT2) {
ret = cxd2820r_sleep_t2(fe);
if (ret)
goto error;

c->delivery_system = SYS_DVBT;
}
}

/* set frontend */
Expand Down Expand Up @@ -562,7 +571,7 @@ static const struct dvb_frontend_ops cxd2820r_ops = {
.delsys = { SYS_DVBT, SYS_DVBT2, SYS_DVBC_ANNEX_A },
/* default: DVB-T/T2 */
.info = {
.name = "Sony CXD2820R (DVB-T/T2)",
.name = "Sony CXD2820R",

.caps = FE_CAN_FEC_1_2 |
FE_CAN_FEC_2_3 |
Expand All @@ -572,7 +581,9 @@ static const struct dvb_frontend_ops cxd2820r_ops = {
FE_CAN_FEC_AUTO |
FE_CAN_QPSK |
FE_CAN_QAM_16 |
FE_CAN_QAM_32 |
FE_CAN_QAM_64 |
FE_CAN_QAM_128 |
FE_CAN_QAM_256 |
FE_CAN_QAM_AUTO |
FE_CAN_TRANSMISSION_MODE_AUTO |
Expand Down Expand Up @@ -602,8 +613,7 @@ static const struct dvb_frontend_ops cxd2820r_ops = {
};

struct dvb_frontend *cxd2820r_attach(const struct cxd2820r_config *cfg,
struct i2c_adapter *i2c,
struct dvb_frontend *fe)
struct i2c_adapter *i2c)
{
struct cxd2820r_priv *priv = NULL;
int ret;
Expand Down
Loading

0 comments on commit 801493c

Please sign in to comment.