1. 15 11月, 2011 12 次提交
    • A
      s390x: initialize virtio dev region · 326384d5
      Alexander Graf 提交于
      When running the s390x virtio machine we can potentially use uninitialized
      memory for the virtio device backing ram. That can lead to weird breakge.
      
      So let's better initialize it to 0 properly.
      Reported-by: NAndreas Färber <afaerber@suse.de>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      
      ---
      
      v1 -> v2:
      
        - use target_phys_addr_t
      326384d5
    • R
      tcg: Use TCGReg for standard tcg-target entry points. · 2a534aff
      Richard Henderson 提交于
      Including tcg_out_ld, tcg_out_st, tcg_out_mov, tcg_out_movi.
      Signed-off-by: NRichard Henderson <rth@twiddle.net>
      Reviewed-by: NAndreas Färber <afaerber@suse.de>
      Reviewed-by: NStefan Weil <sw@weilnetz.de>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      2a534aff
    • R
      tcg: Standardize on TCGReg as the enum for hard registers · 771142c2
      Richard Henderson 提交于
      Most targets did not name the enum; tci used TCGRegister.
      Signed-off-by: NRichard Henderson <rth@twiddle.net>
      Reviewed-by: NAndreas Färber <afaerber@suse.de>
      Reviewed-by: NStefan Weil <sw@weilnetz.de>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      771142c2
    • A
      s390x: Add shutdown for TCG s390-virtio machine · ef81522b
      Alexander Graf 提交于
      Now that we have code in place to do refcounting of online CPUs, we
      can drag the TCG code along and implement shutdown for that one too,
      so it doesn't feel left out by its KVM counterpart.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      ef81522b
    • C
      s390: Fix cpu shutdown for KVM · 854e42f3
      Christian Borntraeger 提交于
      On s390 a shutdown is the state of all CPUs being either stopped
      or disabled (for interrupts) waiting. We have to track the overall
      number of running CPUs to call the shutdown sequence accordingly.
      This patch implements the counting and shutdown handling for the
      kvm path in qemu.
      Lets also wrap changes to env->halted and env->exception_index.
      Signed-off-by: NChristian Borntraeger <borntraeger@de.ibm.com>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      854e42f3
    • C
      s390: fix short kernel command lines · 13449a6e
      Christian Borntraeger 提交于
      The default kernel command line for s390 is
      "root=/dev/ram0 ro"
      
      When overriding this line, we have to ensure to also copy the \0 to
      avoid false lines, for example, -append "root=/dev/vda" will result in
      "root=/dev/vda0 ro" with the current code.
      Signed-off-by: NChristian Borntraeger <borntraeger@de.ibm.com>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      13449a6e
    • C
      s390: fix reset hypercall to reset the status · e9d86b76
      Christian Borntraeger 提交于
      This patch fixes the reset hypercall which is supposed to also
      reset the device status in device memory.
      This fixes the following bug:
      
      [root@localhost driver]# echo virtio0 > unbind
      [   35.056966] ------------[ cut here ]------------
      [   35.057054] kernel BUG at drivers/virtio/virtio.c:157!
      [   35.057113] illegal operation: 0001 [#1] SMP
      [   35.057181] Modules linked in:
      [   35.057243] CPU: 0 Not tainted 3.0.0-rc1-00180-g0792644-dirty #51
      [   35.057323] Process bash (pid: 497, task: 000000003e58c538, ksp: 000000003ef43978)
      [   35.057409] Krnl PSW : 0704100180000000 00000000003d46f8 (virtio_check_driver_offered_feature+0x0/0x38)
      [   35.057528]            R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:0 CC:1 PM:0 EA:3
      [   35.057616] Krnl GPRS: 0000000000000000 0000000040000000 0000000000000007 0000000000000000
      [   35.057716]            00000000003b3be4 0000000000000001 000000003ef4d380 000000003f1cff00
      [   35.057805]            000000003ef43f18 00000000005ca620 0000000000000008 0000000000838e88
      [   35.057919]            000000000083c860 000000003f7c2e00 00000000003d46b0 000000003ef43d10
      [   35.058027] Krnl Code: 00000000003d46e8: f0b00004ebcf	srp	4(12,%r0),3023(%r14),0
      [   35.058115]            00000000003d46ee: f0a0000407f4	srp	4(11,%r0),2036,0
      [   35.058207]            00000000003d46f4: a7f40001		brc	15,3d46f6
      [   35.058295]           >00000000003d46f8: e31020900004	lg	%r1,144(%r2)
      [   35.058383]            00000000003d46fe: bf2f1080		icm	%r2,15,128(%r1)
      [   35.058470]            00000000003d4702: a784000d		brc	8,3d471c
      [   35.058557]            00000000003d4706: e32010780004	lg	%r2,120(%r1)
      [   35.058645]            00000000003d470c: 59302000		c	%r3,0(%r2)
      [   35.058748] Call Trace:
      [   35.058777] ([<00000000003d469e>] virtio_dev_remove+0x36/0x90)
      [   35.058852]  [<00000000003f3a40>] __device_release_driver+0x7c/0xec
      [   35.058936]  [<00000000003f3ae8>] device_release_driver+0x38/0x48
      [   35.059023]  [<00000000003f2a98>] driver_unbind+0xa4/0xc4
      [   35.059111]  [<00000000002acb70>] sysfs_write_file+0xe8/0x19c
      [   35.059226]  [<000000000022e7a4>] vfs_write+0xb0/0x18c
      [   35.059317]  [<000000000022eb18>] SyS_write+0x58/0xb4
      [   35.059398]  [<000000000057e674>] sysc_noemu+0x16/0x1c
      [   35.059475]  [<000003fffd44b6c0>] 0x3fffd44b6c0
      [   35.059531] Last Breaking-Event-Address:
      [   35.059576]  [<00000000003d46f4>] virtio_dev_remove+0x8c/0x90
      [   35.059646]
      [   35.059661] ---[ end trace 9b1959188f21ee11 ]---
      
      Signed-off-by: Christian Borntraeger<borntraeger@de.ibm.com>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      e9d86b76
    • A
      s390x: implement SIGP restart and shutdown · 1864b94a
      Alexander Graf 提交于
      An s390x OS does reboot and shutdown triggers through hypercalls that
      we didn't implement on the TCG backend yet. That means that so far we
      couldn't shut down virtual machines for example, having them hang on
      shutdown when not using KVM.
      
      With this patch, this restriction is gone. We can now shut down and
      reboot s390x virtual machines even when using the TCG backend.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      1864b94a
    • A
      s390x: implement rrbe instruction properly · 17bb18ce
      Alexander Graf 提交于
      The rrbe instruction resets the reference bit in the given storage key.
      So far, we merely made it a nop and also returned an invalid CC value,
      so that the kernel never knew if a page actually got accessed.
      
      This patch implements it properly, flushing the R bit and returning the
      correct CC value.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      17bb18ce
    • A
      s390x: update R and C bits in storage key · b9959138
      Alexander Graf 提交于
      When the s390x maps a page or writes happen to a page, the R and C
      bits get updated. The easiest way to implement this in qemu is to
      simply update them whenever we map a TLB translation and act according
      to the permissions.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      b9959138
    • A
      s390x: make ipte 31-bit aware · 09ed75f7
      Alexander Graf 提交于
      When running 31-bit code we can potentially map the same virtual
      address twice - once as 0x0yyyyyyy and once as 0x8yyyyyyy, because
      the upper bit gets ignored.
      
      This also should be reflected in the tlb invalidation path, so we
      really invalidate also the transparently created tlb entries.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      09ed75f7
    • A
      s390x: add ldeb instruction · 27b5979d
      Alexander Graf 提交于
      While running perl, we encountered the ldeb instruction to be used,
      so we implement it :).
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      27b5979d
  2. 14 11月, 2011 5 次提交
  3. 13 11月, 2011 1 次提交
  4. 12 11月, 2011 15 次提交
  5. 11 11月, 2011 7 次提交