- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I tried doing a Make on the linux driver module, linux-2.6.38+mpss3.4.2, and I get an error message, that intel_i2c.c, does not compile:
/home/aweiss/mpss/mpss-3.4.2/build/linux-2.6.38+mpss3.4.2/drivers/gpu/drm/i915/intel_i2c.c:269:2: error: ‘dev_priv’ undeclared (first use in this function)
dummy_read_dbox_regs()
{
I915_GMBUS_READ(DBOX_ADAK_CTRL_REG);
I915_GMBUS_READ(DBOX_SW_FLAG_REG);
}
For some reason, this expects dev_priv, and the structure that contains dev_priv is not accessible by the function. I looked in intel_i2c.h, it appears that CONFIG_X86_EARLYMIC is set to Y in the config-mic-knc-2.6.38 file is set to Y. This is the wrong configuration version number, how to I generate the correct version?
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I remade everything:
make mrproper
make O=/home/aweiss/mpss/mpss-3.4.2/build/result mrproper
make O=/home/aweiss/mpss/mpss-3.4.2/build/result x86_64_defconfig
make O=/home/aweiss/mpss/mpss-3.4.2/build/result
I am assuming the .config in build/result has the correct settings. I don't see CONFIG_X86_EARLYMIC set in there, but I don't know how to check that it is not getting set elsewhere. Regardless, the compile is still stopping in the same place.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I re-wrote intel_i2c.c, adding in the dev_priv where it was required, and re-compiled. The compile now stops at some source compilation on MIC code, which it is trying to compile using the x86_64 compiler.
So, then I tried plugging in my Phi card. All I get is a flashing blue light, not sure if it is active, although I assume not. What does this flashing blue LED mean? How do I know if the card is plugged in correctly? I put on the 150W and 75W power connectors, so it should be getting enough power. What else can go wrong?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The blue LED is blinking fast, greater than 2 flashes/sec. Does this indicate a problem? What should the LED state be if this is operating normally?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The code in the linux-2.6.38+mpss3.4.2 is kernel code for the coprocessor and the coprocessor is, indeed, running the 2.6.38 kernel. You should not need to rebuild that code unless you specifically want to make changes to the kernel on the coprocessor. That code must be compiled using the cross-compiler version of gcc and include files and libraries that come with the MPSS package. If what you wanted to do was rebuild the mic kernel module for the host, then the file you need is mpss-modules-3.3.1-1.src.rpm.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
1) Will building the mpss-modules rpm give me the drivers to be able to talk with the Phi? That is all I need.
2) Also, what should the LED flashing sequence be on the card, if it is correctly installed, should it be flashing quickly, say 4 - 6 times/sec?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
1) Yes. If you are using a kernel version for which there is no precompiled modules file in mpss3.4.2/modules, then you need to rebuild the kernel modules and rebuilding the mpss-modules src rpm will give you everything you need for a basic install. You can find directions for building mpss-modules in the readme.txt. That documents contains the directions for doing a basic install. However, if you are also installing OFED/InfiniBand, you will need to recompile the ofed-driver src rpm but that is only needed if you are using OFED/InfiniBand.
2) A blinking light means the System Management Controller (SMC) is active. I don't know that the speed of the blinking is significant. However, this reminds me - did you also do the micflash operation? The directions for that are also in the readme.txt file.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In regards to 2, I have not done the micflash operation. Dont' I need to have the drivers installed before I can do that?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Good point. Yes, you do.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So, I unzipped/untarred mpss-modules, did a make, and fixed the compile bugs. I see in the Makefile, install and modules_install, but I am not clear what I do to actually install this stuff. Also, I don't see an executable micctrl, which is in the instructions.
1) How do I install this from mpss-modules, do I need to set INSTALL_MOD_PATH, or some other variables, or use some other parameters?
2) Where is micctrl getting made, is it in mpss-modules? If not, what other files do I need to unpack and execute?
3) I also noticed that mic.ko was not getting installed in a place that modprobe can find it, I'm assuming that this is in the Make configuration as well. I don't see any of this in the readme.txt file, is there some other set of instructions I can use?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It appears that the make install is putting the mic.ko file in /lib/modules/3.7.10-1.40-desktop/extra, and modprobe is not finding it there. All the other modules are under the kernel directory. Also, it appears that there is some file created by depmod, that gives the dependencies for the modules, not sure if this needs to get run prior to the modprobe.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I ran depmod, then modprobe mic, which worked!
So, how do I create micctrl, micflash, etc.?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In the readme.txt file (version 3.4 here), the directions for installing the MPSS say (and this is just a short summary; you will need to read the readme.txt file for all the details):
1) Remove any previous version of the MPSS that is installed.
2) While you are doing the install, disable any security policies that will prevent the MPSS from installing correctly.
3) Download and untar mpss-<version_number>-linux.tar
4) cd into mpss<version_num>
5) If there are files in the mpss<version_number>/modules directory that have a Linux kernel version matching your host machine
copy those files from mpss<version_number>/modules to mpss<version_number>
else
make sure your have all the dev files from your Linux distribution installed
cd to the mpss<version_number>/src directory
run the command 'rpmbuild --rebuild mpss-modules-*.rpm'
copy the newly built mpss-modules and mpss-modules-dev rpms from where they ended up to mpss<version_number>
(the exact location where rpmbuild puts those file differs between Linux distributions)
cd back to mpss<version_number>
endif
6) Install all the rpm files in the mpss<version_number> directory (preferably using yum or zypper)
7) Load the mic kernel module
8) Do a basic MPSS configuration
9) Update the flash and SMC firmware on the coprocessor card
10) Reboot the host
11) Start the mpss service
I think what you did is (and please correct me if I am wrong):
1) Downloaded and untarred mpss-src-3.4.2.tar
2) cd'ed to mpss<version_number>/src
3) Untarred mpss-modules-3.3.1.tar.bz2 and cd'ed into the directory it created
4) executed 'make modules' and 'make install'
While what you did should have given you a working kernel module, there are some problems:
1) You still need to install all the rpm files under mpss<version_number> (that is where micctrl is)
2) If you try to install those rpm files, you will probably get dependency errors because the mpss-module rpms are not installed (rpm doesn't check to see if the files are installed, only that the required rpm files are installed.
3) The install scripts in the rpm file would have run depmod for you; I don't know what other steps might be taken by the install script that you miss out on by not using that file.
4) There is no uninstall target in the Makefile for mpss-modules-<version_number>. This means that it will be painful to remove the old kernel module before installing later releases. And not uninstalling it is a bad idea because file names may change or a file location may be changed, leaving you with orphaned files and the possibility of using an old file rather than the later one.
I don't know why the build using the mpss-modules-<version_number> didn't work for you. Was it the issue with a variable in one of the kernel data structures no longer being there?
Could you try building from the rpm file? If you need to make changes to the source code, you may need to break the rpmbuild down into a prep and a build operation. If you can get that to work, I would recommend trying to uninstall the mpss-modules that were installed using the Makefile, copy the rebuilt mpss-modules rpm file to mpss<version_number> and install all the rpm files there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am on 3.7.10 kernel, so I tried doing a make from the src directory, as you suggested, which failed in exactly the same place as the compile failed, when I tried building from the source.
Is it possible to build miccntrl from the source directory? If so, this would be a lot easier than doing the build from the rpm's. The rpm builds unpack to a source directory, and try to build from these. The problem is, that the source in these files is not compatible with my kernel.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page