Commit Graph

917 Commits

Author SHA1 Message Date
Julian Seward
ac60633d65 Bug 345248 - add support for Solaris OS in valgrind
Authors of this port:
    Petr Pavlu         setup@dagobah.cz
    Ivo Raisr          ivosh@ivosh.net
    Theo Schlossnagle  theo@omniti.com
            


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15426
2015-07-21 14:44:28 +00:00
Rhys Kidd
dd23e30c68 OS X 10.11: Tweak magic offset, which was amended prior to xnu-3247.1.36~7 (DP3). Also align some debug output text between x86 and amd64. bz#348909.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15411
2015-07-12 13:25:55 +00:00
Rhys Kidd
042441c57f Fix Valgrind does not support pthread_sigmask() on OS X
bz#201216

On OS X 10.10

Before:

== 592 tests, 220 stderr failures, 15 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

After:

== 592 tests, 219 stderr failures, 15 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15410
2015-07-12 06:54:56 +00:00
Julian Seward
2ac4c69401 Fix "346411 MIPS: SysRes::_valEx handling is incorrect"
Specialise type SysRes for mips{32,64}-linux to enable 
meaningful equality comparisons.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15404
2015-07-08 17:08:23 +00:00
Rhys Kidd
0fcd971d15 Preliminary support for OS X 10.11 (El Capitan). Refer BZ#348909 for ongoing work.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15403
2015-07-08 13:46:57 +00:00
Florian Krohm
7a474c9455 Fix typos in source code. Patch by Dmitriy (olshevskiy87@bk.ru).
Fixes BZ #349874


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15394
2015-07-05 21:53:33 +00:00
Bart Van Assche
a914bcf7f5 xen: Implement physdev_op and map_pirq
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15385
2015-06-28 16:57:10 +00:00
Bart Van Assche
b64fedcf91 xen: Implement the xsm_op hypercall
More recent Xen toolstacks use this for the SID_TO_CONTEXT operation
only, even when XSM is not in use.

XSM is actually an abstraction layer, of which the only current
implementation is FLASK. So this blindly assumes that the backend is
FLASK. Should another XSM backend be invented then we will have to
sort of detecting the correct one.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15384
2015-06-28 16:55:45 +00:00
Bart Van Assche
31229b7020 xen: syswrap XEN_SCHEDOP_remote_shutdown
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15383
2015-06-28 16:53:58 +00:00
Bart Van Assche
d2a0392539 xen: Basic syswrap infrastructure for XEN_sched_op hypercalls
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15381
2015-06-28 16:48:22 +00:00
Bart Van Assche
f49647fd78 xen: Implement memory map hypercalls
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15380
2015-06-28 16:47:13 +00:00
Bart Van Assche
7a8a964019 xen: syswrap XENMEM_machphys_compat_mfn_list
XENMEM_machphys_compat_mfn_list is functionally identical to
XENMEM_machphys_mfn_list but returns a different list from Xen.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15379
2015-06-28 16:46:30 +00:00
Bart Van Assche
15667c1499 syswrap-xen.c: Make indentation consistent
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15378
2015-06-28 16:45:44 +00:00
Bart Van Assche
b51ec07994 xen: syswrap XEH_HVMOP_set_pci_intx_level
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15377
2015-06-28 16:44:21 +00:00
Bart Van Assche
56e19e386d xen: syswrap XEN_HVMOP_track_dirty_vram
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15376
2015-06-28 16:43:14 +00:00
Bart Van Assche
04c609b998 xen: implement VKI_XEN_DOMCTL_irq_permission
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15375
2015-06-28 16:42:38 +00:00
Bart Van Assche
278a3d1df5 xen: support for XEN_DOMCTL_iomem_permission
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15374
2015-06-28 16:42:05 +00:00
Bart Van Assche
e93aa3706d xen: Handle XEN_DOMCTL_{test_assign,assign,deassign}_device
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Cc: Andrew Cooper <andrew.cooper3@citrix.com


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15373
2015-06-28 16:41:06 +00:00
Bart Van Assche
3fc699dda3 xen: Handle XEN_DOMCTL_SHADOW_OP_{GET,SET}_ALLOCATION
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15372
2015-06-28 16:39:47 +00:00
Bart Van Assche
8269099b13 xen: syswrap XEN_DOMCTL_pin_mem_cacheattr
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15371
2015-06-28 16:38:40 +00:00
Bart Van Assche
10d6d0a7ad xen: syswrap XEN_DOMCTL_[gs]et_vcpu_msrs
The XEN_DOMCTL_[gs]et_vcpu_msrs work simiarly to the other get/set pairs,
taking a vcpu, buffer and size.  A query with a buffer of NULL is a request
for the maximum size.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15370
2015-06-28 16:37:54 +00:00
Bart Van Assche
7806d251be xen: syswrap XEN_DOMCTL_[gs]et_ext_vcpustate
The VKI_XEN_DOMCTL_[gs]et_ext_vcpucontext hypercalls have had interface
changes, but are largly just extentions of the existing structure.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15369
2015-06-28 16:36:30 +00:00
Bart Van Assche
26c53cda38 xen: syswrap XEN_DOMCTL_setvcpuextstate
XEN_DOMCTL_setvcpuextstate reads a vcpu, size and buffer pointer, and reads
size bytes from the buffer.  It has no outputs.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15368
2015-06-28 16:35:13 +00:00
Bart Van Assche
1b6ca5d030 xen: Fix XEN_DOMCTL_getvcpuextstate
Xen only writes into the provided buffer if the guest handle was not NULL.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15367
2015-06-28 16:34:20 +00:00
Bart Van Assche
b1e2a3e6a1 xen: Add domctl interface version 0x0000000a
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15366
2015-06-28 16:33:04 +00:00
Bart Van Assche
c35715d20a xen: Add support for new sysctl and domctl interface versions
The change causing the sysctl bump is not in an implemented subop yet, so no
change is required.  The change causing the domctl bump is in an implemented
subop, but has also been reverted in favor of a different way of performing
the same actions.  Therefore, there is no net difference.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15365
2015-06-28 16:31:54 +00:00
Bart Van Assche
4e84ded15a xen: refactor the various "version not supported" messages into a single helper
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15364
2015-06-28 16:30:36 +00:00
Rhys Kidd
9b3e7344ca Fix incorrect sizeof expression in syswrap-xen.c, reported by Coverity (#1233786)
n-i-bz

Reviewed-by: Ian Campbell <ian.campbell@citrix.com>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15361
2015-06-28 04:06:30 +00:00
Philippe Waroquiers
8c8cd6c9fc 324181 mmap does not handle MAP_32BIT (handle it now, rather than fail it)
324181 was previously closed with a solution to always make
MAP_32BIT fail. This is technically correct/according to the doc,
but is not very usable.
This patch ensures that MAP_32BIT mmap is succesful, as long as
aspacemgr gives a range in the first 2GB
(so, compared to a native run, MAP_32BIT will fail much more quickly
as aspacemgr does not reserve the address space below 2GB on a 64 bits).

Far to be perfect, but this is better than nothing.

Added a regression test that test succesful mmap 32 bits till
the 2GB limit is reached.




git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15341
2015-06-17 19:57:09 +00:00
Rhys Kidd
700aa31d8d Fix UNKNOWN task message [id 3410, to mach_task_self(), reply 0x........] (task_set_special_port)
bz#349087

On OS X 10.10

Before:

== 592 tests, 222 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

After:

== 592 tests, 222 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15339
2015-06-13 22:59:47 +00:00
Rhys Kidd
e35b06fbb8 Fix UNKNOWN task message [id 3406, to mach_task_self(), reply 0x........] (task_set_info)
bz#349086

On OS X 10.10

Before:

== 592 tests, 222 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

After:

== 592 tests, 222 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15336
2015-06-13 06:16:10 +00:00
Christian Borntraeger
c2baee9b7b add KVM_S390_MEMOP ioctl handling
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15334
2015-06-12 10:54:12 +00:00
Rhys Kidd
0f1f6e7bdc Memcheck on multithreaded program fails with Assertion 'sizeof(UWord) == sizeof(UInt)' failed in m_syscall.c
bz#302630
== bz#326797

On OS X 10.7 and OS X 10.8

Before:

== 598 tests, 201 stderr failures, 12 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

After:

== 598 tests, 200 stderr failures, 12 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15329
2015-06-08 11:07:48 +00:00
Julian Seward
a4d69434b8 Bug 348728 - Fix broken check for VIDIOC_G_ENC_INDEX
Patch from Hans Verkuil (hverkuil@xs4all.nl)


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15314
2015-06-05 11:25:32 +00:00
Julian Seward
eed8fbcd80 Bug 348102 - Patch updating v4l2 API support (edit)
Patch from Hans Verkuil (hverkuil@xs4all.nl) 


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15313
2015-06-05 11:23:35 +00:00
Mark Wielaard
9c0019f28a Enable process_vm_readv/writev syscall on arm32.
This makes none/tests/process_vm_readv_writev.vgtest pass on arm32.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15304
2015-06-02 18:17:44 +00:00
Rhys Kidd
d289179fd2 Fix OS X host_create_mach_voucher: UNKNOWN host message [id 222, to mach_host_self(), reply 0x........]
bz#343649

Before:

== 591 tests, 220 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

After:

== 591 tests, 220 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15299
2015-05-31 03:17:53 +00:00
Rhys Kidd
c8440021c5 Fix OS X host_get_special_port: UNKNOWN host message [id 412, to mach_host_self(), reply 0x........]
bz#343525

Before:

== 591 tests, 220 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

After:

== 591 tests, 220 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15298
2015-05-31 01:58:57 +00:00
Rhys Kidd
11f675de8b Fix unhandled syscall: mach:41 (_kernelrpc_mach_port_guard_trap)
bz#344337

Before:

== 591 tests, 220 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

After:

== 591 tests, 220 stderr failures, 14 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15297
2015-05-30 08:59:46 +00:00
Rhys Kidd
11a09e916d Address clang compiler warnings on OS X.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15288
2015-05-25 14:43:47 +00:00
Julian Seward
9dc5a73468 Fix bug 345126: Incorrect handling of VIDIOC_G_AUDIO and G_AUDOUT
Patch from Hans Verkuil (hverkuil@xs4all.nl)


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15276
2015-05-22 10:40:42 +00:00
Rhys Kidd
2a3a28aecf Fix unhandled syscall: unix:473 (readlinkat) on OS X 10.10
bz#344936

Before:

== 595 tests, 229 stderr failures, 23 stdout failures, 1 stderrB failure, 1 stdoutB failure, 30 post failures ==

After:

== 595 tests, 228 stderr failures, 23 stdout failures, 1 stderrB failure, 1 stdoutB failure, 30 post failures ==


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15260
2015-05-20 13:31:02 +00:00
Rhys Kidd
b291112485 Improve documentation of syscall: unix: 44 profil() which was deprecated around OS X 10.6 and removed from the xnu kernel shipped with OS X 10.7. See unresolved bz#264253.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15259
2015-05-20 11:31:35 +00:00
Rhys Kidd
793b9629dc Fix unhandled syscall: unix:410 (sigsuspend_nocancel) on OS X. bz#319274.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15249
2015-05-17 14:02:34 +00:00
Philippe Waroquiers
ae1a9287d8 Add some more cfi directives
With some gcc versions, without these directives, unwind does
not work or gives strange entries in stack traces.

Patch from Matthias Schwarzott 



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15247
2015-05-17 08:24:40 +00:00
Rhys Kidd
57d82d1527 Fix Warning: noted but unhandled ioctl 0x2000747b on Mac OS X. bz#208217.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15246
2015-05-17 07:31:20 +00:00
Rhys Kidd
8763533866 Followup to r15242 - as PRE() and POST() wrappers utilised, define with the *XY variant.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15245
2015-05-17 06:01:04 +00:00
Rhys Kidd
0c10aa2460 Fix unhandled syscall: unix:132 (mkfifo) on OS X. bz#212291.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15242
2015-05-16 14:48:08 +00:00
Florian Krohm
c000459632 Fix bug in do_mremap. Also need to allow SkShmC segments.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15219
2015-05-12 21:19:25 +00:00
Rhys Kidd
6e3d1f9b0a Fix typo in task_policy_set() output. n-i-bz.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15210
2015-05-11 13:24:42 +00:00