pvr: Split pvr_dev_addr_t into a separate header
This type is useful beyond the scope of winsys. It can now be used without being lumbered with a dependency on pvr_winsys.h. Since pvr_winsys.h is used by pvr_private.h, this can be a common cause for circular dependencies during development. Signed-off-by: Matt Coster <matt.coster@imgtec.com> Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17488>
This commit is contained in:
parent
f2e2e66e42
commit
282f0a9330
|
@ -31,7 +31,7 @@
|
|||
|
||||
#include <stdint.h>
|
||||
|
||||
#include "pvr_winsys.h"
|
||||
#include "pvr_types.h"
|
||||
|
||||
#define __pvr_address_type pvr_dev_addr_t
|
||||
#define __pvr_get_address(pvr_dev_addr) (pvr_dev_addr).addr
|
||||
|
|
|
@ -0,0 +1,41 @@
|
|||
/*
|
||||
* Copyright © 2022 Imagination Technologies Ltd.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice (including the next
|
||||
* paragraph) shall be included in all copies or substantial portions of the
|
||||
* Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
* SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef PVR_TYPES_H
|
||||
#define PVR_TYPES_H
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
/*****************************************************************************
|
||||
Device virtual addresses
|
||||
*****************************************************************************/
|
||||
|
||||
typedef struct pvr_dev_addr {
|
||||
uint64_t addr;
|
||||
} pvr_dev_addr_t;
|
||||
|
||||
/* clang-format off */
|
||||
#define PVR_DEV_ADDR_INVALID (pvr_dev_addr_t){ .addr = 0 }
|
||||
/* clang-format on */
|
||||
|
||||
#endif /* PVR_TYPES_H */
|
|
@ -28,6 +28,7 @@
|
|||
|
||||
#include "pvr_bo.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "vk_alloc.h"
|
||||
#include "vk_log.h"
|
||||
|
|
|
@ -43,6 +43,7 @@
|
|||
#include "pvr_limits.h"
|
||||
#include "pvr_pds.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "util/compiler.h"
|
||||
#include "util/list.h"
|
||||
|
|
|
@ -36,6 +36,7 @@
|
|||
#include <vulkan/vulkan.h>
|
||||
|
||||
#include "pvr_bo.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "util/list.h"
|
||||
#include "util/macros.h"
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#include "hwdef/rogue_hw_utils.h"
|
||||
#include "pvr_bo.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_types.h"
|
||||
#include "util/compiler.h"
|
||||
#include "util/list.h"
|
||||
#include "util/log.h"
|
||||
|
|
|
@ -49,6 +49,7 @@
|
|||
#include "pvr_nop_usc.h"
|
||||
#include "pvr_pds.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "rogue/rogue_compiler.h"
|
||||
#include "util/build_id.h"
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
|
||||
#include "hwdef/rogue_hw_defs.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "pvr_types.h"
|
||||
|
||||
enum pvr_pbe_gamma {
|
||||
PVR_PBE_GAMMA_NONE,
|
||||
|
|
|
@ -35,6 +35,7 @@
|
|||
#include "pvr_pds.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_transfer_eot.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_vdm_load_sr.h"
|
||||
#include "pvr_vdm_store_sr.h"
|
||||
#include "pvr_winsys.h"
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#define PVR_JOB_CONTEXT_H
|
||||
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
|
||||
/* Support PDS code/data loading/storing to the 'B' shared register state
|
||||
|
|
|
@ -31,12 +31,14 @@
|
|||
#include "pvr_bo.h"
|
||||
#include "pvr_csb.h"
|
||||
#include "pvr_csb_enum_helpers.h"
|
||||
#include "pvr_debug.h"
|
||||
#include "pvr_job_common.h"
|
||||
#include "pvr_job_context.h"
|
||||
#include "pvr_job_render.h"
|
||||
#include "pvr_pds.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_rogue_fw.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "util/compiler.h"
|
||||
#include "util/macros.h"
|
||||
|
|
|
@ -30,12 +30,13 @@
|
|||
|
||||
#include "hwdef/rogue_hw_defs.h"
|
||||
#include "pvr_limits.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "pvr_types.h"
|
||||
|
||||
struct pvr_device;
|
||||
struct pvr_free_list;
|
||||
struct pvr_render_ctx;
|
||||
struct pvr_rt_dataset;
|
||||
struct pvr_winsys_job_bo;
|
||||
struct vk_sync;
|
||||
|
||||
/* FIXME: Turn 'struct pvr_sub_cmd' into 'struct pvr_job' and change 'struct
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
#include "pvr_pds.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_shader.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "pvr_types.h"
|
||||
#include "rogue/rogue.h"
|
||||
#include "rogue/rogue_build_data.h"
|
||||
#include "util/log.h"
|
||||
|
|
|
@ -45,6 +45,7 @@
|
|||
#include "pvr_job_render.h"
|
||||
#include "pvr_limits.h"
|
||||
#include "pvr_pds.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "rogue/rogue.h"
|
||||
#include "util/bitscan.h"
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
|
||||
#include "hwdef/rogue_hw_defs.h"
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_types.h"
|
||||
#include "util/macros.h"
|
||||
|
||||
/**
|
||||
|
|
|
@ -34,8 +34,9 @@
|
|||
#include <vulkan/vulkan.h>
|
||||
|
||||
#include "hwdef/rogue_hw_defs.h"
|
||||
#include "pvr_rogue_fw.h"
|
||||
#include "pvr_limits.h"
|
||||
#include "pvr_rogue_fw.h"
|
||||
#include "pvr_types.h"
|
||||
#include "util/macros.h"
|
||||
#include "util/vma.h"
|
||||
#include "vk_sync.h"
|
||||
|
@ -43,15 +44,6 @@
|
|||
struct pvr_device_info;
|
||||
struct pvr_device_runtime_info;
|
||||
|
||||
/* device virtual address */
|
||||
typedef struct pvr_dev_addr {
|
||||
uint64_t addr;
|
||||
} pvr_dev_addr_t;
|
||||
|
||||
/* clang-format off */
|
||||
#define PVR_DEV_ADDR_INVALID (pvr_dev_addr_t){ .addr = 0 }
|
||||
/* clang-format on */
|
||||
|
||||
struct pvr_winsys_heaps {
|
||||
struct pvr_winsys_heap *general_heap;
|
||||
struct pvr_winsys_heap *pds_heap;
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <xf86drm.h>
|
||||
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "pvr_winsys_helper.h"
|
||||
#include "util/u_atomic.h"
|
||||
|
|
|
@ -27,7 +27,12 @@
|
|||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
|
||||
#include "pvr_winsys.h"
|
||||
#include "pvr_types.h"
|
||||
|
||||
struct pvr_winsys;
|
||||
struct pvr_winsys_heap;
|
||||
struct pvr_winsys_static_data_offsets;
|
||||
struct pvr_winsys_vma;
|
||||
|
||||
typedef struct pvr_winsys_vma *(*const heap_alloc_reserved_func)(
|
||||
struct pvr_winsys_heap *const heap,
|
||||
|
|
|
@ -38,6 +38,7 @@
|
|||
#include "pvr_srv_public.h"
|
||||
#include "pvr_srv_sync.h"
|
||||
#include "pvr_srv_job_null.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "pvr_winsys_helper.h"
|
||||
#include "util/log.h"
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
#include "pvr_srv.h"
|
||||
#include "pvr_srv_bo.h"
|
||||
#include "pvr_srv_bridge.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys_helper.h"
|
||||
#include "util/u_atomic.h"
|
||||
#include "util/bitscan.h"
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_srv.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "util/macros.h"
|
||||
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
#include "pvr_private.h"
|
||||
#include "pvr_srv.h"
|
||||
#include "pvr_srv_bridge.h"
|
||||
#include "pvr_types.h"
|
||||
#include "util/log.h"
|
||||
#include "util/macros.h"
|
||||
#include "vk_log.h"
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
|
||||
#include "pvr_private.h"
|
||||
#include "pvr_srv.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "pvr_types.h"
|
||||
#include "util/macros.h"
|
||||
|
||||
/******************************************************************************
|
||||
|
|
|
@ -40,6 +40,7 @@
|
|||
#include "pvr_srv_job_common.h"
|
||||
#include "pvr_srv_job_render.h"
|
||||
#include "pvr_srv_sync.h"
|
||||
#include "pvr_types.h"
|
||||
#include "pvr_winsys.h"
|
||||
#include "util/libsync.h"
|
||||
#include "util/log.h"
|
||||
|
|
Loading…
Reference in New Issue