Skip to content

Commit

Permalink
hw/net/smc91c111: Use qemu_log_mask(GUEST_ERROR) instead of hw_error
Browse files Browse the repository at this point in the history
hw_error() finally calls abort(), but there is no need to abort here.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-id: 20180624040609.17572-14-f4bug@amsat.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
  • Loading branch information
philmd authored and pm215 committed Jun 26, 2018
1 parent f6de995 commit b9992d1
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions hw/net/smc91c111.c
Expand Up @@ -11,6 +11,7 @@
#include "hw/sysbus.h"
#include "net/net.h"
#include "hw/devices.h"
#include "qemu/log.h"
/* For crc32 */
#include <zlib.h>

Expand Down Expand Up @@ -478,7 +479,9 @@ static void smc91c111_writeb(void *opaque, hwaddr offset,
}
break;
}
hw_error("smc91c111_write: Bad reg %d:%x\n", s->bank, (int)offset);
qemu_log_mask(LOG_GUEST_ERROR, "smc91c111_write(bank:%d) Illegal register"
" 0x%" HWADDR_PRIx " = 0x%x\n",
s->bank, offset, value);
}

static uint32_t smc91c111_readb(void *opaque, hwaddr offset)
Expand Down Expand Up @@ -621,7 +624,9 @@ static uint32_t smc91c111_readb(void *opaque, hwaddr offset)
}
break;
}
hw_error("smc91c111_read: Bad reg %d:%x\n", s->bank, (int)offset);
qemu_log_mask(LOG_GUEST_ERROR, "smc91c111_read(bank:%d) Illegal register"
" 0x%" HWADDR_PRIx "\n",
s->bank, offset);
return 0;
}

Expand Down

0 comments on commit b9992d1

Please sign in to comment.