Commit graph

8219 commits

Author SHA1 Message Date
recipe-roller
caa0292d6d Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8756964944789902321

depot_tools:
af6eabff53
  af6eabf (bewise@chromium.org)
      Revert "Delete vpython, leaving only vpython3."

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I52e1087b830cd8f2de4d1b356d7448b6a845b464
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5267519
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-02-05 04:03:39 +00:00
recipe-roller
7e72a22722 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757171935158626001

depot_tools:
371aa997c0
  371aa99 (sokcevic@chromium.org)
      Delete py2 checks

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ib888b7dc6276eb2606cf33e010cce395a99b3dce
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5263222
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-02-02 21:09:58 +00:00
recipe-roller
f187befd36 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757173820917672321

depot_tools:
911e2a0893
  911e2a0 (rsesek@chromium.org)
      Add `git cl format --mojom` for .mojom file formatting

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ib6db1bc9fb525fe7ae5c13e8e03019c6b5fa551d
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5263221
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-02-02 20:45:33 +00:00
Frederick Mayle
18283c9e8e devices: virtcpufreq: Add proxy syscall support through UDS
Add skeleton for allowing virtcpufreq to communicate
via sockets to make syscalls using privileged proxy
services. This acts a fallback mechanism for systems
that do not grant CAP_SYS_NICE for crosvm.

Bug: 322197421
Test: ./tools/presubmit
Change-Id: I2ca4e01c477d3867a052bcf709bdeddf32e5ded1
Signed-off-by: David Dai <davidai@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5258454
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
2024-02-02 03:39:54 +00:00
Rob Clark
2f9fe25b9c rutabaga_gfx: Query cachability from minigbm
Drop the hack hard-coding cachability based on driver name, and replace
with querying from minigbm.  This allows other drivers to use cached
minigbm/gralloc allocated buffers in cases where it is beneficial (such
as with sw encoders)

BUG=b:239718180, b:306548532
TEST=cts-tradefed run cts -m CtsVideoTestCases -t android.video.cts.VideoEncoderDecoderTest#testAvcGoog0Perf0320x0240
     no artifact in Camera FOV Calibration of CtsVerifier on rex

Change-Id: I854e2f00b993310716f64a3c568ed8c6f2665469
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/3780218
Reviewed-by: Dawn Han <dawnhan@google.com>
Reviewed-by: Ryan Neph <ryanneph@google.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Chia-I Wu <olv@google.com>
2024-02-01 21:34:17 +00:00
Daniel Verkamp
0c80abfa27 base: macos: add pipe() implementation
We can't use pipe2() since that is a Linux-only API, so O_CLOEXEC must
be applied as a separate step. This should not be a problem in practice
for crosvm, since we should never be calling pipe() simultaneously with
fork()/exec() in another thread, since fork() in a multithreaded process
is generally unsafe and our fork wrapper disallows it.

Change-Id: I27886b6e50f8b0eb018cf38161530fa7f92f4761
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5251101
Reviewed-by: Frederick Mayle <fmayle@google.com>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
2024-02-01 19:38:14 +00:00
Daniel Verkamp
7c5e1f25be base: unix: add set_descriptor_cloexec()
Clean up and refactor the existing clear_*_flags() to allow adding
O_CLOEXEC as well.

Change-Id: Idad76537e3a0d8ed52780bca1723b40c7115a498
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5251100
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Frederick Mayle <fmayle@google.com>
Reviewed-by: Alexandre Courbot <acourbot@chromium.org>
2024-02-01 19:34:21 +00:00
Daniel Verkamp
58a06581bc base: linux: remove pipe() close_on_exec argument
Every caller passes `true`. If a hypothetical future caller wants pipe
descriptors that are not O_CLOEXEC, then they can use `pipe()` plus
`clear_descriptor_cloexec()`.

BUG=None
TEST=tools/dev_container tools/presubmit

Change-Id: If9aa62653e00a163824157819ddd2fce849fe348
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5251099
Reviewed-by: Frederick Mayle <fmayle@google.com>
Reviewed-by: Alexandre Courbot <acourbot@chromium.org>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
2024-02-01 19:33:27 +00:00
recipe-roller
4287f76946 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757272595320968001

depot_tools:
8f4d3df0bc~..7142bf166cf075443c20ab9c66bb64120dc5cd90
  8f4d3df (sokcevic@chromium.org)
      Revert "[gclient] Enable parallel sync on ARM Mac by default"
  7142bf1 (msavigny@google.com)
      Enable deps cache for mac devs.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ia8dcd94c1af4405dbba7ab69b3727c3de03ffe9e
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5258440
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-02-01 18:57:20 +00:00
recipe-roller
c835a46fa7 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757321042687897889

depot_tools:
92469e017f
  92469e0 (ddoman@chromium.org)
      [depot_tools] move the lucifg cipd pin to v1.43.4.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I2910bef2cbf47c9e35cb650a8176a77ece24529b
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5256977
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-02-01 05:37:26 +00:00
recipe-roller
38beb88330 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757323559097483777

depot_tools:
92b780b0bd
  92b780b (jwata@google.com)
      [gclient] Enable parallel sync on ARM Mac by default

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I2a968fb750cbe22399a323cb2575c8ec4adc82f1
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5255595
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-02-01 05:01:02 +00:00
Frederick Mayle
f35dc67e13 crosvm: add cmdline option wait on balloon adjust response
Change-Id: Iae2bde20e9e68d9a40a40526da4553ee9b7cc312
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5255763
Commit-Queue: Frederick Mayle <fmayle@google.com>
Reviewed-by: David Stevens <stevensd@chromium.org>
2024-02-01 01:49:22 +00:00
recipe-roller
62a3fb4be7 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757346204501824785

depot_tools:
db0dcbbe7c
  db0dcbb (bryner@google.com)
      Delete vpython, leaving only vpython3.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I927a5adc792c3d7d2c571d24840e6b77b4305ffe
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5250059
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-31 23:00:12 +00:00
recipe-roller
7aa8d29fc8 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757348723095946113

depot_tools:
b482a5dbba
  b482a5d (msavigny@google.com)
      Reduce local resource fraciton for windows builds.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ida7c963b7524dcaac707caad18967f37ccc2ab3b
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5254280
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-31 22:21:02 +00:00
Idan Raiter
b21b7d650b vmm_vhost: Check for errors on vhost-user WAKE
Add analog of https://crrev.com/c/5247322 for WAKE.

BUG=b:300501737
TEST=snapshotted downstream and resumed

Change-Id: I4567867e14b9eb045c46df8394bb564a8eb2b800
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5252007
Reviewed-by: Noah Gold <nkgold@google.com>
Commit-Queue: Idan Raiter <idanr@google.com>
2024-01-31 21:47:22 +00:00
Idan Raiter
48d18bb1f5 vmm_vhost: Check for errors on vhost-user SLEEP
If a device fails to sleep we never handle it and continue snapshotting.
This causes a corrupt snapshot to be made with silent failure on boot.

I noticed this for the vhost-user GPU, whenever there is a failure to
recover the queue, this failure was not preventing the snapshot.

BUG=b:300501737
TEST=snapshotted downstream and checked error prevents snapshot

Change-Id: I7573805c37ba9bb66495ff2f256e706a33907361
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5247322
Reviewed-by: Noah Gold <nkgold@google.com>
Commit-Queue: Idan Raiter <idanr@google.com>
2024-01-31 20:50:35 +00:00
Idan Raiter
1d7627ddbe vhost-user: gpu: Improve queue handling to prevent snapshot errors
Improves the queue handling code to fix these two issues:

1) Dangling references to the queue cause queue recovery to fail.
   To clean this up we just need to call stop_non_queue_workers as these
   workers have a reference to the state.

2) The cursor queue always fails to snapshot since it has no worker and
   no state tracking to recover the queue. Clean up this path by
   spawning an empty worker instead.

BUG=b:300501737
TEST=snapshotted downstream

Change-Id: Ie8e2eeb0eb71090c873d5fb64f22229f60745f4b
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5247321
Commit-Queue: Idan Raiter <idanr@google.com>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
2024-01-31 20:26:18 +00:00
Will Deacon
fd4488b70f kernel_loader: Reserve memory according to 'image_size' header field
The arm64 kernel header contains an 'image_size' field indicating the
minimum size of the reserved memory region into which the kernel is
loaded. This is larger than the size of the Image file, as it also takes
into account NOBITS sections such as the .bss, which will be zeroed
during boot.

Although crosvm parses the kernel header, it fails to take 'image_size'
into account and can end up loading the initrd over the .bss if the
section is large enough to cross the next 16MiB alignment boundary after
the end of the Image.

Size the memory reservation according to the 'image_size' field in the
arm64 kernel Image header, warning if it's zero and falling back to the
current behaviour.

BUG=b:322966413
TEST=tools/dev_container tools/run_tests --platform=aarch64

Change-Id: I23316f201d8a7fd9025762be518aa505e716c642
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5249889
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Will Deacon <willdeacon@google.com>
Reviewed-by: Frederick Mayle <fmayle@google.com>
2024-01-31 09:15:04 +00:00
recipe-roller
24f4f976a4 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757441206639143681

depot_tools:
10bd39fd47
  10bd39f (msavigny@google.com)
      Enable deps cache for windows builds.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ifd79ff0a18eca966b680af31f984517f5e1658dc
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5250102
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-30 21:49:46 +00:00
Frederick Mayle
c7541ef925 cros_async: don't use relaxed atomics for executor state
I don't know if the relaxed ops are wrong, but they aren't clearly
correct.

Change-Id: Ie67b8ea3b4913e91182f6863514a5d47beb1615e
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5246698
Commit-Queue: Frederick Mayle <fmayle@google.com>
Reviewed-by: Noah Gold <nkgold@google.com>
2024-01-30 19:41:00 +00:00
recipe-roller
d0a2089574 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757451272371969137

depot_tools:
a95979fcc3
  a95979f (gbeaty@chromium.org)
      Update the CheckInfraFreeze canned check to use datetime & zone...

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ibb7553f06b2eb5b45b330cd5b04845ed013e642e
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5251087
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-30 19:07:24 +00:00
Gurchetan Singh
6664cd2bd7 rutabaga_gfx: fix cross-compile on nto
BUG=287085485
TEST=compile using instructions in bug

Change-Id: Ib79ce1d96702aecdc656cf4763cbd16e91827a16
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5247985
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Gurchetan Singh <gurchetansingh@chromium.org>
2024-01-30 01:36:25 +00:00
recipe-roller
76ec7c4707 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757531806455509825

depot_tools:
b808b1bcdd
  b808b1b (gavinmak@google.com)
      Use shlex instead of pipes

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I731df079be38b0439c6f2994ac153cb821dfac4f
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5246690
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-29 21:49:09 +00:00
Daniel Verkamp
5a1a709ba6 windows: remove unused Vm type in create_userspace_irq_chip
Fixes clippy::extra_unused_type_parameters in Rust 1.73.

Change-Id: I090ca0ce4ca1acf5962784046d369f0b7aab3cf7
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5241881
Reviewed-by: Vikram Auradkar <auradkar@google.com>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
2024-01-29 19:42:29 +00:00
Daniel Verkamp
c91134a0a2 devices: virtio-snd: fix clippy::arc_with_non_send_sync
<https://rust-lang.github.io/rust-clippy/master/index.html#arc_with_non_send_sync>

Change-Id: I6d0ee284b45d5e9935834a9c0f1dce204097cd4d
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5241880
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Richard Zhang <rizhang@google.com>
2024-01-29 19:42:29 +00:00
Daniel Verkamp
e9e933ff6f windows: resolve clippy::unnecessary_cast warnings
Change-Id: I07a6c2b2a737721baa202bd41acdc6f3aff4d7bc
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5241879
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Vikram Auradkar <auradkar@google.com>
2024-01-29 19:42:29 +00:00
Ryan Neph
659977977d jail: seccomp: Allow mkdir/mkdirat on ARM for mali shader debugging
Mali driver creates a directory hierarchy when dumping shaders for debug
purposes, necessitating the use of `mkdir` or `mkdirat` syscalls, which
have already been allowed on x86_64 platforms for mesa's shader cache
management and filesystem management by the fs and 9p devices.

BUG=b:322266916
TEST=emerge crosvm
TEST=ARCVM starts successfully

Change-Id: Ib1b838856847edfc2178ab1ae2eb85fdb26a0d2b
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5238061
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Ryan Neph <ryanneph@google.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
2024-01-29 18:04:18 +00:00
Gurchetan Singh
f29fff8331 rutabaga_gfx: fix cross-compile on Windows
When cross-compiling Windows on Linux, multiple features are
reported missing.  Also, winapi::ctypes::c_void and
libc::c_void differ.

winbase isn't used yet, but there's a few futre patches that
benefit from it.

BUG=322802940
TEST=cargo build --target x86_64-pc-windows-gnu

Change-Id: I7aee961b1758050e5f93c3619db27d59bf918fe2
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5245137
Reviewed-by: Dennis Kempin <denniskempin@google.com>
Commit-Queue: Gurchetan Singh <gurchetansingh@chromium.org>
2024-01-29 17:44:33 +00:00
Hikaru Nishida
481d24e461 guest_under_test: Apply virtio-pvclock guest kernel patch for testing
BUG=b:295256641
TEST=make clean-all && make kernel

Change-Id: I7197b7a29f160fe19fcbc1c5fa53043e58088927
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5190792
Reviewed-by: Dennis Kempin <denniskempin@google.com>
Commit-Queue: Hikaru Nishida <hikalium@chromium.org>
Auto-Submit: Hikaru Nishida <hikalium@chromium.org>
2024-01-29 08:37:47 +00:00
recipe-roller
da859e1196 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (recipe_engine) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757588428261035297

recipe_engine:
0c1c828904
  0c1c828 (mingkong@google.com)
      [recipe] Add stability API to luci_analysis recipe module.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ie4728419b455c8652c78fe274e0f2330681c6ec8
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5244274
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-29 06:52:57 +00:00
Vikram Auradkar
fa539725eb tools: add simple windows example script
Makes gpu argument optional

BUG=b:316406247
TEST=ran the script on windows

Change-Id: I08e7961f2477ee56ad162420a99c469e3f4c7b1b
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5124591
Reviewed-by: Noah Gold <nkgold@google.com>
Commit-Queue: Vikram Auradkar <auradkar@google.com>
Auto-Submit: Vikram Auradkar <auradkar@google.com>
2024-01-27 06:17:57 +00:00
Dmitrii Merkurev
b7cb5c3573 crosvm: support passing pci address for net devices
BUG=b:218364216
TEST=cuttlefish net devices assigned at the proper address
TEST=cargo test

Change-Id: I084ddeb2ab0481509d9ce69f22955ccb12f13db5
Signed-off-by: Dmitrii Merkurev <dimorinny@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5238436
Reviewed-by: Cody Schuffelen <schuffelen@google.com>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
2024-01-27 00:01:34 +00:00
Stanislaw Kardach
3363fb9fe7 Cargo.toml: add noncoherent-dma feature flag
Add a top level noncoherent-dma feature flag as well as its
counterparts in devices and hypervisor modules.
This flag enables the MemCacheType::CacheNonCoherent handling,
ensuring that behavior introduced in the previous commit can be
selectively enabled.

BUG=b:316337317
TEST=emerge-rex chromeos-base/crosvm
TEST=USE=crosvm-noncoherent-dma emerge-rex chromeos-base/crosvm

Change-Id: I13f50547b21ce804c5fa4b8f6328931f558b717e
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5237126
Reviewed-by: Frederick Mayle <fmayle@google.com>
Reviewed-by: Zhenyu Z Wang <zhenyuw@linux.intel.com>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Stanisław Kardach <skardach@google.com>
2024-01-26 23:27:58 +00:00
Zhenyu Wang
53c8fb14bf devices: apply new noncoherent attribute for GPU mem's cache info
On Intel, new noncoherent DMA mem flag can be set to allow KVM to
recognize guest cache setting for EPT, which allows WC attribute to be
applied to ensure guest memory access is synchronized in noncoherent DMA.

Unlike previous POC for new device attribute, this uses new added flag
for mem slot.

BUG=b:316337317
TEST=cargo build and run GPU workload

Change-Id: If16d61031bdb2cf0252a57e99d4b6725a89dd38a
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5171312
Reviewed-by: Frederick Mayle <fmayle@google.com>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Stanisław Kardach <skardach@google.com>
2024-01-26 23:27:58 +00:00
Daniel Verkamp
73f4d02be0 clippy: fix redundant any/all in cfg for Rust 1.73
TEST=tools/dev_container tools/presubmit clippy_aarch64
TEST=tools/dev_container tools/presubmit clippy_mingw64

Change-Id: Ibd0a79289f0a10164c91f24ba5b396a3b5c67dce
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5241878
Reviewed-by: Frederick Mayle <fmayle@google.com>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
2024-01-26 23:24:08 +00:00
dawnhan
89ba72800c rutabaga: change how MinigbmDevice finds the render node
Let minigbm decide which randernode to use. In this case, we don't need `rendernode.rs` anymore, and don't have to keep `_fd` in struct `MinigbmDeviceInner`, `fd` can get by calling `gbm_bo_get_fd`

BUG=b:265199561
TEST=./tools/presubmit
TEST=emerge-board crosvm, and deploy to dut
TEST=CQ

Change-Id: I294d6f7f0dcdf075ac85671561dbeeb1eef8edd2
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5038006
Commit-Queue: Dawn Han <dawnhan@google.com>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Ryan Neph <ryanneph@google.com>
2024-01-26 22:43:35 +00:00
recipe-roller
cdfa1f0a5c Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757817437367070209

depot_tools:
68c511349d
  68c5113 (michaeldo@google.com)
      Improve git cl split warning if more than 10 CLs will be created.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I02ef798bb66f0b04ec5f1a4af629c60b86186fcd
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5238062
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-26 18:11:30 +00:00
recipe-roller
f7fc88def5 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757821213428281009

depot_tools:
b25b4680f2
  b25b468 (jojwang@google.com)
      Make scm.ListSubmodules return paths for the OS.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ia3ab1b39c64e7062f2032968b9c87b234fc488bf
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5238060
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-26 17:10:11 +00:00
recipe-roller
4acd0bc86d Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757822470824498801

depot_tools:
3c8baffa8d
  3c8baff (zcbenz@gmail.com)
      Add fetch config node

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ifc7421e067e07593278f48a0114689ac3f411946
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5239636
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-26 16:49:25 +00:00
Pierre Labatut
9ffd450153 [rutabaga_gfx:ffi] Locate target build directory.
Get the directomy from the environement if available.

Test:
  mkdir /tmp/out
  cd rutabaga_gfx/ffi
  CARGO_TARGET_DIR=/tmp/out cargo build

  # Also try.
  cargo build

Bug: b/317884283
Change-Id: I43fc7d17e4bef50e4afcd45144a2dc9bef273a6b
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5237622
Commit-Queue: Dennis Kempin <denniskempin@google.com>
Auto-Submit: Pierre Labatut <plabatut@google.com>
Reviewed-by: Dennis Kempin <denniskempin@google.com>
2024-01-26 16:11:00 +00:00
David Dai
29aba6a1ca devices: virtcpufreq: stub out virtcpufreq
Stub out virtual cpufreq since the current implementation/interface
is unstable so that other users do not rely on this current interface.

Bug=b:284367589
Test=./tools/presubmit

Change-Id: I88d491389293e69dc0cdfb7317708a09a18ef5ff
Signed-off-by: David Dai <davidai@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5237740
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Frederick Mayle <fmayle@google.com>
2024-01-26 00:16:32 +00:00
Frederick Mayle
c81256f2f1 rutabaga_gfx: add FFI API for snapshot-restore
BUG=b:266514608

Change-Id: I091ca52b5864359b0bb03f7cb3ecbfabe47f8203
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/4853266
Commit-Queue: Frederick Mayle <fmayle@google.com>
Auto-Submit: Frederick Mayle <fmayle@google.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
2024-01-25 03:16:30 +00:00
Frederick Mayle
c16b2bf620 rutabaga_gfx: use thread_local for debug handler callback
If OnceCell is used, then rutabaga_init can only be called once per
process.

This commit fixes the ffi tests for me.

Change-Id: If31792d7679292e4bb63d7442a28effafb181b02
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5232199
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Auto-Submit: Frederick Mayle <fmayle@google.com>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
2024-01-25 02:49:30 +00:00
Junnan Wu
b7191b0188 crosvm: add "writable" option for create_composite
Currently, create_composite generates a read-only composite disk by default.

But in embedded system, sometime we need to use a real disk partition as the
backing file. In this case, it is required to create a writable composite disk.
So an optional "writable" argument is added in the command line.

BUG=b:318862474
TEST=cargo test --features composite-disk
TEST=./tools/presubmit
TEST=create a writable composite disk and use it as the backing of virtio-blk,
     the writing works well.

Signed-off-by: Junnan Wu <junnan01.wu@samsung.com>
Change-Id: I05033473cf28628887926b18fe17429e267f26f3
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5179893
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Alexandre Courbot <acourbot@chromium.org>
2024-01-25 01:50:29 +00:00
Daniel Verkamp
90911a659a Cargo.lock: update to shlex 1.3
This is only used by the e2e_tests, so it should not affect most
downstream projects.

BUG=b:321994092

Change-Id: I42bc550c273d68960174bcf577ea0555cb22ef12
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5232209
Reviewed-by: Frederick Mayle <fmayle@google.com>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
2024-01-24 23:11:36 +00:00
David Brazdil
d04f288a7a kernel_loader: Add support for LZ4-compressed kernels
Kernel images are often stored compressed because they can take up a
significant amount of disk space. One of the popular formats for this is
LZ4. Even though it does not offer the best compression ratio, it excels
at decompression speeds.

On arm64, kernels do not come with their own decompressor like they do
on x86. Instead, it is the job of the bootloader to decompress the
kernel before it is executed.

To this end, add crosvm support for LZ4 decompression of kernel images,
via the Rust-safe lz4_flex library. LZ4 file format is detected
automatically via one of its magic numbers. Otherwise crosvm will fall
back to loading the kernel as a raw image.

Some rough numbers using Android's Generic Kernel Image on Pixel 8:
 * compresion rate: 49% (33MB -> 16MB)
 * decompression time: 20-30ms
Given that the total VM boot takes about 1.5s, the overhead is more than
acceptable.

BUG=b:315141974
TEST=tools/dev_container tools/run_tests --platform=aarch64

Change-Id: I1030abe6fdf7087603cea9ac5273bf9136bad693
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5110323
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Dennis Kempin <denniskempin@google.com>
Commit-Queue: David Brazdil <dbrazdil@google.com>
2024-01-24 22:48:25 +00:00
recipe-roller
b04934054c Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8757997371328177665

depot_tools:
2bc81cdf4f
  2bc81cd (gbeaty@chromium.org)
      Add a canned check for enforcing infra freezes.

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ib1a9b676e795566a49f87d62604fb20a38e19d49
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5232205
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-24 18:37:18 +00:00
Zhenyu Wang
7d57013ab8 dev_container: Pass proxy setting
If running behind proxy, need to pass proxy setting for container as well,
otherwise can't pull crates properly. So this tries to add 'http_proxy'
and 'https_proxy' in environment for container.

Change-Id: I897703f571d9fe5bd03b819fc6b13a9e04384e6f
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5232200
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
2024-01-24 18:36:22 +00:00
recipe-roller
f85f1a4328 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (depot_tools) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8758039526346678785

depot_tools:
097edbaba6
  097edba (akhoroshilov@brave.com)
      [git_cache] Allow expansion of `~` in git cache.cachepath param...

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=denniskempin@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Iadc2b183aae54d1261cbfd3ba53f81cf70054b61
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5231619
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2024-01-24 07:16:42 +00:00
Idan Raiter
5694c8c2ce hypervisor: haxm: Update bindings
Refresh the bindings with newer bindgen, allowing us to get rid of the
clippy errors.

BUG=b:322056705
TEST=boot emulator on HAXM

Change-Id: I1eb455b8fbb39c89c7d9e60a134a305afaa99499
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/5232520
Commit-Queue: Idan Raiter <idanr@google.com>
Reviewed-by: Dennis Kempin <denniskempin@google.com>
2024-01-24 01:42:58 +00:00