On 04/07/2017 10:11 AM, Chris Wilson wrote:
On Fri, Apr 07, 2017 at 06:23:14PM +0200, Michal Wajdeczko wrote:
On Fri, Apr 07, 2017 at 02:15:47AM -0700, Oscar Mateo wrote:
Not really needed, but makes the next change a little bit more compact.
v2:
- Use zero-based numbering for engine names: xcs0, xcs1.. xcsN (Tvrtko, Chris)
- Make sure the mock engine name is null-terminated (Tvrtko, Chris)
v3: Because I'm stupid (Chris)
v4: Verify engine name wasn't truncated (Michal)
Cc: Paulo Zanoni <paulo.r.zanoni@xxxxxxxxx>
Cc: Rodrigo Vivi <rodrigo.vivi@xxxxxxxxx>
Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@xxxxxxxxx>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@xxxxxxxxx>
Cc: Michal Wajdeczko <michal.wajdeczko@xxxxxxxxx>
Signed-off-by: Oscar Mateo <oscar.mateo@xxxxxxxxx>
---
Reviewed-by: Michal Wajdeczko <michal.wajdeczko@xxxxxxxxx>
s/WARN_ON/GEM_WARN_ON/ ?
As in:
if (GEM_WARN_ON(snprintf(engine->name, sizeof(engine->name), "%s%u",
class_info->name, info->instance) >= sizeof(engine->name)))
;
or do you want to return an error? (I don't really see the need, but...)
The WARN_ON in mock_engine.c is off-by-one, but really we don't care too
much there so just kill that warn.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx