Hi,
Just dropping in to say that this project is not dead! Despite the lack of visible activity, progress is being made. This post will hopefully bring everyone up to date about what's been happening.
Right now, here are some of the things that has happened or is happening now.
- Getting TI-Nspire support into mainline
- Rewriting the TI-Nspire port to use device trees
- Added support for device tree loading in linuxloader2
- Debugging a very annoying and well hidden bootloader bug which has stumped us for weeks (shout outs to Vogtinator)
- PTT LEDs finally unlocked
MainlineWe're in the process of getting TI-Nspire support into the mainline kernel. If this is successful, it'll make maintaining the kernel much easier and also have better code.
To start off with, we're just submitting the absolute basic platform code needed to boot Linux. It doesn't have support for any other hardware than the interrupt controller, timer, clock and keypad.
Once the base kernel is mainlined, we'll begin porting hardware support in again.
Device tree rewritePart of getting TI-Nspire support into the mainline kernel involved switching to using device trees. This means we can effectively use a file to describe our hardware configuration and we don't have to keep chucking code at the kernel for every new hardware supported which is always nice.
Unfortunately, it was easier to just begin writing the whole platform from scratch than fix up our old code. This was exactly what we did.
The old code was left as-is which is why you're not seeing any new updates in nightly builds.
Device tree support in linuxloader2Obviously, to boot the newer, device tree kernels, the bootloader needed to be updated to support loading device tree blobs. It turned out adding support for it was a lot easier than originally anticipated. The first version did not have support for initrds and command line in DT kernels.
Support for it quickly improved and, thanks largely to Vogtinator's contributions, we had a initrd loading and command line loading working. There was a little confusion with 'initrds' and 'ramdisks' which caused the initial version with support for initrds to not work properly. This was due to my bad variable naming in the bootloader code which did not clearly differentiate between the two.
Just when we thought we had a good bootloader going, Vogtinator and I started noticing random things happening in the kernel. Drivers weren't being loaded properly, the LCD driver would work about fifty percent of the time. At the time I suspected something was broken in the kernel and a race condition was occurring. We were lucky to even make it to a shell. For the next couple of weeks, we were pulling hairs out trying to work out what was wrong (at least I was
![Tongue :P](https://www.omnimaga.org/Smileys/classic/tongue.gif)
). Every now and then, someone would come up with a 'fix' that'd work for about an hour and break again. Other times, we'd blame the device tree handling code. Sure, we looked at the bootloader, Vogtinator shuffled some things around but the same things kept happening.
I assumed that if the device tree handling code was truly broken, there would surely be a kernel patch fixing it very soon so I waited to see if anyone else reported a similar problem. A few more weeks went by and the merge window opened again and nothing showed up. I started to suspect the bootloader again since it was unlikely a bug in the kernel since nobody has stumbled on it and went back to the ARM booting guide. A bit of trial and error and I had something that would now work 100% of the time! It was probably the bootloader's fault after all. I quickly sent a patch over to Vogtinator and voila, it was confirmed we had fixed the bug!
PTT LEDs finally unlockedOn the side, I was also researching how to unlock the PTT LEDs. A few months ago, I had partial success and managed to unlock one register (which was enough to control the LED). Now, the LED interface is fully cracked and unlocked - we can use the LED again!
The catch is, we can't unlock the LED in the TI-Nspire OS because it resets if it detects the LEDs have been unlocked. However, that doesn't bother us since we're booting Linux
![Smiley :)](https://www.omnimaga.org/Smileys/classic/smiley.gif)
Being able to use the LEDs is really awesome for Linux since we can now have activity indicators for various things in the kernel (like NAND access)
ThanksI don't think I've properly credited the few people who've contributed a lot to the project. Cheers to:
- Lionel Debroux - for kindly hosting nightly builds of the kernel, pressuring me to mainline the kernel and providing assistance in managing the project
- Vogtinator - for all the work he has contributed to linuxloader2, kernel and TI-Nspire documentation
- All the end users - for your support and
being guinea pigs testing the kernel for us
So, that's the state of Linux on TI-Nspire right now. It's moving slowly (it's my final year of school so things are pretty busy) but it's moving surely!