Re: [Qemu-devel] [PATCH 3/3] virtio_balloon: Bugfixes for PAGE_SIZE != 4k

2012-04-15 Thread Michael S. Tsirkin
On Fri, Apr 13, 2012 at 01:12:11PM +1000, David Gibson wrote: > On Thu, Apr 12, 2012 at 01:14:06PM +0300, Michael S. Tsirkin wrote: > > On Thu, Apr 12, 2012 at 03:36:35PM +1000, David Gibson wrote: > [snip] > > Good catch! > > > > Unfortunately I find the approach a bit convoluted. > > It also loo

Re: [Qemu-devel] [PATCH 3/3] virtio_balloon: Bugfixes for PAGE_SIZE != 4k

2012-04-12 Thread David Gibson
On Thu, Apr 12, 2012 at 01:14:06PM +0300, Michael S. Tsirkin wrote: > On Thu, Apr 12, 2012 at 03:36:35PM +1000, David Gibson wrote: [snip] > Good catch! > > Unfortunately I find the approach a bit convoluted. > It also looks like when host asks for 5 balloon pages > you interpret this as 0 where 1

Re: [Qemu-devel] [PATCH 3/3] virtio_balloon: Bugfixes for PAGE_SIZE != 4k

2012-04-12 Thread Michael S. Tsirkin
On Thu, Apr 12, 2012 at 03:36:35PM +1000, David Gibson wrote: > The virtio_balloon device is specced to always operate on 4k pages. The > virtio_balloon driver has a feeble attempt at reconciling this with a > lerge kernel page size, but it is (a) exactly wrong (it shifts the pfn in > the wrong di

[Qemu-devel] [PATCH 3/3] virtio_balloon: Bugfixes for PAGE_SIZE != 4k

2012-04-11 Thread David Gibson
The virtio_balloon device is specced to always operate on 4k pages. The virtio_balloon driver has a feeble attempt at reconciling this with a lerge kernel page size, but it is (a) exactly wrong (it shifts the pfn in the wrong direction) and (b) insufficient (it doesn't issue multiple 4k balloon re