drm-misc-next for 5.11: UAPI Changes: Cross-subsystem Changes: * char/agp: Disable frontend without CONFIG_DRM_LEGACY * mm: Fix fput in mmap error path; Introduce vma_set_file() to change vma->vm_file Core Changes: * dma-buf: Use sgtables in system heap; Move heap helpers to CMA-heap code; Skip sync for unmapped buffers; Alloc higher order pages is available; Respect num_fences when initializing shared fence list * doc: Improvements around DRM modes and SCALING_FILTER * Pass full state to connector atomic functions + callee updates * Cleanups * shmem: Map pages with caching by default; Cleanups * ttm: Fix DMA32 for global page pool * fbdev: Cleanups * fb-helper: Update framebuffer after userspace writes; Unmap console buffer during shutdown; Rework damage handling of shadow framebuffer Driver Changes: * amdgpu: Multi-hop fixes, Clenaups * imx: Fix rotation for Vivante tiled formats; Support nearest-neighour skaling; Cleanups * mcde: Fix RGB formats; Support DPI output; Cleanups * meson: HDMI clock fixes * panel: Add driver and bindings for Innolux N125HCE-GN1 * panel/s6e63m0: More backlight levels; Fix init; Cleanups * via: Clenunps * virtio: Use fence ID for handling fences; Cleanups
Showing the changes to include/uapi (2 of 70 files). Show all
Unified · Split
| @@ -218,6 +218,27 @@ extern "C" { · 217 unmodified lines | |||
| 218 | #define DRM_MODE_CONTENT_PROTECTION_DESIRED 1 | 218 | #define DRM_MODE_CONTENT_PROTECTION_DESIRED 1 |
| 219 | #define DRM_MODE_CONTENT_PROTECTION_ENABLED 2 | 219 | #define DRM_MODE_CONTENT_PROTECTION_ENABLED 2 |
| 220 | 220 | ||
| 221 | /** | ||
| 222 | * struct drm_mode_modeinfo - Display mode information. | ||
| 223 | * @clock: pixel clock in kHz | ||
| 224 | * @hdisplay: horizontal display size | ||
| 225 | * @hsync_start: horizontal sync start | ||
| 226 | * @hsync_end: horizontal sync end | ||
| 227 | * @htotal: horizontal total size | ||
| 228 | * @hskew: horizontal skew | ||
| 229 | * @vdisplay: vertical display size | ||
| 230 | * @vsync_start: vertical sync start | ||
| 231 | * @vsync_end: vertical sync end | ||
| 232 | * @vtotal: vertical total size | ||
| 233 | * @vscan: vertical scan | ||
| 234 | * @vrefresh: approximate vertical refresh rate in Hz | ||
| 235 | * @flags: bitmask of misc. flags, see DRM_MODE_FLAG_* defines | ||
| 236 | * @type: bitmask of type flags, see DRM_MODE_TYPE_* defines | ||
| 237 | * @name: string describing the mode resolution | ||
| 238 | * | ||
| 239 | * This is the user-space API display mode information structure. For the | ||
| 240 | * kernel version see struct drm_display_mode. | ||
| 241 | */ | ||
| 221 | struct drm_mode_modeinfo { | 242 | struct drm_mode_modeinfo { |
| 222 | __u32 clock; | 243 | __u32 clock; |
| 223 | __u16 hdisplay; | 244 | __u16 hdisplay; |
| @@ -368,27 +389,95 @@ enum drm_mode_subconnector { · 144 unmodified lines | |||
| 368 | #define DRM_MODE_CONNECTOR_WRITEBACK 18 | 389 | #define DRM_MODE_CONNECTOR_WRITEBACK 18 |
| 369 | #define DRM_MODE_CONNECTOR_SPI 19 | 390 | #define DRM_MODE_CONNECTOR_SPI 19 |
| 370 | 391 | ||
| 392 | /** | ||
| 393 | * struct drm_mode_get_connector - Get connector metadata. | ||
| 394 | * | ||
| 395 | * User-space can perform a GETCONNECTOR ioctl to retrieve information about a | ||
| 396 | * connector. User-space is expected to retrieve encoders, modes and properties | ||
| 397 | * by performing this ioctl at least twice: the first time to retrieve the | ||
| 398 | * number of elements, the second time to retrieve the elements themselves. | ||
| 399 | * | ||
| 400 | * To retrieve the number of elements, set @count_props and @count_encoders to | ||
| 401 | * zero, set @count_modes to 1, and set @modes_ptr to a temporary struct | ||
| 402 | * drm_mode_modeinfo element. | ||
| 403 | * | ||
| 404 | * To retrieve the elements, allocate arrays for @encoders_ptr, @modes_ptr, | ||
| 405 | * @props_ptr and @prop_values_ptr, then set @count_modes, @count_props and | ||
| 406 | * @count_encoders to their capacity. | ||
| 407 | * | ||
| 408 | * Performing the ioctl only twice may be racy: the number of elements may have | ||
| 409 | * changed with a hotplug event in-between the two ioctls. User-space is | ||
| 410 | * expected to retry the last ioctl until the number of elements stabilizes. | ||
| 411 | * The kernel won't fill any array which doesn't have the expected length. | ||
| 412 | * | ||
| 413 | * **Force-probing a connector** | ||
| 414 | * | ||
| 415 | * If the @count_modes field is set to zero, the kernel will perform a forced | ||
| 416 | * probe on the connector to refresh the connector status, modes and EDID. | ||
| 417 | * A forced-probe can be slow and the ioctl will block. A force-probe can cause | ||
| 418 | * flickering and temporary freezes, so it should not be performed | ||
| 419 | * automatically. | ||
| 420 | * | ||
| 421 | * User-space shouldn't need to force-probe connectors in general: the kernel | ||
| 422 | * will automatically take care of probing connectors that don't support | ||
| 423 | * hot-plug detection when appropriate. However, user-space may force-probe | ||
| 424 | * connectors on user request (e.g. clicking a "Scan connectors" button, or | ||
| 425 | * opening a UI to manage screens). | ||
| 426 | */ | ||
| 371 | struct drm_mode_get_connector { | 427 | struct drm_mode_get_connector { |
| 372 | 428 | /** @encoders_ptr: Pointer to ``__u32`` array of object IDs. */ | |
| 373 | __u64 encoders_ptr; | 429 | __u64 encoders_ptr; |
| 430 | /** @modes_ptr: Pointer to struct drm_mode_modeinfo array. */ | ||
| 374 | __u64 modes_ptr; | 431 | __u64 modes_ptr; |
| 432 | /** @props_ptr: Pointer to ``__u32`` array of property IDs. */ | ||
| 375 | __u64 props_ptr; | 433 | __u64 props_ptr; |
| 434 | /** @prop_values_ptr: Pointer to ``__u64`` array of property values. */ | ||
| 376 | __u64 prop_values_ptr; | 435 | __u64 prop_values_ptr; |
| 377 | 436 | ||
| 437 | /** @count_modes: Number of modes. */ | ||
| 378 | __u32 count_modes; | 438 | __u32 count_modes; |
| 439 | /** @count_props: Number of properties. */ | ||
| 379 | __u32 count_props; | 440 | __u32 count_props; |
| 441 | /** @count_encoders: Number of encoders. */ | ||
| 380 | __u32 count_encoders; | 442 | __u32 count_encoders; |
| 381 | 443 | ||
| 382 | __u32 encoder_id; /**< Current Encoder */ | 444 | /** @encoder_id: Object ID of the current encoder. */ |
| 383 | __u32 connector_id; /**< Id */ | 445 | __u32 encoder_id; |
| 446 | /** @connector_id: Object ID of the connector. */ | ||
| 447 | __u32 connector_id; | ||
| 448 | /** | ||
| 449 | * @connector_type: Type of the connector. | ||
| 450 | * | ||
| 451 | * See DRM_MODE_CONNECTOR_* defines. | ||
| 452 | */ | ||
| 384 | __u32 connector_type; | 453 | __u32 connector_type; |
| 454 | /** | ||
| 455 | * @connector_type_id: Type-specific connector number. | ||
| 456 | * | ||
| 457 | * This is not an object ID. This is a per-type connector number. Each | ||
| 458 | * (type, type_id) combination is unique across all connectors of a DRM | ||
| 459 | * device. | ||
| 460 | */ | ||
| 385 | __u32 connector_type_id; | 461 | __u32 connector_type_id; |
| 386 | 462 | ||
| 463 | /** | ||
| 464 | * @connection: Status of the connector. | ||
| 465 | * | ||
| 466 | * See enum drm_connector_status. | ||
| 467 | */ | ||
| 387 | __u32 connection; | 468 | __u32 connection; |
| 388 | __u32 mm_width; /**< width in millimeters */ | 469 | /** @mm_width: Width of the connected sink in millimeters. */ |
| 389 | __u32 mm_height; /**< height in millimeters */ | 470 | __u32 mm_width; |
| 471 | /** @mm_height: Height of the connected sink in millimeters. */ | ||
| 472 | __u32 mm_height; | ||
| 473 | /** | ||
| 474 | * @subpixel: Subpixel order of the connected sink. | ||
| 475 | * | ||
| 476 | * See enum subpixel_order. | ||
| 477 | */ | ||
| 390 | __u32 subpixel; | 478 | __u32 subpixel; |
| 391 | 479 | ||
| 480 | /** @pad: Padding, must be zero. */ | ||
| 392 | __u32 pad; | 481 | __u32 pad; |
| 393 | }; | 482 | }; |
| 394 | 483 | ||
| @@ -905,24 +994,23 @@ struct drm_format_modifier { · 510 unmodified lines | |||
| 905 | 994 | ||
| 906 | /** | 995 | /** |
| 907 | * struct drm_mode_create_blob - Create New block property | 996 | * struct drm_mode_create_blob - Create New block property |
| 908 | * @data: Pointer to data to copy. | 997 | * |
| 909 | * @length: Length of data to copy. | ||
| 910 | * @blob_id: new property ID. | ||
| 911 | * Create a new 'blob' data property, copying length bytes from data pointer, | 998 | * Create a new 'blob' data property, copying length bytes from data pointer, |
| 912 | * and returning new blob ID. | 999 | * and returning new blob ID. |
| 913 | */ | 1000 | */ |
| 914 | struct drm_mode_create_blob { | 1001 | struct drm_mode_create_blob { |
| 915 | /** Pointer to data to copy. */ | 1002 | /** @data: Pointer to data to copy. */ |
| 916 | __u64 data; | 1003 | __u64 data; |
| 917 | /** Length of data to copy. */ | 1004 | /** @length: Length of data to copy. */ |
| 918 | __u32 length; | 1005 | __u32 length; |
| 919 | /** Return: new property ID. */ | 1006 | /** @blob_id: Return: new property ID. */ |
| 920 | __u32 blob_id; | 1007 | __u32 blob_id; |
| 921 | }; | 1008 | }; |
| 922 | 1009 | ||
| 923 | /** | 1010 | /** |
| 924 | * struct drm_mode_destroy_blob - Destroy user blob | 1011 | * struct drm_mode_destroy_blob - Destroy user blob |
| 925 | * @blob_id: blob_id to destroy | 1012 | * @blob_id: blob_id to destroy |
| 1013 | * | ||
| 926 | * Destroy a user-created blob property. | 1014 | * Destroy a user-created blob property. |
| 927 | * | 1015 | * |
| 928 | * User-space can release blobs as soon as they do not need to refer to them by | 1016 | * User-space can release blobs as soon as they do not need to refer to them by |
| @@ -937,36 +1025,32 @@ struct drm_mode_destroy_blob { · 8 unmodified lines | |||
| 937 | 1025 | ||
| 938 | /** | 1026 | /** |
| 939 | * struct drm_mode_create_lease - Create lease | 1027 | * struct drm_mode_create_lease - Create lease |
| 940 | * @object_ids: Pointer to array of object ids. | 1028 | * |
| 941 | * @object_count: Number of object ids. | ||
| 942 | * @flags: flags for new FD. | ||
| 943 | * @lessee_id: unique identifier for lessee. | ||
| 944 | * @fd: file descriptor to new drm_master file. | ||
| 945 | * Lease mode resources, creating another drm_master. | 1029 | * Lease mode resources, creating another drm_master. |
| 946 | */ | 1030 | */ |
| 947 | struct drm_mode_create_lease { | 1031 | struct drm_mode_create_lease { |
| 948 | /** Pointer to array of object ids (__u32) */ | 1032 | /** @object_ids: Pointer to array of object ids (__u32) */ |
| 949 | __u64 object_ids; | 1033 | __u64 object_ids; |
| 950 | /** Number of object ids */ | 1034 | /** @object_count: Number of object ids */ |
| 951 | __u32 object_count; | 1035 | __u32 object_count; |
| 952 | /** flags for new FD (O_CLOEXEC, etc) */ | 1036 | /** @flags: flags for new FD (O_CLOEXEC, etc) */ |
| 953 | __u32 flags; | 1037 | __u32 flags; |
| 954 | 1038 | ||
| 955 | /** Return: unique identifier for lessee. */ | 1039 | /** @lessee_id: Return: unique identifier for lessee. */ |
| 956 | __u32 lessee_id; | 1040 | __u32 lessee_id; |
| 957 | /** Return: file descriptor to new drm_master file */ | 1041 | /** @fd: Return: file descriptor to new drm_master file */ |
| 958 | __u32 fd; | 1042 | __u32 fd; |
| 959 | }; | 1043 | }; |
| 960 | 1044 | ||
| 961 | /** | 1045 | /** |
| 962 | * struct drm_mode_list_lessees - List lessees | 1046 | * struct drm_mode_list_lessees - List lessees |
| 963 | * @count_lessees: Number of lessees. | 1047 | * |
| 964 | * @pad: pad. | 1048 | * List lesses from a drm_master. |
| 965 | * @lessees_ptr: Pointer to lessess. | ||
| 966 | * List lesses from a drm_master | ||
| 967 | */ | 1049 | */ |
| 968 | struct drm_mode_list_lessees { | 1050 | struct drm_mode_list_lessees { |
| 969 | /** Number of lessees. | 1051 | /** |
| 1052 | * @count_lessees: Number of lessees. | ||
| 1053 | * | ||
| 970 | * On input, provides length of the array. | 1054 | * On input, provides length of the array. |
| 971 | * On output, provides total number. No | 1055 | * On output, provides total number. No |
| 972 | * more than the input number will be written | 1056 | * more than the input number will be written |
| @@ -974,23 +1058,26 @@ struct drm_mode_list_lessees { · 1 unmodified line | |||
| 974 | * the size and then the data. | 1058 | * the size and then the data. |
| 975 | */ | 1059 | */ |
| 976 | __u32 count_lessees; | 1060 | __u32 count_lessees; |
| 1061 | /** @pad: Padding. */ | ||
| 977 | __u32 pad; | 1062 | __u32 pad; |
| 978 | 1063 | ||
| 979 | /** Pointer to lessees. | 1064 | /** |
| 980 | * pointer to __u64 array of lessee ids | 1065 | * @lessees_ptr: Pointer to lessees. |
| 1066 | * | ||
| 1067 | * Pointer to __u64 array of lessee ids | ||
| 981 | */ | 1068 | */ |
| 982 | __u64 lessees_ptr; | 1069 | __u64 lessees_ptr; |
| 983 | }; | 1070 | }; |
| 984 | 1071 | ||
| 985 | /** | 1072 | /** |
| 986 | * struct drm_mode_get_lease - Get Lease | 1073 | * struct drm_mode_get_lease - Get Lease |
| 987 | * @count_objects: Number of leased objects. | 1074 | * |
| 988 | * @pad: pad. | 1075 | * Get leased objects. |
| 989 | * @objects_ptr: Pointer to objects. | ||
| 990 | * Get leased objects | ||
| 991 | */ | 1076 | */ |
| 992 | struct drm_mode_get_lease { | 1077 | struct drm_mode_get_lease { |
| 993 | /** Number of leased objects. | 1078 | /** |
| 1079 | * @count_objects: Number of leased objects. | ||
| 1080 | * | ||
| 994 | * On input, provides length of the array. | 1081 | * On input, provides length of the array. |
| 995 | * On output, provides total number. No | 1082 | * On output, provides total number. No |
| 996 | * more than the input number will be written | 1083 | * more than the input number will be written |
| @@ -998,22 +1085,22 @@ struct drm_mode_get_lease { · 1 unmodified line | |||
| 998 | * the size and then the data. | 1085 | * the size and then the data. |
| 999 | */ | 1086 | */ |
| 1000 | __u32 count_objects; | 1087 | __u32 count_objects; |
| 1088 | /** @pad: Padding. */ | ||
| 1001 | __u32 pad; | 1089 | __u32 pad; |
| 1002 | 1090 | ||
| 1003 | /** Pointer to objects. | 1091 | /** |
| 1004 | * pointer to __u32 array of object ids | 1092 | * @objects_ptr: Pointer to objects. |
| 1093 | * | ||
| 1094 | * Pointer to __u32 array of object ids. | ||
| 1005 | */ | 1095 | */ |
| 1006 | __u64 objects_ptr; | 1096 | __u64 objects_ptr; |
| 1007 | }; | 1097 | }; |
| 1008 | 1098 | ||
| 1009 | /** | 1099 | /** |
| 1010 | * struct drm_mode_revoke_lease - Revoke lease | 1100 | * struct drm_mode_revoke_lease - Revoke lease |
| 1011 | * @lessee_id: Unique ID of lessee. | ||
| 1012 | * Revoke lease | ||
| 1013 | */ | 1101 | */ |
| 1014 | struct drm_mode_revoke_lease { | 1102 | struct drm_mode_revoke_lease { |
| 1015 | /** Unique ID of lessee | 1103 | /** @lessee_id: Unique ID of lessee */ |
| 1016 | */ | ||
| 1017 | __u32 lessee_id; | 1104 | __u32 lessee_id; |
| 1018 | }; | 1105 | }; |
| 1019 | 1106 | ||
| @@ -115,6 +115,10 @@ enum virtio_gpu_ctrl_type { · 114 unmodified lines | |||
| 115 | 115 | ||
| 116 | enum virtio_gpu_shm_id { | 116 | enum virtio_gpu_shm_id { |
| 117 | VIRTIO_GPU_SHM_ID_UNDEFINED = 0, | 117 | VIRTIO_GPU_SHM_ID_UNDEFINED = 0, |
| 118 | /* | ||
| 119 | * VIRTIO_GPU_CMD_RESOURCE_MAP_BLOB | ||
| 120 | * VIRTIO_GPU_CMD_RESOURCE_UNMAP_BLOB | ||
| 121 | */ | ||
| 118 | VIRTIO_GPU_SHM_ID_HOST_VISIBLE = 1 | 122 | VIRTIO_GPU_SHM_ID_HOST_VISIBLE = 1 |
| 119 | }; | 123 | }; |
| 120 | 124 | ||