]> git.droids-corp.org - dpdk.git/commitdiff
net/sfc/base: improve RxQ label init prototype
authorAndrew Rybchenko <arybchenko@solarflare.com>
Thu, 16 Nov 2017 08:04:06 +0000 (08:04 +0000)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 16 Jan 2018 17:47:49 +0000 (18:47 +0100)
RxQ type provides more information which may be useful to
setup event queue appropriately.

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
drivers/net/sfc/base/ef10_ev.c
drivers/net/sfc/base/ef10_impl.h
drivers/net/sfc/base/ef10_rx.c

index d9389dab6334404f5e075863d30cb11f7e5ac5cc..eb9ec759acbc59936c5def38d2a4f6987a0d76a4 100644 (file)
@@ -1336,9 +1336,11 @@ ef10_ev_rxlabel_init(
        __in            efx_evq_t *eep,
        __in            efx_rxq_t *erp,
        __in            unsigned int label,
-       __in            boolean_t packed_stream)
+       __in            efx_rxq_type_t type)
 {
        efx_evq_rxq_state_t *eersp;
+       boolean_t packed_stream = (type >= EFX_RXQ_TYPE_PACKED_STREAM_1M) &&
+           (type <= EFX_RXQ_TYPE_PACKED_STREAM_64K);
 
        EFSYS_ASSERT3U(label, <, EFX_ARRAY_SIZE(eep->ee_rxq_state));
        eersp = &eep->ee_rxq_state[label];
index d913c6cd7dc7efd284bf3cd0545fd4e570717e60..ad33da31d8696e9ddd3073ec419b126d95f76f85 100644 (file)
@@ -117,7 +117,7 @@ ef10_ev_rxlabel_init(
        __in            efx_evq_t *eep,
        __in            efx_rxq_t *erp,
        __in            unsigned int label,
-       __in            boolean_t packed_stream);
+       __in            efx_rxq_type_t type);
 
                void
 ef10_ev_rxlabel_fini(
index da1c6453ee7b7365f063a47b59a055450d39a1c5..53ea054909787a7458d3dc66825f730f1526690c 100644 (file)
@@ -978,7 +978,7 @@ ef10_rx_qcreate(
        erp->er_eep = eep;
        erp->er_label = label;
 
-       ef10_ev_rxlabel_init(eep, erp, label, ps_buf_size != 0);
+       ef10_ev_rxlabel_init(eep, erp, label, type);
 
        return (0);