While GPIO functionality is not used by user-mode emulation, it is
conceptually part of qdev - GPIO pins are included in DeviceState
independent of whether this is system or user-mode emulation.
For the Rust bindings, having GPIO functionality in system_ss causes
a problem because, for simplicity, all methods of DeviceState are
included in the Rust hwcore crate. On Windows, rustc is not able
to do dead code elimination as well as on other OSes and this causes
an undefined symbol error, because gpio.c is not linked into the
rust/hw/core/rust-hwcore-rs-integration test binary.
To fix it, move gpio.c out of system_ss and into libhwcore.
Alternatively, it would be possible to define some DeviceState
methods also in the system crate, using for example a separate trace
SystemDeviceMethods. For now, keep all the methods in one crate and
link 200 unused lines of code into user-mode emulators.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>