コード例 #1
0
ファイル: efx_intr.c プロジェクト: Digital-Chaos/freebsd
static			void
falconsiena_intr_status_line(
	__in		efx_nic_t *enp,
	__out		boolean_t *fatalp,
	__out		uint32_t *qmaskp)
{
	efx_intr_t *eip = &(enp->en_intr);
	efx_dword_t dword;

	EFSYS_ASSERT3U(enp->en_magic, ==, EFX_NIC_MAGIC);
	EFSYS_ASSERT3U(enp->en_mod_flags, &, EFX_MOD_INTR);

	/*
	 * Read the queue mask and implicitly acknowledge the
	 * interrupt.
	 */
	EFX_BAR_READD(enp, FR_BZ_INT_ISR0_REG, &dword, B_FALSE);
	*qmaskp = EFX_DWORD_FIELD(dword, EFX_DWORD_0);

	EFSYS_PROBE1(qmask, uint32_t, *qmaskp);

	if (*qmaskp & (1U << eip->ei_level))
		*fatalp = falconsiena_intr_check_fatal(enp);
	else
		*fatalp = B_FALSE;
}
コード例 #2
0
ファイル: efx_intr.c プロジェクト: Digital-Chaos/freebsd
static			void
falconsiena_intr_status_message(
	__in		efx_nic_t *enp,
	__in		unsigned int message,
	__out		boolean_t *fatalp)
{
	efx_intr_t *eip = &(enp->en_intr);

	EFSYS_ASSERT3U(enp->en_magic, ==, EFX_NIC_MAGIC);
	EFSYS_ASSERT3U(enp->en_mod_flags, &, EFX_MOD_INTR);

	if (message == eip->ei_level)
		*fatalp = falconsiena_intr_check_fatal(enp);
	else
		*fatalp = B_FALSE;
}
コード例 #3
0
ファイル: efx_intr.c プロジェクト: fengsi/freebsd
			void
efx_intr_status_message(
	__in		efx_nic_t *enp,
	__in		unsigned int message,
	__out		boolean_t *fatalp)
{
	efx_intr_t *eip = &(enp->en_intr);

	EFSYS_ASSERT3U(enp->en_magic, ==, EFX_NIC_MAGIC);
	EFSYS_ASSERT3U(enp->en_mod_flags, &, EFX_MOD_INTR);

#if EFSYS_OPT_HUNTINGTON
	if (enp->en_family == EFX_FAMILY_HUNTINGTON) {
		/* Huntington reports fatal errors via events */
		*fatalp = B_FALSE;
		return;
	}
#endif
	if (message == eip->ei_level)
		*fatalp = falconsiena_intr_check_fatal(enp);
	else
		*fatalp = B_FALSE;
}
コード例 #4
0
ファイル: efx_intr.c プロジェクト: fengsi/freebsd
			void
efx_intr_status_line(
	__in		efx_nic_t *enp,
	__out		boolean_t *fatalp,
	__out		uint32_t *qmaskp)
{
	efx_intr_t *eip = &(enp->en_intr);
	efx_dword_t dword;

	EFSYS_ASSERT3U(enp->en_magic, ==, EFX_NIC_MAGIC);
	EFSYS_ASSERT3U(enp->en_mod_flags, &, EFX_MOD_INTR);

	/* Ensure Huntington and Falcon/Siena ISR at same location */
	EFX_STATIC_ASSERT(FR_BZ_INT_ISR0_REG_OFST ==
	    ER_DZ_BIU_INT_ISR_REG_OFST);

	/*
	 * Read the queue mask and implicitly acknowledge the
	 * interrupt.
	 */
	EFX_BAR_READD(enp, FR_BZ_INT_ISR0_REG, &dword, B_FALSE);
	*qmaskp = EFX_DWORD_FIELD(dword, EFX_DWORD_0);

	EFSYS_PROBE1(qmask, uint32_t, *qmaskp);

#if EFSYS_OPT_HUNTINGTON
	if (enp->en_family == EFX_FAMILY_HUNTINGTON) {
		/* Huntington reports fatal errors via events */
		*fatalp = B_FALSE;
		return;
	}
#endif
	if (*qmaskp & (1U << eip->ei_level))
		*fatalp = falconsiena_intr_check_fatal(enp);
	else
		*fatalp = B_FALSE;
}