drm/amd: drop dependencies on drm_os_linux.h

Fix so no files in drm/amd/ depends on the
deprecated drm_os_linux.h header file.

It was done manually:
- remove drm_os_linux.h from drmP.h
- fix all build errros

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: "David (ChunMing) Zhou" <David1.Zhou@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20190609220757.10862-3-sam@ravnborg.org
This commit is contained in:
Sam Ravnborg 2019-06-10 00:07:49 +02:00
parent 656600efd6
commit c366be543c
36 changed files with 90 additions and 28 deletions

View File

@ -22,10 +22,12 @@
#define pr_fmt(fmt) "kfd2kgd: " fmt
#include <linux/dma-buf.h>
#include <linux/list.h>
#include <linux/pagemap.h>
#include <linux/sched/mm.h>
#include <linux/dma-buf.h>
#include <linux/sched/task.h>
#include <drm/drmP.h>
#include "amdgpu_object.h"
#include "amdgpu_vm.h"

View File

@ -24,6 +24,8 @@
*
*/
#include <linux/io-64-nonatomic-lo-hi.h>
#include "amdgpu.h"
/**

View File

@ -29,6 +29,16 @@
* Thomas Hellstrom <thomas-at-tungstengraphics-dot-com>
* Dave Airlie
*/
#include <linux/debugfs.h>
#include <linux/iommu.h>
#include <linux/pagemap.h>
#include <linux/sched/task.h>
#include <linux/seq_file.h>
#include <linux/slab.h>
#include <linux/swap.h>
#include <linux/swiotlb.h>
#include <drm/ttm/ttm_bo_api.h>
#include <drm/ttm/ttm_bo_driver.h>
#include <drm/ttm/ttm_placement.h>
@ -36,13 +46,6 @@
#include <drm/ttm/ttm_page_alloc.h>
#include <drm/drmP.h>
#include <drm/amdgpu_drm.h>
#include <linux/seq_file.h>
#include <linux/slab.h>
#include <linux/swiotlb.h>
#include <linux/swap.h>
#include <linux/pagemap.h>
#include <linux/debugfs.h>
#include <linux/iommu.h>
#include "amdgpu.h"
#include "amdgpu_object.h"
#include "amdgpu_trace.h"

View File

@ -1090,7 +1090,7 @@ int amdgpu_vce_ring_test_ring(struct amdgpu_ring *ring)
for (i = 0; i < timeout; i++) {
if (amdgpu_ring_get_rptr(ring) != rptr)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= timeout)

View File

@ -446,7 +446,7 @@ int amdgpu_vcn_dec_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(SOC15_REG_OFFSET(UVD, 0, mmUVD_SCRATCH9));
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)
@ -608,7 +608,7 @@ int amdgpu_vcn_enc_ring_test_ring(struct amdgpu_ring *ring)
for (i = 0; i < adev->usec_timeout; i++) {
if (amdgpu_ring_get_rptr(ring) != rptr)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)
@ -767,7 +767,7 @@ int amdgpu_vcn_jpeg_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(SOC15_REG_OFFSET(UVD, 0, mmUVD_SCRATCH9));
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)
@ -841,7 +841,7 @@ int amdgpu_vcn_jpeg_ring_test_ib(struct amdgpu_ring *ring, long timeout)
tmp = RREG32(SOC15_REG_OFFSET(UVD, 0, mmUVD_SCRATCH9));
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -640,7 +640,7 @@ static int cik_sdma_ring_test_ring(struct amdgpu_ring *ring)
tmp = le32_to_cpu(adev->wb.wb[index]);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -1812,7 +1812,7 @@ static int gfx_v6_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(scratch);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -2080,7 +2080,7 @@ static int gfx_v7_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(scratch);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)
r = -ETIMEDOUT;

View File

@ -20,8 +20,11 @@
* OTHER DEALINGS IN THE SOFTWARE.
*
*/
#include <linux/delay.h>
#include <linux/kernel.h>
#include <linux/firmware.h>
#include <drm/drmP.h>
#include "amdgpu.h"
#include "amdgpu_gfx.h"
@ -855,7 +858,7 @@ static int gfx_v8_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(scratch);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -20,8 +20,11 @@
* OTHER DEALINGS IN THE SOFTWARE.
*
*/
#include <linux/delay.h>
#include <linux/kernel.h>
#include <linux/firmware.h>
#include <drm/drmP.h>
#include "amdgpu.h"
#include "amdgpu_gfx.h"
@ -417,7 +420,7 @@ static int gfx_v9_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(scratch);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -21,7 +21,10 @@
*
* Authors: Alex Deucher
*/
#include <linux/delay.h>
#include <linux/firmware.h>
#include <drm/drmP.h>
#include "amdgpu.h"
#include "amdgpu_ucode.h"
@ -574,7 +577,7 @@ static int sdma_v2_4_ring_test_ring(struct amdgpu_ring *ring)
tmp = le32_to_cpu(adev->wb.wb[index]);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -21,7 +21,10 @@
*
* Authors: Alex Deucher
*/
#include <linux/delay.h>
#include <linux/firmware.h>
#include <drm/drmP.h>
#include "amdgpu.h"
#include "amdgpu_ucode.h"
@ -846,7 +849,7 @@ static int sdma_v3_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = le32_to_cpu(adev->wb.wb[index]);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -22,6 +22,8 @@
*/
#include <linux/firmware.h>
#include <linux/delay.h>
#include <drm/drmP.h>
#include "amdgpu.h"
#include "amdgpu_ucode.h"
@ -1207,7 +1209,7 @@ static int sdma_v4_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = le32_to_cpu(adev->wb.wb[index]);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -230,7 +230,7 @@ static int si_dma_ring_test_ring(struct amdgpu_ring *ring)
tmp = le32_to_cpu(adev->wb.wb[index]);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -491,7 +491,7 @@ static int uvd_v4_2_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(mmUVD_CONTEXT_ID);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -22,7 +22,9 @@
* Authors: Christian König <christian.koenig@amd.com>
*/
#include <linux/delay.h>
#include <linux/firmware.h>
#include <drm/drmP.h>
#include "amdgpu.h"
#include "amdgpu_uvd.h"
@ -506,7 +508,7 @@ static int uvd_v5_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(mmUVD_CONTEXT_ID);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -183,7 +183,7 @@ static int uvd_v6_0_enc_ring_test_ring(struct amdgpu_ring *ring)
for (i = 0; i < adev->usec_timeout; i++) {
if (amdgpu_ring_get_rptr(ring) != rptr)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)
@ -957,7 +957,7 @@ static int uvd_v6_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32(mmUVD_CONTEXT_ID);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -191,7 +191,7 @@ static int uvd_v7_0_enc_ring_test_ring(struct amdgpu_ring *ring)
for (i = 0; i < adev->usec_timeout; i++) {
if (amdgpu_ring_get_rptr(ring) != rptr)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)
@ -1227,7 +1227,7 @@ static int uvd_v7_0_ring_test_ring(struct amdgpu_ring *ring)
tmp = RREG32_SOC15(UVD, ring->me, mmUVD_CONTEXT_ID);
if (tmp == 0xDEADBEEF)
break;
DRM_UDELAY(1);
udelay(1);
}
if (i >= adev->usec_timeout)

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dm_services.h"
#include "core_types.h"
#include "timing_generator.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dm_services.h"
#include "dc.h"
#include "core_types.h"

View File

@ -26,6 +26,9 @@
* Created on: Aug 30, 2016
* Author: agrodzov
*/
#include <linux/delay.h>
#include "dm_services.h"
#include <stdarg.h>

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dm_services.h"
#include "core_types.h"
#include "dce_aux.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "core_types.h"
#include "link_encoder.h"
#include "dce_dmcu.h"

View File

@ -22,6 +22,9 @@
* Authors: AMD
*
*/
#include <linux/delay.h>
#include "dce_i2c.h"
#include "dce_i2c_hw.h"
#include "reg_helper.h"

View File

@ -22,6 +22,9 @@
* Authors: AMD
*
*/
#include <linux/delay.h>
#include "dce_i2c.h"
#include "dce_i2c_sw.h"
#include "include/gpio_service_interface.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "reg_helper.h"
#include "core_types.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dc_bios_types.h"
#include "dce_stream_encoder.h"
#include "reg_helper.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dm_services.h"
#include "dce/dce_11_0_d.h"

View File

@ -22,6 +22,9 @@
* Authors: AMD
*
*/
#include <linux/delay.h>
#include "dm_services.h"
#include "dc.h"
#include "dc_bios_types.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dm_services.h"
/* include DCE11 register header files */

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dce110_transform_v.h"
#include "dm_services.h"
#include "dc.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dm_services.h"
#include "dce/dce_11_2_d.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dm_services.h"
#include "dcn10_hubp.h"
#include "dcn10_hubbub.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "reg_helper.h"
#include "core_types.h"

View File

@ -23,6 +23,7 @@
*
*/
#include <linux/delay.h>
#include "dc_bios_types.h"
#include "dcn10_stream_encoder.h"

View File

@ -23,6 +23,8 @@
*
*/
#include <linux/delay.h>
#include "dm_services.h"
#include "include/gpio_types.h"