Commit 83cd3be8 authored by Dave Airlie's avatar Dave Airlie
Browse files

Merge tag 'drm-xe-fixes-2024-01-25' of https://gitlab.freedesktop.org/drm/xe/kernel into drm-fixes



Driver Changes:
- Make an ops struct static
- Fix an implicit 0 to NULL conversion
- A couple of 32-bit fixes
- A migration coherency fix for Lunar Lake.
- An error path vm id leak fix
- Remove PVC references in kunit tests

Signed-off-by: default avatarDave Airlie <airlied@redhat.com>

From: Thomas Hellstrom <thomas.hellstrom@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/ZbIb7l0EhpVp5cXE@fedora
parents b16702be 9e3a13f3
Loading
Loading
Loading
Loading
+5 −6
Original line number Diff line number Diff line
@@ -35,12 +35,10 @@ static inline int i915_gem_object_read_from_page(struct xe_bo *bo,
					  u32 ofs, u64 *ptr, u32 size)
{
	struct ttm_bo_kmap_obj map;
	void *virtual;
	void *src;
	bool is_iomem;
	int ret;

	XE_WARN_ON(size != 8);

	ret = xe_bo_lock(bo, true);
	if (ret)
		return ret;
@@ -50,11 +48,12 @@ static inline int i915_gem_object_read_from_page(struct xe_bo *bo,
		goto out_unlock;

	ofs &= ~PAGE_MASK;
	virtual = ttm_kmap_obj_virtual(&map, &is_iomem);
	src = ttm_kmap_obj_virtual(&map, &is_iomem);
	src += ofs;
	if (is_iomem)
		*ptr = readq((void __iomem *)(virtual + ofs));
		memcpy_fromio(ptr, (void __iomem *)src, size);
	else
		*ptr = *(u64 *)(virtual + ofs);
		memcpy(ptr, src, size);

	ttm_bo_kunmap(&map);
out_unlock:
+0 −3
Original line number Diff line number Diff line
@@ -74,9 +74,6 @@ static const struct platform_test_case cases[] = {
	SUBPLATFORM_CASE(DG2, G11, B1),
	SUBPLATFORM_CASE(DG2, G12, A0),
	SUBPLATFORM_CASE(DG2, G12, A1),
	PLATFORM_CASE(PVC, B0),
	PLATFORM_CASE(PVC, B1),
	PLATFORM_CASE(PVC, C0),
	GMDID_CASE(METEORLAKE, 1270, A0, 1300, A0),
	GMDID_CASE(METEORLAKE, 1271, A0, 1300, A0),
	GMDID_CASE(LUNARLAKE, 2004, A0, 2000, A0),
+1 −1
Original line number Diff line number Diff line
@@ -613,7 +613,7 @@ void xe_device_wmb(struct xe_device *xe)
u32 xe_device_ccs_bytes(struct xe_device *xe, u64 size)
{
	return xe_device_has_flat_ccs(xe) ?
		DIV_ROUND_UP(size, NUM_BYTES_PER_CCS_BYTE(xe)) : 0;
		DIV_ROUND_UP_ULL(size, NUM_BYTES_PER_CCS_BYTE(xe)) : 0;
}

bool xe_device_mem_access_ongoing(struct xe_device *xe)
+1 −1
Original line number Diff line number Diff line
@@ -175,7 +175,7 @@ static int xe_dma_buf_begin_cpu_access(struct dma_buf *dma_buf,
	return 0;
}

const struct dma_buf_ops xe_dmabuf_ops = {
static const struct dma_buf_ops xe_dmabuf_ops = {
	.attach = xe_dma_buf_attach,
	.detach = xe_dma_buf_detach,
	.pin = xe_dma_buf_pin,
+1 −1
Original line number Diff line number Diff line
@@ -419,7 +419,7 @@ static int xe_hwmon_pcode_read_i1(struct xe_gt *gt, u32 *uval)

	return xe_pcode_read(gt, PCODE_MBOX(PCODE_POWER_SETUP,
			     POWER_SETUP_SUBCOMMAND_READ_I1, 0),
			     uval, 0);
			     uval, NULL);
}

static int xe_hwmon_pcode_write_i1(struct xe_gt *gt, u32 uval)
Loading