Re: [PATCH 9/9] net: vm deadlock avoidance core

2007-01-18 Thread Peter Zijlstra
On Thu, 2007-01-18 at 13:41 +0300, Evgeniy Polyakov wrote: > > > What about 'level-7' ack as you described in introduction? > > > > Take NFS, it does full data traffic in kernel. > > NFS case is exactly the situation, when you only need to generate an ACK. No it is not, it needs the full RPC re

Re: [PATCH 9/9] net: vm deadlock avoidance core

2007-01-18 Thread Evgeniy Polyakov
On Wed, Jan 17, 2007 at 10:07:28AM +0100, Peter Zijlstra ([EMAIL PROTECTED]) wrote: > > You operate with 'current' in different contexts without any locks which > > looks racy and even is not allowed. What will be 'current' for > > netif_rx() case, which schedules softirq from hard irq context - >

Re: [PATCH 0/9] VM deadlock avoidance -v10

2007-01-17 Thread Peter Zijlstra
On Wed, 2007-01-17 at 10:12 +0100, Pavel Machek wrote: > Hi! > > > These patches implement the basic infrastructure to allow swap over > > networked > > storage. > > > > The basic idea is to reserve some memory up front to use when regular memory > > runs out. > > > > To bound network behaviour

Re: [PATCH 0/9] VM deadlock avoidance -v10

2007-01-17 Thread Pavel Machek
Hi! > These patches implement the basic infrastructure to allow swap over networked > storage. > > The basic idea is to reserve some memory up front to use when regular memory > runs out. > > To bound network behaviour we accept only a limited number of concurrent > packets and drop those packe

Re: [PATCH 9/9] net: vm deadlock avoidance core

2007-01-17 Thread Peter Zijlstra
On Wed, 2007-01-17 at 07:54 +0300, Evgeniy Polyakov wrote: > On Tue, Jan 16, 2007 at 05:08:15PM +0100, Peter Zijlstra ([EMAIL PROTECTED]) > wrote: > > On Tue, 2007-01-16 at 18:33 +0300, Evgeniy Polyakov wrote: > > > On Tue, Jan 16, 2007 at 02:47:54PM +0100, Peter Zijlstra ([EMAIL > > > PROTECTED]

Re: [PATCH 9/9] net: vm deadlock avoidance core

2007-01-16 Thread Evgeniy Polyakov
On Tue, Jan 16, 2007 at 05:08:15PM +0100, Peter Zijlstra ([EMAIL PROTECTED]) wrote: > On Tue, 2007-01-16 at 18:33 +0300, Evgeniy Polyakov wrote: > > On Tue, Jan 16, 2007 at 02:47:54PM +0100, Peter Zijlstra ([EMAIL > > PROTECTED]) wrote: > > > > > + if (unlikely(skb->emergency)) > > > > > +

Re: [PATCH 9/9] net: vm deadlock avoidance core

2007-01-16 Thread Peter Zijlstra
On Tue, 2007-01-16 at 18:33 +0300, Evgeniy Polyakov wrote: > On Tue, Jan 16, 2007 at 02:47:54PM +0100, Peter Zijlstra ([EMAIL PROTECTED]) > wrote: > > > > + if (unlikely(skb->emergency)) > > > > + current->flags |= PF_MEMALLOC; > > > > > > Access to 'current' in netif_receive_

Re: [PATCH 9/9] net: vm deadlock avoidance core

2007-01-16 Thread Evgeniy Polyakov
On Tue, Jan 16, 2007 at 02:47:54PM +0100, Peter Zijlstra ([EMAIL PROTECTED]) wrote: > > > + if (unlikely(skb->emergency)) > > > + current->flags |= PF_MEMALLOC; > > > > Access to 'current' in netif_receive_skb()??? > > Why do you want to work with, for example keventd? > > Can this run i

Re: [PATCH 9/9] net: vm deadlock avoidance core

2007-01-16 Thread Peter Zijlstra
On Tue, 2007-01-16 at 16:25 +0300, Evgeniy Polyakov wrote: > On Tue, Jan 16, 2007 at 10:46:06AM +0100, Peter Zijlstra ([EMAIL PROTECTED]) > wrote: > > @@ -1767,10 +1767,23 @@ int netif_receive_skb(struct sk_buff *sk > > struct net_device *orig_dev; > > int ret = NET_RX_DROP; > > __be1

Re: [PATCH 9/9] net: vm deadlock avoidance core

2007-01-16 Thread Evgeniy Polyakov
On Tue, Jan 16, 2007 at 10:46:06AM +0100, Peter Zijlstra ([EMAIL PROTECTED]) wrote: > In order to provide robust networked storage there must be a guarantee > of progress. That is, the storage device must never stall because of > (physical) > OOM, because the device itself might be needed to get

[PATCH 0/9] VM deadlock avoidance -v10

2007-01-16 Thread Peter Zijlstra
These patches implement the basic infrastructure to allow swap over networked storage. The basic idea is to reserve some memory up front to use when regular memory runs out. To bound network behaviour we accept only a limited number of concurrent packets and drop those packets that are not aimed

[PATCH 9/9] net: vm deadlock avoidance core

2007-01-16 Thread Peter Zijlstra
In order to provide robust networked storage there must be a guarantee of progress. That is, the storage device must never stall because of (physical) OOM, because the device itself might be needed to get out of it (reclaim). This means that the device must always find enough memory to build/send

Re: [RFC][PATCH 6/6] net: vm deadlock avoidance core

2006-11-30 Thread Peter Zijlstra
Oops, it seems I missed some chunks. New patch attached. --- Subject: net: vm deadlock avoidance core In order to provide robust networked block devices there must be a guarantee of progress. That is, the block device must never stall because of (physical) OOM, because the device itself might be

Re: VM deadlock avoidance

2006-11-27 Thread David Miller
From: Peter Zijlstra <[EMAIL PROTECTED]> Date: Mon, 27 Nov 2006 15:06:25 +0100 > The patches definitely need more work but would you agree with the > general direction I'm working in or would you suggest yet another > direction? You're definitely going to have to wait at least a week or so before

VM deadlock avoidance

2006-11-27 Thread Peter Zijlstra
Hi Dave, I have a new version of these patches; I'm still using SOCK_VMIO socket tagging and skb->emergency marks, since I have not come up with another approach that might work and my RFC to netdev has so far been ignored. Other than this though, it changed quite a bit; - I now use the regular

Re: [PATCH 00/20] vm deadlock avoidance for NFS, NBD and iSCSI (take 7)

2006-09-12 Thread Nate Diller
On 9/12/06, Linus Torvalds <[EMAIL PROTECTED]> wrote: On Tue, 12 Sep 2006, Peter Zijlstra wrote: > > Linus, when I mentioned swap over network to you in Ottawa, you said it was > a valid use case, that people actually do and want this. Can you agree with > the approach taken in these patches?

Re: [PATCH 00/20] vm deadlock avoidance for NFS, NBD and iSCSI (take 7)

2006-09-12 Thread Linus Torvalds
On Tue, 12 Sep 2006, Peter Zijlstra wrote: > > Linus, when I mentioned swap over network to you in Ottawa, you said it was > a valid use case, that people actually do and want this. Can you agree with > the approach taken in these patches? Well, in all honesty, I don't think I really said "vali

[PATCH 00/20] vm deadlock avoidance for NFS, NBD and iSCSI (take 7)

2006-09-12 Thread Peter Zijlstra
-- Yet another instance of my networked swap patches. The patch-set consists of four parts: - patches 1-2; the basic 'framework' for deadlock avoidance - patches 3-9; implement swap over NFS - patches 10-13; implement swap over NBD - patches 14-20; implement swap over iSCSI The iSCSI work d

[PATCH 02/20] net: vm deadlock avoidance core

2006-09-12 Thread Peter Zijlstra
In order to provide robust networked block devices there must be a guarantee of progress. That is, the block device must never stall because of (physical) OOM, because the device itself might be needed to get out of it (reclaim). This means that the device queue must always be unplugable, this in

[PATCH 02/21] net: vm deadlock avoidance core

2006-09-06 Thread Peter Zijlstra
In order to provide robust networked block devices there must be a guarantee of progress. That is, the block device must never stall because of (physical) OOM, because the device itself might be needed to get out of it (reclaim). This means that the device queue must always be unplugable, this in

Re: [PATCH 1/4] net: VM deadlock avoidance framework

2006-08-29 Thread Indan Zupancic
On Tue, August 29, 2006 11:49, Peter Zijlstra said: > On Tue, 2006-08-29 at 02:01 +0200, Indan Zupancic wrote: >> Good that you're aware of it. Thing is, how much sense does the split-up into >> adjust_memalloc_reserve() and sk_adjust_memalloc() make at this point? Why >> not >> merge the code of

Re: [PATCH 1/4] net: VM deadlock avoidance framework

2006-08-29 Thread Peter Zijlstra
On Tue, 2006-08-29 at 02:01 +0200, Indan Zupancic wrote: > On Mon, August 28, 2006 19:32, Peter Zijlstra said: > > Ah, no accident there, I'm fully aware that there would need to be a > > spinlock in adjust_memalloc_reserve() if there were another caller. > > (I even had it there for some time) -

Re: [PATCH 1/4] net: VM deadlock avoidance framework

2006-08-28 Thread Indan Zupancic
On Mon, August 28, 2006 19:32, Peter Zijlstra said: > Also, I'm really past caring what the thing > is called ;-) But if ppl object I guess its easy enough to run yet > another sed command over the patches. True, same here. >> >> You can get rid of the memalloc_reserve and vmio_request_queues var

Re: [PATCH 1/4] net: VM deadlock avoidance framework

2006-08-28 Thread Peter Zijlstra
On Mon, 2006-08-28 at 18:03 +0200, Indan Zupancic wrote: > On Mon, August 28, 2006 12:22, Peter Zijlstra said: > >> > @@ -391,6 +391,7 @@ enum sock_flags { > >> > SOCK_RCVTSTAMP, /* %SO_TIMESTAMP setting */ > >> > SOCK_LOCALROUTE, /* route locally only, %SO_DONTROUTE setting */ >

Re: [PATCH 1/4] net: VM deadlock avoidance framework

2006-08-28 Thread Indan Zupancic
On Mon, August 28, 2006 12:22, Peter Zijlstra said: > On Sat, 2006-08-26 at 04:37 +0200, Indan Zupancic wrote: >> Why not 'emergency'? Looks like 'emerge' with a typo now. ;-) > > hehe, me lazy, you gentoo ;-) > sed -i -e 's/emerg/emregency/g' -e 's/EMERG/EMERGENCY/g' *.patch I used it for a while

Re: [PATCH 1/4] net: VM deadlock avoidance framework

2006-08-28 Thread Peter Zijlstra
On Sat, 2006-08-26 at 04:37 +0200, Indan Zupancic wrote: > On Fri, August 25, 2006 17:39, Peter Zijlstra said: > > @@ -282,7 +282,8 @@ struct sk_buff { > > nfctinfo:3; > > __u8pkt_type:3, > > fclone:2, > > -

Re: [PATCH 1/4] net: VM deadlock avoidance framework

2006-08-25 Thread Indan Zupancic
On Fri, August 25, 2006 17:39, Peter Zijlstra said: > @@ -282,7 +282,8 @@ struct sk_buff { > nfctinfo:3; > __u8pkt_type:3, > fclone:2, > - ipvs_property:1; > +

[PATCH 1/4] net: VM deadlock avoidance framework

2006-08-25 Thread Peter Zijlstra
The core of the VM deadlock avoidance framework. In order to provide robust networked block devices there must be a guarantee of progress. That is, the block device must never stall because of OOM because the device itself might be needed to get out of OOM (reclaim pageout). This means that the