[PATCH 3/3] drm/i915: Use BIT() for computing the engine's flag

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Since the engine's flag is just the bit of its id, use BIT().

Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
Cc: Joonas Lahtinen <joonas.lahtinen@xxxxxxxxxxxxxxx>
---
 drivers/gpu/drm/i915/intel_ringbuffer.h | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.h b/drivers/gpu/drm/i915/intel_ringbuffer.h
index 93be3bd99a38..3aae2c4f9ca3 100644
--- a/drivers/gpu/drm/i915/intel_ringbuffer.h
+++ b/drivers/gpu/drm/i915/intel_ringbuffer.h
@@ -432,10 +432,9 @@ struct intel_engine_cs {
 	u32 (*get_cmd_length_mask)(u32 cmd_header);
 };
 
-static inline unsigned
-intel_engine_flag(const struct intel_engine_cs *engine)
+static inline unsigned intel_engine_flag(const struct intel_engine_cs *engine)
 {
-	return 1 << engine->id;
+	return BIT(engine->id);
 }
 
 static inline u32
-- 
2.11.0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux