aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-12-19.travis.yml: disable non-aarch64 builds (!UPSTREAM)android/ranchu-linaro-beta3-rebasingandroid/ranchu-linaro-beta3Alex Bennée
This disables all non-aarch64 builds (really all non-android builds) as the console commands are currently global. This also disables the notifications on IRC to prevent additional noise. Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Add avd snapshot command stubsGreg Bellows
Add stub functionality to support the Android emulator console "avd snapshot" sub-commands. Specifically, stub functions and entries for the "list", "save", "load", and "del" sub-commands were added along with their proper help messages. Currently, all of the sub-commands return "unsupported" if executed. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> [AJB: fix up header] Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Add avd name command stubGreg Bellows
Add stub functionality to support the Android emulator console "avd name" command. The proper help messages are displayed, but the command currently returns a message indicating that AVDs are unsupported. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Add avd start commandGreg Bellows
Add Android emulator console "avd start" commmand and associated help messages. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Add avd stop commandGreg Bellows
Add Android emulator console "avd stop" commmand and associated help messages. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Add avd status commandGreg Bellows
Add Android emulator console "avd status" commmand and associated help messages. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Add base avd command supportGreg Bellows
Add base Android emulator console avd command support and associated help message. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> [AJB: fixed up sub-table] Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Fix android_console_help call orderGreg Bellows
Fixes the order and hierarchy of handler calling so that commands with sub-tables take priority over parent only commands. This allows nesting of commands with sub-tables to be called properly. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> [AJB: minor fix due to sub_cmd changes] Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Add event text command stubGreg Bellows
Add Android emulator console "event text" command function stub and help support. The command properly displays help text, but returns a "Not supported" message when executed due to limitations in texting telephony support. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add event send commandGreg Bellows
Add the Android emulator console "event send" command and associated help messages. The "send" command is used to initiate a given event on the Android emulator instance. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add GF event send functionGreg Bellows
Adds Android emulator console command for enqueuing a Goldfish/Ranchu event. The function takes the event type and code (symbol or value) along with an event value and adds it to the Goldfish event device work queue. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add event codes commandGreg Bellows
Add the Android emulator console "event codes" command and associated help messages. The "codes" command is used to display a list of available event codes for a specified type. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add event types commandGreg Bellows
Add the Android emulator console "event types" command and associated help messages. The "types" command is used to display a list of available event types that can be used in other event commands. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add GF event type code reportingGreg Bellows
Adds Goldfish event code tables and functions for reporting the number, value and names of supported codes for a given event type. Also added an internal function for looking up an event code descriptor from its name. This functionality will be used by the Andorid emulator console for displaying names and numbers of available events codes. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add GF event type reportingGreg Bellows
Adds Goldfish event table and functions for reporting the number. value, and names of supported events. Also added an internal function for looking up an event type descriptor by name. This functionality will be used by the Andorid emulator console for displaying names and numbers of available events. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Init the event device ID fieldGreg Bellows
Initializes the Goldfish event device ID field so that it is discoverable by name (ID) when needed by the event commands. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add console base event commandGreg Bellows
Add the base Android emulator console "event" command and infrastructure for adding sub-commands. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> [AJB: minor fix for sub-table] Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Add power capacity commandGreg Bellows
Add the Android emulator console "power capacity" command along associated help messages. The "capacity" command allows the battery capacity of the device to be manipulated. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> --- v2 -> v3 - Add missing "OK" messages
2014-12-19android-console: Add power health commandGreg Bellows
Add the Android emulator console "power health" command and associated help messages. The "health" command allows the battery health of the device to be manipulated. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> --- v2 -> v3 - Add missing "OK" messages
2014-12-19android-console: Add power present commandGreg Bellows
Add the Android emulator console "power present" command and associated help messages. The "present" command allows the battery presence in the device to be manipulated. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> --- v2 -> v3 - Add missing "OK" messages
2014-12-19android-console: Add power status commandGreg Bellows
Add the Android emulator console "power status" command and associated help messages. The "status" command allows the battery status of the device to be manipulated. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> --- v2 -> v3 - Add missing "OK" messages
2014-12-19android-console: Add power ac commandGreg Bellows
Add the Android emulator console "power ac" along with the associated help messages. The "ac" command allows the power supply state of the device to be manipulated. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> --- v2 -> v3 - Add missing "OK" messages
2014-12-19android-console: Add power display commandGreg Bellows
Add the Android emulator console "power display" along with the associated help messages. The "display" command allows the current device power and battery state to be displayed. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add GF battery property getterGreg Bellows
Add a function for acquiring each of the goldfish battery properties. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add GF battery prop print funcGreg Bellows
Add a function for printing out the Goldfish battery properties to the android console. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add header for battery externsGreg Bellows
Added goldfish_battery.h to share power and battery constants and externs between the Goldfish battery code and the Android console code. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Init the battery ID state fieldGreg Bellows
Adds initialization of the battery ID field so that it is discoverable by name (ID) when needed by power commands. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add missing hw_has_battery propGreg Bellows
Added the missing hw_has_battery property to the Goldfish batter state. This property indicates whether the device has a battery and controls whether some power commands are available. In the Android emulator this property is acquired from the AVD for the device. For now, this is wired as always enabled. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Add console base power commandGreg Bellows
Added the base Android emulator console power command and infrastructure for adding sub-commands. Signed-off-by: Greg Bellows <greg.bellows@linaro.org> [AJB: fixed up sub-table] Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android-console: Consolidate redir help textGreg Bellows
Consolidated the Android emulator console help text for the redir command to make the hndler functions more readable. This establishes the pattern to be used for each command added in the future. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Remove extra redir help messageGreg Bellows
Removed an extraneous message in the redir command help. The message is not part of the standard Android emulator output. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19android-console: Fix OK message outputGreg Bellows
Adjusted "OK" message to be shared by all cases to avoid duplicates and need for all help output to print. Alse added missing "OK" after the top most help output. Signed-off-by: Greg Bellows <greg.bellows@linaro.org>
2014-12-19ranchu: trigger rotation in goldfish_sensors on commandAlex Bennée
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19add goldfish_sensors: basic support for pipe based acceleration supportAlex Bennée
This imports a small chunk of the old hw-sensors code to handle the acceleration code. The old code "supported" a bunch of different sensors however I've dropped all the boilerplate for that. Any potential upstream solution will probably want to enumerate things differently. Apart from only supporting the accelerometer this also interfaces directly with the AndroidPipe code instead of going through the qemud layer. It also requires the updated guest code. Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19ranchu: set global graphic_rotation variable to map input eventsAlex Bennée
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19ranchu: trigger goldfish_fb rotation on commandAlex Bennée
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19goldfish_fb: implement basic rotation supportAlex Bennée
This adds support for a rotated display of the android framebuffer. As far as the guest is concerned the location/size of the framebuffer hasn't changed however we change how we copy the data into QEMU's own display buffer depending on the setting of the rotation field. Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19ranchu: add stub console handler for "rotate"Alex Bennée
This uses the new dynamic monitor functionality to add a rotate command to the android console. This will later be hooked into the individual sub-systems to trigger rotation. Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19goldfish_fb: remove SET_ROTATION supportAlex Bennée
This is DEPRECATED functionality from the original bring-up. As this will confuse/complicate the current emulator triggered rotation we no longer handle it. This bumps the version of save/load format. Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19android_pipe: auto-detect PIPE_REG_ACCESS_PARAMS sizeAlex Bennée
The PIPE_REG_ACCESS_PARAMS structure can be one of two sizes depending on the type of host kernel. As the pipe code is shared between both 32 bit and 64 bit worlds it needs to be able to handle both. Introspecting the CPU type is impractical as a 64 bit CPU may be booting a 32 bit kernel. Fortunately due to the overlap of the structures it's possible to detect the use of a 64 bit structure as it implies a non-zero value of the (currently) unused flags field. This also opens the way to the 32 bit code using the 64 bit structure at a later date. Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2014-12-19virtserial ping-pong devicePeter Maydell
Version of the android pipe pingpong test backend using virtserial
2014-12-19virtio: serial: expose a 'guest_writable' callback for usersAmit Shah
Users of virtio-serial may want to know when a port becomes writable. A port can stop accepting writes if the guest port is open but not being read from. In this case, data gets queued up in the virtqueue, and after the vq is full, writes to the port do not succeed. When the guest reads off a vq element, and adds a new one for the host to put data in, we can tell users the port is available for more writes, via the new ->guest_writable() callback. Signed-off-by: Amit Shah <amit.shah@redhat.com>
2014-12-19ranchu: Create console and ADB ports automaticallyPeter Maydell
On startup, start listening on the console and ADB ports automatically, using the same "start at 5554 and work up until we find a pair of ports which we can listen on" algorithm as the classic emulator. Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-12-19android_adb: add Android ADB backendPeter Maydell
The Android adbd daemon running inside Android VMs on the emulator expect to be able to talk to a backend named "qemud:adb" (for historical reasons). The backend will carry out a handshake: 1. Listen for connections from the host adb server on adb_port = <5555 + (2 * emulator instance id)>. 2. Connect to the local adb server on port 5037 if it's available. 3. Listen for and accept the beginning of the handshake with the adbd daemon (adbd sends 'accept' over the write). 4. After the adb backend detects a connection on <adb_port>, it sends back an "ok" string to adbd. 5. The adb backend will not send any more data over the pipe until it recognizes a 'start' request, which means the adbd is ready to receive data from the host ADB server. Once the above process is complete, the adb backend will consume everything it receives on the socket connected on <adb_port> and send it over the adb pipe and will consume everything it receives over the adb pipe and send it on the socket connected on <adb_port>. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> [AJB: Bunch of clean-up/re-factoring to GIOChannel code] Signed-off-by: Alex Bennée <alex.bennee@linaro.org> [PMM: Listen for ADB connections on 127.0.0.1, not localhost] Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-12-19android_adb_dbg: Add Android adb-debug backendChristoffer Dall
Add the adb-debug backend (identified by "qemud:adb-debug") which simply prints all chars send accross the pipe buffers from the guest to stderr. Reads are handled like the zero pipe. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
2014-12-19android_pipe: Factor out example/test pipes from android_pipeChristoffer Dall
The Android Pipe main implementation file should only contain the actual implementation. Keeping all that test backend implementation code in there just makes it confusing to grep in the file and figure out what is going on. This could be made dependent on some sort of debug flag to avoid compiling test code as part of shipped binaries in the future. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
2014-12-19android_pipe: import the qemu_pipe/goldfish_pipe codeAlex Bennée
This brings in the android emulator pipe code from the current aosp-qemu master branch. It works with and has been tested with the pingpong pipe device. Currently the device cannot save and restore. - remove dependency on android utils (ANEW/ASTRDUP/AFREE) - detach from the goldfish_device bus bits (inc irq raising) - import a few helper functions (uint64_set_high/low, goldfish_guest_is_64bit) - disable the VM save/restore code - use current_cpu for memory translation ops instead of cpu_single_env - fix debugging prints using portable formats - common code path for translating vaddr->qemu addr* - make some debug statments user-visible (unimp and guest errors) There is a hacking backlink between AndroidPipeState and the PipeDevice stuff (which should be merged cleanly later) just so we can get back to ->irq when we need to. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> [cdall: special casing "qemud:<name>"] Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
2014-12-19android-console: Make 'help' output match the classic emulatorPeter Maydell
Implement the 'help' command ourselves rather than using the monitor's usual version, so we can make the output text match the format of the classic emulator. This might not be necessary but perhaps external tools are parsing the output to see what commands are supported. Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-12-19android-console: Add KO: prefix to parser syntax error messagesPeter Maydell
Indirect all the syntax error messages from the command parser through a function pointer, so the Android console can override it to put the KO: prefix on them. Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-12-19android-console: Implement quitPeter Maydell
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>