qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [RFC Patch 1/3]Qemu: Enhance "info block" to display ca


From: supriya kannery
Subject: Re: [Qemu-devel] [RFC Patch 1/3]Qemu: Enhance "info block" to display cache setting
Date: Tue, 17 May 2011 14:30:52 +0530
User-agent: Thunderbird 2.0.0.14 (X11/20080501)

Kevin Wolf wrote:
Am 16.05.2011 20:10, schrieb Supriya Kannery:
Enhance "info block" to display cache setting

Example:
(qemu) info block
ide0-hd0: type=hd removable=0 file=../rhel6-32.qcow2 ro=0 drv=qcow2 encrypted=0

Enhanced to include "cache" setting:
(qemu) info block
ide0-hd0: type=hd removable=0 cache=none file=../rhel6-32.qcow2 ro=0 drv=qcow2 encrypted=0


bs_obj = qobject_from_jsonf("{ 'device': %s, 'type': %s, "
-                                    "'removable': %i, 'locked': %i }",
+                                    "'removable': %i, 'locked': %i, "
+                                    "'open_flags': %d }",
                                     bs->device_name, type, bs->removable,
-                                    bs->locked);
+                                    bs->locked, bs->open_flags);
if (bs->drv) {
             QObject *obj;

bs->open_flags is a purely internal thing and its meaning is not
guaranteed to be stable. Exposing it to the user is wrong.

ok. Pls suggest what could a better approach to expose the cache setting.
Kevin





reply via email to

[Prev in Thread] Current Thread [Next in Thread]