wr32(hw, reg, (pat & mask));
val = rd32(hw, reg);
if ((val & mask) != (pat & mask)) {
-#ifdef ETHTOOL_TEST
- i40e_debug(hw, I40E_DEBUG_DIAG,
- "%s: reg pattern test failed - reg 0x%08x pat 0x%08x val 0x%08x\n",
- __func__, reg, pat, val);
-#endif
return I40E_ERR_DIAG_TEST_FAILED;
}
}
wr32(hw, reg, orig_val);
val = rd32(hw, reg);
if (val != orig_val) {
-#ifdef ETHTOOL_TEST
- i40e_debug(hw, I40E_DEBUG_DIAG,
- "%s: reg restore test failed - reg 0x%08x orig_val 0x%08x val 0x%08x\n",
- __func__, reg, orig_val, val);
-#endif
return I40E_ERR_DIAG_TEST_FAILED;
}