All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] tools/ia64: Cull more ia64 code
@ 2013-08-13 13:00 Andrew Cooper
  2013-08-13 13:09 ` Jan Beulich
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Cooper @ 2013-08-13 13:00 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Ian Jackson, Ian Campbell

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
CC: Ian Campbell <Ian.Campbell@citrix.com>
CC: Ian Jackson <Ian.Jackson@eu.citrix.com>
---
 tools/libfsimage/common/fsimage_grub.c |   22 -------------
 tools/python/xen/lowlevel/xc/xc.c      |   53 --------------------------------
 2 files changed, 75 deletions(-)

diff --git a/tools/libfsimage/common/fsimage_grub.c b/tools/libfsimage/common/fsimage_grub.c
index c58790d..42c5a02 100644
--- a/tools/libfsimage/common/fsimage_grub.c
+++ b/tools/libfsimage/common/fsimage_grub.c
@@ -138,28 +138,6 @@ fsig_log2 (unsigned long word)
   return word;
 }
 
-#elif defined(__ia64__)
-
-#if __GNUC__ >= 4 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
-# define ia64_popcnt(x) __builtin_popcountl(x)
-#else
-# define ia64_popcnt(x)                                     \
-  ({                                                        \
-    uint64_t ia64_intri_res;                                \
-    asm ("popcnt %0=%1" : "=r" (ia64_intri_res) : "r" (x)); \
-    ia64_intri_res;                                         \
-  })
-#endif
-
-unsigned long
-fsig_log2 (unsigned long word)
-{
-  unsigned long result;
-
-  result = ia64_popcnt((word - 1) & ~word);
-  return result;
-}
-
 #elif defined(__powerpc__)
 
 #ifdef __powerpc64__
diff --git a/tools/python/xen/lowlevel/xc/xc.c b/tools/python/xen/lowlevel/xc/xc.c
index e611b24..2625fc4 100644
--- a/tools/python/xen/lowlevel/xc/xc.c
+++ b/tools/python/xen/lowlevel/xc/xc.c
@@ -178,10 +178,6 @@ static PyObject *pyxc_domain_unpause(XcObject *self, PyObject *args)
 
 static PyObject *pyxc_domain_destroy_hook(XcObject *self, PyObject *args)
 {
-#ifdef __ia64__
-    dom_op(self, args, xc_ia64_save_to_nvram);
-#endif
-
     Py_INCREF(zero);
     return zero;
 }
@@ -779,39 +775,6 @@ static PyObject *pyxc_get_device_group(XcObject *self,
     return Pystr;
 }
 
-#ifdef __ia64__
-static PyObject *pyxc_nvram_init(XcObject *self,
-                                 PyObject *args)
-{
-    char *dom_name;
-    uint32_t dom;
-
-    if ( !PyArg_ParseTuple(args, "si", &dom_name, &dom) )
-        return NULL;
-
-    xc_ia64_nvram_init(self->xc_handle, dom_name, dom);
-
-    Py_INCREF(zero);
-    return zero;
-}
-
-static PyObject *pyxc_set_os_type(XcObject *self,
-                                  PyObject *args)
-{
-    char *os_type;
-    uint32_t dom;
-
-    if ( !PyArg_ParseTuple(args, "si", &os_type, &dom) )
-        return NULL;
-
-    xc_ia64_set_os_type(self->xc_handle, os_type, dom);
-
-    Py_INCREF(zero);
-    return zero;
-}
-#endif /* __ia64__ */
-
-
 #if defined(__i386__) || defined(__x86_64__)
 static void pyxc_dom_extract_cpuid(PyObject *config,
                                   char **regs)
@@ -950,10 +913,8 @@ static PyObject *pyxc_hvm_build(XcObject *self,
                                 PyObject *kwds)
 {
     uint32_t dom;
-#if !defined(__ia64__)
     struct hvm_info_table *va_hvm;
     uint8_t *va_map, sum;
-#endif
     int i;
     char *image;
     int memsize, target=-1, vcpus = 1, acpi = 0, apic = 1;
@@ -1000,7 +961,6 @@ static PyObject *pyxc_hvm_build(XcObject *self,
                                  target, image) != 0 )
         return pyxc_error_to_exception(self->xc_handle);
 
-#if !defined(__ia64__)
     /* Fix up the HVM info table. */
     va_map = xc_map_foreign_range(self->xc_handle, dom, XC_PAGE_SIZE,
                                   PROT_READ | PROT_WRITE,
@@ -1015,7 +975,6 @@ static PyObject *pyxc_hvm_build(XcObject *self,
         sum += ((uint8_t *)va_hvm)[i];
     va_hvm->checksum -= sum;
     munmap(va_map, XC_PAGE_SIZE);
-#endif
 
     return Py_BuildValue("{}");
 }
@@ -2713,18 +2672,6 @@ static PyMethodDef pyxc_methods[] = {
       " map_limitkb [int]: .\n"
       "Returns: [int] 0 on success; -1 on error.\n" },
 
-#ifdef __ia64__
-    { "nvram_init",
-      (PyCFunction)pyxc_nvram_init,
-      METH_VARARGS, "\n"
-      "Init nvram in IA64 platform\n"
-      "Returns: [int] 0 on success; -1 on error.\n" },
-    { "set_os_type",
-      (PyCFunction)pyxc_set_os_type,
-      METH_VARARGS, "\n"
-      "Set guest OS type on IA64 platform\n"
-      "Returns: [int] 0 on success; -1 on error.\n" },
-#endif /* __ia64__ */
     { "domain_ioport_permission",
       (PyCFunction)pyxc_domain_ioport_permission,
       METH_VARARGS | METH_KEYWORDS, "\n"
-- 
1.7.10.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] tools/ia64: Cull more ia64 code
  2013-08-13 13:00 [PATCH] tools/ia64: Cull more ia64 code Andrew Cooper
@ 2013-08-13 13:09 ` Jan Beulich
  2013-08-13 13:13   ` Andrew Cooper
  0 siblings, 1 reply; 3+ messages in thread
From: Jan Beulich @ 2013-08-13 13:09 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: xen-devel, Ian Jackson, Ian Campbell

>>> On 13.08.13 at 15:00, Andrew Cooper <andrew.cooper3@citrix.com> wrote:
> --- a/tools/libfsimage/common/fsimage_grub.c
> +++ b/tools/libfsimage/common/fsimage_grub.c
> @@ -138,28 +138,6 @@ fsig_log2 (unsigned long word)
>    return word;
>  }
>  
> -#elif defined(__ia64__)
> -
> -#if __GNUC__ >= 4 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
> -# define ia64_popcnt(x) __builtin_popcountl(x)
> -#else
> -# define ia64_popcnt(x)                                     \
> -  ({                                                        \
> -    uint64_t ia64_intri_res;                                \
> -    asm ("popcnt %0=%1" : "=r" (ia64_intri_res) : "r" (x)); \
> -    ia64_intri_res;                                         \
> -  })
> -#endif
> -
> -unsigned long
> -fsig_log2 (unsigned long word)
> -{
> -  unsigned long result;
> -
> -  result = ia64_popcnt((word - 1) & ~word);
> -  return result;
> -}
> -
>  #elif defined(__powerpc__)
>  
>  #ifdef __powerpc64__

Why not rip out the PPC stuff here at once?

Jan

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] tools/ia64: Cull more ia64 code
  2013-08-13 13:09 ` Jan Beulich
@ 2013-08-13 13:13   ` Andrew Cooper
  0 siblings, 0 replies; 3+ messages in thread
From: Andrew Cooper @ 2013-08-13 13:13 UTC (permalink / raw)
  To: Jan Beulich; +Cc: xen-devel, Ian Jackson, Ian Campbell

On 13/08/13 14:09, Jan Beulich wrote:
>>>> On 13.08.13 at 15:00, Andrew Cooper <andrew.cooper3@citrix.com> wrote:
>> --- a/tools/libfsimage/common/fsimage_grub.c
>> +++ b/tools/libfsimage/common/fsimage_grub.c
>> @@ -138,28 +138,6 @@ fsig_log2 (unsigned long word)
>>    return word;
>>  }
>>  
>> -#elif defined(__ia64__)
>> -
>> -#if __GNUC__ >= 4 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
>> -# define ia64_popcnt(x) __builtin_popcountl(x)
>> -#else
>> -# define ia64_popcnt(x)                                     \
>> -  ({                                                        \
>> -    uint64_t ia64_intri_res;                                \
>> -    asm ("popcnt %0=%1" : "=r" (ia64_intri_res) : "r" (x)); \
>> -    ia64_intri_res;                                         \
>> -  })
>> -#endif
>> -
>> -unsigned long
>> -fsig_log2 (unsigned long word)
>> -{
>> -  unsigned long result;
>> -
>> -  result = ia64_popcnt((word - 1) & ~word);
>> -  return result;
>> -}
>> -
>>  #elif defined(__powerpc__)
>>  
>>  #ifdef __powerpc64__
> Why not rip out the PPC stuff here at once?
>
> Jan
>

Can do - this appears to be the only ppc which can be ripped out.  v2 on
its way

~Andrew

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-08-13 13:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-08-13 13:00 [PATCH] tools/ia64: Cull more ia64 code Andrew Cooper
2013-08-13 13:09 ` Jan Beulich
2013-08-13 13:13   ` Andrew Cooper

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.