On Tue, 22 Jul 2025 20:21:25 +0100 Adrian Larumbe <adrian.laru...@collabora.com> wrote:
> > /** > > @@ -1074,6 +1079,9 @@ struct drm_gpuvm_map_req { > > /** @offset: offset in the GEM */ > > u64 offset; > > } gem; > > + > > + /** @flags: combination of DRM_GPUVA_ flags describing the mapping > > properties. */ > > + enum drm_gpuva_flags flags; > > Wouldn't this be better expressed as a u32 combination of enum > drm_gpuva_flags flags? > Calling it 'flags' makes me feel like any OR'd combination of enum values > would be possible. I agree, but it's how other flags field are defined in gpuvm so I went for the same definition to keep things consistent. Luckily (or unfortunately, depending on where you place yourself), C is pretty lax about what can be assigned to an enum type.