Replaced the INTRMASK and INTRUNMASK macros by "|" and "&~" operations.

Some interface botches went away, leaving the macros unused outside of
the implementation of interrupt masking, and it was silly for the
implementation to use the macros in only one place each.
This commit is contained in:
Bruce Evans 1999-12-26 12:43:47 +00:00
parent 265cdeddb7
commit ffd344ddbb
6 changed files with 8 additions and 16 deletions

View file

@ -60,8 +60,6 @@
void INTREN __P((u_int));
void INTRDIS __P((u_int));
#define INTRMASK(msk,s) (msk |= (s))
#define INTRUNMASK(msk,s) (msk &= ~(s))
#else /* APIC_IO */
@ -72,8 +70,6 @@ extern unsigned imen; /* interrupt mask enable */
#define INTREN(s) (imen &= ~(s), SET_ICUS())
#define INTRDIS(s) (imen |= (s), SET_ICUS())
#define INTRMASK(msk,s) (msk |= (s))
#define INTRUNMASK(msk,s) (msk &= ~(s))
#if 0
#ifdef PC98

View file

@ -635,13 +635,13 @@ update_masks(intrmask_t *maskptr, int irq)
if ((*maskptr & mask) == 0)
return;
/* the irq was included in the classes mask, remove it */
INTRUNMASK(*maskptr, mask);
*maskptr &= ~mask;
} else {
/* a reference to this maskptr was found in this irq's chain */
if ((*maskptr & mask) != 0)
return;
/* put the irq into the classes mask */
INTRMASK(*maskptr, mask);
*maskptr |= mask;
}
/* we need to update all values in the intr_mask[irq] array */
update_intr_masks();

View file

@ -635,13 +635,13 @@ update_masks(intrmask_t *maskptr, int irq)
if ((*maskptr & mask) == 0)
return;
/* the irq was included in the classes mask, remove it */
INTRUNMASK(*maskptr, mask);
*maskptr &= ~mask;
} else {
/* a reference to this maskptr was found in this irq's chain */
if ((*maskptr & mask) != 0)
return;
/* put the irq into the classes mask */
INTRMASK(*maskptr, mask);
*maskptr |= mask;
}
/* we need to update all values in the intr_mask[irq] array */
update_intr_masks();

View file

@ -60,8 +60,6 @@
void INTREN __P((u_int));
void INTRDIS __P((u_int));
#define INTRMASK(msk,s) (msk |= (s))
#define INTRUNMASK(msk,s) (msk &= ~(s))
#else /* APIC_IO */
@ -72,8 +70,6 @@ extern unsigned imen; /* interrupt mask enable */
#define INTREN(s) (imen &= ~(s), SET_ICUS())
#define INTRDIS(s) (imen |= (s), SET_ICUS())
#define INTRMASK(msk,s) (msk |= (s))
#define INTRUNMASK(msk,s) (msk &= ~(s))
#if 0
#ifdef PC98

View file

@ -635,13 +635,13 @@ update_masks(intrmask_t *maskptr, int irq)
if ((*maskptr & mask) == 0)
return;
/* the irq was included in the classes mask, remove it */
INTRUNMASK(*maskptr, mask);
*maskptr &= ~mask;
} else {
/* a reference to this maskptr was found in this irq's chain */
if ((*maskptr & mask) != 0)
return;
/* put the irq into the classes mask */
INTRMASK(*maskptr, mask);
*maskptr |= mask;
}
/* we need to update all values in the intr_mask[irq] array */
update_intr_masks();

View file

@ -635,13 +635,13 @@ update_masks(intrmask_t *maskptr, int irq)
if ((*maskptr & mask) == 0)
return;
/* the irq was included in the classes mask, remove it */
INTRUNMASK(*maskptr, mask);
*maskptr &= ~mask;
} else {
/* a reference to this maskptr was found in this irq's chain */
if ((*maskptr & mask) != 0)
return;
/* put the irq into the classes mask */
INTRMASK(*maskptr, mask);
*maskptr |= mask;
}
/* we need to update all values in the intr_mask[irq] array */
update_intr_masks();