All of lore.kernel.org
 help / color / mirror / Atom feed
From: Keir Fraser <keir@xensource.com>
To: Jimi Xenidis <jimix@watson.ibm.com>, xen-devel@lists.xensource.com
Subject: Re: [PATCH] fix xenctl_cpumap translation to handle bitops accessed like arrays
Date: Mon, 18 Dec 2006 09:26:07 +0000	[thread overview]
Message-ID: <C1AC0F2F.5FF0%keir@xensource.com> (raw)
In-Reply-To: <E1Gw0CP-0006C6-Tb@localhost.localdomain>

On 17/12/06 5:53 pm, "Jimi Xenidis" <jimix@watson.ibm.com> wrote:

> On PowerPC (and other big endian and/or RISC architectures) bit
> offsets in a bitmap are actually represented by a bit-offset from an
> element in an array rather than a bit-offset from the base memory
> pointer,  see xen/include/asm-powerpc/bitops.h for a complete
> explanation.
> 
> This complicates the conversion of cpumask_t from/to xenctl_cpumap.
> 
> The following patch allows an architecture to declare that bitops are
> "by long" rather than "by bit" and use an alternate scheme for
> encoding.

If the array-element type matters on big-endian systems then the tools
really need fixing: one libxc operation passes down a uint32_t unit; another
a uint64_t. Perhaps we should fix so they pass down 8-bit units (as the type
of xenctl_cpumap_t would suggest) and then we could have byte_to_long_bitmap
and long_to_byte_bitmap in Xen (which might encourage us to pull proper
endianness headers into Xen).

 -- Keir

  reply	other threads:[~2006-12-18  9:26 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-17 17:53 [PATCH] fix xenctl_cpumap translation to handle bitops accessed like arrays Jimi Xenidis
2006-12-18  9:26 ` Keir Fraser [this message]
2006-12-18 16:50   ` Jimi Xenidis
2006-12-18 17:55     ` Keir Fraser
2006-12-20 19:05       ` [RFC] " Jimi Xenidis
2006-12-21 10:48         ` Keir Fraser
2006-12-21 17:32           ` Jimi Xenidis
2006-12-21 19:51             ` Keir Fraser
2007-01-16 23:26               ` Jimi Xenidis
2007-01-17 12:20                 ` Keir Fraser
2007-01-17 12:50                   ` Jimi Xenidis
2007-01-17 13:55                     ` Keir Fraser
2007-01-21 16:10                       ` Jimi Xenidis
2007-01-21 16:20                         ` Keir Fraser
2007-01-21 21:43                           ` Jimi Xenidis

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=C1AC0F2F.5FF0%keir@xensource.com \
    --to=keir@xensource.com \
    --cc=jimix@watson.ibm.com \
    --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 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.