~n-muench/ubuntu/precise/open-vm-tools/open-vm-tools.raring-precise.backport

« back to all changes in this revision

Viewing changes to lib/include/vm_basic_asm.h

  • Committer: Package Import Robot
  • Author(s): Nate Muench
  • Date: 2012-01-23 16:09:45 UTC
  • mfrom: (1.4.6) (2.4.26 sid)
  • Revision ID: package-import@ubuntu.com-20120123160945-b6s0r1vkcovucpf3
Tags: 2011.12.20-562307-0ubuntu1
* Merge latest upstream git tag. Fixes building on Precise
  (LP: #898289, LP: #905612)

* Items merged from Debian unstable:
  - debian/control:
    + open-vm-tools recommends open-vm-dkms. (LP: #598933)
    + open-vm-tools now suggests open-vm-toolbox. (LP: #604998)
  (From 2011.08.21-471295-1 release)
  - Updating maintainer and uploaders fields.
  - Removing vcs fields.
  - Removing references to Daniel's old email address.
  - Updating years in copyright file.
  - Updating to standards version 3.9.2.
  - Updating to debhelper version 8.
  - Switching to source format 3.0 (quilt).
  - Removing manual chrpath setting.
  - Removing exclusion from plugins from debhelper shlibs.
  - Rediffing kvers.patch.
  (From 2011.09.23-491607-1 release)
  - Marking binary architecture-dependend packages as linux and kfreebsd
  only.
  - Removing liburiparser-dev from build-depends as upstream dropped
  unity support.
  - Building with libproc-dev on amd64 again.
  - Dropping disabling of dnet support.
  (From 2011.09.23-491607-2 release)
  - Adding doxygen to build-depends for api documentation.
  - Adding libcunit1-dev to build-depends for test suites.
  - Minimizing rules file.
  - Adding open-vm-tools-dev package, containing only the api
    documentation for now.
  (From 2011.09.23-491607-3 release)
  - Sorting overrides in rules alphabetically.
  - Compacting copyright file.
  - Adding udev rule to set timeout for vmware scsi devices
  (From 2011.12.20-562307-1 release)
  - Adding patch to correct typo in upstreams dkms configuration

* Remaining Changes:
  - Remove Stable part of version numbering.
  - debian folder:
    + Re-added open-vm-dkms.postinst & open-vm-dkms.prerm.
      * Allows dkms modules to compile upon installation.
  - debian/control:
    + Re-add open-vm-source and make into a transitional package
      for open-vm-toolbox.
    + Return dependancies that were moved to open-vm-tools back to
      open-vm-toolbox.
  - debian/rules and debian/open-vm-toolbox.lintian-overrides:
    + Make vmware-user-suid-wrapper suid-root
  - debian/rules:
    + Added CFLAGS field with -Wno-deprecated-declarations
      * Will suppress issues with glib 2.31 or later.
    + Add line to copy vmware-xdg-detect-de into place.
    + Install vmware-user.desktop through toolbox package.
  - debian/open-vm-tools.init:
    + Re-add 'modprobe [-r] vmblock'.
    + Add 'modprobe [-r] vmxnet'.
      * Incase it's not loaded during boot.
    + Remove and re-add pcnet32 module
      * Will be done before (remove) and after (readd) vmxnet module
        is added.
      * If vmxnet doesn't exist (aka modules fail to build), pcnet32 can be
        still used for network connectivity.
      * Workaround until a better fix can be done.
  - Re-add gnome-session to debian/local/xautostart.conf
  - Manpages removed (from debian/manpages):
    + vmmemctl.9
    + vmxnet3.9
    + Remove references to manpages that have been removed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
603
603
        );
604
604
   return dst;
605
605
#else
606
 
   int dummy0;
607
 
   int dummy1;
 
606
   size_t dummy0;
 
607
   void *dummy1;
608
608
 
609
609
   __asm__ __volatile__("\t"
610
610
                        "cld"            "\n\t"
633
633
        );
634
634
   return dst;
635
635
#else
636
 
   int dummy0;
637
 
   int dummy1;
 
636
   size_t dummy0;
 
637
   void *dummy1;
638
638
 
639
639
   __asm__ __volatile__("\t"
640
640
                        "cld"            "\n\t"
740
740
static INLINE uint32
741
741
Bswap32(uint32 v) // IN
742
742
{
743
 
#if defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) || defined(__arm__) // {
 
743
#if defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) || \
 
744
   (defined(__arm__) && !defined(__ANDROID__))  // {
744
745
#ifdef __arm__
745
746
    __asm__("rev %0, %0" : "+r"(v));
746
747
    return v;
1028
1029
   _bittestandreset64((__int64 *)var, index);
1029
1030
#endif
1030
1031
}
 
1032
#endif /* VM_X86_64 */
1031
1033
 
1032
1034
static INLINE Bool
1033
 
TestBit32(uint32 *var, uint32 index)
 
1035
TestBit32(const uint32 *var, uint32 index)
1034
1036
{
1035
1037
#ifdef __GNUC__
1036
1038
   Bool bit;
1042
1044
      : "cc"
1043
1045
   );
1044
1046
   return bit;
1045
 
#elif defined _MSC_VER
 
1047
#else
1046
1048
   return (*var & (1 << index)) != 0;
1047
1049
#endif
1048
1050
}
1049
1051
 
1050
1052
static INLINE Bool
1051
 
TestBit64(uint64 *var, uint64 index)
 
1053
TestBit64(const uint64 *var, uint64 index)
1052
1054
{
1053
 
#ifdef __GNUC__
 
1055
#if defined __GNUC__ && defined VM_X86_64
1054
1056
   Bool bit;
1055
1057
   __asm__ (
1056
1058
      "bt %[index], %[var] \n"
1060
1062
      : "cc"
1061
1063
   );
1062
1064
   return bit;
1063
 
#elif defined _MSC_VER
 
1065
#else
1064
1066
   return (*var & (CONST64U(1) << index)) != 0;
1065
1067
#endif
1066
1068
}
1067
 
#endif /* VM_X86_64 */
1068
1069
 
1069
1070
/*
1070
1071
 *-----------------------------------------------------------------------------