[Qemu-devel] [PATCH v2] allwinner-a10: add config script support

2013-12-25 Thread liguang
sunxi-linux kernel parses a special config script to do hardware configuration, bootloader loads script into fixed RAM address, then kernel will learn from it. this script is transformed from a text script into binary by a tool. reference: http://linux-sunxi.org/Sunxi-tools script file address:

Re: [Qemu-devel] [PATCHv4] block: add native support for NFS

2013-12-25 Thread ronnie sahlberg
On Wed, Dec 25, 2013 at 9:42 PM, Fam Zheng wrote: > On 2013年12月21日 00:04, Peter Lieven wrote: >> >> This patch adds native support for accessing images on NFS shares without >> the requirement to actually mount the entire NFS share on the host. >> >> NFS Images can simply be specified by an url of

Re: [Qemu-devel] [PATCHv4] block: add native support for NFS

2013-12-25 Thread Fam Zheng
On 2013年12月21日 00:04, Peter Lieven wrote: This patch adds native support for accessing images on NFS shares without the requirement to actually mount the entire NFS share on the host. NFS Images can simply be specified by an url of the form: nfs: For example: qemu-img create -f qcow2 nfs://

[Qemu-devel] [PATCH] acpi unit-test: Remove temporary disk after test

2013-12-25 Thread Fam Zheng
Signed-off-by: Fam Zheng --- tests/acpi-test.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/acpi-test.c b/tests/acpi-test.c index ca83b1d6..df1af83 100644 --- a/tests/acpi-test.c +++ b/tests/acpi-test.c @@ -382,6 +382,7 @@ int main(int argc, char *argv[]) {

Re: [Qemu-devel] [PATCH v2 10/24] block: Introduce bdrv_co_do_preadv()

2013-12-25 Thread Wenchao Xia
> /* throttling disk I/O */ > if (bs->io_limits_enabled) { > -bdrv_io_limits_intercept(bs, nb_sectors, false); > +bdrv_io_limits_intercept(bs, bytes >> BDRV_SECTOR_BITS, false); > +} Is it possible (bytes >> BDRV_SECTOR_BITS) == 0? >

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Li Guang
Peter Maydell wrote: On 26 December 2013 01:09, Peter Crosthwaite wrote: Can you just provide a generic solution to the "blob some random data into RAM" problem (If one doesn't exist already)? Well, we do already have that (see -machine firmware=whatever), but... Yes, right.

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Peter Maydell
On 26 December 2013 01:09, Peter Crosthwaite wrote: > Can you just provide a generic solution to the "blob some random data > into RAM" problem (If one doesn't exist already)? Well, we do already have that (see -machine firmware=whatever), but... > I think your binary file here can then just be

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Li Guang
Peter Crosthwaite wrote: On Thu, Dec 26, 2013 at 10:47 AM, Peter Maydell wrote: On 26 December 2013 00:39, Li Guang wrote: Peter Maydell wrote: On 26 December 2013 00:14, Li Guang wrote: it's the approach sunxi-linux kernel config hardware, the binary is actua

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Peter Crosthwaite
On Thu, Dec 26, 2013 at 10:47 AM, Peter Maydell wrote: > On 26 December 2013 00:39, Li Guang wrote: >> Peter Maydell wrote: >>> >>> On 26 December 2013 00:14, Li Guang wrote: it's the approach sunxi-linux kernel config hardware, the binary is actually a transformed text script, an

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Li Guang
Peter Maydell wrote: On 26 December 2013 00:39, Li Guang wrote: Peter Maydell wrote: On 26 December 2013 00:14, Li Guang wrote: it's the approach sunxi-linux kernel config hardware, the binary is actually a transformed text script, and context of script is like: [card0_bo

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Peter Maydell
On 26 December 2013 00:39, Li Guang wrote: > Peter Maydell wrote: >> >> On 26 December 2013 00:14, Li Guang wrote: >>> it's the approach sunxi-linux kernel config hardware, >>> the binary is actually a transformed text script, >>> and context of script is like: >>> >>> [card0_boot_para] >>> card_

Re: [Qemu-devel] [PATCH] hw/sd: move sdhci.h to include/hw

2013-12-25 Thread Li Guang
Peter Maydell wrote: On 26 December 2013 00:22, Li Guang wrote: Peter Maydell wrote: On 25 December 2013 07:21, liguang wrote: This is where your patch should have had an explanation for why you're making this change. What is the user outside of hw/sd/ that needs this header that m

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Li Guang
Peter Maydell wrote: On 26 December 2013 00:14, Li Guang wrote: Peter Maydell wrote: On 25 December 2013 08:35, liguang wrote: sunxi-linux kernel parse config script to do hardware configurations Signed-off-by: liguang --- hw/arm/allwinner-a10.c | 18 +++

Re: [Qemu-devel] [PATCH] hw/sd: move sdhci.h to include/hw

2013-12-25 Thread Peter Maydell
On 26 December 2013 00:22, Li Guang wrote: > Peter Maydell wrote: >> On 25 December 2013 07:21, liguang wrote: >> This is where your patch should have had an explanation >> for why you're making this change. What is the user outside >> of hw/sd/ that needs this header that means we should >> move

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Peter Maydell
On 26 December 2013 00:14, Li Guang wrote: > Peter Maydell wrote: >> >> On 25 December 2013 08:35, liguang wrote: >> >>> >>> sunxi-linux kernel parse config script >>> to do hardware configurations >>> >>> Signed-off-by: liguang >>> --- >>> hw/arm/allwinner-a10.c | 18

Re: [Qemu-devel] [PATCH] hw/sd: move sdhci.h to include/hw

2013-12-25 Thread Li Guang
Peter Maydell wrote: On 25 December 2013 07:21, liguang wrote: This is where your patch should have had an explanation for why you're making this change. What is the user outside of hw/sd/ that needs this header that means we should move it into include/ ? I don't mean someone will inclu

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Li Guang
Peter Maydell wrote: On 25 December 2013 08:35, liguang wrote: sunxi-linux kernel parse config script to do hardware configurations Signed-off-by: liguang --- hw/arm/allwinner-a10.c | 18 ++ hw/arm/cubieboard.c|2 ++ include/hw/arm/allwinner-a1

Re: [Qemu-devel] [PATCH v3] Add DSDT node for AppleSMC

2013-12-25 Thread Michael S. Tsirkin
On Wed, Dec 25, 2013 at 10:33:16PM +0100, Alexander Graf wrote: > > On 25.12.2013, at 20:20, Michael S. Tsirkin wrote: > > > On Wed, Dec 25, 2013 at 08:11:56PM +0100, Alexander Graf wrote: > >> > >> > >>> Am 23.12.2013 um 04:19 schrieb "Gabriel L. Somlo" : > >>> > >>> On Sun, Dec 22, 2013 at

Re: [Qemu-devel] [PATCH v3] Add DSDT node for AppleSMC

2013-12-25 Thread Alexander Graf
On 25.12.2013, at 20:20, Michael S. Tsirkin wrote: > On Wed, Dec 25, 2013 at 08:11:56PM +0100, Alexander Graf wrote: >> >> >>> Am 23.12.2013 um 04:19 schrieb "Gabriel L. Somlo" : >>> >>> On Sun, Dec 22, 2013 at 11:21:00PM +0100, Laszlo Ersek wrote: > 2. Use "IRQNoFlags() { 5 }" with the

Re: [Qemu-devel] [PATCH v3] Add DSDT node for AppleSMC

2013-12-25 Thread Michael S. Tsirkin
On Wed, Dec 25, 2013 at 08:11:56PM +0100, Alexander Graf wrote: > > > > Am 23.12.2013 um 04:19 schrieb "Gabriel L. Somlo" : > > > > On Sun, Dec 22, 2013 at 11:21:00PM +0100, Laszlo Ersek wrote: > >>>2. Use "IRQNoFlags() { 5 }" with the SMC (or any other > >>> number that isn't already

Re: [Qemu-devel] [PATCH v3] Add DSDT node for AppleSMC

2013-12-25 Thread Alexander Graf
> Am 23.12.2013 um 04:19 schrieb "Gabriel L. Somlo" : > > On Sun, Dec 22, 2013 at 11:21:00PM +0100, Laszlo Ersek wrote: >>>2. Use "IRQNoFlags() { 5 }" with the SMC (or any other >>> number that isn't already allocated. >> >> I don't think there's anything left free: >> ... >> >> I gu

[Qemu-devel] [PATCH v3 2/2] acpi unit-test: extract iasl executable from configuration

2013-12-25 Thread Marcel Apfelbaum
The test checked if iasl is installed by running "iasl" and checking the error output. It is better to use the iasl executable as appears in configuration. Signed-off-by: Marcel Apfelbaum --- v2 -> v3: - Used existing stringify() macro v1 -> v2: Addressed Michael S. Tsirkin's comments: - Strin

[Qemu-devel] [PATCH v3 1/2] configure: add CONFIG_IASL to config-host.h

2013-12-25 Thread Marcel Apfelbaum
Acpi unit-tests will extract iasl executable from CONFIG_IASL define. Signed-off-by: Marcel Apfelbaum --- v1 -> v2 - Removed double-quote characters around iasl value because it will be stringified in the test itself scripts/create_config | 4 1 file changed, 4 insertions(+) diff -

[Qemu-devel] [PATCH v3 0/2] acpi unit-test: extract iasl executable from configuration

2013-12-25 Thread Marcel Apfelbaum
To be applied on top of: [Qemu-devel] [PATCH v2 0/3] acpi unit-test: compare resulting aml vs expected aml The test checked if iasl is installed by running "iasl" and checking the error output. It is better to use the iasl executable as appears in configuration. patch 1: exports IASL configu

[Qemu-devel] [PATCH v2 0/2] acpi unit-test: extract iasl executable from configuration

2013-12-25 Thread Marcel Apfelbaum
To be applied on top of: [Qemu-devel] [PATCH v2 0/3] acpi unit-test: compare resulting aml vs expected aml The test checked if iasl is installed by running "iasl" and checking the error output. It is better to use the iasl executable as appears in configuration. patch 1: exports IASL configu

[Qemu-devel] [PATCH v2 2/2] acpi unit-test: extract iasl executable from configuration

2013-12-25 Thread Marcel Apfelbaum
The test checked if iasl is installed by running "iasl" and checking the error output. It is better to use the iasl executable as appears in configuration. Signed-off-by: Marcel Apfelbaum --- v1 -> v2: Addressed Michael S. Tsirkin's comments: - Stringified iasl value tests/acpi-test.c | 35 +++

[Qemu-devel] [PATCH v2 1/2] configure: add CONFIG_IASL to config-host.h

2013-12-25 Thread Marcel Apfelbaum
Acpi unit-tests will extract iasl executable from CONFIG_IASL define. Signed-off-by: Marcel Apfelbaum --- v1 -> v2 - Removed double-quote characters around iasl value because it will be stringified in the test itself scripts/create_config | 4 1 file changed, 4 insertions(+) diff -

Re: [Qemu-devel] [PATCH] virtio: Fix return value for dummy function vhost_net_virtqueue_pending

2013-12-25 Thread Michael S. Tsirkin
On Sun, Dec 22, 2013 at 03:51:22PM +0100, Stefan Weil wrote: > cgcc complains that -ENOSYS is not a good value for 'bool'. > > A dummy virtio will never have pending queue entries, so let us return > false. > > Signed-off-by: Stefan Weil Applied, thanks. > --- > > Could we also use g_assert_n

Re: [Qemu-devel] [PATCH 1/2] configure: add CONFIG_IASL to config-host.h

2013-12-25 Thread Michael S. Tsirkin
On Wed, Dec 25, 2013 at 12:50:15PM +0200, Marcel Apfelbaum wrote: > Acpi unit-tests will extract the iasl executable > from CONFIG_IASL define. > > Signed-off-by: Marcel Apfelbaum > --- > scripts/create_config | 4 > 1 file changed, 4 insertions(+) > > diff --git a/scripts/create_config b/

Re: [Qemu-devel] [PATCH v3] Add DSDT node for AppleSMC

2013-12-25 Thread Michael S. Tsirkin
On Sun, Dec 22, 2013 at 10:34:56AM -0500, Gabriel L. Somlo wrote: > AppleSMC (-device isa-applesmc) is required to boot OS X guests. > OS X expects a SMC node to be present in the ACPI DSDT. This patch > adds a SMC node to the DSDT, and dynamically patches the return value > of SMC._STA to either 0

Re: [Qemu-devel] [PATCH 1/2] configure: add CONFIG_IASL to config-host.h

2013-12-25 Thread Marcel Apfelbaum
On Wed, 2013-12-25 at 12:50 +0200, Marcel Apfelbaum wrote: > Acpi unit-tests will extract the iasl executable > from CONFIG_IASL define. > > Signed-off-by: Marcel Apfelbaum Added the maintainers of scripts/create_config, sorry for not doing it in the first place. Thanks, Marcel > --- > script

[Qemu-devel] [PATCH 1/2] configure: add CONFIG_IASL to config-host.h

2013-12-25 Thread Marcel Apfelbaum
Acpi unit-tests will extract the iasl executable from CONFIG_IASL define. Signed-off-by: Marcel Apfelbaum --- scripts/create_config | 4 1 file changed, 4 insertions(+) diff --git a/scripts/create_config b/scripts/create_config index b1adbf5..0478315 100755 --- a/scripts/create_config +++

[Qemu-devel] [PATCH 0/2] acpi unit-test: extract iasl executable from configuration

2013-12-25 Thread Marcel Apfelbaum
The test checked if iasl is installed by running "iasl" and checking the error output. It is better to use the iasl executable as appears in configuration. patch 1: exports IASL configuration option to config-host.h patch 2: acpi unit-test uses the exported CONFIG_IASL define Marcel Apfelbaum (2)

[Qemu-devel] [PATCH 2/2] acpi unit-test: extract iasl executable from configuration

2013-12-25 Thread Marcel Apfelbaum
The test checked if iasl is installed by running "iasl" and checking the error output. It is better to use the iasl executable as appears in configuration. Signed-off-by: Marcel Apfelbaum --- tests/acpi-test.c | 31 --- 1 file changed, 8 insertions(+), 23 deletions(-)

Re: [Qemu-devel] examples or tutorial/docs for writing block drivers for qemu

2013-12-25 Thread Vasiliy Tolstov
2013/12/24 Hani Benhabiles : > > I haven't taken the time to look at it yet, but there is a talk from this > year's > KVM Forum (Implementing New Block Drivers: A QEMU Developer Primer - Jeff > Cody) > that could help you. Thank you! -- Vasiliy Tolstov, e-mail: v.tols...@selfip.ru jabber: v..

Re: [Qemu-devel] vhost-net issue: does not survive reboot on ppc64

2013-12-25 Thread Michael S. Tsirkin
On Wed, Dec 25, 2013 at 12:36:12PM +1100, Alexey Kardashevskiy wrote: > On 12/25/2013 02:43 AM, Michael S. Tsirkin wrote: > > On Wed, Dec 25, 2013 at 01:15:29AM +1100, Alexey Kardashevskiy wrote: > >> On 12/24/2013 08:40 PM, Michael S. Tsirkin wrote: > >>> On Tue, Dec 24, 2013 at 02:09:07PM +1100,

Re: [Qemu-devel] [PATCH] hw/sd: move sdhci.h to include/hw

2013-12-25 Thread Peter Maydell
On 25 December 2013 07:21, liguang wrote: This is where your patch should have had an explanation for why you're making this change. What is the user outside of hw/sd/ that needs this header that means we should move it into include/ ? > Signed-off-by: liguang thanks -- PMM

Re: [Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread Peter Maydell
On 25 December 2013 08:35, liguang wrote: > sunxi-linux kernel parse config script > to do hardware configurations > > Signed-off-by: liguang > --- > hw/arm/allwinner-a10.c | 18 ++ > hw/arm/cubieboard.c|2 ++ > include/hw/arm/allwinner-a10.h |5

[Qemu-devel] [PATCH] allwinner-a10: add config script support

2013-12-25 Thread liguang
sunxi-linux kernel parse config script to do hardware configurations Signed-off-by: liguang --- hw/arm/allwinner-a10.c | 18 ++ hw/arm/cubieboard.c|2 ++ include/hw/arm/allwinner-a10.h |5 + pc-bios/aw-script.bin | Bin 0 -> 50188 bytes