Re: [ANNOUNCE] Darkstar Development Project

2000-09-11 Thread Jonathan Lemon
In article [EMAIL PROTECTED]> you write: >On Mon, Sep 11, 2000 at 05:48:44PM -0500, Tony Mantler wrote: >> >> "It's the latency, stupid". I wouldn't care to argue whether CVS is slower >> than BK or not, but consider that if you had a router between you and the >> CVS server that was dropping eve

Re: [ANNOUNCE] Darkstar Development Project

2000-09-11 Thread Jonathan Lemon
On Mon, Sep 11, 2000 at 05:05:08PM -0700, Larry McVoy wrote: > On Mon, Sep 11, 2000 at 06:49:43PM -0500, Jonathan Lemon wrote: > > I don't know why I'm bothering to reply to this, but yes, if you're > > trying to synchronize CVS source trees with only CVS, it will be

Re: kqueue microbenchmark results

2000-10-24 Thread Jonathan Lemon
On Tue, Oct 24, 2000 at 09:45:14PM -0700, Dan Kegel wrote: > If you haven't already, you might peek at the discussion on > linux-kernel. Linus seems to be on the verge of adding > something like kqueue() to Linux, but appears opposed to > supporting level-triggering; he likes the simplicity of >

Re: kqueue microbenchmark results

2000-10-25 Thread Jonathan Lemon
On Wed, Oct 25, 2000 at 11:27:09AM -0400, Simon Kirby wrote: > On Wed, Oct 25, 2000 at 01:02:46AM -0500, Jonathan Lemon wrote: > > > Yes, someone pointed me to those today. I would suggest reading > > some of the relevant literature before embarking on a design. My > >

Re: kqueue microbenchmark results

2000-10-25 Thread Jonathan Lemon
On Wed, Oct 25, 2000 at 09:40:53PM +0200, Jamie Lokier wrote: > Simon Kirby wrote: > > And you'd need to take the descriptor out of the read() set in the > > select() case anyway, so I don't really see what's different. > > The difference is that taking a bit out of select()'s bitmap is > basical

Re: kqueue microbenchmark results

2000-10-25 Thread Jonathan Lemon
On Wed, Oct 25, 2000 at 11:40:28AM -0700, Simon Kirby wrote: > On Wed, Oct 25, 2000 at 12:23:07PM -0500, Jonathan Lemon wrote: > > > Consider a program which reads from point A, writes to point B. If > > the buffer associated with B fills up, then we don't want to cont

Re: kqueue microbenchmark results

2000-10-25 Thread Jonathan Lemon
On Wed, Oct 25, 2000 at 03:11:37PM -0700, David Schwartz wrote: > > > Now, next time around the loop, we get a notification for an event > > when there is no data to read. The application now must be prepared > > to handle this case (meaning no blocking read() calls can be used). > > -- > > Jona

Re: kqueue microbenchmark results

2000-10-26 Thread Jonathan Lemon
On Thu, Oct 26, 2000 at 02:16:28AM -0700, Gideon Glass wrote: > Jonathan Lemon wrote: > > > > Also, consider the following scenario for the proposed get_event(): > > > >1. packet arrives, queues an event. > >2. user retrieves event. > >3. se

Re: kqueue microbenchmark results

2000-10-26 Thread Jonathan Lemon
On Fri, Oct 27, 2000 at 01:50:40AM +0100, Alan Cox wrote: > > kqueue currently does this; a close() on an fd will remove any pending > > events from the queues that they are on which correspond to that fd. > > This seems an odd thing to do. Surely what you need to do is to post a > 'close complet

Re: Linux's implementation of poll() not scalable?

2000-10-26 Thread Jonathan Lemon
In article [EMAIL PROTECTED]> you write: >Linus Torvalds wrote: >> I'd much rather have an event interface that is documented to be edge- >> triggered and is really _lightweight_, than have another interface that >> starts out with some piggy features. > >Agreed (except for that 'edge-triggered' p

Re: [PATCH net-next 1/5] skbuff: rename fields of struct napi_alloc_cache to be more intuitive

2021-01-11 Thread Jonathan Lemon
On Mon, Jan 11, 2021 at 06:28:21PM +, Alexander Lobakin wrote: > skb_cache and skb_count fields are used to store skbuff_heads queued > for freeing to flush them by bulks, and aren't related to allocation > path. Give them more obvious names to improve code understanding and > allow to expand t

Re: [PATCH bpf-next v2 2/3] xdp: xdp_umem: replace kmap on vmap for umem map

2019-08-15 Thread Jonathan Lemon
On 15 Aug 2019, at 5:13, Ivan Khoronzhuk wrote: For 64-bit there is no reason to use vmap/vunmap, so use page_address as it was initially. For 32 bits, in some apps, like in samples xdpsock_user.c when number of pgs in use is quite big, the kmap memory can be not enough, despite on this, kmap lo

Re: [PATCH bpf-next v2 2/3] xdp: xdp_umem: replace kmap on vmap for umem map

2019-08-15 Thread Jonathan Lemon
On 15 Aug 2019, at 12:19, Ivan Khoronzhuk wrote: On Thu, Aug 15, 2019 at 11:23:16AM -0700, Jonathan Lemon wrote: On 15 Aug 2019, at 5:13, Ivan Khoronzhuk wrote: For 64-bit there is no reason to use vmap/vunmap, so use page_address as it was initially. For 32 bits, in some apps, like in

Re: [PATCH bpf-next v2 2/3] xdp: xdp_umem: replace kmap on vmap for umem map

2019-08-15 Thread Jonathan Lemon
, despite on this, kmap looks like is > deprecated in such cases as it can block and should be used rather > for dynamic mm. > > Signed-off-by: Ivan Khoronzhuk Acked-by: Jonathan Lemon

Re: [PATCH bpf 1/1] xdp: unpin xdp umem pages in error path

2019-08-15 Thread Jonathan Lemon
On 15 Aug 2019, at 13:56, Ivan Khoronzhuk wrote: > Fix mem leak caused by missed unpin routine for umem pages. > Fixes: 8aef7340ae9695 ("commit xsk: introduce xdp_umem_page") > > Signed-off-by: Ivan Khoronzhuk Acked-by: Jonathan Lemon

Re: [PATCH 4.14] tcp: fix tcp_rtx_queue_tail in case of empty retransmit queue

2019-08-24 Thread Jonathan Lemon
t; zero window. > > Patch is needed for 4.4, 4.9 and 4.14 stable branches. > > Fixes: 8c3088f895a0 ("tcp: be more careful in tcp_fragment()") > Change-Id: I839bde7167ae59e2f7d916c913507372445765c5 > Signed-off-by: Tim Froidcoeur > Signed-off-by: Matthieu Baerts > Reviewed-by: Christoph Paasch Acked-by: Jonathan Lemon

Re: [PATCH bpf-next v2 3/3] samples: bpf: syscal_nrs: use mmap2 if defined

2019-08-19 Thread Jonathan Lemon
On 15 Aug 2019, at 5:13, Ivan Khoronzhuk wrote: > For arm32 xdp sockets mmap2 is preferred, so use it if it's defined. > Declaration of __NR_mmap can be skipped and it breaks build. > > Signed-off-by: Ivan Khoronzhuk Acked-by: Jonathan Lemon > --- > samples/

Re: [PATCH bpf-next 1/3] libbpf: add asm/unistd.h to xsk to get __NR_mmap2

2019-08-13 Thread Jonathan Lemon
On 13 Aug 2019, at 3:23, Ivan Khoronzhuk wrote: > That's needed to get __NR_mmap2 when mmap2 syscall is used. > > Signed-off-by: Ivan Khoronzhuk Acked-by: Jonathan Lemon

Re: [PATCH bpf-next 3/3] samples: bpf: syscal_nrs: use mmap2 if defined

2019-08-13 Thread Jonathan Lemon
On 13 Aug 2019, at 3:23, Ivan Khoronzhuk wrote: > For arm32 xdp sockets mmap2 is preferred, so use it if it's defined. > > Signed-off-by: Ivan Khoronzhuk Doesn't this change the application API? -- Jonathan > --- > samples/bpf/syscall_nrs.c | 5 + > samples/bpf/tracex5_kern.c | 11 +

Re: [PATCH bpf-next 2/3] xdp: xdp_umem: replace kmap on vmap for umem map

2019-08-13 Thread Jonathan Lemon
On 13 Aug 2019, at 3:23, Ivan Khoronzhuk wrote: For 64-bit there is no reason to use vmap/vunmap, so use page_address as it was initially. For 32 bits, in some apps, like in samples xdpsock_user.c when number of pgs in use is quite big, the kmap memory can be not enough, despite on this, kmap

Re: [PATCH bpf-next 2/3] xdp: xdp_umem: replace kmap on vmap for umem map

2019-08-13 Thread Jonathan Lemon
On 13 Aug 2019, at 11:30, Ivan Khoronzhuk wrote: On Tue, Aug 13, 2019 at 10:42:18AM -0700, Jonathan Lemon wrote: On 13 Aug 2019, at 3:23, Ivan Khoronzhuk wrote: For 64-bit there is no reason to use vmap/vunmap, so use page_address as it was initially. For 32 bits, in some apps, like in

Re: [PATCH bpf-next] MAINTAINERS: add reviewer to maintainers entry

2019-06-24 Thread Jonathan Lemon
On 23 Jun 2019, at 22:24, Björn Töpel wrote: > From: Björn Töpel > > Jonathan Lemon has volunteered as an official AF_XDP reviewer. Thank > you, Jonathan! > > Signed-off-by: Björn Töpel Acked-by: Jonathan Lemon

Re: [PATCH] xsk: Properly terminate assignment in xskq_produce_flush_desc

2019-06-25 Thread Jonathan Lemon
nd everything works as expected. Fixes: c497176cb2e4 ("xsk: add Rx receive functions and poll support") Link: https://github.com/ClangBuiltLinux/linux/issues/544 Signed-off-by: Nathan Chancellor Nice find. Acked-by: Jonathan Lemon --- net/xdp/xsk_queue.h | 2 +- 1 file changed, 1 i

Re: [PATCH bpf v3] xdp: fix hang while unregistering device bound to xdp socket

2019-06-10 Thread Jonathan Lemon
On 10 Jun 2019, at 9:15, Ilya Maximets wrote: Device that bound to XDP socket will not have zero refcount until the userspace application will not close it. This leads to hang inside 'netdev_wait_allrefs()' if device unregistering requested: # ip link del p1 < hang on recvmsg on netlink soc

Re: [PATCH bpf] xdp: check device pointer before clearing

2019-06-10 Thread Jonathan Lemon
On 7 Jun 2019, at 10:27, Ilya Maximets wrote: We should not call 'ndo_bpf()' or 'dev_put()' with NULL argument. Fixes: c9b47cc1fabc ("xsk: fix bug when trying to use both copy and zero-copy on one queue id") Signed-off-by: Ilya Maximets Acked-by: Jonathan Lemon

Re: [PATCH] net: Fix hang while unregistering device bound to xdp socket

2019-06-06 Thread Jonathan Lemon
On 6 Jun 2019, at 5:40, Ilya Maximets wrote: > Device that bound to XDP socket will not have zero refcount until the > userspace application will not close it. This leads to hang inside > 'netdev_wait_allrefs()' if device unregistering requested: > > # ip link del p1 > < hang on recvmsg on net

Re: [PATCH bpf v5 1/2] xdp: hold device for umem regardless of zero-copy mode

2019-06-27 Thread Jonathan Lemon
Acked-by: Jonathan Lemon

Re: [PATCH bpf v5 2/2] xdp: fix hang while unregistering device bound to xdp socket

2019-06-27 Thread Jonathan Lemon
+ XSK_BINDED, + XSK_UNBINDED, + } state; I'd prefer that these were named better, perhaps: XSK_READY, XSK_BOUND, XSK_UNBOUND, Other than that: Acked-by: Jonathan Lemon -- Jonathan /* Protects multiple processes in the control path */ struct

Re: [PATCH bpf] xdp: fix potential deadlock on socket mutex

2019-07-08 Thread Jonathan Lemon
;xdp: fix hang while unregistering device bound to xdp socket") Signed-off-by: Ilya Maximets Thanks, Ilya! I think in the long run the locking needs to be revisited, but this should fix the deadlock for now. Acked-by: Jonathan Lemon This patch is a fix for patch that is not yet in

Re: [PATCH 1/4] dma-mapping: add a new dma_need_sync API

2020-07-07 Thread Jonathan Lemon
On Tue, Jul 07, 2020 at 08:47:30AM +0200, Christoph Hellwig wrote: > On Mon, Jul 06, 2020 at 12:42:27PM -0700, Jonathan Lemon wrote: > > On Mon, Jun 29, 2020 at 03:03:56PM +0200, Christoph Hellwig wrote: > > > Add a new API to check if calls to dma_sync_single_for_{device,cpu}

Re: [PATCH 1/4] dma-mapping: add a new dma_need_sync API

2020-07-06 Thread Jonathan Lemon
On Mon, Jun 29, 2020 at 03:03:56PM +0200, Christoph Hellwig wrote: > Add a new API to check if calls to dma_sync_single_for_{device,cpu} are > required for a given DMA streaming mapping. > > +:: > + > + bool > + dma_need_sync(struct device *dev, dma_addr_t dma_addr); > + > +Returns %true i

Re: [PATCH bpf-next] bpf: Fix build error without CONFIG_INET

2019-06-12 Thread Jonathan Lemon
x_accesses': > verifier.c: undefined reference to `bpf_xdp_sock_convert_ctx_access' > > Reported-by: Hulk Robot > Fixes: fada7fdc83c0 ("bpf: Allow bpf_map_lookup_elem() on an xskmap") > Signed-off-by: YueHaibing Acked-by: Jonathan Lemon

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-26 Thread Jonathan Lemon
[1] https://lore.kernel.org/netdev/20200626074725.ga21...@lst.de/ > > Cc: Christoph Hellwig > Fixes: 2b43470add8c ("xsk: Introduce AF_XDP buffer allocation API") > Signed-off-by: Björn Töpel Acked-by: Jonathan Lemon

[PATCH] linux/log2.h: enclose macro arg in parens

2020-06-23 Thread Jonathan Lemon
From: Jonathan Lemon roundup_pow_of_two uses its arg without enclosing it in parens. A call of the form: roundup_pow_of_two(boolval ? PAGE_SIZE : frag_size) resulted in an compile warning: warning: ?: using integer constants in boolean context [-Wint-in-bool-context