I am very new to linux and I want to figure out all the task's methods/states but I couldn't find find where it is located.
I am using this site to figure out the result: http://lxr.free-electrons.com/source/
Br,
new enthusiastic linux student
figure out all the task's methods/states
What do you mean by task methods/states ?
I am using this site http://lxr.free-electrons.com/source/
Linux Cross Reference by Free Electrons is a really good website that has the entire source code of every Linux Kernel from 2.0 to the latest 4.7. Go through the code to check how the kernel is being implemented.
This was in sched.h file. Thank you for answers.
Related
I'am learning about embedded systems, and i was able to compile and setup a SAM9x35 EK with buildroot, mounting the bootstrap, the U-Boot, the Linux and The rootfs (Buildroot's basic RFS[root file system]skeleton).
I have LOTS of questions, but one of the most important is:
Pre Question Statements, for context:
I already have a provided JFFS2 with and app inside that is made of several NetBeans (c++) projects.
These projects use kernel built in (if selected in buildroot's menu) libraries
How does it work?
How the rootfs and the netbeans (makefiles) connect to linux packages?
What I mean is, How the kernel manages the makefiles from the netbeans projects?
i.e.: If i create a project that shows a picture on the screen i add some needed packages to the rootfs and then this is flashed to the device. How the kernel knows how to read and run this app? What I have read after doing this question is that Kernel start some script in init.d folder. But I would like a more Conceptual explanation of the interaction between Kernel and Rootfs
Any Explanation could help me because i dont understand how exactly works. The application is a standalone application that is loaded at the start of the linux (power on) and is only that, it runs and uses hardware to go through its different functions.
Please feel free to use links or examples.
Thank you very Much.
I am new to Linux. I want to add a system call to linux. But I don't know from where to begin.Can somebody please guide me through the whole process? From installing Linux to getting the kernel source code. I don't know where will I run or test or write the modified source code. Please help me with that also. I searched online for the linux kernel source code but it is giving me a lot of options of GIT files. What are they? How do I install them?
thank you.
Here are some good tutorials for adding system calls to kernel
http://arvindsraj.wordpress.com/2012/10/05/adding-hello-world-system-call-to-linux/
http://blog.techveda.org/adding-system-calls-linux-kernel-3-5-x/
http://www.cs.rochester.edu/~sandhya/csc256/assignments/adding-a-system-call.html
http://seshagiriprabhu.wordpress.com/2012/11/15/adding-a-simple-system-call-to-the-linux-3-2-0-kernel-from-scratch/
http://appusajeev.wordpress.com/2010/11/13/implementing-a-system-call-in-linux-kernel-2-6-35/
Check this Linux Kernel Module Programming Guide . It gives you brief information on system calls and basic tutorials demonstrating their role in Linux Kernel.
I am new to linux programming & interested to tweak linux kernel(though I am not sure, what to tweak, I am planning to write drivers for particular device). To learn internal of kernel, I have started from historic kernel release (first release).
My problem is, how to test whatever changes I am doing for development, without disturbing my current os environment.(ubuntu 12, 64 bit). Is there any way like virtual box, sandbox?
Along with these, if anybody send some good approaches to learn these things, I would be really greatful.
Thank You.
If you're new to linux programming then you really don't want to be tweaking the kernel. You really want to be an advanced programmer capable of programming drivers and complex software first.
But yes there is, you can can create a virtual machine using openbox or vmware. If you're really keen on tweaking the kernel you probably want to first just try compiling and configuring the kernel and seeing if that works.
Also make sure you're well acquainted with how the kernel works and advanced OS designs in general.
Search in google fr "Kernel configuration" you u will get many links how to configure your own kernel.
And one more thing do not use a outdated version of kernel ,always use latest stable release , because a lot of code and API is changed in new versions and no book in market is updated so ,, u have to read from kernel documentation. Thats the best way to learn the most updated information about linux kernel
Yes, you can test your changes on any of the commonly available virtual machines (VMs); that way, whatever changes you make to the VM kernel won't affect native OS.
Personally, I prefer using CentOS 64 bit on VMWare Player. With this setup, I got away with minimal system maintenance while was able to focus on the actual job at hand. Once the VM is up & running, you can download and compile one of the latest stable releases from kernel.org. Instructions on compiling your downloaded version of kernel could be found here and here; however, this may require little tweaking based on your actual setup. Once the VM is running on your desired version of kernel, using a combination of cscope and ctags will help you immensely in kernel code browsing.
Finally, if you want to become a serious kernel programmer and write your own device drivers, you need to get familiar with it in the first place. Below are a few excellent references -
Linux Device Driver by Corbet, Rubini, Kroah-Hartman, 3rd edition
Linux Kernel Development by Robert Love, 3rd edition
Understanding the Linux Kernel by Bovet, Cesati
Linux kernel source (ideally placed into your /usr/src/$(DESIRED_KERNEL) path, symlinked to /usr/src/linux)
Going through these books is a tedious job and chances are that you may hit the roadblock from time to time. kernelnewbies mailing list and StackOverflow are some of the few reliable places where people would be happy to answer to your queries.
Good luck!
We a team of 10 people are set out to build an Operating System for mobiles/tablet from scratch.
I then came by this link awesome-link
which has a load of OS briefed. But we would like to build the OS in Java on top of linux kernel(possible?) .
I would like to know whether the project is feasible and if yes, from where should I start ?
And with all the knowledge and right resources(assume), will it be possible to build an OS with all the mobile functionalities within 6 months?
Any help is much appreciated. Thanks.
But we would like to build the OS in Java on top of linux kernel(possible?)
Yes, what do you think Android is made of (of course it's not just Java + Linux kernel, but both are inside Android)?
I would like to know whether the project is feasible and if yes, from where should I start ?
Ever written an OS? How well do you know Linux kernel APIs? Do you know what's missing from Linux kernel to build a full featured OS? Answer those, they're your starting point.
And with all the knowledge and right resources(assume), will it be possible to build an OS with all the mobile functionalities within 6 months?
"All mobile functionalities" is biased, what is "all"? Be specific.
Please make enough research and planning before you are set out to start such a difficult, yet excellent journey.
Make sure you know what you should do, right from the technologies you are gonna use, the architecture you are planning to establish upon, the pros and cons of all the approach, the issues with the current OS and your idea of correcting those issues.
With a site like SO for your help, it is never a question of feasibility, but you would require the determination and the perseverance to achieve it.
Finally, all the best!!
You have Android build on scaled down Linux Kernel and apk is build through java & sdk manager. So you have the things in your hand, similarly ubuntu touch is also coming. What you can do is to customize things as per your requirements as per your architecture.
For ubuntu touch :- https://wiki.ubuntu.com/Touch/Building
For Your own customized Android:- http://source.android.com/source/index.html
Thanks & Regards,
Alok Thaker
I have ARM-based device with linux on-board. Its very difficult to flash custom kernel for some reasons (uBoot cant load kernel via tftp or something else)
I need to test my custom kernel.
So, idea is - replace kernel in memory. How do you think, is it possible?
Tell me any suggestions please.
Take a look at this link
It's for a project called Ksplice that allows one to patch a running kernel.
At one point this code was open, but Oracle bought it... So they may have closed it up and made it cost money. If that's the case, look around and see if you can find the formerly open code in the wild...