Received: by 2002:a25:f815:0:0:0:0:0 with SMTP id u21csp3153907ybd; Mon, 24 Jun 2019 20:28:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqwf3hFNe6wQeef9gBlG7ig7OzD5nRtAybZgnG23v5Y9194ZF8zIQm2gWtC5JCkFS26QikeJ X-Received: by 2002:a63:d4c:: with SMTP id 12mr8467837pgn.30.1561433338842; Mon, 24 Jun 2019 20:28:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561433338; cv=none; d=google.com; s=arc-20160816; b=zHKp1KYHbOKVyhzYB96bhkU+HP9dwCLvsAedi3S3Ly/thkKjJ7Ec/Gg25nFz48ol1f m8mEk5o5Jbc61bvV0az89qmw+9mO4R0G4fJK4MS8ToGjPns1O7XDmIMEl9OA0G/9NUyS qm+xiI3pAxO4uZLshCZb/xElbXVpFc0Bvpbk9mnctW82AsjFHE+eriHYdRlS+HZ22C1D UMKEwTlrhT0zZEqx2r2+6U4EXhZQqAn74hmj9xXiEJx4svV9gCzA2oUObYfebrLpYqhY Hsa6PQtJSqR8iAqjjesIy4LOqHT9vBsknJBfvUIUJqolu9CJmtlqvH8a7NhgFQAz0g9S +6oA== 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 :organization:references:in-reply-to:message-id:subject:cc:to:from :date:dkim-signature; bh=l+t11w+lYzgMdf9afpAfNi/wBZxJpJdB0Y+rhM6lHks=; b=IwYGZe9psiZLTZjeGGznwn5LKajKicI4/0CCrbzbZKC5tR008X5ahekYd6M5A3VAQS PPaKiw49zMd6fubjUNhAuYYpL5MTb1gCtnNAgfqiseX6C7z4QAE5BHKKC9IGlnR7WMLa KgsPS/oBPPMgyQxuiB9B6FwVeXIiM2t0A13Qwrqep6B+YWjFOH5wrH91hCMTs6YcqEmz 922xive5pUVJ2BrVH62U3evntF1Oeg4Q29BIt31Zw83vUnndKyLAF4XhWEqe7qWoOsu6 DXClQOquzte6N+/5UwgMHYE732Vd9G8sSC7cQQwK7KIv/1NTg45eqGDsvxi2jGkrvSYZ T0dw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@netronome-com.20150623.gappssmtp.com header.s=20150623 header.b=1JNiS8o8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l1si12772075pgj.504.2019.06.24.20.28.43; Mon, 24 Jun 2019 20:28:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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=@netronome-com.20150623.gappssmtp.com header.s=20150623 header.b=1JNiS8o8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726931AbfFXWqD (ORCPT + 99 others); Mon, 24 Jun 2019 18:46:03 -0400 Received: from mail-qk1-f195.google.com ([209.85.222.195]:37740 "EHLO mail-qk1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726567AbfFXWqD (ORCPT ); Mon, 24 Jun 2019 18:46:03 -0400 Received: by mail-qk1-f195.google.com with SMTP id d15so11083748qkl.4 for ; Mon, 24 Jun 2019 15:46:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=netronome-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :organization:mime-version:content-transfer-encoding; bh=l+t11w+lYzgMdf9afpAfNi/wBZxJpJdB0Y+rhM6lHks=; b=1JNiS8o8LLcLGJ7yDeuoGqe7R53WxwUnBJ473OA/Sj94hjFkUtbMZgxLmpjtFcBKa6 N8tfCq4i4n89X7x24u4RaZsPtxHqdSZxpQvXnuae5hnCD5wud1xsEgxlwfhTEoVI9cPt g3jQIXuW7CiLlgUVdgWO8zSkn1nQjlMb25O4W634mUf1mJezM/d1gtgwSbKc319j57bs dLGovYfEKNj36SFTmOEAS+n8b5B1My2OgGKfdHQcGOBv6EgC/AuW1Oqplc0bR0zzeUgo jYXXxiIhD1iH9bA0rFt9Qmmx+ThDGH8ng7MqzQSE2+OlYR7eeju/cBxmDLZn9ZaILbBX PPLw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:organization:mime-version:content-transfer-encoding; bh=l+t11w+lYzgMdf9afpAfNi/wBZxJpJdB0Y+rhM6lHks=; b=NjZo/l6wYrqynOYKMdTj30aJLOyJr09+HwvpPZ2zV7GI8wG+RjCwlui7qsh0kmje8h ckhmbmznHZbWJFCJ048fHmEy9ID2CXaqL+1POLl5UnkkWqOAX1o3M3aOfX3w+Oj67xk1 oxHYjDU7wzgu5rPWsEHssIzpw97+oO21TQtGGGCmdY21lFgCwzXNvEYW58XCGydNpS33 NhbenDRnXdUwDMeXfR3MC+gO5Rcx9Wwx+C378gf8vkKuDC9/ZEMm5txDIm2GhXr3ZgIF cfr4EFIej/ncCOdQK0UdZ38JbbQZLXEgq4AN9+mdNAETyzgC4XnKnTKWvrNEvWdZ/F6T Eq8A== X-Gm-Message-State: APjAAAXinVkb6oWnfRlLuXXvegQvNSgaeQTfKQO8fGX7POBU0hYHoKhv sIAhhdS6xRZbNTqEfFyPYXYDvQ== X-Received: by 2002:ae9:e608:: with SMTP id z8mr114743476qkf.182.1561416362271; Mon, 24 Jun 2019 15:46:02 -0700 (PDT) Received: from cakuba.netronome.com ([66.60.152.14]) by smtp.gmail.com with ESMTPSA id k40sm7384209qta.50.2019.06.24.15.46.00 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:46:02 -0700 (PDT) Date: Mon, 24 Jun 2019 15:45:58 -0700 From: Jakub Kicinski To: Brian Vazquez Cc: Brian Vazquez , Alexei Starovoitov , Daniel Borkmann , "David S . Miller" , Stanislav Fomichev , Willem de Bruijn , Petar Penkov , linux-kernel@vger.kernel.org, netdev@vger.kernel.org, bpf@vger.kernel.org Subject: Re: [RFC PATCH 2/6] bpf: add BPF_MAP_DUMP command to access more than one entry per call Message-ID: <20190624154558.65c31561@cakuba.netronome.com> In-Reply-To: <20190621231650.32073-3-brianvv@google.com> References: <20190621231650.32073-1-brianvv@google.com> <20190621231650.32073-3-brianvv@google.com> Organization: Netronome Systems, Ltd. MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 21 Jun 2019 16:16:46 -0700, Brian Vazquez wrote: > @@ -385,6 +386,14 @@ union bpf_attr { > __u64 flags; > }; > > + struct { /* struct used by BPF_MAP_DUMP command */ > + __u32 map_fd; There is a hole here, perhaps flags don't have to be 64 bit? > + __aligned_u64 prev_key; > + __aligned_u64 buf; > + __aligned_u64 buf_len; /* input/output: len of buf */ > + __u64 flags; > + } dump; > + > struct { /* anonymous struct used by BPF_PROG_LOAD command */ > __u32 prog_type; /* one of enum bpf_prog_type */ > __u32 insn_cnt;