Skip to content
Snippets Groups Projects
  • Markus Armbruster's avatar
    a44432b4
    numa: Don't include hw/boards.h into sysemu/numa.h · a44432b4
    Markus Armbruster authored
    
    sysemu/numa.h includes hw/boards.h just for the CPUArchId typedef, at
    the cost of pulling in more than two dozen extra headers indirectly.
    
    I could move the typedef from hw/boards.h to qemu/typedefs.h.  But
    it's used in just two headers: boards.h and numa.h.
    
    I could move it to another header both its users include.
    exec/cpu-common.h seems to be the least bad fit.
    
    But I'm keeping this simple & stupid: declare the struct tag in
    numa.h.
    
    Cc: Eduardo Habkost <ehabkost@redhat.com>
    Cc: Marcel Apfelbaum <marcel.apfelbaum@gmail.com>
    Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
    Reviewed-by: default avatarEduardo Habkost <ehabkost@redhat.com>
    Message-Id: <20190812052359.30071-24-armbru@redhat.com>
    a44432b4
    History
    numa: Don't include hw/boards.h into sysemu/numa.h
    Markus Armbruster authored
    
    sysemu/numa.h includes hw/boards.h just for the CPUArchId typedef, at
    the cost of pulling in more than two dozen extra headers indirectly.
    
    I could move the typedef from hw/boards.h to qemu/typedefs.h.  But
    it's used in just two headers: boards.h and numa.h.
    
    I could move it to another header both its users include.
    exec/cpu-common.h seems to be the least bad fit.
    
    But I'm keeping this simple & stupid: declare the struct tag in
    numa.h.
    
    Cc: Eduardo Habkost <ehabkost@redhat.com>
    Cc: Marcel Apfelbaum <marcel.apfelbaum@gmail.com>
    Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
    Reviewed-by: default avatarEduardo Habkost <ehabkost@redhat.com>
    Message-Id: <20190812052359.30071-24-armbru@redhat.com>
numa.h 1.17 KiB