Author Topic: Calling all Linux Kernel developers!  (Read 353227 times)

0 Members and 1 Guest are viewing this topic.

Offline tangrs

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 229
  • Rating: +98/-0
    • View Profile
    • tangrs blog
Re: Calling all Linux Kernel developers!
« Reply #600 on: January 23, 2013, 09:56:56 pm »
I've changed it so the classic nspires uses 8bpp. I'll push it when X is working on it.

@Vogtinator, I've been researching the meanings behind clcdfb_check's (5+1) magic numbers and this is what I got. Does this mean we can simply put hsync_len as 6 (and change left_margin and right_margin as appropriate as well)? It doesn't seem to be panel specific so maybe we don't have to set it to the same settings the nspire OS uses.

Also, regarding X being broken, did you enable the FBDEV driver in buildroot? The config option is BR2_PACKAGE_XDRIVER_XF86_VIDEO_FBDEV When I use the FBDEV driver, I found that clcdfb_check isn't even called at all so even hsync_len values less than 6 will be accepted (possibly because FBDEV doesn't try to change the video mode).

Basically, should we just simply chuck the minimum value of 6 into hsync_len, left_margin and right_margin?

Edit: Woo!
« Last Edit: January 23, 2013, 10:41:03 pm by tangrs »

Offline Juju

  • Incredibly sexy mare
  • Coder Of Tomorrow
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 5730
  • Rating: +500/-19
  • Weird programmer
    • View Profile
    • juju2143's shed
Re: Calling all Linux Kernel developers!
« Reply #601 on: January 23, 2013, 11:10:37 pm »
Oooh you got X working it's pretty awesome :D

Is the mouse the touchpad/clickpad or something?
« Last Edit: January 23, 2013, 11:11:44 pm by Juju »

Remember the day the walrus started to fly...

I finally cleared my sig after 4 years you're happy now?
THEGAME
This signature is ridiculously large you've been warned.

The cute mare that used to be in my avatar is Yuki Kagayaki, you can follow her on Facebook and Tumblr.

Offline Vogtinator

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1193
  • Rating: +108/-5
  • Instruction counter
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #602 on: January 24, 2013, 01:17:49 am »
Yes, it is. (hopefully)

I didn't test x, I used links -g (directfb) which printed
"current mode not upported".
It works only if I return 0 in clcdfb_check.
That's exactly the same error mssage we had earlier.

Offline tangrs

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 229
  • Rating: +98/-0
    • View Profile
    • tangrs blog
Re: Calling all Linux Kernel developers!
« Reply #603 on: January 24, 2013, 05:40:51 am »
Yes, it is. (hopefully)

I didn't test x, I used links -g (directfb) which printed
"current mode not upported".
It works only if I return 0 in clcdfb_check.
That's exactly the same error mssage we had earlier.


I changed hsync_len to be 6 so it should pass the clcdfb_check tests. Can you pull the latest changes and check that it actually worked?

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
Re: Calling all Linux Kernel developers!
« Reply #604 on: January 24, 2013, 09:06:57 am »
Hi
I have a question : what are the limitations (unless time) to have Nspire linux to work with the NAND filesystem ?
We know it uses Datalight Reliance v2.10 Build 1150 and Datalight FlashFX Pro v3.00 Build 1358 and after some research on them I found that it has "somewhere" a support for bootstrapping linux : http://embedded-computing.com/white-papers/white-flash-flashfx-tera-reliance-nitro/

I cannot find sources (even the "free 30-days source demo" doesn't work when logged in), but maybe already packaged libs exist for Linux running on ARM9 ?
« Last Edit: January 24, 2013, 09:07:42 am by Levak »
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua

Offline Vogtinator

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1193
  • Rating: +108/-5
  • Instruction counter
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #605 on: January 24, 2013, 09:16:51 am »
Quote
I cannot find sources (even the "free 30-days source demo" doesn't work when logged in), but maybe already packaged libs exists for Linux running on ARM9 ?
Works for me.
But they use mount -t relfs, so they're probably using the modules purchased from datalight :-(

Offline tangrs

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 229
  • Rating: +98/-0
    • View Profile
    • tangrs blog
Re: Calling all Linux Kernel developers!
« Reply #606 on: January 24, 2013, 09:24:18 am »
There's two things we need to solve for NAND accesses to work. First is to actually get access to the NAND (i.e. get a driver working) and second is to get it to work with a filesystem of some sort.

At the moment, we don't even have a driver for the NAND controller yet (the PL350 is really weird to control). In fact, this is the main limitation that's holding us back - nobody really knows how to interface with the NAND controller.

I have also considered the filesystem issue where there's no public driver for the Datalight filesystem and FlashFX. Unfortunately, we'll probably have to give up being able to access those filesystems.

The plan I have in my head is to try and 'partition' the NAND to divide some space between the Nspire OS and Linux - each to their own filesystems. We could probably find entry points to certain functions in boot2 or the Nspire OS to format the flash and trick them into believing we have less flash than we actually have. That way we could probably have some flash unused at the end that Linux could utilise.

Failing that, we could probably modify nLaunch in a way to load the kernel directly from flash and have the whole NAND to ourselves (save the pages required by the booting process). Obviously, if we use this method, the Nspire OS will not be able to exist so it'd be a Linux-only calculator (whether that's for the better or worse hehe).

Anyhow, no point discussing all that when we don't even have a driver yet. And writing a NAND driver isn't to be taken lightly, it's a notch harder than writing a keypad driver for example (to say the least). I still don't get how the PL350 in the CX works :(

Offline Vogtinator

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1193
  • Rating: +108/-5
  • Instruction counter
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #607 on: January 24, 2013, 09:31:04 am »
Quote
nobody really knows how to interface with the NAND controller.
Isn't the nspire_emu source enough to start from?

Edit: http://ftp.icpdas.com/pub/beta_version/WinPac-8000/flashfx/dcl/common/loader/reliance/dlrelcore.h
Edit2: http://ftp.icpdas.com/pub/beta_version/WinPac-8000/flashfx/doc/ Someone forgot to make a .htaccess xD ;)
« Last Edit: January 24, 2013, 10:19:24 am by Vogtinator »

Offline merauder75

  • LV3 Member (Next: 100)
  • ***
  • Posts: 75
  • Rating: +1/-1
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #608 on: January 24, 2013, 10:23:57 am »
So, would a basic NAND driver potentially fix the issue with partially corrupting the NAND on reboot? (My CX CAS often freezes on reboot or it reboots with a non-functional touchpad, very weird). ??? I think I saw a whitepaper on Datalight's site for using their NAND in linux (im probably looking at the wrong thing). Honestly, the quality of this NAND seems pretty low overall (seems prone to corruption/bad blocks, etc.), so partitioning could cause more problems.

Even if dual boot was possible (maybe a new bootloader could be written to boot1, or those first 128kb where the logo is stored), it would be extremely difficult to write/set up.

Edit: Nice find, Vogtinator, someone should save that before they realize their mistake.
« Last Edit: January 24, 2013, 10:26:58 am by merauder75 »
Known Programming Languages:
C++,C#,Java,Python,Lua,PHP,x86 ASM,TI-Basic(Z80 and Nspire),C

Offline Vogtinator

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1193
  • Rating: +108/-5
  • Instruction counter
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #609 on: January 24, 2013, 10:29:37 am »
Quote
So, would a basic NAND driver potentially fix the issue with partially corrupting the NAND on reboot? (My CX CAS often freezes on reboot or it reboots with a non-functional touchpad, very weird).
The latest version (actually, some days ago) resets the touchpad before rebooting. I haven't had an issue since, hard reset still doesn't work.

Isn't it possible to use boot2's functions for file management?

Offline excale

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 103
  • Rating: +19/-1
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #610 on: January 24, 2013, 10:32:41 am »
You would have to load boot2 in memory, and to its specific address. I don't think Linux will like that^^.

Offline Vogtinator

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1193
  • Rating: +108/-5
  • Instruction counter
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #611 on: January 24, 2013, 10:33:38 am »
Quote
You would have to load boot2 in memory, and to its specific address. I don't think Linux will like that^^.
MMU? (Just map the right pages)

Offline excale

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 103
  • Rating: +19/-1
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #612 on: January 24, 2013, 10:36:18 am »
Well, why not then. You also have to uncompress it.
And isn't that a problem is the boot2 starts writing in interrupt register/ sets the screen buffer, ect...?

Lots of things to patch...
« Last Edit: January 24, 2013, 10:36:53 am by excale »

Offline Vogtinator

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1193
  • Rating: +108/-5
  • Instruction counter
    • View Profile
Re: Calling all Linux Kernel developers!
« Reply #613 on: January 24, 2013, 10:37:28 am »
We "just" have to find the right function pointers so we only call what we really need.

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua