Add NAND device to QEMU Stellaris - arm

I need to test NAND FTL on QEMU. My NAND controller(Tc6393xb) which is already emulated on QEMU has to be interfaced with ARM Cortex-M3. So I chose stellaris as my base machine. can somebody help me with information on adding this controller(Tc6393xb.c in QEMU 1.2.0) to stellaris. Secondly how do I test it on non-OS environment.

In Qemu version 2.2.1, there is a device (PXA255 Sharp Zaurus) that instantiates the controller Tc6393xb: tc6393xb_init function.

Related

MATLAB interface with QEMU

I'm trying to develop a custom machine in QEMU and kind of successful in doing so. Now I want to build a module that can communicate with QEMU to provide some inputs to QEMU and interact with it.
I have chosen MATLAB to build a model that interfaces with my custom machine in QEMU. I know MATLAB has Embedded coder interface and QEMU add on that runs QEMU as third party software internally(downloads the QEMU itself).
But since I have customized QEMU for my machine, how do I interface MATLAB with custom QEMU?
I thought it would be something like running QEMU as
qemu-system-arm -machine x -s -S -kernel x.elf so that when I run QEMU with -s it listens on a port and communicate with other modules. Is this possible with MATLAB? Or is there any other way?

What is a structure of u-boot flash file? ( ARM versatile pb )

I'm working on creating file that I can load with -kernel option of qemu. I mostly mind here u-boot config file that I have found information should be placed somewhere in file. That file have to contain u-boot binary, freebsd kernel and RTOS to run ( so i can choose which kernel to load or do some experimental developement in loading 2 OS at same time - eg. FreeBSD is loaded by u-boot and then FreeBSD loads FreeRTOS on 2nd core - so called ASMP ). It seems there is no tools around to do that in automatic way ( I mean supporting multiple kernels in one flash file ). So I need to know how is u-boot flash file structured to make my own and pass it to qemu emulating am versatilepb.
qemu-system-arm -M versatilepb -m 128M -nographic -kernel myflashfile
So the answer here depends in part on the board you are emulating with QEMU. Next, unfortunately the versatilepb has been dropped from mainline U-Boot some time ago (and being ARM926EJS it is not the ideal core for ASMP, you may wish to try vexpress a9 instead). Now, all of that said, you want -pflash to pass along a binary file you control the contents of as the parallel flash device used by the machine. And you lay that out however you like since you're still using -kernel u-boot.bin to boot the machine. You may however find it easier to use -tftp /some/dir and load the files via the network instead.

Embedded Linux Porting On ARM-Cortex-A8(beagle board)

I am porting Embedded linux os on Beagle Board with ARM-Cortex A8 processor.
I wanted to add the functionality of insmod and rmmod and my driver as well in os.
Please help me in doing this, so that my driver can work over my board properly.
Thank you
Himanshi
You will Have to include Your drivers with the Image BUILD insmod and rmmod will not keep your driver there after a reboot inserting your drivers every boot sure is inappropriate

Issue with opencl on linux

I have a desktop with a linux and a nvidia gforce 5200. The graphics card does not support opencl programming. Hence, I installed AMD APP SDK v.2 to program opencl on the CPU.
However, when I execute after compilation I get the following:
FATAL: Module fglrx not found.
fgrlx is the module of kernel for the ATI proprietary driver. Why is this module required?
Fglrx is a proprietary, Linux binary-only driver for ATI graphic chips with support for 3D acceleration. You can read about it here
For installing AMD App SDK the following system requirements needs to be satisfied
http://developer.amd.com/tools/heterogeneous-computing/amd-accelerated-parallel-processing-app-sdk/system-requirements-driver-compatibility/
Basically an AMD CPU as the bare minimum.
Basically you need to install ATI drivers. Here is a tutorial which talk about the procedure
For RPM based linux (like Fedora)
http://gofedora.com/how-to-install-ati-catalyst-fglrx-98-drivers-fedora-11/comment-page-1/
For Debian based Linux (like Ubuntu)
https://help.ubuntu.com/community/BinaryDriverHowto/
A blog talks about how to install AMD App SDK
http://blog.markloiseau.com/2012/05/install-opencl-sdk-ubuntu/

How to add new QEMU machine types without modifying the mainline source code?

Can a new machine type be added for qemu-system-arm -M <MachineType> without having to recompile qemu or write code? Are there docs to do this? I would like to be able to emulate raspberry pi and pandaboard using qemu.
I know that meego's fork of qemu supports pandaboard, but I am trying to stick with the main stream qemu that I can manage from the apt-get package manager. the main stream qemu now supports beagleboard rev C and beagleboard xm that were previously supported only in the meego fork.
without having to recompile qemu or write code?
No. There must be some code doing the device specific emulation, like for example the way the Raspberry Pi or the Pandaboard implement video output. This is not a matter of just a few config files.
I've been able to emulate the Pi with -M versatilepb: https://raspberrypi.stackexchange.com/questions/165/emulation-on-a-linux-pc/53991#53991 and -M raspi2 has was later added in QEMU 2.6.
Maybe this feature is feasible to implement, see my experience with adding a new platform device: How to add a new device in QEMU source code?
There, I only needed to add a single line to attach a new device to versatilepb:
sysbus_create_simple("lkmc_platform_device", 0x101e9000, pic[18]);
so maybe we could have a config file containing lines of type:
type name regid irq
sysbus lkmc_platform_device 0x101e9000 18
Related: out-of-tree devices: How to create out-of-tree QEMU devices?

Resources