summaryrefslogtreecommitdiffstats
path: root/sys/dev/mfi/mfi.c
diff options
context:
space:
mode:
authoremaste <emaste@FreeBSD.org>2011-06-02 00:43:16 +0000
committeremaste <emaste@FreeBSD.org>2011-06-02 00:43:16 +0000
commit11e6bdb86e206bb45b2edb0ce2c5c7496bb19032 (patch)
tree975c2a72315332f3fb67ca1126bb144f3baeb0ea /sys/dev/mfi/mfi.c
parent64fa4da5ee705ed9a004b5f5400e08e6188efa48 (diff)
downloadFreeBSD-src-11e6bdb86e206bb45b2edb0ce2c5c7496bb19032.zip
FreeBSD-src-11e6bdb86e206bb45b2edb0ce2c5c7496bb19032.tar.gz
There are a couple of structs in mfireg.h with members named 'class'.
These cause problems when trying to include the header in a C++ project. Rename them to 'evt_class', and track the change in mfi and mfiutil. Submitted by: Mark Johnston Sponsored by: Sandvine Incorporated Reviewed by: jhb@ MFC after: 1 week
Diffstat (limited to 'sys/dev/mfi/mfi.c')
-rw-r--r--sys/dev/mfi/mfi.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/sys/dev/mfi/mfi.c b/sys/dev/mfi/mfi.c
index eb18ffe..1962648 100644
--- a/sys/dev/mfi/mfi.c
+++ b/sys/dev/mfi/mfi.c
@@ -788,7 +788,7 @@ mfi_aen_setup(struct mfi_softc *sc, uint32_t seq_start)
class_locale.members.reserved = 0;
class_locale.members.locale = mfi_event_locale;
- class_locale.members.class = mfi_event_class;
+ class_locale.members.evt_class = mfi_event_class;
if (seq_start == 0) {
error = mfi_get_log_state(sc, &log_state);
@@ -1082,8 +1082,8 @@ mfi_decode_evt(struct mfi_softc *sc, struct mfi_evt_detail *detail)
{
device_printf(sc->mfi_dev, "%d (%s/0x%04x/%s) - %s\n", detail->seq,
- format_timestamp(detail->time), detail->class.members.locale,
- format_class(detail->class.members.class), detail->description);
+ format_timestamp(detail->time), detail->evt_class.members.locale,
+ format_class(detail->evt_class.members.evt_class), detail->description);
}
static int
@@ -1099,16 +1099,16 @@ mfi_aen_register(struct mfi_softc *sc, int seq, int locale)
if (sc->mfi_aen_cm != NULL) {
prior_aen.word =
((uint32_t *)&sc->mfi_aen_cm->cm_frame->dcmd.mbox)[1];
- if (prior_aen.members.class <= current_aen.members.class &&
+ if (prior_aen.members.evt_class <= current_aen.members.evt_class &&
!((prior_aen.members.locale & current_aen.members.locale)
^current_aen.members.locale)) {
return (0);
} else {
prior_aen.members.locale |= current_aen.members.locale;
- if (prior_aen.members.class
- < current_aen.members.class)
- current_aen.members.class =
- prior_aen.members.class;
+ if (prior_aen.members.evt_class
+ < current_aen.members.evt_class)
+ current_aen.members.evt_class =
+ prior_aen.members.evt_class;
mfi_abort(sc, sc->mfi_aen_cm);
}
}
@@ -1199,7 +1199,7 @@ mfi_parse_entries(struct mfi_softc *sc, int start_seq, int stop_seq)
class_locale.members.reserved = 0;
class_locale.members.locale = mfi_event_locale;
- class_locale.members.class = mfi_event_class;
+ class_locale.members.evt_class = mfi_event_class;
size = sizeof(struct mfi_evt_list) + sizeof(struct mfi_evt_detail)
* (MAX_EVENTS - 1);
OpenPOWER on IntegriCloud