mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
tools/include: move xc_bitops.h to xen-tools/bitops.h
Move xc_bitops.h to common tools location to be shared between the toolstack and unit test code. Adjust the guard in xen-tools/bitops.h Correct the #include directives and comments referring to the old xc_bitops.h in the toolstack code. Signed-off-by: Denis Mukhin <dmukhin@ford.com> Acked-by: Anthony PERARD <anthony.perard@vates.tech>
This commit is contained in:
1 parent
375f0dd538
commit
b0bdfbfc88
6 files changed
+11
-14
No files matched your search
@@ -1,5 +1,5 @@
|
||||
#ifndef XC_BITOPS_H
|
||||
#define XC_BITOPS_H 1
|
||||
#ifndef __XEN_TOOLS_BITOPS_H__
|
||||
#define __XEN_TOOLS_BITOPS_H__
|
||||
|
||||
/* bitmap operations for single threaded access */
|
||||
|
||||
@@ -81,4 +81,4 @@ static inline void bitmap_or(void *_dst, const void *_other,
|
||||
dst[i] |= other[i];
|
||||
}
|
||||
|
||||
#endif /* XC_BITOPS_H */
|
||||
#endif /* __XEN_TOOLS_BITOPS_H__ */
|
||||
@@ -17,8 +17,8 @@
|
||||
* License along with this library; If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "xc_bitops.h"
|
||||
#include "xc_private.h"
|
||||
#include <xen-tools/bitops.h>
|
||||
#include <xen/hvm/hvm_op.h>
|
||||
|
||||
int xc_get_max_cpus(xc_interface *xch)
|
||||
@@ -94,11 +94,12 @@ xc_cpumap_t xc_cpumap_alloc(xc_interface *xch)
|
||||
}
|
||||
|
||||
/*
|
||||
* xc_bitops.h has macros that do this as well - however they assume that
|
||||
* the bitmask is word aligned but xc_cpumap_t is only guaranteed to be
|
||||
* byte aligned and so we need byte versions for architectures which do
|
||||
* not support misaligned accesses (which is basically everyone
|
||||
* but x86, although even on x86 it can be inefficient).
|
||||
* <xen-tools/bitops.h> has macros that do this as well - however they
|
||||
* assume that the bitmask is word aligned but xc_cpumap_t is only
|
||||
* guaranteed to be byte aligned and so we need byte versions for
|
||||
* architectures which do not support misaligned accesses (which is
|
||||
* basically everyone but x86, although even on x86 it can be
|
||||
* inefficient).
|
||||
*
|
||||
* NOTE: The xc_bitops macros now use byte alignment.
|
||||
* TODO: Clean up the users of this interface.
|
||||
|
||||
@@ -26,7 +26,6 @@
|
||||
#include <inttypes.h>
|
||||
|
||||
#include "xg_private.h"
|
||||
#include "xc_bitops.h"
|
||||
|
||||
#define XEN_VER "xen-3.0"
|
||||
|
||||
|
||||
@@ -25,7 +25,6 @@
|
||||
#include <assert.h>
|
||||
|
||||
#include "xg_private.h"
|
||||
#include "xc_bitops.h"
|
||||
|
||||
/* ------------------------------------------------------------------------ */
|
||||
/* parse elf binary */
|
||||
|
||||
@@ -28,9 +28,9 @@
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include "xc_private.h"
|
||||
#include "xc_bitops.h"
|
||||
#include "xenguest.h"
|
||||
|
||||
#include <xen-tools/bitops.h>
|
||||
#include <xen/memory.h>
|
||||
#include <xen/elfnote.h>
|
||||
#include <xen/libelf/libelf.h>
|
||||
|
||||
@@ -5,8 +5,6 @@
|
||||
|
||||
#include "xg_private.h"
|
||||
#include "xg_save_restore.h"
|
||||
#include "xc_bitops.h"
|
||||
|
||||
#include "xg_sr_stream_format.h"
|
||||
|
||||
/* String representation of Domain Header types. */
|
||||
|
||||