From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f46.google.com (mail-wm0-f46.google.com [74.125.82.46]) by dpdk.org (Postfix) with ESMTP id 59F8A1B210 for ; Sat, 11 Nov 2017 18:18:48 +0100 (CET) Received: by mail-wm0-f46.google.com with SMTP id l8so2489732wmg.4 for ; Sat, 11 Nov 2017 09:18:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:content-transfer-encoding:mime-version:subject:message-id:date :to; bh=Cvy0yxdWgd91BShHe+A3VOtcGGoANsl7FX3EpwQJ0uA=; b=MEVKQbmrtWFOsTvFK0V6m36CGmqp7ncBLY9+YXGKIfKjb6C26m5uYloFP3XPLLHQFm IvYJJjcUlAC68G6usQdmhmuKVmDHy0hgL8PpkNrjTfXC1LQ42d2/hGL4wfeca4tnAVxe h1XAY5wTQhOJRzlWVH/w5yggiSRb4prN2ByMeKKBWJGc/5ufYb/s8rTNDLM+HcmA8G6h Zib0/wG8HgLBOVeAQayeCs6V55oRVV+ycOHI879TIWKriiN5iPLXgfA+saJSs3qi2M4I lc+9cBoB12kdgYHFia+x7y2UMGMXOcRoGPYLyN0TSmFlKvAjfQC8TGuis5vECMgjurd2 COmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:content-transfer-encoding:mime-version :subject:message-id:date:to; bh=Cvy0yxdWgd91BShHe+A3VOtcGGoANsl7FX3EpwQJ0uA=; b=X4DXJxAn4jJTW+dO1AtQ6Y1W7Xal+Zj8G+MFsP1/DwWle7OICNEzvtVeor74E0ooTb lTOurKpbhk7B7pRV4uf78OpLTF9nyqOA4xlWM6YQTSAM5Rcl0RtmLBno2IjqWzIFuDif 5o0Mn/K/SFWdc/Msr/YBj7sEqYmt9W8RbF/sZ9TXqTXPQQA5z9+pwaE89lkVDhKkssSU qNrrolS5POakGFaxsKCb+ed+w6plEb8HfQOtm7Ev8jDF6DOmv6AHN2Ub92Tdwv2MKpup n0QQ8djTn900iMaL6mS360zAqiLGJvgGKFpvqZhFZ7hnvvOya4mQ9DMm0gdS240+eKPv 5V7w== X-Gm-Message-State: AJaThX4g9qA0gw75uu0VEBVA/eLejasla5MbxHuDD9RGf9FmfmXm6a3R mcr6yu+nYPg4jD2UyoIaCWeGbMm2 X-Google-Smtp-Source: AGs4zMZaPMjzPlswoj0+TJkk9UdTtZn3QTd36fZMaIkTDiEDkgh39FycHCePYi6wElCNvgtq4i8CPw== X-Received: by 10.80.141.18 with SMTP id s18mr5749259eds.241.1510420727914; Sat, 11 Nov 2017 09:18:47 -0800 (PST) Received: from [192.168.1.145] ([94.205.75.192]) by smtp.gmail.com with ESMTPSA id m7sm11682599eda.91.2017.11.11.09.18.46 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 11 Nov 2017 09:18:47 -0800 (PST) From: Ilya Matveychikov Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\)) Message-Id: <2259E047-80C0-40AC-AAF4-F21617605508@gmail.com> Date: Sat, 11 Nov 2017 21:18:45 +0400 To: dev@dpdk.org X-Mailer: Apple Mail (2.3273) Subject: [dpdk-dev] A question about (poor) rte_ethdev internal rx/tx callbacks design X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Nov 2017 17:18:48 -0000 Folks, Are you serious with it: typedef uint16_t (*eth_rx_burst_t)(void *rxq, struct rte_mbuf **rx_pkts, uint16_t nb_pkts); typedef uint16_t (*eth_tx_burst_t)(void *txq, struct rte_mbuf **tx_pkts, uint16_t nb_pkts); I=E2=80=99m not surprised that every PMD stores port_id in every and = each queue as having just the queue as an argument doesn=E2=80=99t allow = to get the device. So the question is - why not to use something like: typedef uint16_t (*eth_rx_burst_t)(void *dev, uint16_t queue_id, struct rte_mbuf **rx_pkts, uint16_t nb_pkts); typedef uint16_t (*eth_tx_burst_t)(void *dev, uint16_t queue_id, struct rte_mbuf **tx_pkts, uint16_t nb_pkts); Ilya.