Commit Graph

16 Commits

Author SHA1 Message Date
Martin Jansa
b12fb49843 libvmi: ignore incompatible-pointer-types
* temporary work around to unblock gcc-15 upgrade in oe-core

Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2025-05-06 01:45:13 +00:00
Bruce Ashfield
db81cacee3 libvmi: update v0.14.0-tip
Bumping libvmi to version v0.10-1144-gf02aeb7, which comprises the following commits:

    f02aeb7 implement Windows PTE resolving (#1074)
    8f9b010 update memory size properties as modified by daf350644dc in mmap logic (#1097)
    60ddb31 Add KF/x's rwmem to examples (#1107)
    033a0ec Add vmi_get_domain_status and Xen driver implementation (#1106)
    932c602 add vmi_mmap_guest_pa method (#1103)
    bdb9ffb Fix memory leak in read-disk-example.c (#1102)
    2d7258b Move mmap option from source to CMake config (#1101)
    c85b701 Export events.h only once if multiple drivers support it (#1100)
    ea5d6ad Remove centos CI tests (#1099)
    df8547f Set mem-range access, read wstrings, get last PF (#1095)

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2025-03-25 03:28:19 +00:00
Bruce Ashfield
623219b362 libvmi: update -tip
Bumping libvmi to version v0.10-1135-gdf8547f, which comprises the following commits:

    df8547f Set mem-range access, read wstrings, get last PF (#1095)
    fba6232 driver_wrapper: fix debug prints (#1094)
    8f37f07 Xen: fix calculation of ram size (#1092)
    071d81f Ensure that the third level descriptor is valid prior to returning (#1091)
    a2438e8 CMake: Adjust scope of linked libraries (#1089)
    d048e41 Kvm: Fix events not being processed during shutdown  (#1038)
    782bfff Implement SLAT for kvm (#1043)
    9bf6b62 Fill offset field for singlestep events (#1088)
    72ef3aa Add missing event clear wiring (#1087)
    e707440 Reduce cognitive complexity of kvm_events.c (#1086)
    bcc057c Add DIRTY bit definition (#1085)
    12d3a8c Fix bug not looking up xc_domain_setmaxmem (#1084)
    d4f95a5 New physical page api (#1083)
    1b47190 Feature/osx_support (#1078)
    b9691ca driver interface, xen driver: added prot flag to mmap interface (#1082)
    f47a568 Xen 4.18 support (#1081)
    0332ac2 fix KPCR read on Windows x86 (#1077)
    3c42697 examples: add missing long_opts array terminator (#1079)
    e2313cc Remove cached config entry as part of vmi_destroy function (#1076)
    8a79057 Use actions/checkout@v3 (#1075)
    d5b0177 Sanitize input for PE parser (#1073)
    0f832eb Symbol RVA translation for ELF executables and shared libraries (#1072)
    f2bfd4a Adding basic support for reading an ARM64 memory dump (#1070)
    d2f3fe9 Change xen vbd state check from 1 to 4 (#1069)
    9166fd6 Revise Xen minor version sanity checking logic (#1068)
    79ace5c Fix documentation url (#1067)
    c0edc27 Adjust xc_monitor_io availability (#1066)
    3fe7e6e I/O event hooking, firmware type check (#1045)
    63a6a2d Split complexity from scan-build CI test (#1065)
    a95e99e Calculate cognitive complexity score as part of scan-build (#1062)
    db93f47 Address to kernel symbol translation for windows (#1056)
    dd919a6 linux: use more strickt checks while initializing linux kaslr (#1060)
    9dee43c Skip consecutive PD/PT entries for Windows 10 in vmi_get_va_pages (#1055)
    afb05d0 Fix x64 windows address translation (#1054)
    5662dba Create SECURITY.md
    36bcb2c Return success if whole region is unmapped (#1050)
    38ff0db Fix struct layout warning in kvm.c (#1051)
    fecdb1f Revert "Revert "Limit single step dispatch to successful events to harmonize KVM / XEN behavior (#1040)" (#1047)" (#1049)
    b26888c Rework mem-event-example (#1048)
    68a4a69 Revert "Limit single step dispatch to successful events to harmonize KVM / XEN behavior (#1040)" (#1047)
    546e2e3 Fix vmi_read_str on page boundary (#1046)
    78a9512 Limit single step dispatch to successful events to harmonize KVM / XEN behavior (#1040)
    7328e9e Fix memory cache remove (#1042)
    92f9f70 Kvm: Implement pause counter (#1039)
    50d256b Pop pending events after pausing vm (#1026)
    0cb5db8 Add support for new Xen event type for vm exits (#1036)
    5edc478 Kvm: Flush pages from memory cache after write operation (#1035)
    ff2c1c9 Fix memory corruption in kvm interrupt event handling (#1034)
    09be0ef cmake: add ZLIB detection (#1033)
    932a87a vbd: fix uncompression of qcow2 cluster (#1032)
    26152fc vbd: Add support for JSON format of qcow2 backing file description (#1030)
    afd541b vbd: Remove some copy-paste in qcow2 reading code (#1031)
    1d17c98 vbd: Fix memory leak in uncompress_cluster (#1029)
    6859024 Fix vmi_init_paging issue on ARM64/ZCU102 (#1028)
    710b0a5 Fix double free corruption (#1027)
    7c0c537 Kvm: Ensure monitor_intr_on ist set to false in error case (#1025)
    f51d3fd Add kvm support for swap/clear events (#1024)
    c87a1fb Remove xen includes from vbd.c (#1023)
    45b32c0 Switch pid cache to g_direct_hash/equal (#1021)
    f108304 Use g_direct_hash/equal everywhere (#1020)
    b34cb61 Plug holes in events ABI and bump ABI version (#1019)
    f9db2f4 Use g_direct_hash/direct_equal for generic mem_events (#1018)
    41600b6 Actually define __XS_EVENT_REASON_MAX (#1016)

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-03-15 17:17:20 +00:00
Bruce Ashfield
08435d20b1 recipes/classes/scripts: Drop SRCPV usage
bitbake has been enhanced such that SRCPV is no longer needed in
PV to handle updating git hashes and task signatures.

We can simplify our PV by dropping SRCPV

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-08-24 01:38:21 +00:00
Martin Jansa
d61d6cff9c libvmi: add dependency on autoconf-archive-native
* since https://git.openembedded.org/openembedded-core/commit/?id=571132415ea7fe2d91c62948f2b6aa553eafa83d
  this doesn't get autoconf-archive-native dependency and fails with:
  http://errors.yoctoproject.org/Errors/Details/708195/

  ./configure: line 14424: syntax error near unexpected token `-fno-strict-overflow,'
  ./configure: line 14424: `  AX_CHECK_COMPILE_FLAG(-fno-strict-overflow, HARDEN_CFLAGS="$HARDEN_CFLAGS -fno-strict-overflow", , -Werror )'

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-06-15 17:42:11 -04:00
Martin Jansa
7de3e4e51a libvmi: add dependency on flex-native and bison-native instead of byacc-native
* fails to build with byacc-native 20230219 from:
  https://git.openembedded.org/meta-openembedded/commit/?id=3462709d651f44f3d067b3ce0bcfba876be9ff1d

* https://invisible-island.net/byacc/CHANGES.html#index-t20230219 says:
  provide for a named union, e.g., "%union foo" by detecting the name and
  deferring the typedef in that case until the end of copying the union
  definition (report by Dag-Erling Smørgrav).

  which in this case leads to this diff (compared to byacc 20230201):

  --- 0.14.0+gitAUTOINC+41600b6028-r0-byacc_20230201/git/libvmi/config/grammar.c  2023-05-03 07:44:51.694234317 +0000
  +++ 0.14.0+gitAUTOINC+41600b6028-r0-byacc_20230219/git/libvmi/config/grammar.c  2023-05-03 07:37:14.177205785 +0000
  @@ -5,7 +5,7 @@
   #define YYBYACC 1
   #define YYMAJOR 2
   #define YYMINOR 0
  -#define YYPATCH 20230201
  +#define YYPATCH 20230219

   #define YYEMPTY        (-1)
   #define yyclearin      (yychar = YYEMPTY)
  @@ -273,7 +273,7 @@
   #ifndef YYSTYPE_IS_DECLARED
   #define YYSTYPE_IS_DECLARED 1
   #line 249 "libvmi/config/grammar.y"
  -typedef union YYSTYPE{
  +typedef union YYSTYPE�(�o&V{
       char *str;
   } YYSTYPE;
   #endif /* !YYSTYPE_IS_DECLARED */

* and the unicode chars after YYSTYPE lead to:
  http://errors.yoctoproject.org/Errors/Details/702745/

libvmi/config/grammar.y:249:22: error: stray '\370' in program
  249 | %union{
      |                      ^
libvmi/config/grammar.y:249:25: error: expected ')' before '+' token
  249 | %union{
      |                         ^
      |                         )
libvmi/config/grammar.y:249:26: error: stray '\3' in program
  249 | %union{
      |                          ^
make[1]: *** [Makefile:1997: libvmi/config/libconfig_la-grammar.lo] Error 1

* bison-native works fine, so use that for now

* I've reported this issue to byacc author over e-mail

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-05-08 18:41:38 -04:00
He Zhe
1f9c37e1a6 libvmi: Fix out of box build failure with xen disabled
vbd was added for xen based VMs since
bdee00fac9b4 ("Disk reading interface for Xen based VMs and example")
and should be built only when xen is enabled, otherwise there would not be
necessary xen headers and cause the following failure.

Signed-off-by: He Zhe <zhe.he@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-04-13 23:16:49 -04:00
Bruce Ashfield
cd8f8873a0 libvmi: update to 0.14-tip
Bumping libvmi to version v0.10-1073-g41600b6, which comprises the following commits:

    41600b6 Actually define __XS_EVENT_REASON_MAX (#1016)

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-03-29 08:11:27 -04:00
Bruce Ashfield
108e089f7e global: update licence values to SPDX values
These changes are the result of running the convert-spdx-licenses.py
oe-core script.

There's no impact to the build, but we will avoid issues when
interacting with core QA by the alignment.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-02-18 13:07:10 -05:00
Bruce Ashfield
0a7ae8bc50 global: convert github SRC_URIs to use https protocol
github is removing git:// access, and fetches will start experiencing
interruptions in service, and eventually will fail completely.

bitbake will also begin to warn on github src_uri's that don't use
https. So we convert the meta-virt instances to use protocol=https
(done using the oe-core contrib conversion script)

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-11-02 09:57:03 -04:00
Bruce Ashfield
ac399ad091 global: add explicit branch to all SRC_URIs
As introduced in the oe-core post:

  https://lists.openembedded.org/g/openembedded-core/message/157623

SRC_URIs without an explicit branch will generate warnings, and
eventually be an error.

We run the provided conversion script to make sure that meta-virt
is ready for the change.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-11-02 09:57:03 -04:00
Bruce Ashfield
d876cfc5bf global: overrides syntax conversion
OEcore/bitbake are moving to use the clearer ":" as an overrides
separator.

This is pass one of updating the meta-virt recipes to use that
syntax.

This has only been minimally build/runtime tested, more changes
will be required for missed overrides, or incorrect conversions

Note: A recent bitbake is required:

    commit 75fad23fc06c008a03414a1fc288a8614c6af9ca
    Author: Richard Purdie <richard.purdie@linuxfoundation.org>
    Date:   Sun Jul 18 12:59:15 2021 +0100

        bitbake: data_smart/parse: Allow ':' characters in variable/function names

        It is becomming increasingly clear we need to find a way to show what
        is/is not an override in our syntax. We need to do this in a way which
        is clear to users, readable and in a way we can transition to.

        The most effective way I've found to this is to use the ":" charater
        to directly replace "_" where an override is being specified. This
        includes "append", "prepend" and "remove" which are effectively special
        override directives.

        This patch simply adds the character to the parser so bitbake accepts
        the value but maps it back to "_" internally so there is no behaviour
        change.

        This change is simple enough it could potentially be backported to older
        version of bitbake meaning layers using the new syntax/markup could
        work with older releases. Even if other no other changes are accepted
        at this time and we don't backport, it does set us on a path where at
        some point in future we could
        require a more explict syntax.

        I've tested this patch by converting oe-core/meta-yocto to the new
        syntax for overrides (9000+ changes) and then seeing that builds
        continue to work with this patch.

        (Bitbake rev: 0dbbb4547cb2570d2ce607e9a53459df3c0ac284)

        Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-08-02 17:17:53 -04:00
Bruce Ashfield
d281b8b55c libvmi: upadte to 0.14.0
Integrating the following commits:

   3f5b0d5 Wire up cpuid events on kvmi (#975)
   8cdef96 Clear up event example even more (#974)
   548da8d Simplify event-example (#973)
   cffe055 Clean up on partial init failure (#972)
   fb2e006 Add snapcraft.yaml (#961)
   582fc95 Add vmtrace (IPT) buffer offset to vm_event ABI (#960)
   8b88b72 Turn on all debug options for scan-build test (#959)
   719d90f Debug print in volatility_ist can segfault, fix (#958)
   19379a9 Remove temp file accidentaly added to git (#957)
   f686145 Nested support (#956)
   6d65cc3 Add AC_PROG_CC_C99 to configure.ac (#955)
   e21df55 Add more files to gitignore (#954)
   d9e490e Container build test (#953)
   c68d899 Switch to using Github Actions for CI (#952)
   6d07174 Bump version to 0.15.0 (odd-numbered dev version) (#951)
   1ae3950 examples: fix reinjection in breakpoint-recoil-example (#945)

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-06-04 08:43:11 -04:00
Zqiang
31a5facbef libvmi: uprev from 0.12 to 0.14
Bump version to 0.14.
This upgrade is mainly to fix some BUG.

Signed-off-by: Zqiang <qiang.zhang@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-03-30 16:42:07 -04:00
Bruce Ashfield
b74c0d4ec2 libvmi: add byacc-native to the DEPENDS
libvmi is looking for yacc during configuration, so we must add it to
our DEPENDS as a native tool.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2018-11-16 13:51:35 -05:00
Hongzhi.Song
e2ab59ec3e libvmi: add a new recipe
LibVMI is a C library with Python bindings that makes it easy to
monitor the low-level details of a running virtual machine by
viewing its memory, trapping on hardware events, and accessing
the vCPU registers. This is called virtual machine introspection.

Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2018-07-26 10:40:26 -04:00