URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 297 |
Rev 338 |
struct GTeth_desc
|
struct GTeth_desc
|
{
|
{
|
unsigned ed_cmdsts;
|
unsigned ed_cmdsts;
|
};
|
};
|
struct GTeth_softc
|
struct GTeth_softc
|
{
|
{
|
struct GTeth_desc txq_desc[32];
|
struct GTeth_desc txq_desc[32];
|
unsigned int txq_fi;
|
unsigned int txq_fi;
|
unsigned int txq_nactive;
|
unsigned int txq_nactive;
|
};
|
};
|
|
|
void
|
void
|
GTeth_txq_free (struct GTeth_softc *sc)
|
GTeth_txq_free (struct GTeth_softc *sc)
|
{
|
{
|
struct GTeth_desc *txd = &sc->txq_desc[0];
|
struct GTeth_desc *txd = &sc->txq_desc[0];
|
txd->ed_cmdsts &= ~(1U << (31));
|
txd->ed_cmdsts &= ~(1U << (31));
|
}
|
}
|
void
|
void
|
GTeth_txq_done (struct GTeth_softc *sc)
|
GTeth_txq_done (struct GTeth_softc *sc)
|
{
|
{
|
while (sc->txq_nactive > 0)
|
while (sc->txq_nactive > 0)
|
{
|
{
|
volatile struct GTeth_desc *txd = &sc->txq_desc[sc->txq_fi];
|
volatile struct GTeth_desc *txd = &sc->txq_desc[sc->txq_fi];
|
if (txd->ed_cmdsts)
|
if (txd->ed_cmdsts)
|
{
|
{
|
if (sc->txq_nactive == 1)
|
if (sc->txq_nactive == 1)
|
return;
|
return;
|
}
|
}
|
GTeth_txq_free (sc);
|
GTeth_txq_free (sc);
|
}
|
}
|
}
|
}
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.