/* Called during device stop to stop RX channel operation  */
static void emac_stop_rxch(struct emac_priv *priv, u32 ch)
/* Called during device stop to stop RX channel operation  */
static void emac_stop_rxch(struct emac_priv *priv, u32 ch)
{
	struct emac_rxch *rxch = priv->rxch[ch];
	if (rxch) {
		rxch->teardown_pending = 1;
		emac_write(EMAC_RXTEARDOWN, ch);
		emac_rxch_teardown(priv, ch);
		rxch->teardown_pending = 0;
		emac_write(EMAC_RXINTMASKCLEAR, BIT(ch));
	}
}