@@ -44,6 +44,15 @@ static inline void xe_map_memset(struct xe_device *xe,
iosys_map_memset(dst, offset, value, len);
}
+static inline ssize_t xe_map_read_from(struct xe_device *xe, void __user *to,
+ size_t count, loff_t *ppos,
+ const struct iosys_map *map,
+ size_t available)
+{
+ xe_device_assert_mem_access(xe);
+ return iosys_map_read_from(to, count, ppos, map, available);
+}
+
/* FIXME: We likely should kill these two functions sooner or later */
static inline u32 xe_map_read32(struct xe_device *xe, struct iosys_map *map)
{
It is preferable to use the xe_map layer instead of directly accessing iosys_map, so add a wrapper for the recently added iosys_map_read_from() function. Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Cc: Lucas De Marchi <lucas.demarchi@intel.com> --- Cc: linux-fsdevel@vger.kernel.org Cc: dri-devel@lists.freedesktop.org --- drivers/gpu/drm/xe/xe_map.h | 9 +++++++++ 1 file changed, 9 insertions(+)