xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Cooper <andrew.cooper3@citrix.com>
To: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Cc: "Keir (Xen.org)" <keir@xen.org>, "jbeulich@suse.com" <jbeulich@suse.com>
Subject: Re: [PATCH 4 of 4] CONFIG: remove #ifdef __ia64__ from the	x86 arch tree
Date: Wed, 8 Feb 2012 17:24:15 +0000	[thread overview]
Message-ID: <4F32AFBF.7090201@citrix.com> (raw)
In-Reply-To: <d59767433c7f8913c198.1328719539@andrewcoop.uk.xensource.com>

[-- Attachment #1: Type: text/plain, Size: 182 bytes --]

Presented v2, refreshing the patch without emulating a version 0x20 IOAPIC

-- 
Andrew Cooper - Dom0 Kernel Engineer, Citrix XenServer
T: +44 (0)1223 225 900, http://www.citrix.com


[-- Attachment #2: remove-itanium-ifdefs-in-x86-tree.patch --]
[-- Type: text/x-patch, Size: 2821 bytes --]

# HG changeset patch
# Parent a8f3abaaf3102ab493957d33e17ce59447915401
CONFIG: remove #ifdef __ia64__ from the x86 arch tree

__ia64__ really really should not be defined in the x86 arch subtree,
so remove it from xen/include/public/arch-x86/hvm/save.h

This in turn allows the removal of VIOAPIC_IS_IOSAPIC, as x86 does not
use streamlined {IO,L}APICs, allowing for the removal of more code
from the x86 tree.

Changes since v1:
 *  Refresh patch following the decision not to try emulating a
    version 0x20 IOAPIC

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>

diff -r a8f3abaaf310 xen/arch/x86/hvm/vioapic.c
--- a/xen/arch/x86/hvm/vioapic.c
+++ b/xen/arch/x86/hvm/vioapic.c
@@ -59,12 +59,10 @@ static unsigned long vioapic_read_indire
                   | (VIOAPIC_VERSION_ID & 0xff));
         break;
 
-#if !VIOAPIC_IS_IOSAPIC
     case VIOAPIC_REG_APIC_ID:
     case VIOAPIC_REG_ARB_ID:
         result = ((vioapic->id & 0xf) << 24);
         break;
-#endif
 
     default:
     {
@@ -179,14 +177,12 @@ static void vioapic_write_indirect(
         /* Writes are ignored. */
         break;
 
-#if !VIOAPIC_IS_IOSAPIC
     case VIOAPIC_REG_APIC_ID:
         vioapic->id = (val >> 24) & 0xf;
         break;
 
     case VIOAPIC_REG_ARB_ID:
         break;
-#endif
 
     default:
     {
@@ -227,12 +223,6 @@ static int vioapic_write(
         vioapic_write_indirect(vioapic, length, val);
         break;
 
-#if VIOAPIC_IS_IOSAPIC
-    case VIOAPIC_REG_EOI:
-        vioapic_update_EOI(v->domain, val);
-        break;
-#endif
-
     default:
         break;
     }
diff -r a8f3abaaf310 xen/include/asm-x86/hvm/vioapic.h
--- a/xen/include/asm-x86/hvm/vioapic.h
+++ b/xen/include/asm-x86/hvm/vioapic.h
@@ -30,11 +30,7 @@
 #include <xen/smp.h>
 #include <public/hvm/save.h>
 
-#if !VIOAPIC_IS_IOSAPIC
 #define VIOAPIC_VERSION_ID 0x11 /* IOAPIC version */
-#else
-#define VIOAPIC_VERSION_ID 0x21 /* IOSAPIC version */
-#endif
 
 #define VIOAPIC_EDGE_TRIG  0
 #define VIOAPIC_LEVEL_TRIG 1
diff -r a8f3abaaf310 xen/include/public/arch-x86/hvm/save.h
--- a/xen/include/public/arch-x86/hvm/save.h
+++ b/xen/include/public/arch-x86/hvm/save.h
@@ -344,12 +344,7 @@ DECLARE_HVM_SAVE_TYPE(PIC, 3, struct hvm
  * IO-APIC
  */
 
-#ifdef __ia64__
-#define VIOAPIC_IS_IOSAPIC 1
-#define VIOAPIC_NUM_PINS  24
-#else
 #define VIOAPIC_NUM_PINS  48 /* 16 ISA IRQs, 32 non-legacy PCI IRQS. */
-#endif
 
 struct hvm_hw_vioapic {
     uint64_t base_address;
@@ -368,13 +363,8 @@ struct hvm_hw_vioapic {
             uint8_t trig_mode:1;
             uint8_t mask:1;
             uint8_t reserve:7;
-#if !VIOAPIC_IS_IOSAPIC
             uint8_t reserved[4];
             uint8_t dest_id;
-#else
-            uint8_t reserved[3];
-            uint16_t dest_id;
-#endif
         } fields;
     } redirtbl[VIOAPIC_NUM_PINS];
 };

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

  reply	other threads:[~2012-02-08 17:24 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-08 16:45 [PATCH 0 of 4] Prune outdated/impossible preprocessor symbols, and update VIOAPIC emulation Andrew Cooper
2012-02-08 16:45 ` [PATCH 1 of 4] CONFIG: remove CONFIG_SMP #ifdefs Andrew Cooper
2012-02-08 17:22   ` Andrew Cooper
2012-02-09 10:54     ` Jan Beulich
2012-02-09 11:51       ` Andrew Cooper
2012-02-09 14:56         ` Jan Beulich
2012-02-08 16:45 ` [PATCH 2 of 4] CONFIG: remove smp barrier definitions Andrew Cooper
2012-02-09 10:49   ` Jan Beulich
2012-02-09 12:42     ` Keir Fraser
2012-02-08 16:45 ` [PATCH 3 of 4] VIOAPIC: Emulate a version 0x20 IOAPIC Andrew Cooper
2012-02-08 17:05   ` Tim Deegan
2012-02-08  9:12     ` Keir Fraser
2012-02-08 17:13     ` Andrew Cooper
2012-02-08 16:45 ` [PATCH 4 of 4] CONFIG: remove #ifdef __ia64__ from the x86 arch tree Andrew Cooper
2012-02-08 17:24   ` Andrew Cooper [this message]
2012-02-09 11:03     ` Jan Beulich
2012-02-09 11:52       ` Andrew Cooper
2012-02-09 13:08         ` Andrew Cooper
2012-02-09 14:58           ` Jan Beulich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F32AFBF.7090201@citrix.com \
    --to=andrew.cooper3@citrix.com \
    --cc=jbeulich@suse.com \
    --cc=keir@xen.org \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).