History

Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net

Cross-merge networking fixes after downstream PR. No conflicts. Adjacent changes: drivers/net/ethernet/stmicro/stmmac/common.h 38cc3c6dcc09 ("net: stmmac: protect updates of 64-bit statistics counters") fd5a6a71313e ("net: stmmac: est: Per Tx-queue error count for HLBF") c5c3e1bfc9e0 ("net: stmmac: Offload queueMaxSDU from tc-taprio") drivers/net/wireless/microchip/wilc1000/netdev.c c9013880284d ("wifi: fill in MODULE_DESCRIPTION()s for wilc1000") 328efda22af8 ("wifi: wilc1000: do not realloc workqueue everytime an interface is added") net/unix/garbage.c 11498715f266 ("af_unix: Remove io_uring code for GC.") 1279f9d9dec2 ("af_unix: Call kfree_skb() for dead unix_(sk)->oob_skb in GC.")

Jakub Kicinski committed 2 years ago

Commit 3be042c2 parents b6b6145 1f719a2427 files · +4973 −3032Browse files

Showing the changes to tools/include/uapi (7 of 427 files). Show all

Unified · Split

7 files
  1. tools/include/uapi/asm-generic/unistd.h +14 −1
  2. tools/include/uapi/drm/drm.h +71 −1
  3. tools/include/uapi/drm/i915_drm.h +6 −6
  4. tools/include/uapi/linux/fcntl.h +3 −0
  5. tools/include/uapi/linux/kvm.h +50 −90
  6. tools/include/uapi/linux/mount.h +70 −0
  7. tools/include/uapi/linux/stat.h +1 −0
tools/include/uapi/asm-generic/unistd.h+14−1
@@ -829,8 +829,21 @@ __SYSCALL(__NR_futex_wait, sys_futex_wait) · 828 unmodified lines
829829 #define __NR_futex_requeue 456
830830 __SYSCALL(__NR_futex_requeue, sys_futex_requeue)
831831
832+#define __NR_statmount 457
833+__SYSCALL(__NR_statmount, sys_statmount)
834+
835+#define __NR_listmount 458
836+__SYSCALL(__NR_listmount, sys_listmount)
837+
838+#define __NR_lsm_get_self_attr 459
839+__SYSCALL(__NR_lsm_get_self_attr, sys_lsm_get_self_attr)
840+#define __NR_lsm_set_self_attr 460
841+__SYSCALL(__NR_lsm_set_self_attr, sys_lsm_set_self_attr)
842+#define __NR_lsm_list_modules 461
843+__SYSCALL(__NR_lsm_list_modules, sys_lsm_list_modules)
844+
832845 #undef __NR_syscalls
833−#define __NR_syscalls 457
846+#define __NR_syscalls 462
834847
835848 /*
836849 * 32 bit systems traditionally used different
tools/include/uapi/drm/drm.h+71−1
@@ -713,7 +713,8 @@ struct drm_gem_open { · 712 unmodified lines
713713 /**
714714 * DRM_CAP_ASYNC_PAGE_FLIP
715715 *
716− * If set to 1, the driver supports &DRM_MODE_PAGE_FLIP_ASYNC.
716+ * If set to 1, the driver supports &DRM_MODE_PAGE_FLIP_ASYNC for legacy
717+ * page-flips.
717718 */
718719 #define DRM_CAP_ASYNC_PAGE_FLIP 0x7
719720 /**
@@ -773,6 +774,13 @@ struct drm_gem_open { · 53 unmodified lines
773774 * :ref:`drm_sync_objects`.
774775 */
775776 #define DRM_CAP_SYNCOBJ_TIMELINE 0x14
777+/**
778+ * DRM_CAP_ATOMIC_ASYNC_PAGE_FLIP
779+ *
780+ * If set to 1, the driver supports &DRM_MODE_PAGE_FLIP_ASYNC for atomic
781+ * commits.
782+ */
783+#define DRM_CAP_ATOMIC_ASYNC_PAGE_FLIP 0x15
776784
777785 /* DRM_IOCTL_GET_CAP ioctl argument type */
778786 struct drm_get_cap {
@@ -842,6 +850,31 @@ struct drm_get_cap { · 63 unmodified lines
842850 */
843851 #define DRM_CLIENT_CAP_WRITEBACK_CONNECTORS 5
844852
853+/**
854+ * DRM_CLIENT_CAP_CURSOR_PLANE_HOTSPOT
855+ *
856+ * Drivers for para-virtualized hardware (e.g. vmwgfx, qxl, virtio and
857+ * virtualbox) have additional restrictions for cursor planes (thus
858+ * making cursor planes on those drivers not truly universal,) e.g.
859+ * they need cursor planes to act like one would expect from a mouse
860+ * cursor and have correctly set hotspot properties.
861+ * If this client cap is not set the DRM core will hide cursor plane on
862+ * those virtualized drivers because not setting it implies that the
863+ * client is not capable of dealing with those extra restictions.
864+ * Clients which do set cursor hotspot and treat the cursor plane
865+ * like a mouse cursor should set this property.
866+ * The client must enable &DRM_CLIENT_CAP_ATOMIC first.
867+ *
868+ * Setting this property on drivers which do not special case
869+ * cursor planes (i.e. non-virtualized drivers) will return
870+ * EOPNOTSUPP, which can be used by userspace to gauge
871+ * requirements of the hardware/drivers they're running on.
872+ *
873+ * This capability is always supported for atomic-capable virtualized
874+ * drivers starting from kernel version 6.6.
875+ */
876+#define DRM_CLIENT_CAP_CURSOR_PLANE_HOTSPOT 6
877+
845878 /* DRM_IOCTL_SET_CLIENT_CAP ioctl argument type */
846879 struct drm_set_client_cap {
847880 __u64 capability;
@@ -893,6 +926,7 @@ struct drm_syncobj_transfer { · 45 unmodified lines
893926 #define DRM_SYNCOBJ_WAIT_FLAGS_WAIT_ALL (1 << 0)
894927 #define DRM_SYNCOBJ_WAIT_FLAGS_WAIT_FOR_SUBMIT (1 << 1)
895928 #define DRM_SYNCOBJ_WAIT_FLAGS_WAIT_AVAILABLE (1 << 2) /* wait for time point to become available */
929+#define DRM_SYNCOBJ_WAIT_FLAGS_WAIT_DEADLINE (1 << 3) /* set fence deadline to deadline_nsec */
896930 struct drm_syncobj_wait {
897931 __u64 handles;
898932 /* absolute timeout */
@@ -901,6 +935,14 @@ struct drm_syncobj_wait { · 2 unmodified lines
901935 __u32 flags;
902936 __u32 first_signaled; /* only valid when not waiting all */
903937 __u32 pad;
938+ /**
939+ * @deadline_nsec - fence deadline hint
940+ *
941+ * Deadline hint, in absolute CLOCK_MONOTONIC, to set on backing
942+ * fence(s) if the DRM_SYNCOBJ_WAIT_FLAGS_WAIT_DEADLINE flag is
943+ * set.
944+ */
945+ __u64 deadline_nsec;
904946 };
905947
906948 struct drm_syncobj_timeline_wait {
@@ -913,6 +955,14 @@ struct drm_syncobj_timeline_wait { · 6 unmodified lines
913955 __u32 flags;
914956 __u32 first_signaled; /* only valid when not waiting all */
915957 __u32 pad;
958+ /**
959+ * @deadline_nsec - fence deadline hint
960+ *
961+ * Deadline hint, in absolute CLOCK_MONOTONIC, to set on backing
962+ * fence(s) if the DRM_SYNCOBJ_WAIT_FLAGS_WAIT_DEADLINE flag is
963+ * set.
964+ */
965+ __u64 deadline_nsec;
916966 };
917967
918968 /**
@@ -1218,6 +1268,26 @@ extern "C" { · 299 unmodified lines
12181268
12191269 #define DRM_IOCTL_SYNCOBJ_EVENTFD DRM_IOWR(0xCF, struct drm_syncobj_eventfd)
12201270
1271+/**
1272+ * DRM_IOCTL_MODE_CLOSEFB - Close a framebuffer.
1273+ *
1274+ * This closes a framebuffer previously added via ADDFB/ADDFB2. The IOCTL
1275+ * argument is a framebuffer object ID.
1276+ *
1277+ * This IOCTL is similar to &DRM_IOCTL_MODE_RMFB, except it doesn't disable
1278+ * planes and CRTCs. As long as the framebuffer is used by a plane, it's kept
1279+ * alive. When the plane no longer uses the framebuffer (because the
1280+ * framebuffer is replaced with another one, or the plane is disabled), the
1281+ * framebuffer is cleaned up.
1282+ *
1283+ * This is useful to implement flicker-free transitions between two processes.
1284+ *
1285+ * Depending on the threat model, user-space may want to ensure that the
1286+ * framebuffer doesn't expose any sensitive user information: closed
1287+ * framebuffers attached to a plane can be read back by the next DRM master.
1288+ */
1289+#define DRM_IOCTL_MODE_CLOSEFB DRM_IOWR(0xD0, struct drm_mode_closefb)
1290+
12211291 /*
12221292 * Device specific ioctls should only be in their respective headers
12231293 * The device specific ioctl range is from 0x40 to 0x9f.
tools/include/uapi/drm/i915_drm.h+6−6
@@ -693,7 +693,7 @@ typedef struct drm_i915_irq_wait { · 692 unmodified lines
693693 #define I915_PARAM_HAS_EXEC_FENCE 44
694694
695695 /* Query whether DRM_I915_GEM_EXECBUFFER2 supports the ability to capture
696− * user specified bufffers for post-mortem debugging of GPU hangs. See
696+ * user-specified buffers for post-mortem debugging of GPU hangs. See
697697 * EXEC_OBJECT_CAPTURE.
698698 */
699699 #define I915_PARAM_HAS_EXEC_CAPTURE 45
@@ -1606,7 +1606,7 @@ struct drm_i915_gem_busy { · 906 unmodified lines
16061606 * is accurate.
16071607 *
16081608 * The returned dword is split into two fields to indicate both
1609− * the engine classess on which the object is being read, and the
1609+ * the engine classes on which the object is being read, and the
16101610 * engine class on which it is currently being written (if any).
16111611 *
16121612 * The low word (bits 0:15) indicate if the object is being written
@@ -1815,7 +1815,7 @@ struct drm_i915_gem_madvise { · 202 unmodified lines
18151815 __u32 handle;
18161816
18171817 /* Advice: either the buffer will be needed again in the near future,
1818− * or wont be and could be discarded under memory pressure.
1818+ * or won't be and could be discarded under memory pressure.
18191819 */
18201820 __u32 madv;
18211821
@@ -3246,7 +3246,7 @@ struct drm_i915_query_topology_info { · 1424 unmodified lines
32463246 * // enough to hold our array of engines. The kernel will fill out the
32473247 * // item.length for us, which is the number of bytes we need.
32483248 * //
3249− * // Alternatively a large buffer can be allocated straight away enabling
3249+ * // Alternatively a large buffer can be allocated straightaway enabling
32503250 * // querying in one pass, in which case item.length should contain the
32513251 * // length of the provided buffer.
32523252 * err = ioctl(fd, DRM_IOCTL_I915_QUERY, &query);
@@ -3256,7 +3256,7 @@ struct drm_i915_query_topology_info { · 3 unmodified lines
32563256 * // Now that we allocated the required number of bytes, we call the ioctl
32573257 * // again, this time with the data_ptr pointing to our newly allocated
32583258 * // blob, which the kernel can then populate with info on all engines.
3259− * item.data_ptr = (uintptr_t)&info,
3259+ * item.data_ptr = (uintptr_t)&info;
32603260 *
32613261 * err = ioctl(fd, DRM_IOCTL_I915_QUERY, &query);
32623262 * if (err) ...
@@ -3286,7 +3286,7 @@ struct drm_i915_query_topology_info { · 23 unmodified lines
32863286 /**
32873287 * struct drm_i915_engine_info
32883288 *
3289− * Describes one engine and it's capabilities as known to the driver.
3289+ * Describes one engine and its capabilities as known to the driver.
32903290 */
32913291 struct drm_i915_engine_info {
32923292 /** @engine: Engine class and instance. */
tools/include/uapi/linux/fcntl.h+3−0
@@ -116,5 +116,8 @@ · 115 unmodified lines
116116 #define AT_HANDLE_FID AT_REMOVEDIR /* file handle is needed to
117117 compare object identity and may not
118118 be usable to open_by_handle_at(2) */
119+#if defined(__KERNEL__)
120+#define AT_GETATTR_NOSEC 0x80000000
121+#endif
119122
120123 #endif /* _UAPI_LINUX_FCNTL_H */
tools/include/uapi/linux/kvm.h+50−90
@@ -16,76 +16,6 @@ · 15 unmodified lines
1616
1717 #define KVM_API_VERSION 12
1818
19−/* *** Deprecated interfaces *** */
20−
21−#define KVM_TRC_SHIFT 16
22−
23−#define KVM_TRC_ENTRYEXIT (1 << KVM_TRC_SHIFT)
24−#define KVM_TRC_HANDLER (1 << (KVM_TRC_SHIFT + 1))
25−
26−#define KVM_TRC_VMENTRY (KVM_TRC_ENTRYEXIT + 0x01)
27−#define KVM_TRC_VMEXIT (KVM_TRC_ENTRYEXIT + 0x02)
28−#define KVM_TRC_PAGE_FAULT (KVM_TRC_HANDLER + 0x01)
29−
30−#define KVM_TRC_HEAD_SIZE 12
31−#define KVM_TRC_CYCLE_SIZE 8
32−#define KVM_TRC_EXTRA_MAX 7
33−
34−#define KVM_TRC_INJ_VIRQ (KVM_TRC_HANDLER + 0x02)
35−#define KVM_TRC_REDELIVER_EVT (KVM_TRC_HANDLER + 0x03)
36−#define KVM_TRC_PEND_INTR (KVM_TRC_HANDLER + 0x04)
37−#define KVM_TRC_IO_READ (KVM_TRC_HANDLER + 0x05)
38−#define KVM_TRC_IO_WRITE (KVM_TRC_HANDLER + 0x06)
39−#define KVM_TRC_CR_READ (KVM_TRC_HANDLER + 0x07)
40−#define KVM_TRC_CR_WRITE (KVM_TRC_HANDLER + 0x08)
41−#define KVM_TRC_DR_READ (KVM_TRC_HANDLER + 0x09)
42−#define KVM_TRC_DR_WRITE (KVM_TRC_HANDLER + 0x0A)
43−#define KVM_TRC_MSR_READ (KVM_TRC_HANDLER + 0x0B)
44−#define KVM_TRC_MSR_WRITE (KVM_TRC_HANDLER + 0x0C)
45−#define KVM_TRC_CPUID (KVM_TRC_HANDLER + 0x0D)
46−#define KVM_TRC_INTR (KVM_TRC_HANDLER + 0x0E)
47−#define KVM_TRC_NMI (KVM_TRC_HANDLER + 0x0F)
48−#define KVM_TRC_VMMCALL (KVM_TRC_HANDLER + 0x10)
49−#define KVM_TRC_HLT (KVM_TRC_HANDLER + 0x11)
50−#define KVM_TRC_CLTS (KVM_TRC_HANDLER + 0x12)
51−#define KVM_TRC_LMSW (KVM_TRC_HANDLER + 0x13)
52−#define KVM_TRC_APIC_ACCESS (KVM_TRC_HANDLER + 0x14)
53−#define KVM_TRC_TDP_FAULT (KVM_TRC_HANDLER + 0x15)
54−#define KVM_TRC_GTLB_WRITE (KVM_TRC_HANDLER + 0x16)
55−#define KVM_TRC_STLB_WRITE (KVM_TRC_HANDLER + 0x17)
56−#define KVM_TRC_STLB_INVAL (KVM_TRC_HANDLER + 0x18)
57−#define KVM_TRC_PPC_INSTR (KVM_TRC_HANDLER + 0x19)
58−
59−struct kvm_user_trace_setup {
60− __u32 buf_size;
61− __u32 buf_nr;
62−};
63−
64−#define __KVM_DEPRECATED_MAIN_W_0x06 \
65− _IOW(KVMIO, 0x06, struct kvm_user_trace_setup)
66−#define __KVM_DEPRECATED_MAIN_0x07 _IO(KVMIO, 0x07)
67−#define __KVM_DEPRECATED_MAIN_0x08 _IO(KVMIO, 0x08)
68−
69−#define __KVM_DEPRECATED_VM_R_0x70 _IOR(KVMIO, 0x70, struct kvm_assigned_irq)
70−
71−struct kvm_breakpoint {
72− __u32 enabled;
73− __u32 padding;
74− __u64 address;
75−};
76−
77−struct kvm_debug_guest {
78− __u32 enabled;
79− __u32 pad;
80− struct kvm_breakpoint breakpoints[4];
81− __u32 singlestep;
82−};
83−
84−#define __KVM_DEPRECATED_VCPU_W_0x87 _IOW(KVMIO, 0x87, struct kvm_debug_guest)
85−
86−/* *** End of deprecated interfaces *** */
87−
88−
8919 /* for KVM_SET_USER_MEMORY_REGION */
9020 struct kvm_userspace_memory_region {
9121 __u32 slot;
@@ -95,6 +25,19 @@ struct kvm_userspace_memory_region { · 3 unmodified lines
9525 __u64 userspace_addr; /* start of the userspace allocated memory */
9626 };
9727
28+/* for KVM_SET_USER_MEMORY_REGION2 */
29+struct kvm_userspace_memory_region2 {
30+ __u32 slot;
31+ __u32 flags;
32+ __u64 guest_phys_addr;
33+ __u64 memory_size;
34+ __u64 userspace_addr;
35+ __u64 guest_memfd_offset;
36+ __u32 guest_memfd;
37+ __u32 pad1;
38+ __u64 pad2[14];
39+};
40+
9841 /*
9942 * The bit 0 ~ bit 15 of kvm_userspace_memory_region::flags are visible for
10043 * userspace, other bits are reserved for kvm internal use which are defined
@@ -102,6 +45,7 @@ struct kvm_userspace_memory_region { · 1 unmodified line
10245 */
10346 #define KVM_MEM_LOG_DIRTY_PAGES (1UL << 0)
10447 #define KVM_MEM_READONLY (1UL << 1)
48+#define KVM_MEM_GUEST_MEMFD (1UL << 2)
10549
10650 /* for KVM_IRQ_LINE */
10751 struct kvm_irq_level {
@@ -265,6 +209,7 @@ struct kvm_xen_exit { · 157 unmodified lines
265209 #define KVM_EXIT_RISCV_CSR 36
266210 #define KVM_EXIT_NOTIFY 37
267211 #define KVM_EXIT_LOONGARCH_IOCSR 38
212+#define KVM_EXIT_MEMORY_FAULT 39
268213
269214 /* For KVM_EXIT_INTERNAL_ERROR */
270215 /* Emulate instruction failed. */
@@ -518,6 +463,13 @@ struct kvm_run { · 247 unmodified lines
518463 #define KVM_NOTIFY_CONTEXT_INVALID (1 << 0)
519464 __u32 flags;
520465 } notify;
466+ /* KVM_EXIT_MEMORY_FAULT */
467+ struct {
468+#define KVM_MEMORY_EXIT_FLAG_PRIVATE (1ULL << 3)
469+ __u64 flags;
470+ __u64 gpa;
471+ __u64 size;
472+ } memory_fault;
521473 /* Fix the size of the union. */
522474 char padding[256];
523475 };
@@ -945,9 +897,6 @@ struct kvm_ppc_resize_hpt { · 421 unmodified lines
945897 */
946898 #define KVM_GET_VCPU_MMAP_SIZE _IO(KVMIO, 0x04) /* in bytes */
947899 #define KVM_GET_SUPPORTED_CPUID _IOWR(KVMIO, 0x05, struct kvm_cpuid2)
948−#define KVM_TRACE_ENABLE __KVM_DEPRECATED_MAIN_W_0x06
949−#define KVM_TRACE_PAUSE __KVM_DEPRECATED_MAIN_0x07
950−#define KVM_TRACE_DISABLE __KVM_DEPRECATED_MAIN_0x08
951900 #define KVM_GET_EMULATED_CPUID _IOWR(KVMIO, 0x09, struct kvm_cpuid2)
952901 #define KVM_GET_MSR_FEATURE_INDEX_LIST _IOWR(KVMIO, 0x0a, struct kvm_msr_list)
953902
@@ -1201,6 +1150,11 @@ struct kvm_ppc_resize_hpt { · 247 unmodified lines
12011150 #define KVM_CAP_ARM_EAGER_SPLIT_CHUNK_SIZE 228
12021151 #define KVM_CAP_ARM_SUPPORTED_BLOCK_SIZES 229
12031152 #define KVM_CAP_ARM_SUPPORTED_REG_MASK_RANGES 230
1153+#define KVM_CAP_USER_MEMORY2 231
1154+#define KVM_CAP_MEMORY_FAULT_INFO 232
1155+#define KVM_CAP_MEMORY_ATTRIBUTES 233
1156+#define KVM_CAP_GUEST_MEMFD 234
1157+#define KVM_CAP_VM_TYPES 235
12041158
12051159 #ifdef KVM_CAP_IRQ_ROUTING
12061160
@@ -1291,6 +1245,7 @@ struct kvm_x86_mce { · 84 unmodified lines
12911245 #define KVM_XEN_HVM_CONFIG_EVTCHN_2LEVEL (1 << 4)
12921246 #define KVM_XEN_HVM_CONFIG_EVTCHN_SEND (1 << 5)
12931247 #define KVM_XEN_HVM_CONFIG_RUNSTATE_UPDATE_FLAG (1 << 6)
1248+#define KVM_XEN_HVM_CONFIG_PVCLOCK_TSC_UNSTABLE (1 << 7)
12941249
12951250 struct kvm_xen_hvm_config {
12961251 __u32 flags;
@@ -1483,6 +1438,8 @@ struct kvm_vfio_spapr_tce { · 186 unmodified lines
14831438 struct kvm_userspace_memory_region)
14841439 #define KVM_SET_TSS_ADDR _IO(KVMIO, 0x47)
14851440 #define KVM_SET_IDENTITY_MAP_ADDR _IOW(KVMIO, 0x48, __u64)
1441+#define KVM_SET_USER_MEMORY_REGION2 _IOW(KVMIO, 0x49, \
1442+ struct kvm_userspace_memory_region2)
14861443
14871444 /* enable ucontrol for s390 */
14881445 struct kvm_s390_ucas_mapping {
@@ -1507,20 +1464,8 @@ struct kvm_s390_ucas_mapping { · 18 unmodified lines
15071464 _IOW(KVMIO, 0x67, struct kvm_coalesced_mmio_zone)
15081465 #define KVM_UNREGISTER_COALESCED_MMIO \
15091466 _IOW(KVMIO, 0x68, struct kvm_coalesced_mmio_zone)
1510−#define KVM_ASSIGN_PCI_DEVICE _IOR(KVMIO, 0x69, \
1511− struct kvm_assigned_pci_dev)
15121467 #define KVM_SET_GSI_ROUTING _IOW(KVMIO, 0x6a, struct kvm_irq_routing)
1513−/* deprecated, replaced by KVM_ASSIGN_DEV_IRQ */
1514−#define KVM_ASSIGN_IRQ __KVM_DEPRECATED_VM_R_0x70
1515−#define KVM_ASSIGN_DEV_IRQ _IOW(KVMIO, 0x70, struct kvm_assigned_irq)
15161468 #define KVM_REINJECT_CONTROL _IO(KVMIO, 0x71)
1517−#define KVM_DEASSIGN_PCI_DEVICE _IOW(KVMIO, 0x72, \
1518− struct kvm_assigned_pci_dev)
1519−#define KVM_ASSIGN_SET_MSIX_NR _IOW(KVMIO, 0x73, \
1520− struct kvm_assigned_msix_nr)
1521−#define KVM_ASSIGN_SET_MSIX_ENTRY _IOW(KVMIO, 0x74, \
1522− struct kvm_assigned_msix_entry)
1523−#define KVM_DEASSIGN_DEV_IRQ _IOW(KVMIO, 0x75, struct kvm_assigned_irq)
15241469 #define KVM_IRQFD _IOW(KVMIO, 0x76, struct kvm_irqfd)
15251470 #define KVM_CREATE_PIT2 _IOW(KVMIO, 0x77, struct kvm_pit_config)
15261471 #define KVM_SET_BOOT_CPU_ID _IO(KVMIO, 0x78)
@@ -1537,9 +1482,6 @@ struct kvm_s390_ucas_mapping { · 10 unmodified lines
15371482 * KVM_CAP_VM_TSC_CONTROL to set defaults for a VM */
15381483 #define KVM_SET_TSC_KHZ _IO(KVMIO, 0xa2)
15391484 #define KVM_GET_TSC_KHZ _IO(KVMIO, 0xa3)
1540−/* Available with KVM_CAP_PCI_2_3 */
1541−#define KVM_ASSIGN_SET_INTX_MASK _IOW(KVMIO, 0xa4, \
1542− struct kvm_assigned_pci_dev)
15431485 /* Available with KVM_CAP_SIGNAL_MSI */
15441486 #define KVM_SIGNAL_MSI _IOW(KVMIO, 0xa5, struct kvm_msi)
15451487 /* Available with KVM_CAP_PPC_GET_SMMU_INFO */
@@ -1592,8 +1534,6 @@ struct kvm_s390_ucas_mapping { · 46 unmodified lines
15921534 #define KVM_SET_SREGS _IOW(KVMIO, 0x84, struct kvm_sregs)
15931535 #define KVM_TRANSLATE _IOWR(KVMIO, 0x85, struct kvm_translation)
15941536 #define KVM_INTERRUPT _IOW(KVMIO, 0x86, struct kvm_interrupt)
1595−/* KVM_DEBUG_GUEST is no longer supported, use KVM_SET_GUEST_DEBUG instead */
1596−#define KVM_DEBUG_GUEST __KVM_DEPRECATED_VCPU_W_0x87
15971537 #define KVM_GET_MSRS _IOWR(KVMIO, 0x88, struct kvm_msrs)
15981538 #define KVM_SET_MSRS _IOW(KVMIO, 0x89, struct kvm_msrs)
15991539 #define KVM_SET_CPUID _IOW(KVMIO, 0x8a, struct kvm_cpuid)
@@ -2267,4 +2207,24 @@ struct kvm_s390_zpci_op { · 667 unmodified lines
22672207 /* flags for kvm_s390_zpci_op->u.reg_aen.flags */
22682208 #define KVM_S390_ZPCIOP_REGAEN_HOST (1 << 0)
22692209
2210+/* Available with KVM_CAP_MEMORY_ATTRIBUTES */
2211+#define KVM_SET_MEMORY_ATTRIBUTES _IOW(KVMIO, 0xd2, struct kvm_memory_attributes)
2212+
2213+struct kvm_memory_attributes {
2214+ __u64 address;
2215+ __u64 size;
2216+ __u64 attributes;
2217+ __u64 flags;
2218+};
2219+
2220+#define KVM_MEMORY_ATTRIBUTE_PRIVATE (1ULL << 3)
2221+
2222+#define KVM_CREATE_GUEST_MEMFD _IOWR(KVMIO, 0xd4, struct kvm_create_guest_memfd)
2223+
2224+struct kvm_create_guest_memfd {
2225+ __u64 size;
2226+ __u64 flags;
2227+ __u64 reserved[6];
2228+};
2229+
22702230 #endif /* __LINUX_KVM_H */
tools/include/uapi/linux/mount.h+70−0
@@ -138,4 +138,74 @@ struct mount_attr { · 137 unmodified lines
138138 /* List of all mount_attr versions. */
139139 #define MOUNT_ATTR_SIZE_VER0 32 /* sizeof first published struct */
140140
141+
142+/*
143+ * Structure for getting mount/superblock/filesystem info with statmount(2).
144+ *
145+ * The interface is similar to statx(2): individual fields or groups can be
146+ * selected with the @mask argument of statmount(). Kernel will set the @mask
147+ * field according to the supported fields.
148+ *
149+ * If string fields are selected, then the caller needs to pass a buffer that
150+ * has space after the fixed part of the structure. Nul terminated strings are
151+ * copied there and offsets relative to @str are stored in the relevant fields.
152+ * If the buffer is too small, then EOVERFLOW is returned. The actually used
153+ * size is returned in @size.
154+ */
155+struct statmount {
156+ __u32 size; /* Total size, including strings */
157+ __u32 __spare1;
158+ __u64 mask; /* What results were written */
159+ __u32 sb_dev_major; /* Device ID */
160+ __u32 sb_dev_minor;
161+ __u64 sb_magic; /* ..._SUPER_MAGIC */
162+ __u32 sb_flags; /* SB_{RDONLY,SYNCHRONOUS,DIRSYNC,LAZYTIME} */
163+ __u32 fs_type; /* [str] Filesystem type */
164+ __u64 mnt_id; /* Unique ID of mount */
165+ __u64 mnt_parent_id; /* Unique ID of parent (for root == mnt_id) */
166+ __u32 mnt_id_old; /* Reused IDs used in proc/.../mountinfo */
167+ __u32 mnt_parent_id_old;
168+ __u64 mnt_attr; /* MOUNT_ATTR_... */
169+ __u64 mnt_propagation; /* MS_{SHARED,SLAVE,PRIVATE,UNBINDABLE} */
170+ __u64 mnt_peer_group; /* ID of shared peer group */
171+ __u64 mnt_master; /* Mount receives propagation from this ID */
172+ __u64 propagate_from; /* Propagation from in current namespace */
173+ __u32 mnt_root; /* [str] Root of mount relative to root of fs */
174+ __u32 mnt_point; /* [str] Mountpoint relative to current root */
175+ __u64 __spare2[50];
176+ char str[]; /* Variable size part containing strings */
177+};
178+
179+/*
180+ * Structure for passing mount ID and miscellaneous parameters to statmount(2)
181+ * and listmount(2).
182+ *
183+ * For statmount(2) @param represents the request mask.
184+ * For listmount(2) @param represents the last listed mount id (or zero).
185+ */
186+struct mnt_id_req {
187+ __u32 size;
188+ __u32 spare;
189+ __u64 mnt_id;
190+ __u64 param;
191+};
192+
193+/* List of all mnt_id_req versions. */
194+#define MNT_ID_REQ_SIZE_VER0 24 /* sizeof first published struct */
195+
196+/*
197+ * @mask bits for statmount(2)
198+ */
199+#define STATMOUNT_SB_BASIC 0x00000001U /* Want/got sb_... */
200+#define STATMOUNT_MNT_BASIC 0x00000002U /* Want/got mnt_... */
201+#define STATMOUNT_PROPAGATE_FROM 0x00000004U /* Want/got propagate_from */
202+#define STATMOUNT_MNT_ROOT 0x00000008U /* Want/got mnt_root */
203+#define STATMOUNT_MNT_POINT 0x00000010U /* Want/got mnt_point */
204+#define STATMOUNT_FS_TYPE 0x00000020U /* Want/got fs_type */
205+
206+/*
207+ * Special @mnt_id values that can be passed to listmount
208+ */
209+#define LSMT_ROOT 0xffffffffffffffff /* root mount */
210+
141211 #endif /* _UAPI_LINUX_MOUNT_H */
tools/include/uapi/linux/stat.h+1−0
@@ -154,6 +154,7 @@ struct statx { · 153 unmodified lines
154154 #define STATX_BTIME 0x00000800U /* Want/got stx_btime */
155155 #define STATX_MNT_ID 0x00001000U /* Got stx_mnt_id */
156156 #define STATX_DIOALIGN 0x00002000U /* Want/got direct I/O alignment info */
157+#define STATX_MNT_ID_UNIQUE 0x00004000U /* Want/got extended stx_mount_id */
157158
158159 #define STATX__RESERVED 0x80000000U /* Reserved for future struct statx expansion */
159160