Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 98015
b: refs/heads/master
c: 6460a26
h: refs/heads/master
i:
  98013: 5637e6d
  98011: 798e422
  98007: 8097ce5
  97999: f753fde
  97983: db5a2bc
v: v3
  • Loading branch information
Ingo Molnar authored and Greg Kroah-Hartman committed Jun 12, 2008
1 parent ac164ce commit d5a0bb7
Show file tree
Hide file tree
Showing 111 changed files with 942 additions and 1,081 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: aaef4d6c2ee64d5e4d59b7c4d23c37ce59115211
refs/heads/master: 6460a261b5893e769a314c246faec31bbc4aad9c
2 changes: 1 addition & 1 deletion trunk/Documentation/kobject.txt
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ should not be manipulated by any other user.

A kset keeps its children in a standard kernel linked list. Kobjects point
back to their containing kset via their kset field. In almost all cases,
the kobjects belonging to a kset have that kset (or, strictly, its embedded
the kobjects belonging to a ket have that kset (or, strictly, its embedded
kobject) in their parent.

As a kset contains a kobject within it, it should always be dynamically
Expand Down
2 changes: 1 addition & 1 deletion trunk/Documentation/laptops/thinkpad-acpi.txt
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ generate input device EV_KEY events.
In addition to the EV_KEY events, thinkpad-acpi may also issue EV_SW
events for switches:

SW_RFKILL_ALL T60 and later hardare rfkill rocker switch
SW_RADIO T60 and later hardare rfkill rocker switch
SW_TABLET_MODE Tablet ThinkPads HKEY events 0x5009 and 0x500A

Non hot-key ACPI HKEY event map:
Expand Down
10 changes: 5 additions & 5 deletions trunk/MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -228,21 +228,21 @@ ACPI BATTERY DRIVERS
P: Alexey Starikovskiy
M: astarikovskiy@suse.de
L: linux-acpi@vger.kernel.org
W: http://www.lesswatts.org/projects/acpi/
W: http://acpi.sourceforge.net/
S: Supported

ACPI EC DRIVER
P: Alexey Starikovskiy
M: astarikovskiy@suse.de
L: linux-acpi@vger.kernel.org
W: http://www.lesswatts.org/projects/acpi/
W: http://acpi.sourceforge.net/
S: Supported

ACPI FAN DRIVER
P: Len Brown
M: len.brown@intel.com
L: linux-acpi@vger.kernel.org
W: http://www.lesswatts.org/projects/acpi/
W: http://acpi.sourceforge.net/
S: Supported

ACPI PCI HOTPLUG DRIVER
Expand All @@ -255,14 +255,14 @@ ACPI THERMAL DRIVER
P: Len Brown
M: len.brown@intel.com
L: linux-acpi@vger.kernel.org
W: http://www.lesswatts.org/projects/acpi/
W: http://acpi.sourceforge.net/
S: Supported

ACPI VIDEO DRIVER
P: Rui Zhang
M: rui.zhang@intel.com
L: linux-acpi@vger.kernel.org
W: http://www.lesswatts.org/projects/acpi/
W: http://acpi.sourceforge.net/
S: Supported

ACPI WMI DRIVER
Expand Down
9 changes: 2 additions & 7 deletions trunk/arch/ia64/kernel/acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,7 @@ void __init acpi_numa_slit_init(struct acpi_table_slit *slit)
printk(KERN_ERR
"ACPI 2.0 SLIT: size mismatch: %d expected, %d actual\n",
len, slit->header.length);
memset(numa_slit, 10, sizeof(numa_slit));
return;
}
slit_table = slit;
Expand Down Expand Up @@ -573,14 +574,8 @@ void __init acpi_numa_arch_fixup(void)
printk(KERN_INFO "Number of memory chunks in system = %d\n",
num_node_memblks);

if (!slit_table) {
for (i = 0; i < MAX_NUMNODES; i++)
for (j = 0; j < MAX_NUMNODES; j++)
node_distance(i, j) = i == j ? LOCAL_DISTANCE :
REMOTE_DISTANCE;
if (!slit_table)
return;
}

memset(numa_slit, -1, sizeof(numa_slit));
for (i = 0; i < slit_table->locality_count; i++) {
if (!pxm_bit_test(i))
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/ia64/kvm/mmio.c
Original file line number Diff line number Diff line change
Expand Up @@ -159,8 +159,7 @@ static void mmio_access(struct kvm_vcpu *vcpu, u64 src_pa, u64 *dest,

if (p->u.ioreq.state == STATE_IORESP_READY) {
if (dir == IOREQ_READ)
/* it's necessary to ensure zero extending */
*dest = p->u.ioreq.data & (~0UL >> (64-(s*8)));
*dest = p->u.ioreq.data;
} else
panic_vm(vcpu);
out:
Expand Down
9 changes: 5 additions & 4 deletions trunk/arch/powerpc/kvm/44x_tlb.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ static void kvmppc_44x_shadow_release(struct kvm_vcpu *vcpu,
struct tlbe *stlbe = &vcpu->arch.shadow_tlb[index];
struct page *page = vcpu->arch.shadow_pages[index];

kunmap(vcpu->arch.shadow_pages[index]);

if (get_tlb_v(stlbe)) {
if (kvmppc_44x_tlbe_is_writable(stlbe))
kvm_release_page_dirty(page);
Expand All @@ -142,19 +144,18 @@ void kvmppc_mmu_map(struct kvm_vcpu *vcpu, u64 gvaddr, gfn_t gfn, u64 asid,
stlbe = &vcpu->arch.shadow_tlb[victim];

/* Get reference to new page. */
down_read(&current->mm->mmap_sem);
down_write(&current->mm->mmap_sem);
new_page = gfn_to_page(vcpu->kvm, gfn);
if (is_error_page(new_page)) {
printk(KERN_ERR "Couldn't get guest page for gfn %lx!\n", gfn);
printk(KERN_ERR "Couldn't get guest page!\n");
kvm_release_page_clean(new_page);
up_read(&current->mm->mmap_sem);
return;
}
hpaddr = page_to_phys(new_page);

/* Drop reference to old page. */
kvmppc_44x_shadow_release(vcpu, victim);
up_read(&current->mm->mmap_sem);
up_write(&current->mm->mmap_sem);

vcpu->arch.shadow_pages[victim] = new_page;

Expand Down
33 changes: 33 additions & 0 deletions trunk/arch/powerpc/kvm/booke_guest.c
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,39 @@ void kvmppc_check_and_deliver_interrupts(struct kvm_vcpu *vcpu)
}
}

static int kvmppc_emulate_mmio(struct kvm_run *run, struct kvm_vcpu *vcpu)
{
enum emulation_result er;
int r;

er = kvmppc_emulate_instruction(run, vcpu);
switch (er) {
case EMULATE_DONE:
/* Future optimization: only reload non-volatiles if they were
* actually modified. */
r = RESUME_GUEST_NV;
break;
case EMULATE_DO_MMIO:
run->exit_reason = KVM_EXIT_MMIO;
/* We must reload nonvolatiles because "update" load/store
* instructions modify register state. */
/* Future optimization: only reload non-volatiles if they were
* actually modified. */
r = RESUME_HOST_NV;
break;
case EMULATE_FAIL:
/* XXX Deliver Program interrupt to guest. */
printk(KERN_EMERG "%s: emulation failed (%08x)\n", __func__,
vcpu->arch.last_inst);
r = RESUME_HOST;
break;
default:
BUG();
}

return r;
}

/**
* kvmppc_handle_exit
*
Expand Down
12 changes: 0 additions & 12 deletions trunk/arch/powerpc/kvm/emulate.c
Original file line number Diff line number Diff line change
Expand Up @@ -246,11 +246,6 @@ int kvmppc_emulate_instruction(struct kvm_run *run, struct kvm_vcpu *vcpu)
case 31:
switch (get_xop(inst)) {

case 23: /* lwzx */
rt = get_rt(inst);
emulated = kvmppc_handle_load(run, vcpu, rt, 4, 1);
break;

case 83: /* mfmsr */
rt = get_rt(inst);
vcpu->arch.gpr[rt] = vcpu->arch.msr;
Expand All @@ -272,13 +267,6 @@ int kvmppc_emulate_instruction(struct kvm_run *run, struct kvm_vcpu *vcpu)
kvmppc_set_msr(vcpu, vcpu->arch.gpr[rs]);
break;

case 151: /* stwx */
rs = get_rs(inst);
emulated = kvmppc_handle_store(run, vcpu,
vcpu->arch.gpr[rs],
4, 1);
break;

case 163: /* wrteei */
vcpu->arch.msr = (vcpu->arch.msr & ~MSR_EE)
| (inst & MSR_EE);
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/s390/kvm/diag.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ static int __diag_time_slice_end(struct kvm_vcpu *vcpu)
VCPU_EVENT(vcpu, 5, "%s", "diag time slice end");
vcpu->stat.diagnose_44++;
vcpu_put(vcpu);
yield();
schedule();
vcpu_load(vcpu);
return 0;
}
Expand Down
7 changes: 2 additions & 5 deletions trunk/arch/s390/kvm/interrupt.c
Original file line number Diff line number Diff line change
Expand Up @@ -339,11 +339,6 @@ int kvm_s390_handle_wait(struct kvm_vcpu *vcpu)
if (kvm_cpu_has_interrupt(vcpu))
return 0;

__set_cpu_idle(vcpu);
spin_lock_bh(&vcpu->arch.local_int.lock);
vcpu->arch.local_int.timer_due = 0;
spin_unlock_bh(&vcpu->arch.local_int.lock);

if (psw_interrupts_disabled(vcpu)) {
VCPU_EVENT(vcpu, 3, "%s", "disabled wait");
__unset_cpu_idle(vcpu);
Expand Down Expand Up @@ -371,6 +366,8 @@ int kvm_s390_handle_wait(struct kvm_vcpu *vcpu)
no_timer:
spin_lock_bh(&vcpu->arch.local_int.float_int->lock);
spin_lock_bh(&vcpu->arch.local_int.lock);
__set_cpu_idle(vcpu);
vcpu->arch.local_int.timer_due = 0;
add_wait_queue(&vcpu->arch.local_int.wq, &wait);
while (list_empty(&vcpu->arch.local_int.list) &&
list_empty(&vcpu->arch.local_int.float_int->list) &&
Expand Down
13 changes: 2 additions & 11 deletions trunk/arch/s390/kvm/kvm-s390.c
Original file line number Diff line number Diff line change
Expand Up @@ -423,30 +423,20 @@ int kvm_arch_vcpu_ioctl_set_mpstate(struct kvm_vcpu *vcpu,
return -EINVAL; /* not implemented yet */
}

extern void s390_handle_mcck(void);

static void __vcpu_run(struct kvm_vcpu *vcpu)
{
memcpy(&vcpu->arch.sie_block->gg14, &vcpu->arch.guest_gprs[14], 16);

if (need_resched())
schedule();

if (test_thread_flag(TIF_MCCK_PENDING))
s390_handle_mcck();

kvm_s390_deliver_pending_interrupts(vcpu);

vcpu->arch.sie_block->icptcode = 0;
local_irq_disable();
kvm_guest_enter();
local_irq_enable();
VCPU_EVENT(vcpu, 6, "entering sie flags %x",
atomic_read(&vcpu->arch.sie_block->cpuflags));
if (sie64a(vcpu->arch.sie_block, vcpu->arch.guest_gprs)) {
VCPU_EVENT(vcpu, 3, "%s", "fault in sie instruction");
kvm_s390_inject_program_int(vcpu, PGM_ADDRESSING);
}
sie64a(vcpu->arch.sie_block, vcpu->arch.guest_gprs);
VCPU_EVENT(vcpu, 6, "exit sie icptcode %d",
vcpu->arch.sie_block->icptcode);
local_irq_disable();
Expand Down Expand Up @@ -485,6 +475,7 @@ int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run)
might_sleep();

do {
kvm_s390_deliver_pending_interrupts(vcpu);
__vcpu_run(vcpu);
rc = kvm_handle_sie_intercept(vcpu);
} while (!signal_pending(current) && !rc);
Expand Down
44 changes: 17 additions & 27 deletions trunk/arch/s390/mm/pgtable.c
Original file line number Diff line number Diff line change
Expand Up @@ -254,46 +254,36 @@ void disable_noexec(struct mm_struct *mm, struct task_struct *tsk)
int s390_enable_sie(void)
{
struct task_struct *tsk = current;
struct mm_struct *mm, *old_mm;
struct mm_struct *mm;
int rc;

/* Do we have pgstes? if yes, we are done */
task_lock(tsk);

rc = 0;
if (tsk->mm->context.pgstes)
return 0;
goto unlock;

/* lets check if we are allowed to replace the mm */
task_lock(tsk);
rc = -EINVAL;
if (!tsk->mm || atomic_read(&tsk->mm->mm_users) > 1 ||
tsk->mm != tsk->active_mm || tsk->mm->ioctx_list) {
task_unlock(tsk);
return -EINVAL;
}
task_unlock(tsk);
tsk->mm != tsk->active_mm || tsk->mm->ioctx_list)
goto unlock;

/* we copy the mm with pgstes enabled */
tsk->mm->context.pgstes = 1;
tsk->mm->context.pgstes = 1; /* dirty little tricks .. */
mm = dup_mm(tsk);
tsk->mm->context.pgstes = 0;
if (!mm)
return -ENOMEM;

/* Now lets check again if somebody attached ptrace etc */
task_lock(tsk);
if (!tsk->mm || atomic_read(&tsk->mm->mm_users) > 1 ||
tsk->mm != tsk->active_mm || tsk->mm->ioctx_list) {
mmput(mm);
task_unlock(tsk);
return -EINVAL;
}

/* ok, we are alone. No ptrace, no threads, etc. */
old_mm = tsk->mm;
rc = -ENOMEM;
if (!mm)
goto unlock;
mmput(tsk->mm);
tsk->mm = tsk->active_mm = mm;
preempt_disable();
update_mm(mm, tsk);
cpu_set(smp_processor_id(), mm->cpu_vm_mask);
preempt_enable();
rc = 0;
unlock:
task_unlock(tsk);
mmput(old_mm);
return 0;
return rc;
}
EXPORT_SYMBOL_GPL(s390_enable_sie);
14 changes: 1 addition & 13 deletions trunk/arch/x86/kvm/i8254.c
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,7 @@ int __pit_timer_fn(struct kvm_kpit_state *ps)

atomic_inc(&pt->pending);
smp_mb__after_atomic_inc();
/* FIXME: handle case where the guest is in guest mode */
if (vcpu0 && waitqueue_active(&vcpu0->wq)) {
vcpu0->arch.mp_state = KVM_MP_STATE_RUNNABLE;
wake_up_interruptible(&vcpu0->wq);
Expand Down Expand Up @@ -236,19 +237,6 @@ static enum hrtimer_restart pit_timer_fn(struct hrtimer *data)
return HRTIMER_NORESTART;
}

void __kvm_migrate_pit_timer(struct kvm_vcpu *vcpu)
{
struct kvm_pit *pit = vcpu->kvm->arch.vpit;
struct hrtimer *timer;

if (vcpu->vcpu_id != 0 || !pit)
return;

timer = &pit->pit_state.pit_timer.timer;
if (hrtimer_cancel(timer))
hrtimer_start(timer, timer->expires, HRTIMER_MODE_ABS);
}

static void destroy_pit_timer(struct kvm_kpit_timer *pt)
{
pr_debug("pit: execute del timer!\n");
Expand Down
6 changes: 0 additions & 6 deletions trunk/arch/x86/kvm/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,3 @@ void kvm_timer_intr_post(struct kvm_vcpu *vcpu, int vec)
/* TODO: PIT, RTC etc. */
}
EXPORT_SYMBOL_GPL(kvm_timer_intr_post);

void __kvm_migrate_timers(struct kvm_vcpu *vcpu)
{
__kvm_migrate_apic_timer(vcpu);
__kvm_migrate_pit_timer(vcpu);
}
2 changes: 0 additions & 2 deletions trunk/arch/x86/kvm/irq.h
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,6 @@ void kvm_timer_intr_post(struct kvm_vcpu *vcpu, int vec);
void kvm_inject_pending_timer_irqs(struct kvm_vcpu *vcpu);
void kvm_inject_apic_timer_irqs(struct kvm_vcpu *vcpu);
void __kvm_migrate_apic_timer(struct kvm_vcpu *vcpu);
void __kvm_migrate_pit_timer(struct kvm_vcpu *vcpu);
void __kvm_migrate_timers(struct kvm_vcpu *vcpu);

int pit_has_pending_timer(struct kvm_vcpu *vcpu);
int apic_has_pending_timer(struct kvm_vcpu *vcpu);
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/x86/kvm/mmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -658,7 +658,7 @@ static int is_empty_shadow_page(u64 *spt)
u64 *end;

for (pos = spt, end = pos + PAGE_SIZE / sizeof(u64); pos != end; pos++)
if (is_shadow_present_pte(*pos)) {
if (*pos != shadow_trap_nonpresent_pte) {
printk(KERN_ERR "%s: %p %llx\n", __func__,
pos, *pos);
return 0;
Expand Down Expand Up @@ -1858,7 +1858,6 @@ static void free_mmu_pages(struct kvm_vcpu *vcpu)
sp = container_of(vcpu->kvm->arch.active_mmu_pages.next,
struct kvm_mmu_page, link);
kvm_mmu_zap_page(vcpu->kvm, sp);
cond_resched();
}
free_page((unsigned long)vcpu->arch.mmu.pae_root);
}
Expand Down
Loading

0 comments on commit d5a0bb7

Please sign in to comment.