From patchwork Sat Sep 29 11:28:00 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Ilias Apalodimas X-Patchwork-Id: 147835 Delivered-To: patch@linaro.org Received: by 2002:a2e:8595:0:0:0:0:0 with SMTP id b21-v6csp1815153lji; Sat, 29 Sep 2018 04:28:14 -0700 (PDT) X-Google-Smtp-Source: ACcGV60Du8gePk0X3kBEy39vj13iXQ336prKX5zJm2g9hYMtSp5UtGWDFfAXUR3tXoyilEwFPFUO X-Received: by 2002:a62:9992:: with SMTP id t18-v6mr2703196pfk.239.1538220493858; Sat, 29 Sep 2018 04:28:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538220493; cv=none; d=google.com; s=arc-20160816; b=ok5o0IntJYB0EQWoNO3q8hSVAw4hEEc2aJmqc6ibq7pgSaBpF6uWB7LNskW1vpbZZx +fBTSNE2wTBh4fQV3R9gwsaAaBqs3NjdAZ6Y7mAzlJQjEtLPXK2+lHa6yCgvSUC0DpY4 vTL1N8/+WhmA+7b2KqOuv3CNbZJ4dsuFOhxw+hYqSNOUK2vuiYo1YOVbveFG1S52LMVT HmM4W2g3jbEOCqYsVFJDfzhNrdkQcBvmAO553lSYURZz9jdRqc65YDbgUP57iYyogdYA GjQ0ko9I+mDuwFrhaTV6j49laQ4LlDnAUH7cnWEJRdWj3wZM+Nl/OxutuKYRAykbawuc 1KEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=m55m9LHV9zCwoZWtbkZ4pGKxII2lW9nWyi+s0pdzB7A=; b=UOGnE0oZGP/GGUfZ4RhbUF1NYJLJ7lRk2ph/jZdWF2P+3xjUCI1BUswSe79jKMGfsJ vxKjzvw9+b+OhUaEp5swEJkHUwN+5AhjGnw91PQvyUfAkKjM6WfpVTFdiY0a4f70G/gL HVJXum75ZjQOiEBF0xk3WfqSTmfKe5QUC/IrSY+E28vB3d7FCPdpjPC2TtkrcoPHOwq8 XxIDBVABIIUF1vUlrTQodqDyth/8ytEMk5x6hKlVg7KQMyzMLegbfS6mkLKsX4iWX1xp d+2rSr2T6GKO+plSriJEw1G2xoBgcMSYned8qSijhyzM0O5Ekd1ppWLfaMh9QQ1kdRce jJSw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=HVMqIL7T; spf=pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m76-v6si7494789pfg.323.2018.09.29.04.28.13; Sat, 29 Sep 2018 04:28:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=HVMqIL7T; spf=pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728066AbeI2R4R (ORCPT + 10 others); Sat, 29 Sep 2018 13:56:17 -0400 Received: from mail-wr1-f65.google.com ([209.85.221.65]:36341 "EHLO mail-wr1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727961AbeI2R4R (ORCPT ); Sat, 29 Sep 2018 13:56:17 -0400 Received: by mail-wr1-f65.google.com with SMTP id y16so684936wrw.3 for ; Sat, 29 Sep 2018 04:28:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=m55m9LHV9zCwoZWtbkZ4pGKxII2lW9nWyi+s0pdzB7A=; b=HVMqIL7T72xq5ZMQbQ4Y1PlERB9tRrDwSVc58F4zOtxMzBsnWcRPg+o29C/HjR3xIG UbmVcAiPOVfjG0Z3JpMsUQNR60oalJxfQ8IgfjIsIEBsN+XnBueg2PFI0NMISoxQLthp SIhSL9xEtusMAR9HLLdgiRbbh69FF6tURD7a0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=m55m9LHV9zCwoZWtbkZ4pGKxII2lW9nWyi+s0pdzB7A=; b=P6DhC5zY64Ip7sIRx5jsZMEdJAXHb2Krw+BcTLHAQdNFjyaqQAuBFQJJaIpHqpLI+b PPFZt5fFxV2H4fp1kvMIgQoT/f/Ik3+1krsxrpTpQMGI4yk9JqN26BrNF1gFpbWfH8TB fYUw1p1J3un5vGfO3P/fBVyQH5tPnyUClKWMD0Yb0UvXsdckoWqoKIibV8Lv9dGEOG0r cRNPANlCbxf6zdd6o/O9Hz6dMTGEj24XqcFWAZUSCzNniwrGnj/IwyBjHh9nMM3UVxi0 hKdrionRSvl57/+2P6U8LrKE4MaCPuQIX0iD8H1N/VmQU4W5BFmEE1tY2z/ViDO2ogIn oyGw== X-Gm-Message-State: ABuFfoiqXME2rOFiwmnbVqf7VifgZR4QeCD22SQfZ2k+1SXvFGfKNBIP vnLYypYOGGw04tCZxvjx2NCgN0Gw3mQ= X-Received: by 2002:adf:f506:: with SMTP id q6-v6mr1865000wro.241.1538220490116; Sat, 29 Sep 2018 04:28:10 -0700 (PDT) Received: from localhost.localdomain ([2a02:587:4603:8d00:2e56:dcff:fe9a:8f06]) by smtp.gmail.com with ESMTPSA id q5-v6sm6841080wmd.29.2018.09.29.04.28.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 29 Sep 2018 04:28:09 -0700 (PDT) From: Ilias Apalodimas To: netdev@vger.kernel.org, jaswinder.singh@linaro.org Cc: ard.biesheuvel@linaro.org, masami.hiramatsu@linaro.org, arnd@arndb.de, bjorn.topel@intel.com, magnus.karlsson@intel.com, brouer@redhat.com, daniel@iogearbox.net, ast@kernel.org, jesus.sanchez-palencia@intel.com, vinicius.gomes@intel.com, makita.toshiaki@lab.ntt.co.jp, Ilias Apalodimas Subject: [net-next, PATCH 0/2, v3] net: socionext: XDP support Date: Sat, 29 Sep 2018 14:28:00 +0300 Message-Id: <1538220482-16129-1-git-send-email-ilias.apalodimas@linaro.org> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org This patch series adds AF_XDP support socionext netsec driver In addition the new dma allocation scheme offers a 10% boost on Rx pps rate using 64b packets - patch [1/2]: Use a different allocation scheme for Rx DMA buffers to prepare the driver for AF_XDP support - patch [2/2]: Add XDP support without zero-copy test and performance numbers (64b packets): ------------------------------------------- - Normal SKBs on Rx: ~217kpps test: pktgen -> intel i210 -> netsec -> XDP_TX/XDP_REDIRECT - XDP_TX: 320kpps - XDP_REDIRECT: 320kpps qemu -> pktgen -> virtio -> ndo_xdp_xmit -> netsec - ndo_xdp_xmit: Could not send more than 120kpps. Interface forwarded that with success Changes since v2: - Always allocate Rx buffers with XDP_PACKET_HEADROOM Björn Töpel: - Added locking in the Tx queue Jesper Dangaard Brouer: - Added support for .ndo_xdp_xmit - XDP_TX does not flush every packet Changes since v1: - patch [2/2]: Toshiaki Makita: - Added XDP_PACKET_HEADROOM - Fixed a bug on XDP_PASS case - Using extact for error messaging instead of netdev_warn, when trying to setup XDP Ilias Apalodimas (2): net: socionext: different approach on DMA net: socionext: add XDP support drivers/net/ethernet/socionext/netsec.c | 541 +++++++++++++++++++++++++------- 1 file changed, 426 insertions(+), 115 deletions(-) -- 2.7.4