From 552755e4666f6fff37fc971d225b30e11853050e Mon Sep 17 00:00:00 2001 From: jgoutin Date: Thu, 17 Feb 2022 14:23:16 +0100 Subject: [PATCH] Fix issue when Kernel module install requires reboot and /tmp is a tmpfs. --- tasks/aws_fpga.yml | 6 +++--- tasks/video_sdk.yml | 6 +++--- tasks/xrt.yml | 12 ++++++++---- tasks/xrt_from_pkg.yml | 2 -- 4 files changed, 14 insertions(+), 12 deletions(-) diff --git a/tasks/aws_fpga.yml b/tasks/aws_fpga.yml index ad6f8e8..14a65f2 100644 --- a/tasks/aws_fpga.yml +++ b/tasks/aws_fpga.yml @@ -1,5 +1,8 @@ --- +- include_tasks: kernel.yml + when: aws_fpga_driver is defined + - name: Get "/usr/local/lib64" directory information stat: path: /usr/local/lib64 @@ -110,9 +113,6 @@ executable: /bin/bash when: not libfpga_mgmt.stat.exists -- include_tasks: kernel.yml - when: aws_fpga_driver is defined - - name: Install AWS FPGA alternate driver command: "make -C {{ aws_fpga_src }}/sdk/linux_kernel_drivers/{{ aws_fpga_driver }} install" changed_when: false diff --git a/tasks/video_sdk.yml b/tasks/video_sdk.yml index badff2e..21f3ac2 100644 --- a/tasks/video_sdk.yml +++ b/tasks/video_sdk.yml @@ -5,6 +5,9 @@ path: /opt/xilinx/xcdr/xclbins/transcode.xclbin register: vsdk_xclbin +- include_tasks: kernel.yml + when: not vsdk_xclbin.stat.exists + - include_tasks: epel.yml when: not vsdk_xclbin.stat.exists @@ -39,9 +42,6 @@ until: vsdk_tar is successful when: not vsdk_xclbin.stat.exists -- include_tasks: kernel.yml - when: not vsdk_xclbin.stat.exists - - name: Set Xilinx Video SDK release directory set_fact: vsdk_release_path: "{{ vsdk_tar | video_sdk_release_dir(ansible_facts, vsdk_tmp.path) }}" diff --git a/tasks/xrt.yml b/tasks/xrt.yml index b5eb17c..cfd5c98 100644 --- a/tasks/xrt.yml +++ b/tasks/xrt.yml @@ -1,5 +1,10 @@ --- +- name: Get "xbutil" file information + stat: + path: /opt/xilinx/xrt/bin/xbutil + register: xbutil + - name: Ensure Linux kernel version is compatible include_role: name: accelize.linux_kernel @@ -9,11 +14,10 @@ - xilinx_xrt_ensure_compatible_kernel | bool - xrt_required_kernel != "" # noqa empty-string-compare - not (xilinx_xrt_container | bool) + - not xbutil.stat.exists -- name: Get "xbutil" file information - stat: - path: /opt/xilinx/xrt/bin/xbutil - register: xbutil +- include_tasks: kernel.yml + when: not xbutil.stat.exists - name: Create temporary directory tempfile: diff --git a/tasks/xrt_from_pkg.yml b/tasks/xrt_from_pkg.yml index 79630c3..c1c68c6 100644 --- a/tasks/xrt_from_pkg.yml +++ b/tasks/xrt_from_pkg.yml @@ -120,5 +120,3 @@ when: - ansible_distribution == "CentOS" - ansible_distribution_major_version == "8" - -- include_tasks: kernel.yml