FreeBSD/sys/dev/cxgbe/common/t4_hw.c
/*
 * Return TRUE if the specified firmware matches the adapter.  I.e. T4
 * firmware for T4 adapters, T5 firmware for T5 adapters, etc.  We go ahead
 * and emit an error message for mismatched firmware to save our caller the
 * effort ...
 */
Return TRUE if the specified firmware matches the adapter.
Return TRUE if the specified firmware matches the adapter .
static int t4_fw_matches_chip(struct adapter *adap,
			      const struct fw_hdr *hdr)
{
	if ((is_t4(adap) && hdr->chip == FW_HDR_CHIP_T4) ||
	    (is_t5(adap) && hdr->chip == FW_HDR_CHIP_T5) ||
	    (is_t6(adap) && hdr->chip == FW_HDR_CHIP_T6))
		return 1;
	CH_ERR(adap,
		"FW image (%d) is not suitable for this adapter (%d)\n",
		hdr->chip, chip_id(adap));
	return 0;
}
static int t4_fw_matches_chip ( struct adapter * adap , const struct fw_hdr * hdr ) { if ( ( is_t4 ( adap ) && hdr -> chip == FW_HDR_CHIP_T4 ) || ( is_t5 ( adap ) && hdr -> chip == FW_HDR_CHIP_T5 ) || ( is_t6 ( adap ) && hdr -> chip == FW_HDR_CHIP_T6 ) ) return 1 ; CH_ERR ( adap , " \n " , hdr -> chip , chip_id ( adap ) ) ; return 0 ; }
Return TRUE if the specified firmware matches the adapter.
Return TRUE if the specified firmware matches the adapter .
/*
	 * The expression below will return FALSE for any unsupported adapter
	 * which will keep us "honest" in the future ...
	 */