Skip to content

Commit ab3d7b6

Browse files
tomeuvlynxeye-dev
authored andcommitted
drm/etnaviv: Add nn_core_count to chip feature struct
We will use these for differentiating between GPUs and NPUs, as the downstream driver does. Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
1 parent 1b929c0 commit ab3d7b6

2 files changed

Lines changed: 7 additions & 0 deletions

File tree

drivers/gpu/drm/etnaviv/etnaviv_gpu.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ struct etnaviv_chip_identity {
5151
/* Number of shader cores. */
5252
u32 shader_core_count;
5353

54+
/* Number of Neural Network cores. */
55+
u32 nn_core_count;
56+
5457
/* Size of the vertex cache. */
5558
u32 vertex_cache_size;
5659

drivers/gpu/drm/etnaviv/etnaviv_hwdb.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_identities[] = {
1616
.register_max = 64,
1717
.thread_count = 128,
1818
.shader_core_count = 1,
19+
.nn_core_count = 0,
1920
.vertex_cache_size = 8,
2021
.vertex_output_buffer_size = 1024,
2122
.pixel_pipes = 1,
@@ -47,6 +48,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_identities[] = {
4748
.register_max = 64,
4849
.thread_count = 512,
4950
.shader_core_count = 2,
51+
.nn_core_count = 0,
5052
.vertex_cache_size = 16,
5153
.vertex_output_buffer_size = 1024,
5254
.pixel_pipes = 1,
@@ -78,6 +80,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_identities[] = {
7880
.register_max = 64,
7981
.thread_count = 512,
8082
.shader_core_count = 2,
83+
.nn_core_count = 0,
8184
.vertex_cache_size = 16,
8285
.vertex_output_buffer_size = 1024,
8386
.pixel_pipes = 1,
@@ -140,6 +143,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_identities[] = {
140143
.register_max = 64,
141144
.thread_count = 1024,
142145
.shader_core_count = 4,
146+
.nn_core_count = 0,
143147
.vertex_cache_size = 16,
144148
.vertex_output_buffer_size = 1024,
145149
.pixel_pipes = 2,

0 commit comments

Comments
 (0)