aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/powerpc/powerpc/intr_machdep.c6
-rw-r--r--sys/sys/bus.h1
2 files changed, 4 insertions, 3 deletions
diff --git a/sys/powerpc/powerpc/intr_machdep.c b/sys/powerpc/powerpc/intr_machdep.c
index 74dc4f548a22..743c8a62b080 100644
--- a/sys/powerpc/powerpc/intr_machdep.c
+++ b/sys/powerpc/powerpc/intr_machdep.c
@@ -451,7 +451,7 @@ powerpc_enable_intr(void)
if (error)
continue;
- if (i->trig == -1)
+ if (i->trig == INTR_TRIGGER_INVALID)
PIC_TRANSLATE_CODE(i->pic, i->intline, i->fwcode,
&i->trig, &i->pol);
if (i->trig != INTR_TRIGGER_CONFORM ||
@@ -497,7 +497,7 @@ powerpc_setup_intr(const char *name, u_int irq, driver_filter_t filter,
error = powerpc_map_irq(i);
if (!error) {
- if (i->trig == -1)
+ if (i->trig == INTR_TRIGGER_INVALID)
PIC_TRANSLATE_CODE(i->pic, i->intline,
i->fwcode, &i->trig, &i->pol);
@@ -545,7 +545,7 @@ powerpc_fw_config_intr(int irq, int sense_code)
if (i == NULL)
return (ENOMEM);
- i->trig = -1;
+ i->trig = INTR_TRIGGER_INVALID;
i->pol = INTR_POLARITY_CONFORM;
i->fwcode = sense_code;
diff --git a/sys/sys/bus.h b/sys/sys/bus.h
index e9fca9b70cc8..03912978c512 100644
--- a/sys/sys/bus.h
+++ b/sys/sys/bus.h
@@ -265,6 +265,7 @@ enum intr_type {
};
enum intr_trigger {
+ INTR_TRIGGER_INVALID = -1,
INTR_TRIGGER_CONFORM = 0,
INTR_TRIGGER_EDGE = 1,
INTR_TRIGGER_LEVEL = 2