All of lore.kernel.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t] i915/intel_memory_region: Add missing forward declaration
@ 2021-08-10  8:14 Janusz Krzysztofik
  2021-08-10  8:48 ` Petri Latvala
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Janusz Krzysztofik @ 2021-08-10  8:14 UTC (permalink / raw)
  To: igt-dev; +Cc: Andrzej Turko, Janusz Krzysztofik

Intel memory region header declares some functions with a pointer to a
structure defined elsewhere as one of their arguments.  Forward declare
that structure to avoid compiler warnings.

../lib/i915/intel_memory_region.h:69:19: warning: ‘struct drm_i915_gem_memory_class_instance’ declared inside parameter list will not be visible outside of this definition or declaration
   69 |            struct drm_i915_gem_memory_class_instance *mem_regions,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../lib/i915/intel_memory_region.h:73:15: warning: ‘struct drm_i915_gem_memory_class_instance’ declared inside parameter list will not be visible outside of this definition or declaration
   73 |        struct drm_i915_gem_memory_class_instance *mem_regions,
      |               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Janusz Krzysztofik <janusz.krzysztofik@linux.intel.com>
---
 lib/i915/intel_memory_region.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/i915/intel_memory_region.h b/lib/i915/intel_memory_region.h
index e9d1d66d4..8cd18ea0e 100644
--- a/lib/i915/intel_memory_region.h
+++ b/lib/i915/intel_memory_region.h
@@ -62,6 +62,8 @@ uint8_t gem_get_lmem_region_count(int fd);
 
 bool gem_has_lmem(int fd);
 
+struct drm_i915_gem_memory_class_instance;
+
 int __gem_create_in_memory_region_list(int fd, uint32_t *handle, uint64_t size,
 				       struct drm_i915_gem_memory_class_instance *mem_regions,
 				       int num_regions);
-- 
2.25.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2021-08-11  9:12 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-10  8:14 [igt-dev] [PATCH i-g-t] i915/intel_memory_region: Add missing forward declaration Janusz Krzysztofik
2021-08-10  8:48 ` Petri Latvala
2021-08-10  8:55   ` Janusz Krzysztofik
2021-08-10  9:27     ` Petri Latvala
2021-08-11  9:12       ` Janusz Krzysztofik
2021-08-10  9:59 ` [igt-dev] ✗ Fi.CI.BAT: failure for " Patchwork
2021-08-10 10:29   ` Janusz Krzysztofik
2021-08-10 16:15     ` Vudum, Lakshminarayana
2021-08-10 12:45 ` [igt-dev] ✗ GitLab.Pipeline: warning " Patchwork
2021-08-10 15:07 ` [igt-dev] ✓ Fi.CI.BAT: success " Patchwork
2021-08-10 19:18 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.