Porting RISC OS to Linux
Pages: 1 2
Simon Willcocks (1499) 522 posts |
unix_ or ix_, as prefixes? I’d be interested in your eventual goal, as well. |
Rick Murray (539) 13851 posts |
…err…that’s not how the allocations system works. You should contact the allocate@ address to request a SWI chunk. You will then be informed of what chunk has been allocated to you. Given the ROOL guys read this, you may get a nod to claiming &C0000 if it has not already been claimed but then again you might get the next allocation off the pile, because it is irregular to say that you want specific SWIs. More details at https://www.riscosopen.org/content/allocate |
Jan Rinze (235) 368 posts |
@Timothy |
Jan Rinze (235) 368 posts |
@Timothy: interestingly both the XScale and the Cortex A15 will print: The Xscale will loop this but the A15 stops after this. |
Jan Rinze (235) 368 posts |
the arthur module (PER_RISCOS) is not enabled when compiling for EABI. did you compile in OABI? I could just enable it in EABI though (will try anyway.) |
Jan Rinze (235) 368 posts |
Using kernel 2.6.33.1 on my XScale laptop with PER_RISCOS enabled in EABI yields one empty line printed. |
Jan Rinze (235) 368 posts |
The arthur module will pass on all SWI’s except for SWI 0. |
Steve Pampling (1551) 8172 posts |
Since it all appears to be based on source from the ROOL repository it all has to be fed back to Castle under the terms of the licence. “derivative work” is the operative bit. NB. GPL does not and cannot override the open, but commercial, nature of licence of the original code. |
Jan Rinze (235) 368 posts |
For testing purposes 0×0C0000 seems right then. OABI an EABI not only differ in SWI base number, they also differ in the calling standard. So remapping to 0×900000 won’t be correct and possibly breaks things. @David: this is like running RPCemu on Linux with code running directly on the CPU. In fact I plan to use this to get RPCemu on ARM linux with decent performance. Currently RPCemu runs at 30 MIPS on a 1.7 GHz ARM.. This also might provide a route to enable RISC OS on more ARM platforms. a HAL that can delegate work to a Linux kernel will alleviate the burden of porting to newer hardware. Next to that it won’t violate GPL since using Linux syscalls from RISC OS is no different from running closed source software on Linux. Even if we would create a special Linux module to handle special activities, that would not cause any problems. |
Colin (478) 2433 posts |
Dreaded licences again heres my 2p
No it doesn’t there can be as many forks as you like. Castle have the right to use any of the changes they find but don’t have to be informed at all or use any changes. |
Colin (478) 2433 posts |
GPL can’t be used with the Castle code either |
Jan Rinze (235) 368 posts |
there are many other threads discussing license details. this thread is looking into cooperation between RISC OS and Linux… |
Colin (478) 2433 posts |
Ok last word. There can be no ‘cooperation’ between riscos and linux. If I was ROOL I would have nothing to do with any code produced as it would be debatable if it was legal as it would for you to distribute it. You could have ported to NetBSD without the legal problems. Just trying to save the effort of coding something you can never distribute. |
Jeffrey Lee (213) 6048 posts |
Hence my questions to Timothy about whether this is a passing fancy or something more significant. If we’re aiming for a proper solution for running RISC OS on Linux then we should probably be focusing on using a modified Linux kernel instead of a stock one – so that things like SWIs, PSR manipulation, etc. will just work instead of having to heavily modify RISC OS and its programs in order to fit with how Linux expects things. Otherwise you could end up with heavy resistance from developers and users – developers won’t want to spend ages patching and fixing their code (and may be opposed to the idea entirely), and users won’t want to use the system because all of their old apps won’t work. |
Jan Rinze (235) 368 posts |
@Jeffrey: to get somewhere we first need to experiment and learn. |
Rick Murray (539) 13851 posts |
My 2p – I’m not sure about the idea of running RISC OS on top of a Linux kernel. Where does Linux stop and RISC OS begin? As a project it is very interesting, however it seems to me that a lot of things you can do with the OS stand to be diminished with the use of Linux underneath, primarily for fear of mucking up the environment that the host expects. ’tis a shame nobody is looking at faking a Linux environment under RISC OS – it would be nice to look to having dsp codecs and such that come as standard for Linux… Above all, don’t let us put you off; it is an interesting concept and one worth following to see where it takes you. |
Rick Murray (539) 13851 posts |
Interesting quirk. Quote: “If any part of any Derivative Work distributed by You can reasonably be considered an independent and separate work then this Licence shall not apply to any such part where You distribute such part as an independent and separate work;”.
Boolean logic fail. Quote: “by including a copy of the source code with Your distribution and/or by uploading the source code to the official RISC OS source code repository at […]” – in either case, derivative work that you distribute1 is supposed to be uploaded to the repo. One could consider this an implicit notification of changes. And here is the one for the GPL crowd: “2.3 If, […] or any other reason You are unable to comply fully with the terms and conditions of this Licence then You shall refrain from distributing RISC OS or such Derivative Works (as appropriate) for the duration of such non-compliance.”. The modifications to the RISC OS code base are covered under the Castle licence. Modifications to any version of the Linux kernel are covered under GPLv2. They cannot clash, and more importantly, one cannot supplant the other. 1 The implication here being that you can do what you want with code that is never intended to be distributed: gleefully mix Castle and GPL code, set all the copyright messages to say “Cookie Monster” and throw darts at a printed photo of RMS… whatever… problem is… code that is never intended to be distributed… kind of a waste of time, don’t’cha think? |
Chris Evans (457) 1614 posts |
Comment Deleted as thread I now see is in Aldershot and has moved on! |
Jan Rinze (235) 368 posts |
Just a bit of info on the Arthur module. Long ago Philip Blundell was working on a method to run RISC OS binaries on Linux. This ran on the Risc PC and my Netwinder. I have helped to get it working and we worked on riscose at that time called ‘rose’. The Arthur module was conceived to allow SWI calls to be trapped and a switch from 32 to 26 bit mode. This kernel module still exists today. With a patch the module will use the standard Linux personality settings and userspace will need to catch the SIGILL signal. That signal handler will receive info on the processor state at the point of the SWI. In general it is not more than a plug to redirect software interrupts back to the user program. What this means for RISC OS emulation, now 32 bit code is available, we can run 32 bit code that uses non-Linux SWI calls. Using the SIGILL signal handler to perform the requested SWI and return to the 32 bit code. Trapping signals is a standard feature of Linux. Arthur makes it a bit easier to use that mechanism when working with binary ARM code that uses SWIs in the way that RISC OS does. |
Pages: 1 2