L4T on Acer Chromebook 13 CB5

I used an earlier script from here:

And consider an ‘update’ to 21.3 actually :)
If I succeeded I will post here again. It seems good to keep this thread active here.
The only other source of valuable information is the link above and here:
http://www.reddit.com/r/chrubuntu/comments/2hhb31/chrubuntu_on_acer_chromebook_13/

My install does not work. Cuda compiles but will not run - read this thread, the kernel appears to have been updated sometime in spring 2015, which breaks cuda:

[url]Redirecting to Google Groups

Oh, that is a real pity. But the rest of the script/system works well?
Also, does it rely to be run on a ‘fresh’ ChromeOS, or could it be launched from a former chrubuntu?
At first glance it seems like the script fetches files from hardcoded ChromeOS directories?

There are two errors. First find “gpio-keys.4” in the script and make it “gpio-keys.5”, so that the lid will suspend when closed. Second, there is a missing symlink to … tegra/libGL.so - it still points to the Mesa version.

Thanks, would you mind elaborating how to fix that one in the script (or poast-script)?
And does the script need to be run on a ‘fresh, untouched ChromeOS’ ?

For now I would rather once more stress that “Cuda compiles but will not run” - see previous comments. This is a showstopper.

The problem is definitely with the updated kernel. After backpedaling to a known good point in time with L4T 19.3 and this kernel

https://chromium.googlesource.com/chromiumos/third_party/kernel/+archive/release-R41-6680.B-chromeos-3.10.tar.gz

… configured like part three in this article

http://www.synkhronix.com/journal/gentoo-chromebook-3.rst
(adjusted for differences in partitioning and that the target is / rather than /mnt/rootfs…)

… then Cuda works.

[CUDA Bandwidth Test] - Starting...
Running on...

 Device 0: GK20A
 Quick Mode

 Host to Device Bandwidth, 1 Device(s)
 PINNED Memory Transfers
   Transfer Size (Bytes)	Bandwidth(MB/s)
   33554432			7229.8

 Device to Host Bandwidth, 1 Device(s)
 PINNED Memory Transfers
   Transfer Size (Bytes)	Bandwidth(MB/s)
   33554432			11349.8

 Device to Device Bandwidth, 1 Device(s)
 PINNED Memory Transfers
   Transfer Size (Bytes)	Bandwidth(MB/s)
   33554432			8145.2

Result = PASS

Hi,
sounds like good news!
Following your route is a bit out of scope for me now Im afraid, though.
Would it be feasable to re-insert the 19.3 kernel into the 21.3 version?

I think so - I don’t see any immediate reason why it shouldn’t work. It is still a “3.10.18” for all the world would know, just with a different config. As long as you understand that if/when you update to 21.3, the chrubuntu script will now snatch the chromeos kernel that meanwhile has been updated OTA (with the hooks to CUDA rationalized away) and that the cuda libraries then will fail and go looking for a module that does not exist and never did. What I can do is to document the exact steps taken to restore the kernel, as a script, starting with the wgets and ending with the dd. We all have the exact same chrubuntu partitioning scheme, so it’s completely mechanical. Wait a day or two - I have new toys here ;-)

OK, great. Anything ‘reproducable’ and ‘from scratch’ will be appreciated.
My Chromebook is running an early Chrubuntu version right now. Is it feasable to start from there?
Or should I set it back to ChromeOS somehow first?

(updated below)

So I first run the script that installs 21.3
from post #20: Dropbox - chrubuntu-install-21.3.sh - Simplify your life
and afterwards I run the commands you just posted to get back to a kernel that works with cuda?

(updated below)

Hi,
sorry for being a tad lame here.
Thanks for your efforts first, but I am still not sure about what the ‘whole procedure’ is.You set up chrubuntu as in post #20:
“I installed ubuntu using Dropbox - chrubuntu-install-21.3.sh - Simplify your life

And then I would follow the script in post #30.
Is that complete or just some sort of ‘diff’ to another script?
And then I put the rest into a script and execute it.
That should compile a working kernel to use in 21.3 instead of the one included in 21.3
And then I dd that new kernel with which cuda will also work.

Is that correct?
And that being said, is there any point to check 21.4?

enthusi,

If you have installed chrubuntu recently - by any script out there, but yes, I used 21.3 - the chrome-os kernel will have been updated OTA, and does not support CUDA anymore. This script grabs the old kernel and compiles it from source. Cuda 6.5 then works again.

cd && clear
echo "--------------------------------------------------------"
echo "     Script to re-enable cuda capabilities              "
echo "     on Acer CB5-311 Chromebooks                        "
echo "--------------------------------------------------------"
echo
echo "install tools"
sudo apt-get -y install cgpt vboot-kernel-utils device-tree-compiler build-essential u-boot-tools ncurses-dev mpi-default-dev mpi-default-bin

cd $HOME/Downloads
echo
echo "fetch sources"
wget  http://commondatastorage.googleapis.com/chromeos-localmirror/distfiles/xhci-firmware-2014.10.10.00.00.tbz2 
wget  https://chromium.googlesource.com/chromiumos/third_party/kernel/+archive/release-R41-6680.B-chromeos-3.10.tar.gz
# The CUDA repo to use when we are done:
wget http://developer.download.nvidia.com/embedded/L4T/r21_Release_v3.0/cuda-repo-l4t-r21.3-6-5-prod_6.5-42_armhf.deb

echo
ls -l xhci-firmware*tbz2 release-R41-6680.B*tar.gz

mkdir -p $HOME/src/linux
cd $HOME/src/linux
echo
echo "copy firmware"
sudo tar xf $HOME/Downloads/xhci-firmware-2014.10.10.00.00.tbz2 -C /
echo
echo "extract kernel"
tar -xf $HOME/Downloads/release-R41-6680.B-chromeos-3.10.tar.gz
echo
ls
echo
echo "configure"
./chromeos/scripts/prepareconfig chromeos-tegra

./scripts/config --set-val CONFIG_EXTRA_FIRMWARE \"nvidia/tegra124/xusb.bin\"
./scripts/config --set-val CONFIG_EXTRA_FIRMWARE_DIR \"/lib/firmware\"
./scripts/config -d CONFIG_CC_STACKPROTECTOR
./scripts/config -d CONFIG_SECURITY_CHROMIUMOS
WIFIVERSION=-3.8 make oldnoconfig
cat ./.config|grep CONFIG_EXTRA_FIRMWARE
echo

WIFIVERSION=-3.8 make -j4 zImage
WIFIVERSION=-3.8 make -j4 modules
WIFIVERSION=-3.8 make tegra124-nyan-big.dtb
sudo WIFIVERSION=-3.8 make INSTALL_PATH=/boot INSTALL_MOD_PATH=/ firmware_install modules_install 

cat << __EOF__ > arch/arm/boot/kernel.its
/dts-v1/;

/ {
        description = "ChromeOS kernel image with one or more FDT-blobs.";
        images {
                kernel@1{
                        description = "kernel";
                        data = /incbin/("zImage");
                        type = "kernel_noload";
                        arch = "arm";
                        os = "linux";
                        compression = "none";
                        load = <0>;
                        entry = <0>;
                };
                fdt@1{
                        description = "tegra124-nyan-big.dtb";
                        data = /incbin/("dts/tegra124-nyan-big.dtb");
                        type = "flat_dt";
                        arch = "arm";
                        compression = "none";
                        hash@1 {
                                algo = "sha1";
                        };
                };
        };
        configurations {
                default = "conf@1";
                conf@1 {
                        kernel = "kernel@1";
                        fdt = "fdt@1";
                };
        };
};
__EOF__

mkimage -f arch/arm/boot/kernel.its vmlinux.uimg
echo "console=tty1 debug verbose root=/dev/mmcblk0p7 rootfstype=ext4 rootwait rw lsm.module_locking=0" > kernel-config
vbutil_kernel \
        --version 1 \
        --arch arm \
        --keyblock /usr/share/vboot/devkeys/kernel.keyblock \
        --signprivate /usr/share/vboot/devkeys/kernel_data_key.vbprivk \
        --vmlinuz vmlinux.uimg \
        --pack chromeos-R41-6680.B.kpart \
        --config kernel-config

echo
echo "--------------------------------------------------------"
echo "  We are done. Install kernel now? - Then do:"
echo 
echo "  cd $HOME/src/linux                                    "  
echo "  sudo dd if=chromeos-R41-6680.B.kpart of=/dev/mmcblk0p6"
echo "  sudo cgpt add -i 6 -P 5 -T 1 /dev/mmcblk0             "
echo 
echo "  ... and reboot.                                       "

Oh, and one more thing; To make CUDA run fast, do:

sudo -i
echo performance > /sys/devices/soc0/50000000.host1x/57000000.gk20a/devfreq/57000000.gk20a/governor

This gives me a device bandwidth of 27 GB/sec according to bandwidthTest, and 307 single precision GFlops according to nbody -benchmark -numbodies=32768

Hi guys,

You can get my basic bootable USB stick system image built from Debian and an earlier working ChromeOS kernel and instructions here:

https://drive.google.com/folderview?id=0B6wc5jYvaeo-fnQ3eV83cDFaMkNvRjRrYW1CZGhSX0k3SjVzZWZROWRqSnVYR3RJYV9HdmM&usp=sharing

Working kernel sources are included. This is a basic “math only” image, but it is certainly possible to add accelerated X11, etc. This image is for the HP, but it is trivial to make the Acer kernel image.

Hey guys,

i’ve edited chrubuntu-script from first page:

 - Fixed some bugs that causes crashes
 - Fixed bug in udev rule so lid switch is working now
 - Updated to 21.4

https://drive.google.com/file/d/0BzyE6eJDfqGRWG1XZ0l1ZzJMaU0/view?usp=sharing

NoDiskNoFun

Hey guys,

i also successfully build dante (doom3 engine port for OpenGLES), it’s a dirty build but it works flawless except of fullscreen (don’t know why). This build has OpenGLES enabled, OpenGL build works in fullscreen till you start a game then crashes (segmentation fault).

You have to place your doom 3 files in /usr/local/games/doom3
You need also patch files which can be extracted from offical installer

Anyways here it is:
https://drive.google.com/file/d/0BzyE6eJDfqGRUlJzZkRYaHI3QjA/view?usp=sharing

navigate to neo and start doom.armv7l

Have Fun,
NoDiskNoFun

After going through some difficulties i was finally able to build dhewm3. This build of the Doom 3 engine runs better than dante and also uses OpenGL instead of OpenGLES. Here’s the link:

https://drive.google.com/file/d/0BzyE6eJDfqGRNVp6TUFFampSMDA/view?usp=sharing

place it in /usr/local/bin, also place base folder in it.

run dhewm3 with +set in_tty 0 to avoid crashes on startup or create a file in /usr/bin, call it doom3, make it executable and insert:

/usr/local/bin/dhewm3 +set in_tty 0

Have fun,
NoDiskNoFun