[3/3] accel: Remove unused AccelClass::available field
diff mbox series

Message ID 20190422210448.2488-4-ehabkost@redhat.com
State New
Headers show
Series
  • Remove AccelClass::available field
Related show

Commit Message

Eduardo Habkost April 22, 2019, 9:04 p.m. UTC
The field is not used anymore, we can remove it.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
 include/sysemu/accel.h | 1 -
 accel/accel.c          | 5 -----
 2 files changed, 6 deletions(-)

Comments

Philippe Mathieu-Daudé April 22, 2019, 10:20 p.m. UTC | #1
On 4/22/19 11:04 PM, Eduardo Habkost wrote:
> The field is not used anymore, we can remove it.
> 
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>

Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
mingw64:
Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com>

> ---
>  include/sysemu/accel.h | 1 -
>  accel/accel.c          | 5 -----
>  2 files changed, 6 deletions(-)
> 
> diff --git a/include/sysemu/accel.h b/include/sysemu/accel.h
> index 5565e00a96..70e9e2f2a1 100644
> --- a/include/sysemu/accel.h
> +++ b/include/sysemu/accel.h
> @@ -38,7 +38,6 @@ typedef struct AccelClass {
>  
>      const char *opt_name;
>      const char *name;
> -    int (*available)(void);
>      int (*init_machine)(MachineState *ms);
>      void (*setup_post)(MachineState *ms, AccelState *accel);
>      bool *allowed;
> diff --git a/accel/accel.c b/accel/accel.c
> index 454fef9d92..5fa31717b4 100644
> --- a/accel/accel.c
> +++ b/accel/accel.c
> @@ -107,11 +107,6 @@ void configure_accelerator(MachineState *ms, const char *progname)
>          if (!acc) {
>              continue;
>          }
> -        if (acc->available && !acc->available()) {
> -            printf("%s not supported for this target\n",
> -                   acc->name);
> -            continue;
> -        }
>          ret = accel_init_machine(acc, ms);
>          if (ret < 0) {
>              init_failed = true;
>
Thomas Huth April 23, 2019, 5:09 a.m. UTC | #2
On 22/04/2019 23.04, Eduardo Habkost wrote:
> The field is not used anymore, we can remove it.
> 
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> ---
>  include/sysemu/accel.h | 1 -
>  accel/accel.c          | 5 -----
>  2 files changed, 6 deletions(-)

Reviewed-by: Thomas Huth <thuth@redhat.com>

Patch
diff mbox series

diff --git a/include/sysemu/accel.h b/include/sysemu/accel.h
index 5565e00a96..70e9e2f2a1 100644
--- a/include/sysemu/accel.h
+++ b/include/sysemu/accel.h
@@ -38,7 +38,6 @@  typedef struct AccelClass {
 
     const char *opt_name;
     const char *name;
-    int (*available)(void);
     int (*init_machine)(MachineState *ms);
     void (*setup_post)(MachineState *ms, AccelState *accel);
     bool *allowed;
diff --git a/accel/accel.c b/accel/accel.c
index 454fef9d92..5fa31717b4 100644
--- a/accel/accel.c
+++ b/accel/accel.c
@@ -107,11 +107,6 @@  void configure_accelerator(MachineState *ms, const char *progname)
         if (!acc) {
             continue;
         }
-        if (acc->available && !acc->available()) {
-            printf("%s not supported for this target\n",
-                   acc->name);
-            continue;
-        }
         ret = accel_init_machine(acc, ms);
         if (ret < 0) {
             init_failed = true;