Re: [PATCH RFC 4/5] tun: vringfd xmit support.

2008-04-06 Thread Herbert Xu
can clone individual pages out of this skb and put it into a new skb. Therefore whatever scheme we come up with will either need to be page-based, or add a flag to tell the network stack that it can't clone those pages. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbe

[0/6] [NET]: virtio SG/TSO patches

2008-04-17 Thread Herbert Xu
G/TSO, and the other useful for testing SG per se. The other patch is to the KVM backend to make all this work. It isn't the prettiest or the smartest solution but it was the easiest :) Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]&

[1/6] [TUN]: Add GSO support

2008-04-17 Thread Herbert Xu
N_RECV_CSUM 0x0400 +#define TUN_RECV_GSO 0x0400 /* Ioctl defines */ #define TUNSETNOCSUM _IOW('T', 200, int) @@ -87,6 +90,9 @@ struct tun_struct { #define IFF_TAP0x0002 #define IFF_NO_PI 0x1000 #define IFF_ONE_QUEUE 0x2000 +#define IFF_VIRTIO_HDR 0x4000 +#defin

[2/6] [TUN]: Add GSO detection

2008-04-17 Thread Herbert Xu
e IFF_RECV_GSO 0x0800 +#define IFF_ALL_FLAGS (IFF_TUN | IFF_TAP | IFF_NO_PI | IFF_ONE_QUEUE | \ + IFF_VIRTIO_HDR | IFF_RECV_CSUM | IFF_RECV_GSO) struct tun_pi { unsigned short flags; -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EM

[3/6] [TUN]: Fix GSO mapping

2008-04-17 Thread Herbert Xu
rr = get_user_skb_frags(iv, count, sinfo->frags); + err = get_user_skb_frags(iv, count, sinfo); if (err < 0) goto fail; - sinfo->nr_frags = err; skb->len += len; skb->data_len += len; + skb->truesize += len;

[4/6] [KVM] virtio-net: Add SG/GSO support

2008-04-17 Thread Herbert Xu
e *vlan, const char *ifname1, s = net_tap_fd_init(vlan, fd); if (!s) return -1; + +s->gso = gso; snprintf(s->vc->info_str, sizeof(s->vc->info_str), "tap: ifname=%s setup_script=%s", ifname, setup_script); if (down_script &&

[5/6] [VIRTIO] net: Add ethtool ops for SG/GSO

2008-04-17 Thread Herbert Xu
"hardware" checksums? */ -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virt

[6/6] [VIRTIO] net: Allow receiving SG packets

2008-04-17 Thread Herbert Xu
skb_shinfo(skb)->nr_frags++; + } + num = skb_to_sgvec(skb, sg+1, 0, skb->len) + 1; skb_queue_head(&vi->recv, skb); -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROT

Re: [6/6] [VIRTIO] net: Allow receiving SG packets

2008-04-18 Thread Herbert Xu
On Sat, Apr 19, 2008 at 12:08:04AM +1000, Rusty Russell wrote: > On Friday 18 April 2008 13:24:27 Herbert Xu wrote: > > Finally this patch lets virtio_net receive GSO packets in addition > > to sending them. This can definitely be optimised for the non-GSO > > case. F

Re: [5/6] [VIRTIO] net: Add ethtool ops for SG/GSO

2008-04-21 Thread Herbert Xu
On Tue, Apr 22, 2008 at 05:01:46AM +1000, Rusty Russell wrote: > On Friday 18 April 2008 13:21:42 Herbert Xu wrote: > > +static int virtnet_change_mtu(struct net_device *dev, int mtu) > > +{ > > + int max = 65535 - ETH_HLEN; > > + > > + if (mtu >

Re: [6/6] [VIRTIO] net: Allow receiving SG packets

2008-04-21 Thread Herbert Xu
d just drop them if they show up. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Vi

Re: [PATCH 1/4] virtio: wean net driver off NETDEV_TX_BUSY

2008-04-28 Thread Herbert Xu
kb: we only queue one. */ > + kfree_skb(skb); > + goto stop_queue; We should increment the drop counter here. Otherwise these patches all look good to me. Acked-by: Herbert Xu <[EMAIL PROTECTED]> Thanks, -- Visit Openswan at http://www.openswa

Re: [PATCH 2/2] lguest: virtio-rng support

2008-05-16 Thread Herbert Xu
he guest at least unpredictable on start-up without increasing the guest's entropy, and use the host's random to actually increase the guest's entropy. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://go

Re: [PATCH 3/3] virtio_net: Fix skb->csum_start computation

2008-05-28 Thread Herbert Xu
Mark McLoughlin <[EMAIL PROTECTED]> Good catch! Clearly shows I never ran this across a real Ethernet device :) Acked-by: Herbert Xu <[EMAIL PROTECTED]> Thanks, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: htt

Re: [3/6] [TUN]: Fix GSO mapping

2008-05-29 Thread Herbert Xu
On Thu, May 29, 2008 at 11:32:51AM +0100, Mark McLoughlin wrote: > > Subject: [PATCH 1/1] tun: Do not use kmap_atomic() since memcpy_fromiovec() > can sleep > > Signed-off-by: Mark McLoughlin <[EMAIL PROTECTED]> Good catch! Thanks, -- Visit Openswan at http://www.openswa

Re: [PATCH 3/5] virtio net: Add ethtool ops for SG/GSO

2008-07-14 Thread Herbert Xu
On Mon, Jul 14, 2008 at 10:40:49PM -0500, Rusty Russell wrote: > From: Herbert Xu <[EMAIL PROTECTED]> > > This patch adds some basic ethtool operations to virtio_net so > I could test SG without GSO (which was really useful because TSO > turned out to be buggy :) > > S

Re: [PATCH 4/5] virtio net: Allow receiving SG packets

2008-07-14 Thread Herbert Xu
are forwarding packets which is totally unnecessary for virtio. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http:/

Re: [PATCH 4/5] virtio net: Allow receiving SG packets

2008-07-15 Thread Herbert Xu
On Tue, Jul 15, 2008 at 06:25:04PM +1000, Rusty Russell wrote: > > Oops. I grepped for LRO when I did this and found nothing. > > How's this one? Looks good. Thanks! -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROT

Re: [PATCH 3/4] tun: Allow GSO using virtio_net_hdr

2008-07-24 Thread Herbert Xu
, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtualization@

Re: [PATCH 2/2] virtio_net: Improve the recv buffer allocation scheme

2008-10-09 Thread Herbert Xu
> ... > > + memcpy(hdr, p, sizeof(*hdr)); > > + p += sizeof(*hdr); > > I think you need kmap_atomic() here to access the page. And yes, that will > effect performance :( No we don't. kmap would only be necessary for highmem which

Re: [PATCH] AF_VMCHANNEL address family for guest<->host communication.

2008-12-15 Thread Herbert Xu
I outlined in my response to Jeremy's last note. When combined with namespaces I don't see why using the kernel TCP stack would create any security problems that wouldn't otherwise exist. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Hom

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
read_wait altogether and just use socket.wait in tun_struct. Let me whip up a patch. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herber

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
On Wed, Apr 15, 2009 at 04:36:10PM +0800, Herbert Xu wrote: > > Let me whip up a patch. tun: Fix sk_sleep races when attaching/detaching As the sk_sleep wait queue actually lives in tfile, which may be detached from the tun device, bad things will happen when we use sk_sleep after det

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
calling poll_wait? Thanks, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtua

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
On Wed, Apr 15, 2009 at 09:46:10PM +0800, Herbert Xu wrote: > > Does anything actually rely on this behaviour? I doubt it :) > If not we should just change it to not do that. It appears that this was introduced in commit c70f182940f988448f3c12a209d18b1edc276e33 Author: Eric W. Bieder

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtualization@lists.linux-foundation.

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
the network namespace > exiting and destroying all of the virtual network devices before > we close the file handle. In that case what's the problem with holding a refcount to the unregistered device until the process owning the fd closes it? Cheers, -- Visit Openswan at http://www.openswan

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
ave to fix it whatever way we can. You can unfix it when you come back :) Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.o

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
uses sk_sleep can happen anywhere. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing lis

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
counter to tun_struct. We'd also change the async detach path to set a marker instead of detaching. That marker can then be checked in places like tun_get. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/

Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

2009-04-15 Thread Herbert Xu
t; less racy to deal with. As I said the difficulty with putting the socket in tun_file is how do you get it on the RX callback path without introducing new races. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herb

[2/2] tun: Fix sk_sleep races when attaching/detaching

2009-04-16 Thread Herbert Xu
On Thu, Apr 16, 2009 at 07:08:18PM +0800, Herbert Xu wrote: > > tun: Only free a netdev when all tun descriptors are closed With that patch we can now safely move read_wait. tun: Fix sk_sleep races when attaching/detaching As the sk_sleep wait queue actually lives in tfile, which

[1/2] tun: Only free a netdev when all tun descriptors are closed

2009-04-16 Thread Herbert Xu
On Wed, Apr 15, 2009 at 10:38:34PM +0800, Herbert Xu wrote: > > So how about this? We replace the dev destructor with our own that > doesn't immediately call free_netdev. We only call free_netdev once > all tun fd's attached to the device have been closed. Here's th

Re: [1/2] tun: Only free a netdev when all tun descriptors are closed

2009-04-16 Thread Herbert Xu
this purpose since it was already being used for that, albeit from the opposite angle. Note that we no longer zero tfile->tun since tun_get will return NULL anyway after the refcount on tfile hits zero. Instead it represents whether this device has ever been attached to a device. Signed-off-by: H

Re: [1/2] tun: Only free a netdev when all tun descriptors are closed

2009-04-18 Thread Herbert Xu
e refcount in tun->sk has been reappropriated for this purpose since it was already being used for that, albeit from the opposite angle. Note that we no longer zero tfile->tun since tun_get will return NULL anyway after the refcount on tfile hits zero. Instead it represents whether this dev

Re: [2/2] tun: Fix sk_sleep races when attaching/detaching

2009-04-20 Thread Herbert Xu
On Thu, Apr 16, 2009 at 07:09:52PM +0800, Herbert Xu wrote: > > tun: Fix sk_sleep races when attaching/detaching That patch doesn't apply anymore because of contextual changes caused by the first patch. Here's an update. tun: Fix sk_sleep races when attaching/detaching As t

Re: [2/2] tun: Fix sk_sleep races when attaching/detaching

2009-04-20 Thread Herbert Xu
On Mon, Apr 20, 2009 at 02:26:35AM -0700, David Miller wrote: > > Do you think these two patches are ready to go into net-2.6 > now? I think so. Thanks, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ P

Re: [1/2] tun: Only free a netdev when all tun descriptors are closed

2009-04-24 Thread Herbert Xu
On Fri, Apr 24, 2009 at 10:55:49AM +0200, Christian Borntraeger wrote: > Am Thursday 16 April 2009 13:08:18 schrieb Herbert Xu: > > > Here's the patch. I'd appreciate if everyone can review it > > and see if they can recreate the original race by > > > > 1

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-02 Thread Herbert Xu
o me. If we have to do this to fix a bug, sure. But just doing it for the sake of it smells wrong. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt __

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-02 Thread Herbert Xu
is just passing the problem to someone else, which is not nice at all. For example, anyone running tcpdump will now see the packet twice. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.ap

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-07 Thread Herbert Xu
ore you get a packet that overflows by looking at the amount of free queue space after transmitting each packet. For most drivers this is easy to do. What's so different about virtio-net that makes this impossible? Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-13 Thread Herbert Xu
ch case we should handle it > correctly). Most of them just do this: start_xmit: if (unlikely(queue is full)) { /* This should never happen. */ return TX_BUSY; } transmit if (queue is full) stop queue Cheers, -- Visit Openswan at http://www.openswan.org/ Email:

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-18 Thread Herbert Xu
27;t think we should reshape our APIs based on how broken the existing users are. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt __

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-18 Thread Herbert Xu
ated. As I have said repeatedly your driver should be checking the stop-queue condition after transmission, not before. In fact queueing it in the driver is just as bad as return TX_BUSY! Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gond

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-19 Thread Herbert Xu
because it's ugly and complex! The right solution is to stop the queue properly. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt __

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-22 Thread Herbert Xu
t a packet that is queued in this way. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mai

Re: [PATCH 2/4] virtio_net: return NETDEV_TX_BUSY instead of queueing an extra skb.

2009-06-22 Thread Herbert Xu
- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https:

Re: [PATCH 1/4] net: skb_orphan on dev_hard_start_xmit

2009-07-03 Thread Herbert Xu
need to the skb to be freed (e.g., iSCSI or Xen), this simply doesn't work. So anytime someone tries to propose such a solution it is a sign that they have bigger problems. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.

Re: [PATCH 1/4] net: skb_orphan on dev_hard_start_xmit

2009-07-03 Thread Herbert Xu
rg/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linux-foundation.org/mail

Re: [PATCH 1/4] net: skb_orphan on dev_hard_start_xmit

2009-07-04 Thread Herbert Xu
this flag when its socket buffer is close to capacity. Routing would set this flag per NAPI run, etc. Of course you'd ignore this flag completely if the qdisc queue is non-empty. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gon

Re: [PATCH 1/4] net: skb_orphan on dev_hard_start_xmit

2009-07-04 Thread Herbert Xu
On Sat, Jul 04, 2009 at 03:42:45PM +0800, Herbert Xu wrote: > > Here's an idea: We let the sender decide whether we need to enable > notification. This decision would be carried as a flag in the skb. > For example, UDP would set this flag when its socket buffer is close > t

Re: [PATCH 1/4] net: skb_orphan on dev_hard_start_xmit

2009-07-04 Thread Herbert Xu
On Sat, Jul 04, 2009 at 05:09:10PM +0800, Herbert Xu wrote: > > One potential problem is if the socket is constantly running > close to capacity, but that should only happen if the device > TX queue is also close to capacity which means that the qdisc > queue should be non-empty. H

Re: [PATCH 1/4] net: skb_orphan on dev_hard_start_xmit

2009-07-04 Thread Herbert Xu
On Sun, Jul 05, 2009 at 11:26:58AM +0800, Herbert Xu wrote: > > Here's a another crazy idea: > > Let's use dummy TX descriptors to generate an interrupt, either > with or without transmitting an actual packet on the wire depending > on the NIC. Here's an even cr

Re: [PATCH 1/4] net: skb_orphan on dev_hard_start_xmit

2009-08-18 Thread Herbert Xu
mation of turning interrupt notification off. Evidently that is not working in the way I intended it to. I'm in the process of repeating the same experiment with cxgb3 which hopefully should let me turn interrupts off on descriptors while still reporting completion status. Cheers, -- Vis

Re: [PATCH 22/25] xen: xen-netfront: use skb.cb for storing private data

2007-04-23 Thread Herbert Xu
e "cb" > field specifically for stashing this kind of info, so use it. > > Signed-off-by: Jeremy Fitzhardinge <[EMAIL PROTECTED]> > Cc: Herbert Xu <[EMAIL PROTECTED]> > Cc: Chris Wright <[EMAIL PROTECTED]> > Cc: Christian Limpach <[EMAIL PROTECTED]> Th

Re: [PATCH 23/25] xen: Lockdep fixes for xen-netfront

2007-04-23 Thread Herbert Xu
gt;if (unlikely(!netfront_carrier_ok(np))) { > - spin_unlock(&np->rx_lock); > + spin_unlock_bh(&np->rx_lock); You don't need to disable BH in netif_poll since it's always called with BH disabled. Cheers, -- Visit Openswan at http://www.o

Re: [PATCH 22/25] xen: xen-netfront: use skb.cb for storing private data

2007-04-23 Thread Herbert Xu
ECKSUM_PARTIAL in netfront is not going to stop netback from sending CHECKSUM_PARTIAL packets to us. If these packets are then routed/bridged back to netback, they'll have the wrong checksum. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL

Re: [PATCH 22/25] xen: xen-netfront: use skb.cb for storing private data

2007-04-27 Thread Herbert Xu
m0 patch to be applied as well? They can be applied separately so you don't need the dom0 part for your tree. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.a

Re: [PATCH 22/25] xen: xen-netfront: use skb.cb for storing private data

2007-04-27 Thread Herbert Xu
On Fri, Apr 27, 2007 at 04:27:21PM -0700, Jeremy Fitzhardinge wrote: > Herbert Xu wrote: > > They can be applied separately so you don't need the dom0 part for your > > tree. > > Great, thanks. BTW, the version I posted to you is missing the following line. Cheers,

Re: [PATCH 22/25] xen: xen-netfront: use skb.cb for storing private data

2007-04-29 Thread Herbert Xu
On Sun, Apr 29, 2007 at 12:43:33AM -0700, Jeremy Fitzhardinge wrote: > Herbert Xu wrote: > > BTW, the version I posted to you is missing the following line. > > > > --- linux-2.6.20.i386/drivers/xen/core/skbuff.c 2007-04-28 > > 15:30:16.0 +1000 > >

Re: [patch 31/32] xen: --- drivers/net/xen-netfront.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)

2007-05-02 Thread Herbert Xu
nt isn't just in a single patch? It makes it a bit hard to review having it scattered around like this. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.

Re: [patch 25/29] xen: Add the Xen virtual network device driver.

2007-05-05 Thread Herbert Xu
ce_detach. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing l

[1/2] [NET] link_watch: Move link watch list into net_device

2007-05-08 Thread Herbert Xu
gged thanks to an smp_mb__before_clear_bit. Signed-off-by: Herbert Xu <[EMAIL PROTECTED]> Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~h

[2/2] [NET] link_watch: Remove delay for up even when we're down

2007-05-08 Thread Herbert Xu
storms by only delaying down events and unnecssary up events. The latter is defined as up events when we're already up. Signed-off-by: Herbert Xu <[EMAIL PROTECTED]> Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Pa

Re: [1/2] [NET] link_watch: Move link watch list into net_device

2007-05-09 Thread Herbert Xu
n initial down->up transition, and so the > timing concern has been solved. > > Signed-off-by: Jeremy Fitzhardinge <[EMAIL PROTECTED]> > Cc: Herbert Xu <[EMAIL PROTECTED]> > Cc: Keir Fraser <[EMAIL PROTECTED]> Looks good to me. Thanks, -- Visit Openswan

Re: [patch 7/9] lguest: the net driver

2007-05-09 Thread Herbert Xu
to 1500. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing

Re: [patch 7/9] lguest: the net driver

2007-05-09 Thread Herbert Xu
Features kill puppies!" 8) Heh :) Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___

Re: [Xen-devel] Re: [kvm-devel] [PATCH RFC 1/3] virtio infrastructure

2007-06-04 Thread Herbert Xu
enswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtualization@list

Re: [kvm-devel] [PATCH RFC 1/3] virtio infrastructure

2007-06-04 Thread Herbert Xu
to one physical interface unless it contains IP fragments which should never happen for TCP. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~her

Re: [kvm-devel] [PATCH 3/6] virtio net driver

2007-09-21 Thread Herbert Xu
causes problems with AF_PACKET seeing things twice. Thanks, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___

Re: LFENCE instruction (was: [rfc][patch 3/3] x86: optimise barriers)

2007-10-16 Thread Herbert Xu
e can have these adopt the new SMP barriers on x86 instead of the IO ones as they currently do. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: htt

Re: [PATCH 2/3] virtio: Net header needs gso_hdr_len

2008-01-15 Thread Herbert Xu
gso_type |= SKB_GSO_DODGY; >skb_shinfo(skb)->gso_segs = 0; > + skb_set_transport_header(skb, hdr->gso_hdr_len); Why do we need this? When receiving GSO packets from an untrusted source the network stack will fill in the transport header offset after verifying that the headers are san

Re: [PATCH 2/3] virtio: Net header needs gso_hdr_len

2008-01-22 Thread Herbert Xu
nothing to do with GSO as you also need it for SG with large MTUs. I think this is more flexible than the Xen approach where this is essentially hard-coded to 64 bytes. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: htt

Re: [PATCH 2/3] virtio: Net header needs gso_hdr_len

2008-01-22 Thread Herbert Xu
just "hdr_len" rather than "gso_hdr_len"? Sounds fine to me. Thanks, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt __

Re: [PATCH] crypto: virtio-crypto: call finalize with bh disabled

2023-11-06 Thread Herbert Xu
e same as that of the network stack receive side. That means hard IRQ paths are unacceptable but softirq is OK. Cheers, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtua

Re: [PATCH 12/38] crypto: virtio: Replace deprecated CPU-hotplug functions.

2021-08-12 Thread Herbert Xu
tplug functions with the official version. > The behavior remains unchanged. > > Cc: Gonglei > Cc: "Michael S. Tsirkin" > Cc: Jason Wang > Cc: Herbert Xu > Cc: "David S. Miller" > Cc: virtualization@lists.linux-foundation.org > Cc: linux-cry

[PATCH] crypto: virtio - Use helper to set reqsize

2022-11-22 Thread Herbert Xu
The value of reqsize must only be changed through the helper. Signed-off-by: Herbert Xu diff --git a/drivers/crypto/virtio/virtio_crypto_akcipher_algs.c b/drivers/crypto/virtio/virtio_crypto_akcipher_algs.c index 168195672e2e..b2979be613b8 100644 --- a/drivers/crypto/virtio

Re: [PATCH] virtio-crypto: Do not use GFP_ATOMIC when not needed

2023-02-10 Thread Herbert Xu
letion(-) Patch applied. Thanks. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: [PATCH 8/9] x86/crypto: eliminate anonymous module_init & module_exit

2022-04-08 Thread Herbert Xu
r > implementation of serpent cipher") > Fixes: b9f535ffe38f ("[CRYPTO] twofish: i586 assembly version") > Fixes: ff0a70fe0536 ("crypto: twofish-x86_64-3way - module init/exit > functions should be static") > Fixes: 8280daad436e ("crypto: twofish - add 3-way para

Re: [PATCH v2 2/2] virtio: rng: ensure reads happen after successful probe

2014-07-10 Thread Herbert Xu
for data to arrive from > > the host, which never happens. > > > > CC: Kees Cook > > CC: Jason Cooper > > CC: Herbert Xu > > CC: # For v3.15+ > > Signed-off-by: Amit Shah > > --- > > drivers/char/hw_random/core.c | 6 ++ > >

Re: [PATCH v3 0/2] hwrng, virtio-rng: init-time fixes

2014-07-14 Thread Herbert Xu
init >callback don't contribute to system randomness more than once. The >weirdness is resolved here by using the randomness each time >hwrng_init() is attempted, irrespective of the existence of the >device's ->init() callback. All applied to crypt

Re: [PATCH v3 0/2] hwrng, virtio-rng: init-time fixes

2014-07-14 Thread Herbert Xu
On Tue, Jul 15, 2014 at 10:10:28AM +0530, Amit Shah wrote: > On (Mon) 14 Jul 2014 [20:50:06], Herbert Xu wrote: > > On Thu, Jul 10, 2014 at 03:42:33PM +0530, Amit Shah wrote: > > > v3: > > > - Kees Cook pointed out a weird side-effect: devices which have > > &

Re: [RFC PATCH 1/3] hw_random: allow RNG devices to give early randomness after a delay

2014-07-18 Thread Herbert Xu
gt; apparent reason. Seems like a far stretch, though. Does anyone else > > have an opinion on this? > > Herbert, do you have any preference? So it's only virtio-rng that's a problem, right? How about if we abuse the scan hook in virtio and move the hwrng_register there

Re: [PATCH v2 3/4] virtio: rng: delay hwrng_register() till driver is ready

2014-07-21 Thread Herbert Xu
turned is ENOMEM which isn't of much interest to the caller of probe anyway. On the other hand, if you are calling hwrng_register you better be damn sure that your hardware is ready to answer requests from the hwrng system. Please don't add silly flags to work around this. Cheers, -

Re: [PATCH v2 0/3] fix stuck in accessing hwrng attributes

2014-09-17 Thread Herbert Xu
not going to accept your fix which simply papers over the problem. Please bite the bullet and convert this over to RCU. Cheers, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt _

Re: [PATCH v2 4/6] hw_random: fix unregister race.

2014-10-21 Thread Herbert Xu
usty Russell You totally corrupted Rusty's patch. If you're going to repost his series you better make sure that you've got the right patches. Just as well though as it made me think a little more about this patch :) Cheers, -- Email: Herbert Xu Home Page: http://go

Re: [PATCH 3/5] hw_random: fix unregister race.

2014-10-21 Thread Herbert Xu
bviously better than what we have now, I don't believe this is 100% safe as the cleanup function might still be running even after the ref count hits zero. Once we return from this function the module may be unloaded so we need to ensure that nothing is runn

Re: [PATCH v2 4/6] hw_random: fix unregister race.

2014-10-31 Thread Herbert Xu
On Fri, Oct 31, 2014 at 10:28:00AM +1030, Rusty Russell wrote: > Herbert Xu writes: > > On Thu, Sep 18, 2014 at 08:37:45PM +0800, Amos Kong wrote: > >> From: Rusty Russell > >> > >> The previous patch added one potential problem: we can still be > >>

Re: [PATCH v2 4/6] hw_random: fix unregister race.

2014-11-02 Thread Herbert Xu
On Sun, Nov 02, 2014 at 11:06:13PM +0800, Amos Kong wrote: > On Fri, Oct 31, 2014 at 03:23:21PM +0800, Herbert Xu wrote: > > On Fri, Oct 31, 2014 at 10:28:00AM +1030, Rusty Russell wrote: > > > Herbert Xu writes: > > > > On Thu, Sep 18, 2014 at 08:37:45PM +0800,

Re: [PATCH v4 4/6] hw_random: fix unregister race.

2014-11-10 Thread Herbert Xu
leanup_done = true; Thanks, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoun

Re: [PATCH v4 4/6] hw_random: fix unregister race.

2014-11-11 Thread Herbert Xu
On Mon, Nov 10, 2014 at 09:47:27PM +0800, Herbert Xu wrote: > On Mon, Nov 03, 2014 at 11:56:24PM +0800, Amos Kong wrote: > > > > @@ -98,6 +99,8 @@ static inline void cleanup_rng(struct kref *kref) > > > > if (rng->cleanup) > > rng->cleanup

Re: [PATCH v5 0/6] fix hw_random stuck

2014-12-05 Thread Herbert Xu
On Sat, Dec 06, 2014 at 12:16:36PM +0800, Amos Kong wrote: > When I hotunplug a busy virtio-rng device or try to access > hwrng attributes in non-smp guest, it gets stuck. Please resend these via the linux-crypto mailing list so they can be picked up by patchwork. Thanks, -- Email: Herb

Re: [PATCH 8/9] virtio_pci: split out legacy device support

2014-12-16 Thread Herbert Xu
Restore module licence and other attributes When the virtio_pci driver was moved into virtio_pci_legacy.c the module licence and other attributes went AWOL. This patch restores them. Signed-off-by: Herbert Xu diff --git a/drivers/virtio/virtio_pci_legacy.c b/drivers/virtio/virtio_pci_legacy.

Re: [PATCH v5 REPOST 0/6] fix hw_random stuck

2014-12-22 Thread Herbert Xu
| use a fifo as rng backend, execute test 0 ~ 5 with no input of fifo All applied. Thanks a lot! -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization maili

Re: [PATCH v2 06/35] crypto: Use kmemdup rather than duplicating its implementation

2019-07-26 Thread Herbert Xu
11 +++ > drivers/crypto/virtio/virtio_crypto_algs.c | 4 +--- > 2 files changed, 4 insertions(+), 11 deletions(-) Patch applied. Thanks. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt __

Re: [PATCH v2 0/6] crypto: engine - Permit to enqueue all async requests

2018-02-15 Thread Herbert Xu
transfer_xxx_request_to_engine functions > > Corentin Labbe (6): > Documentation: crypto: document crypto engine API > crypto: engine - Permit to enqueue all async requests > crypto: omap: convert to new crypto engine API > crypto: virtio: convert to new crypto engine AP

Re: [PATCH v2 0/6] crypto: engine - Permit to enqueue all async requests

2018-02-16 Thread Herbert Xu
the patches to be squashed then please send them in one email. Thanks, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualization mailing list Virtualization@lists.linux-fou

Re: [PATCH] crypto: virtio - remove dependency on CRYPTO_AUTHENC

2018-03-16 Thread Herbert Xu
gt; > Fixes: dbaf0624ffa5 ("crypto: add virtio-crypto driver") > Signed-off-by: Peter Wu Patch applied. Thanks. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___

Re: [PATCH] crypto: virtio: Replace GFP_ATOMIC with GFP_KERNEL in __virtio_crypto_ablkcipher_do_req()

2018-08-03 Thread Herbert Xu
anually check the kernel code before reporting it. > > Signed-off-by: Jia-Ju Bai Patch applied. Thanks. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt ___ Virtualizati

Re: [v3,11/41] mips: reuse asm-generic/barrier.h

2016-01-18 Thread Herbert Xu
p? This is crazy! smp_rmb started out being strictly stronger than smp_read_barrier_depends, when did this stop being the case? -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt _

  1   2   >