From 645e51dc1d583ce0ab2d33525db56369722c5afe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Josef=20S=C3=B6ntgen?= Date: Thu, 18 Nov 2021 16:23:18 +0100 Subject: [PATCH] gpu: add information for etnaviv driver Mesa queries information about the underlying device and this header denotes the layout of the information. It is also used by the driver itself to populate the 'info_dataspace'. Issue #4329. --- repos/os/include/gpu/info_etnaviv.h | 43 +++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 repos/os/include/gpu/info_etnaviv.h diff --git a/repos/os/include/gpu/info_etnaviv.h b/repos/os/include/gpu/info_etnaviv.h new file mode 100644 index 0000000000..d4dd46a93b --- /dev/null +++ b/repos/os/include/gpu/info_etnaviv.h @@ -0,0 +1,43 @@ +/* + * \brief Gpu Information ETNAVIV + * \author Josef Soentgen + * \date 2021-09-20 + */ + +/* + * Copyright (C) 2021 Genode Labs GmbH + * + * This file is part of the Genode OS framework, which is distributed + * under the terms of the GNU Affero General Public License version 3. + */ + +#ifndef _INCLUDE__GPU_INFO_ETNAVIV_H_ +#define _INCLUDE__GPU_INFO_ETNAVIV_H_ + +#include +#include +#include + +namespace Gpu { + + struct Info_etnaviv; +} /* namespace Gpu */ + + +/* + * Gpu information + * + * Used to query information in the DRM backend + */ +struct Gpu::Info_etnaviv +{ + /* + * Size the array based on the list of params in + * etnaviv_drm.h that allow for 1:1 access. + */ + enum { MAX_ETNAVIV_PARAMS = 32, }; + using Param = Genode::uint64_t; + Param param[MAX_ETNAVIV_PARAMS] { }; +}; + +#endif /* _INCLUDE__GPU_INFO_ETNAVIV_H_ */