XRT icon indicating copy to clipboard operation
XRT copied to clipboard

Port kernel driver to Linux 6.8

Open keryell opened this issue 1 year ago • 11 comments
trafficstars

To be rebased on main once https://github.com/Xilinx/XRT/pull/8003 has landed. I think the code would benefit from some review by DRM experts because I have 0 expertise. @superm1 @airlied This is to have https://github.com/amd/xdna-driver working along https://github.com/amd/xdna-driver/issues/3

keryell avatar Mar 12 '24 01:03 keryell

keryell - is not a collaborator Can XRT admins please validate PR

gbuildx avatar Mar 12 '24 01:03 gbuildx

/build

maxzhen avatar Mar 12 '24 04:03 maxzhen

keryell - is not a collaborator Can XRT admins please validate PR

gbuildx avatar Mar 12 '24 15:03 gbuildx

I have signed-off the commits now. This PR is not supposed to be squashed as its commits and their messages are independent.

keryell avatar Mar 12 '24 15:03 keryell

I do not know if removing DRM_UNLOCKED which is no longer in use since Linux 6.3 is OK, since the driver is supposed to be compiled also on some antique kernels where it might be required. I have no idea about the big picture of this driver.

keryell avatar Mar 12 '24 16:03 keryell

I do not know if removing DRM_UNLOCKED which is no longer in use since Linux 6.3 is OK, since the driver is supposed to be compiled also on some antique kernels where it might be required. I have no idea about the big picture of this driver.

It should not be unconditionally removed. Maybe just add a Macro like #if KERNEL_VERSION(6, 8, 0) <= LINUX_VERSION_CODE #define DRM_UNLOCKED 0 #endif

houlz0507 avatar Mar 12 '24 17:03 houlz0507

It should not be unconditionally removed. Maybe just add a Macro

Yes I can do that.

keryell avatar Mar 12 '24 17:03 keryell

This is not clear why the test on pcie-hw-tests (xilinx_u250_gen3x16_xdma_4_1_202210_1) is not working. How to investigate this?

keryell avatar Mar 12 '24 23:03 keryell

XOAH shows ERROR: Not enough host mem. Please check grub settings.: Cannot allocate memory on pcie-hw-tests (xilinx_u250_gen3x16_xdma_4_1_202210_1).

keryell avatar Mar 13 '24 00:03 keryell

OK, the problem was that in af7a239 (#8005) I forgot to replace the << by *, so there was a UB operation due to the overflow, probably leading 0, so the allocation was always too big... Ahem.

keryell avatar Mar 13 '24 02:03 keryell

This PR is not supposed to be squashed as its commits and their messages are independent.

keryell avatar Mar 13 '24 02:03 keryell

So, what is the problem on this PR?

keryell avatar Mar 26 '24 18:03 keryell

@stsoe Thanks!

keryell avatar Mar 26 '24 18:03 keryell