VME: Difference between revisions
No edit summary |
|||
Line 7: | Line 7: | ||
== '''JVME driver installation''' == | == '''JVME driver installation''' == | ||
'''Install jvme driver''' | '''Install jvme driver''' | ||
Line 15: | Line 16: | ||
'''NOTE''': CODA will not use ''jvme-release-3.0'' area directly. Instead, another directory ''$CODA/src/jvme'' will be created with CODA-specific Makefile and structure, and symbolic links from that directory will be pointed to ''jvme-release-3.0'' area. That means you may not need to do anything described above, just install ''jvme-release-3.0'' and configure synbolic links to it from ''$CODA/src/jvme'' (!!!???) | '''NOTE''': CODA will not use ''jvme-release-3.0'' area directly. Instead, another directory ''$CODA/src/jvme'' will be created with CODA-specific Makefile and structure, and symbolic links from that directory will be pointed to ''jvme-release-3.0'' area. That means you may not need to do anything described above, just install ''jvme-release-3.0'' and configure synbolic links to it from ''$CODA/src/jvme'' (!!!???) | ||
'''old gefvme removal''' | '''old gefvme removal''' |
Latest revision as of 10:55, 16 May 2025
VME controller BIOS important settings
Make sure VME memry size is set to 512M
It can be several network ports in BIOS, find right one by using 'blinking', remember MAC address.
JVME driver installation
Install jvme driver
Go to git link: https://code.jlab.org/fedaq/drivers/jvme/-/tree/release-3.0. Click on blue button 'Code' and download progect as 'tar'.
On vme controller as boiarino, copy jvme-release-3.0.tar to $CODA/src and untar it.
NOTE: CODA will not use jvme-release-3.0 area directly. Instead, another directory $CODA/src/jvme will be created with CODA-specific Makefile and structure, and symbolic links from that directory will be pointed to jvme-release-3.0 area. That means you may not need to do anything described above, just install jvme-release-3.0 and configure synbolic links to it from $CODA/src/jvme (!!!???)
old gefvme removal
yum remove kmod-gefvme gefvme-library
If failed on 'gefvme-library', do
rpm -e --noscripts gefvme-library
If file /etc/modules-load.d/gefvme.conf was not removed by above commands, remove it manually (if working from chroot ... then everything is done in root area, but gefvme.conf may survive in snapshot area, in that case remove it on controller and not in chroot).
File /etc/modules-load.d/vme.conf with contents
cmem_rcc jvme vme_vivo vme_ca91cx42 vme_tsi148 vme
may not be needed (if modules already in kernel ?).
new jvme (not sure if module installation is needed, maybe in kernel already ?)
Create two environment scripts:
jvme_bash:
#!/bin/bash export LINUXVME=${CODA}/src/jvme-release-3.0/linuxvme export LINUXVME_INC=${LINUXVME}/include export LINUXVME_LIB=${LINUXVME}/Linux_`uname -m`_vme/lib export LINUXVME_BIN=${LINUXVME}/Linux_`uname -m`_vme/bin export LD_LIBRARY_PATH=${LINUXVME_LIB}:${LD_LIBRARY_PATH} export KERNELRELEASE=3.10.0-1062.9.1.el7.x86_64
jvme_tcsh:
#!/bin/tcsh setenv LINUXVME ${CODA}/src/jvme-release-3.0/linuxvme setenv LINUXVME_INC ${LINUXVME}/include setenv LINUXVME_LIB ${LINUXVME}/Linux_`uname -m`_vme/lib setenv LINUXVME_BIN ${LINUXVME}/Linux_`uname -m`_vme/bin setenv LD_LIBRARY_PATH ${LINUXVME_LIB}:${LD_LIBRARY_PATH} setenv KERNELRELEASE 3.10.0-1062.9.1.el7.x86_64
Run source jvme_tcsh. Go inside jvme-release-3.0. In two files CMakeLists.txt and src/CMakeLists.txt, change
set(libpath Linux-${CMAKE_SYSTEM_PROCESSOR}/lib) set(libpath Linux-${CMAKE_SYSTEM_PROCESSOR}/bin)
to
set(libpath Linux_${CMAKE_SYSTEM_PROCESSOR}_vme/lib) set(libpath Linux_${CMAKE_SYSTEM_PROCESSOR}_vme/bin)
Type cmake -B build -S . -DCMAKE_INSTALL_PREFIX=$LINUXVME
Fix Makefile in kernel_driver and three it's subdirectories, it must have following in the beginning:
KVERSION := $(KERNELRELEASE) ifeq ($(origin KERNELRELEASE), undefined) KVERSION := $(shell uname -r) endif
In directory jvme-release-3.0, type make and make install,
Do cd kernel_driver and make (do NOT do make install).
On the server, do
mount -o bind /usr/clas12 /diskless/CentOS7/x86_64/root/usr/clas12 mount -o bind /usr/local /diskless/CentOS7/x86_64/root/usr/local mount -o bind /home /diskless/CentOS7/x86_64/root/home chroot /diskless/CentOS7/x86_64/root cd /usr/clas12/release/2.0.0/coda/src source jvme_bash cd jvme-release-3.0/kernel_driver make install
Still on server, add two files to /etc/udev/rules.d directory:
99-cmem.rules:
KERNEL=="cmem_rcc", MODE="0666"
99-vme.rules:
KERNEL=="bus/vme/ctl", MODE="0666" KERNEL=="bus/vme/m_a16", MODE="0666" KERNEL=="bus/vme/m_a24", MODE="0666" KERNEL=="bus/vme/m_a32", MODE="0666" KERNEL=="bus/vme/m_crcsr", MODE="0666" KERNEL=="bus/vme/s_a32", MODE="0666" KERNEL=="bus/vme/s_rsvd1", MODE="0666" KERNEL=="bus/vme/s_rsvd2", MODE="0666" KERNEL=="bus/vme/s_rsvd3", MODE="0666"
Reboot controller, check if everything is good.
NOTE: if changing something in kernel module(s), it is not needed to reboot every time after make/make install is done in jvme-release-3.0/kernel_driver directory. Just run ./load_driver.sh as root on controller, and all modules will be reloaded.