qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [RFC 07/25] accel: Make AccelClass.available() optional


From: Eduardo Habkost
Subject: [Qemu-devel] [RFC 07/25] accel: Make AccelClass.available() optional
Date: Wed, 9 Jul 2014 19:04:04 -0300

When we move accel classes outside accel.c, the available() function
won't be necessary anymore, because the classes will be registered only
if the accelerator code is really enable at build time.

Signed-off-by: Eduardo Habkost <address@hidden>
---
 hw/core/accel.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/core/accel.c b/hw/core/accel.c
index b42335c..b2a92b6 100644
--- a/hw/core/accel.c
+++ b/hw/core/accel.c
@@ -82,7 +82,7 @@ int configure_accelerator(MachineClass *mc)
             fprintf(stderr, "\"%s\" accelerator does not exist.\n", buf);
             continue;
         }
-        if (!acc->available()) {
+        if (acc->available && !acc->available()) {
             printf("%s not supported for this target\n",
                    acc->name);
             continue;
-- 
1.9.3




reply via email to

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