dpaa: Add "libbsd,dedicated-portal" to QMan portals

By default, the network interfaces use a pool channel, see
dpaa_get_channel() in dpaa_eth_priv_probe().  To enable a dedicated QMan
software portal, use libbsd,dedicated-portal = "enabled";.  This option
is useful for special purpose 10Gbit/s Ethernet processing.

/ {
        soc: soc@ffe000000 {
                fman0: fman@400000 {
                        enet7: ethernet@f2000 {
                                libbsd,dedicated-portal = "enabled";
                        };
                };
        };
};
This commit is contained in:
Sebastian Huber
2017-07-13 08:31:46 +02:00
parent e818128789
commit de5791b345
9 changed files with 124 additions and 0 deletions

View File

@@ -40,6 +40,8 @@ struct mbuf;
struct dpaa_priv *dpaa_get_priv_of_ifp(struct ifnet *);
int dpaa_get_qman_portal_irq_of_ifp(struct ifnet *);
typedef struct {
size_t count;
struct bm_buffer bmb[8];

View File

@@ -590,3 +590,12 @@ dpaa_get_priv_of_ifp(struct ifnet *ifp)
sc = ifp->if_softc;
return (netdev_priv(&sc->mac_dev.net_dev));
}
int
dpaa_get_qman_portal_irq_of_ifp(struct ifnet *ifp)
{
struct fman_mac_softc *sc;
sc = ifp->if_softc;
return (qman_portal_get_irq(sc->mac_dev.portal));
}