mirror of
https://git.FreeBSD.org/src.git
synced 2024-11-21 07:15:49 +00:00
bhyve: Fix the build with gcc
gcc doesn't like const and static to not be at the start of a variable declaration. Update the gdb_regset arrays to make it more obvious they are arrays of struct gdb_reg and to fix the gcc build. Reviewed by: corvink, markj Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45550
This commit is contained in:
parent
abf239cf09
commit
9a4813e1dc
@ -166,10 +166,10 @@ static bool gdb_active = false;
|
||||
struct gdb_reg {
|
||||
enum vm_reg_name id;
|
||||
int size;
|
||||
}
|
||||
};
|
||||
|
||||
#ifdef __amd64__
|
||||
static const gdb_regset[] = {
|
||||
static const struct gdb_reg gdb_regset[] = {
|
||||
{ .id = VM_REG_GUEST_RAX, .size = 8 },
|
||||
{ .id = VM_REG_GUEST_RBX, .size = 8 },
|
||||
{ .id = VM_REG_GUEST_RCX, .size = 8 },
|
||||
@ -212,7 +212,7 @@ static const gdb_regset[] = {
|
||||
{ .id = VM_REG_GUEST_EFER, .size = 8 },
|
||||
};
|
||||
#else /* __aarch64__ */
|
||||
static const gdb_regset[] = {
|
||||
static const struct gdb_reg gdb_regset[] = {
|
||||
{ .id = VM_REG_GUEST_X0, .size = 8 },
|
||||
{ .id = VM_REG_GUEST_X1, .size = 8 },
|
||||
{ .id = VM_REG_GUEST_X2, .size = 8 },
|
||||
|
Loading…
Reference in New Issue
Block a user