================================================================================
=                 CORAS(LNX) for VPC/Solution-ePC/EPC/LPC                      =
=          CONTEC RAS driver for Linux for VPC/Solution-ePC/EPC/LPC            =
=                                                               Ver. 1.6.0     =
=                                                          CONTEC Co.,Ltd.     =
================================================================================

Contents
=========
  Introduction
  About the Product
  Support products
  Restrictions
  Note
  install/uninstall
  File Structure
  Version up history

Introduction
=============
  The explanation of CORAS(LNX) is described as follows. You must read it
  because some contents are not described in help.

About the Product
==================
  - CORAS (LNX) provides a group of functions for controlling our boards such as
    VPC series by using modular drivers and shared libraries.

  - Start up the driver and use it, by using the script files for starting the
    driver.

  - Sample source code is attached.

support products
=================
  - VPC-1700 Series *1
  - VPC-3100 Series *1
  - VPC-5000-J Series *1
  - MR4100 Series
  - EPC-C5000 Series
  - LPC-400 Series
  - VPC-1800-J Series
  - VPC-3200-J Series
  - LPC-1800-J Series

  *1) Please note that the initial state of DIO (including LED in VPC-1700 and
      VPC-3100) differs depending on the BIOS version, so please be careful when
      using the API.

Restrictions
=============
  The operation check environment is as follows.
  The following description may be described together with the confirmation
  information in the conventional version. Please note that the execution has
  not been confirmed again for all combinations of this version and all models
  and the listed distributions (and versions). In addition, we do not guarantee
  the operation with all the listed models and each distribution (and version).
  * The contents below are as of the release. It may not match the support
    status of each distribution.
  * For operation confirmation information for individual models, see the
    contents of the operation confirmation document for each model.

  Distribution                Kernel version
  ----------------------      ------------------
  Ubuntu
    Ubuntu 20.04 LTS          5.11.0-27-generic(x86_64)(hwe)
                              5.15.0-67-generic(x86_64)(hwe)
    Ubuntu 22.04 LTS          5.15.0-43-generic(x86_64)
                              5.19.0-32-generic(x86_64)(hwe)
                              6.2.0-26-generic(x86_64)(hwe)
                              6.8.0-40-generic(x86_64)(hwe)
    Ubuntu 24.04 LTS          6.8.0-41-generic(x86_64)
                              6.14.0-27-generic(x86_64)(hwe)
  Red Hat Enterprise Linux(RHEL)
    RHEL 7.9                  3.10.0-1160.el7.x86_64
    RHEL 8.5                  4.18.0-348.el8.x86_64
    RHEL 8.6                  4.18.0-372.9.1.el8.x86_64
    RHEL 8.7                  4.18.0-425.19.2.el8_7.x86_64
    RHEL 8.8                  4.18.0-477.10.1.el8_8.x86_64
    RHEL 8.9                  4.18.0-513.5.1.el8_9.x86_64
    RHEL 8.10                 4.18.0-553.el8_10.x86_64
    RHEL 9.0                  5.14.0-70.13.1.el9_0.x86_64
    RHEL 9.1                  5.14.0-162.6.1.el9_1.x86_64
    RHEL 9.2                  5.14.0-284.11.1.el9_2.x86_64
    RHEL 9.3                  5.14.0-362.8.1.el9_3.x86_64
    RHEL 9.4                  5.14.0-427.13.1.el9_4.x86_64
    RHEL 9.5                  5.14.0-503.11.1.el9_5.x86_64
    RHEL 9.6                  5.14.0-570.12.1.el9_6.x86_64
    RHEL 10.0                 6.12.0-55.9.1.el10_0.x86_64
  MIRACLE LINUX(ML)
    ML 8.4                    4.18.0-305.el8.x86_64
    ML 8.6                    4.18.0-372.9.1.el8.x86_64
    ML 8.8                    4.18.0-477.10.1.el8_8.x86_64
    ML 8.10                   4.18.0-553.el8_10.x86_64
    ML 9.0                    5.14.0-70.13.1.el9_0.x86_64
    ML 9.2                    5.14.0-284.11.1.el9_2.x86_64
    ML 9.4                    5.14.0-427.13.1.el9_4.x86_64
    ML 9.6                    5.14.0-570.12.1.el9_6.x86_64
  AlmaLinux(AL)
    AL 9.6                    5.14.0-570.12.1.el9_6.x86_64
    AL 10.0                   6.12.0-55.9.1.el10_0.x86_64(x86_64-v3)

  dependencies
  ------------
    - glibc ≧ 2.17
    - gcc
    - GNU make
    - systemd
    etc.

Note
==============
  - Before using the driver source and library included in this software
    package, please check the contents of the attached EULA and agree to the
    terms of use.

  - You need to have root privileges to install and configure the driver, start
    it, and run make. In addition, there may be restrictions on operations,
    etc. depending on your environment such as permission settings and security
    settings.

  - When updating the kernel, rebuild this kernel module as appropriate.

  - For details, please refer to the help documents and the contents of each
    script and program source.

install/uninstall
==================
[src package]
  - install
    Compile and install modules, libraries, etc.
    # cd ./(CORASLNX_Top_Directory)
    # make install

  - uninstall
    Uninstalls modules, libraries, etc.
    # cd ./(CORASLNX_Top_Directory)
    # make uninstall

    * If you have changed the installation destination, the uninstall process
      may not be performed properly, so please check the contents in advance.
      Also, when uninstalling, do not use a version different from the one used
      at the time of installation. It may not be processed normally.

note
* makefile Execution option
  install        .. The module and library related items will be installed.
  uninstall      .. The module and library related items will be uninstalled.
  install_all    .. The module, library amd hardware monitoring daemon,
                    will be installed.
  uninstall_all  .. The module, library amd hardware monitoring daemon,
                    will be uninstalled.
  install_util   .. The hardware monitoring daemon will be installed.
                    (Installation related to module and library is required.)
  uninstall_util .. The hardware monitoring daemon will be uninstalled.
  sample         .. Build the console sample corresponding to the device.
                    (Note: Since it is judged only by dmi information, it may
                    be built including unsupported ones.)
  clean          .. Delete the intermediate files, executable files, etc.
                    created when "install" and "sample" options are used.

* For RHEL-based distributions, the coras driver module may not load properly
  due to SELinux security policy. If the loading of the coras module is
  restricted by SELinux, you need to make changes such as setting the policy
  appropriately. The following is an example of how to set the policy.
  (Run after installation)
  Create and move to work directory
    # mkdir (work_dir) && cd ./(work_dir)
  Generate policy package
    # ausearch -c 'insmod' -f '/opt/contec/CoRasMod/coras.ko' --raw | \
      audit2allow -M coras-insmod
  Enable policy package
    # semodule -i coras-insmod.pp
  Confirm that policy package is enabled
    # semanage module -l | grep coras-insmod

  Reboot and verify that the coras module is loaded.

  Reload the coras module if necessary.
    # systemctl restart coras_load.service

[rpm package]
The included RPM package may be used in RHEL and RHEL compatible environments
such as ML. Below is an example using the dnf command.

  - install
    # cd ./(CORASLNX_Top_Directory)/rpm/elX/<arch>

    package install
    # dnf install \
      ./kmod-coras.X.X-X.elX.<arch>.rpm \
      ./coras-X.X-X.elX.<arch>.rpm \
      ./coras-tools-X.X-X.elX.<arch>.rpm \
      ./coras-devel-X.X-X.elX.<arch>.rpm

    coras module load (start service or reboot)
    # systemctl restart coras_load

    CLI tool execution test (temperature information)
    # corasctl temp

    * The kmod package is in kABI-tracking kmod format. Please install the
      package according to the execution environment (for example, for an el9.1
      kernel environment, install the 162.6.1.el9_1 package, etc.). If you
      update the kernel package to a newer el minor release after installing
      the kmod package, the kernel modules in the kmod package may stop working
      due to kernel ABI incompatibilities. When upgrading, you must ensure that
      the appropriate kmod-coras package is provided and update or reinstall the
      kmod-coras package.

  - uninstall
    package uninstall
    # dnf remove kmod-coras coras coras-tools coras-devel

[deb package]
May be available in compatible environments such as Ubuntu.
The following is an execution example using the apt command.

  - install
    # cd ./(CORASLNX_Top_Directory)/deb/<ubuntu_codename>/<arch>

    package install
    # apt install \
      ./coras-vpc-dkms_X.XX-XubuntuX_<arch>.deb \
      ./coras_X.XX-XubuntuX_<arch>.deb \
      ./coras-tools_X.XX-XubuntuX_<arch>.deb \
      ./coras-dev_X.XX-XubuntuX_<arch>.deb

    CLI tool execution test (temperature information)
    # corasctl temp

    * The "coras-vpc-dkms" package uses dkms. You will need to install dkms and
      dependent packages. When updating a kernel package, dkms will attempt to
      rebuild this module for the target kernel.

  - uninstall
    package uninstall
    # apt purge coras-vpc-dkms coras coras-tools coras-dev

File Structure
===============
  The file structure is as follows.

  ./(CORASLNX_Top_Directory)/
    readme_j.txt .......... README file (Japanese)
    readme_e.txt .......... README file (English)
    EULA_JP.txt ........... License Agreement (Japanese)
    EULA_EN.txt ........... License Agreement (English)
    Makefile .............. Makefile for batch processing

    help/ ................. help file storage directory
      jp/ ................. Japanese version
        corashelp.htm ..... html help files
        data/ ............. Help data
      en/ ................. English version
        corashelp.htm ..... html help files
        data/ ............. Help data

    module/ ............... for coras driver module

    library/
      include/
        coras_lib.h ....... Shared library header file
        coras_ctl.h ....... Shared library / device driver common header file
        mtdll.h ........... Shared library / device driver common header file
      x86_64/ ............. 64bit Shared library
        libcoraslib.so.x.x
        libmtdll.so.x.x
      Makefile ............ Makefile for installing

    samples/
      corasctl/ ........... Sample CLI Tool
      cohwmond/ ........... Sample Hardware monitoring daemon
      console_samples/ .... Sample source code storage directory
        bin/ .............. for console sample binary
        dio/ .............. General purpose input/output control sample program
        hwmon/ ............ Hardware monitor sample program
        PMonitor/ ......... Temperature monitoring sample program
        Serial/ ........... RS-422/485 full-duplex communication sample program
        sled/ ............. Status LED control sample program
        wdt/ .............. Watchdog timer control sample program

    rpms/ ................. rpm packages
      el8/x86_64/ ......... for el 8 - x86_64
      el9/x86_64/ ......... for el 9 - x86_64
      el10/x86_64/ ........ for el10 - x86_64(x86_64-v3)

      [rpm packages]
        kmod-coras ........ kmod kernel module packages (kABI-tracking kmod)
        coras ............. coras package(module init service and libs)
        coras-devel ....... for development sub-package(header, etc.)
        coras-tools ....... sample tools sub-package (daemon and cli tools)

        * about rpm file name
          <pkg_name>-<pkg_ver>-<pkg_rel>[.<extra_ver>].<dist>.<arch>.rpm
            pkg_name  : package name (coras, coras-devel, etc.)
            pkg_ver   : package version
            pkg_rel   : package release (rpm package)
            extra_ver : extra version info
                       (kmod-coras : additional kernel information at build)
                        [el8]
                          80       : el 8.0
                          147      : el 8.1 - 8.4
                          348      : el 8.5 - 8.10
                        [el9]
                          70.13.1  : el 9.0
                          162.6.1  : el 9.1
                          284.11.1 : el 9.2
                          362.8.1  : el 9.3
                          427.13.1 : el 9.4
                          503.11.1 : el 9.5
                          570.12.1 : el 9.6
                        [el10]
                          55.9.1   : el 10.0
            dist      : elX(_X)
            arch      : x86_64

    debs/ ................. deb packages
      jammy/x86_64/ ....... for 22.04(.X) LTS (Jammy Jellyfish) x86_64
      noble/x86_64/ ....... for 24.04(.X) LTS (Noble Numbat) x86_64

      [deb packages]
        coras-vpc-dkms .... kernel module packages (dkms)
        coras ............. coras package(module init service and libs)
        coras-dev ......... for development sub-package(header, etc.)
        coras-tools ....... sample tools sub-package (daemon and cli tools)

        * about deb file name
          <pkg_name>_<pkg_ver>[-revision]_<arch>.rpm
            pkg_name  : package name (coras, coras-devel, etc.)
            pkg_ver   : package version
            revision  : debian revision
            arch      : amd64

Version up history
===================
  Ver. 1.6.0 (Nov. 2025)
  -----------------------
    - added support products
      - VPC-1800
      - VPC-3200
      - LPC-1800

  Ver. 1.5.0 (Oct. 2025)
  -----------------------
    - added support products
      - LPC-400
    - Update to attached deb packages
      - Removed deb packages for ubuntu 18.04(.x) LTS (Focal Fossa)
      - Added deb packages for ubuntu 24.04(.x) LTS (Noble Numbat)
    - Update to attached rpm packages
      - Added rpm packages for el 9.5, 9.6
    - Updated list of supported distributions
      - CentOS 7 removed due to EOL
      etc.

  Ver. 1.04.1 (Dec. 2023)
  -----------------------
    - add deb packages for
      - Ubuntu 20.04 LTS (Focal Fossa)
      - Ubuntu 22.04 LTS (Jammy Jellyfish)
    - minor update

  Ver. 1.04 (Jun. 2023)
  -----------------------
    - added support products
      - EPC-C5000

  Ver. 1.03 (Apr. 2023)
  -----------------------
    - add sample cli-tool(corasctl)
    - add rpm packages
    - minor update

  Ver. 1.02 (Mar. 2023)
  -----------------------
    - added support products
      - MR-4100
    - Specification change of cohwmond sample program

  Ver. 1.01 (Oct. 2022)
  -----------------------
    - added support products
      - VPC-3100
      - VPC-1700

  Ver. 1.00 (Apr. 2022)
  -----------------------------
    - First Release

<<------------------------------------------------------------------------------
  Linux® is the registered trademark of Linus Torvalds in the U.S. and other
  countries. Ubuntu is a trademark or registered trademark of Canonical Ltd.
  CentOS, Red Hat, and Red Hat Enterprise Linux are registered trademarks of
  Red Hat, Inc. in the United States and other countries. MIRACLE LINUX and
  ミラクル・リナックス are registered trademarks of Cybertrust Japan Co., Ltd.
  AlmaLinux is trademarks of AlmaLinux OS Foundation.
  Other brand, product names and service names are trademarks of their
  respective holder.
------------------------------------------------------------------------------>>
