Skip to content

Commit

Permalink
target/ppc: fix the PPC_BIT definitions
Browse files Browse the repository at this point in the history
Change the PPC_BIT macro to use ULL instead of UL and the PPC_BIT32
and PPC_BIT8 not to use any suffix.

This fixes a compile breakage on windows.

Signed-off-by: Cédric Le Goater <clg@kaod.org>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
  • Loading branch information
legoater authored and dgibson committed Dec 20, 2018
1 parent 95de6f4 commit a7d4b1b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions target/ppc/cpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@
#define PPC_ELF_MACHINE EM_PPC
#endif

#define PPC_BIT(bit) (0x8000000000000000UL >> (bit))
#define PPC_BIT32(bit) (0x80000000UL >> (bit))
#define PPC_BIT8(bit) (0x80UL >> (bit))
#define PPC_BIT(bit) (0x8000000000000000ULL >> (bit))
#define PPC_BIT32(bit) (0x80000000 >> (bit))
#define PPC_BIT8(bit) (0x80 >> (bit))
#define PPC_BITMASK(bs, be) ((PPC_BIT(bs) - PPC_BIT(be)) | PPC_BIT(bs))
#define PPC_BITMASK32(bs, be) ((PPC_BIT32(bs) - PPC_BIT32(be)) | \
PPC_BIT32(bs))
Expand Down

0 comments on commit a7d4b1b

Please sign in to comment.