Operating System

 Concurrency And Synchronization in Linux

Let us take a quick look at a fragment of hypothetical device memory management code. Device is checking whether the memory it requires has been allocated yet or not. if (!dptr->data[s_pos]) { dptr->data[s_pos] = kmalloc(quantum, GFP_KERNEL); if (!dptr->data[s_pos]) goto out; } Suppose for a moment that two processes (we’ll call [...]

2023-10-31T23:18:11+05:30Categories: Linux|

Working with Modules in Linux

Loading Module Each module is made up of object code that can be dynamically linked to the running kernel by the insmod program and can be unlinked by the rmmod program. modprobe, like insmod, loads a module into the kernel. It differs in that it will look at the module [...]

2023-10-27T17:59:39+05:30Categories: Linux|

Debugging Process Memory Usage

Each process requires memory for the execution. But with a virtual memory operating system like Linux the answer is quite complex. The numbers given by top and ps don't really add up. You can see an individual process' memory usage by examining /proc/<pid>/status Details about memory usage are in /proc/<pid>/statm [...]

2023-08-18T17:45:10+05:30Categories: Linux|Tags: |

Install Downloaded Package on Ubuntu

A package can also be installed after downloading from internet. This post discuss about installing downloaded package on Ubuntu/Debian. In this post i will be using Beyond Compare as example. Graphical Install Download the required .deb package. Double-click the .deb package to install using the graphical package manager. Using GDebi [...]

2023-06-26T22:07:49+05:30Categories: Linux|

What does m mean in Linux Kernel Configuration File?

Linux Kernel has multiple configuration which can be enabled on the need basis. CONFIG_UNIX=m Above is an example of configuration. A configuration can one of the possible value y : Yes, it is always installed n: No, never installed m: Module, it can be installed and uninstalled as you wish

2022-11-14T18:33:40+05:30Categories: Linux|

interface_cast and asBinder Explanation

Binder in Android are used for Inter Process Communication. In Android code base, interface_cast and asBinder function are used at multiple places in context of Binder. This article tries to explain the interpretation of these API. interface_cast Let's analyze it based on the following ICameraClient example: // https://android.googlesource.com/platform/frameworks/av/+/refs/heads/master/camera/ICamera.cpp sp<ICameraClient> cameraClient [...]

2022-06-10T19:20:20+05:30Categories: Android|

Binder Native and Proxy Object in Android

Binder framework takes an object-oriented approach in its design principle and every entity that is capable of serving inter-process calls is a user-space object. In native user space the IBinder is the base class of all kinds of Binder objects i.e. proxy objects and native objects. All native Binder objects [...]

2022-06-07T18:53:22+05:30Categories: Android|Tags: |

What is Binder in Android ?

There are several techniques to achieve IPC (Inter-process communication) like files, sockets, signals, pipes, message queues, semaphores, shared memory, etc. Binder is an Android-specific IPC mechanism, which enables an RPC (remote procedure call) mechanism between the client and server processes. Client process can execute remote methods in the server process [...]

2022-03-30T19:55:33+05:30Categories: Android|Tags: |

Working With Environment Variable in Linux

Environment variables are a set of dynamic named values in Linux, used by applications launched in shell. It allow you to customize how the system works and the behavior of the applications. For example, the environment variable can store information about the default browser or the path to executable files. [...]

2022-03-29T19:11:11+05:30Categories: Linux|

Working with Directory in Linux

In this article, we will show you how to work with directory in Linux. We can create a directory using mkdir command. To delete a directory use rmdir command. Current Working Directory To find the current working directory, use pwd command as shown below. pwd What the pwd does is [...]

2022-03-10T19:30:31+05:30Categories: Linux|
Go to Top