Difference between Real time Kernel and RT Patch - linux-kernel

I want to apply the RT patch in my yocto build kernel So I searched over the internet and with results, I supposed that there are two things.
To make Real Time Kernel
To apply the RT patch in our existing kernel.
Is my assumption right? If yes, then kindly someone tell me what is difference between both. If No, then how can I apply RT Patch in my existing kernel or make my kernel real-time.
Any replies would be appreciated. Thanks in advance

Related

How does a Linux distribution affect the kernel behavior

This might be obvious for some but not to me so I'll ask =)
I'm having an issue that I have build an embedded Linux stack for some piece of hardware (NVidia TX2 + ConnectTech Astro carrier). I use a PCIe card from EPIX
If I use Ubuntu's official distribution for tegra, the PCIe card is properly detected.
With identical kernel and device tree blob, and the same HW unit, the detection fails with embedded Linux.
I thought that detecting PCIe devices would be kernel's job and not be influence by the distro, unless the drivers are built as kernel modules and inserted at different times. But in my case they are build in kernel.
Could someone elaborate why the detection would work with one distro but not the order?
Here is a link to what I tried to do to fix the detection
tx2-pcie-does-not-detect-endpoint-on-connecttech-carrier-board
Thanks!
A Linux distribution contains a kernel that usually differs from the vanilla kernel of the same release. Most of the time a distribution kernel contains lots of back ports of bug fixes that were discovered and fixed later in micro releases. There may be other features that a specific vendor includes and the vanilla kernel does not, like more recent version of certain drivers, etc. What makes this even more confusing is that sets of these back ports are often different in distributions from different vendors. As a side effect, this makes it difficult to depend on something like KERNEL_VERSION() macro in custom kernel code or in custom device drivers.
I can't say about the specific issue that you're having. The topic is pretty generic, and I hope that this explanation helps.

How to see and track kernel changes in linux related to a subsystem say I2C

Something in kernel is bugging me.
As of now the of_* support for i2c devices are somewhat not acceptable to me.
There was a probe_new* function added, but now I can't see that and I am using older probe.
The kernel that I have (4.4.127), is customised for Beaglebone black and taken from Robert C nelson github repository.
So I want to know if someone have done any improvement in I2C ,so I search and get this,
https://patchwork.kernel.org/patch/9395089/
Here I see that its done in 2016. As my kernel is newer 4.4.127 and also I have 4.9 too I know it should have that patch.
But its not there. I checked the files and the patch is not there.
So what happened? Surely in between there were changes done and its possible that this particular change was removed/modified.
I try to take the newest kernel from https://www.kernel.org/ and it have removed/added many files from drivers/i2c/
Now porting the changes to my kernel version is a daunting task as too many files/structures are changed.
So How do I get to see these changes?
How I can improve to understand linux from release to release?
How can I start to port my kernel for I2C newest changes?
I think its a broad question, but any kernel expert can tell me what should I have done or look in particular places to gain such understanding.
https://marc.info/?l=linux-i2c
Here I can see all changes done in I2C subsystem.

Linux on Dragonboard APQ8074

I have a DragonBoard APQ8074 with SnapDragon 800. I am able to successfully build Android and run some OpenCL related apps on this.
I am currently trying to build a linux kernel and load either Ubuntu or Fedora on this board.
It wouldbe really helpful if anyone could point me to suitable posts or guides.
I did look into Freedreno, it is really a good starting point, but i am still unable to understand the part of initrd/ramdisk img file.
Also the bootloader (similar to u-boot i assume), i am not clear which parts of it i need to update, if at all necessary.
Thanks in advance.
regard,
Anup.
This might help http://whiteboard.ping.se/Android/Android. There's a few sections there that might be handy. I also found this other article that helped me understand intrd and intramfs a bit better if that helps. http://www.linux.com/learn/linux-career-center/114923-the-kernel-newbie-corner-qinitrdq-and-qinitramfsq-some-unfinished-business

Customizing linux kernel for new board

I'm porting/customizing linux kernel for our board. I will base on atmel evolution board configuration, and I need to overwrite some startup routines and add our drivers.
Is there any document, link, forum where I can get information how to make it in Linux way ?
Which files can I overwrite, and which shall I create from scratch ?
Is this a Board Support Package question ?
Thank you
I doubt that there is short and simple answer to your question. To accomplish this task you should more or less good understand Linux as distribution (kernel + boot scripts + user space software) work together and how make them be a friends.
I could recommend you book, which I found extremely useful as embedded Linux engineer: Embedded Linux Primer: A Practical Real-World Approach (2nd Edition) I am quite confident it will answer most of your questions.
I think that's it. Short, nice, fresh:
http://free-electrons.com/blog/elce-2012-slides-porting-linux-to-new-arm-soc/

linux kernel ota framework?

Before designing my own Linux OTA stack, I'd better probe if anybody knows of an existing Linux OTA stack/framework that I could make use of/contribute to.
What I mean by Linux OTA stack/framework is a service capable of updating the Linux kernel on my device from a remote repository. Basically something like the OTA update feature found on most Linux smartphones today. It must be 99.99% fail-safe such that my devices (which will be mounted in 500 cars for 6-12 months) will not turn into useless bricks that require on-site service to become working again.
An open source solution is not a must - commercial solutions that do the job has equal interest.
Thanks in Advance.
Christian
Could you just use the APT, combined with suitable kernel packages?
Doing the actual update is pretty trivial, you can use any of the existing package management frameworks to provide a new kernel package that the system upgrades to when available.
The hard part is when your device reboots into the new kernel you need some way to detect if it doesn't boot, and boot it back into the old kernel. To do that without human intervention you'll need some sort of watchdog facility in your hardware.

Resources