Re: unlikely compiler flag propagation

2015-02-18 Thread Matthias Brugger
Hi Greg, hi all, 2015-02-18 19:24 GMT+01:00 Greg KH : > On Wed, Feb 18, 2015 at 07:09:47PM +0100, Matthias Brugger wrote: >> Hi all, >> >> I have a question about the unlikely compiler flag. >> When a called function is only returns an error with the unlikely fl

unlikely compiler flag propagation

2015-02-18 Thread Matthias Brugger
Hi all, I have a question about the unlikely compiler flag. When a called function is only returns an error with the unlikely flag set, should I set the unlikely compiler flag for the return value check in the callee as well? For example: int function_one(int *list, int num_elements) { int i

Re: x86_64_defconfig and i386_defconfig: What is the difference?

2014-09-09 Thread Matthias Brugger
On 09/09/14 09:58, Rajat Jain wrote: > Hi, > > Can someone tell me if the i386 one is to be used when we want to build for a > 32bit machine and the x86_64 is to be used for 64 bit machine? You can build the kernel with any architecture for any architecture. This is called cross-compiling. The

Kconfig set default macro bug?

2014-04-09 Thread Matthias Brugger
Hi all, I'm just playing with the early printk macros of the low level printk. The address of the UART port is set to a default value [1]. So if you save the config and then enter again in menuconfig, you are not able to change the value to a different default value (I suppose because Kconfig see

Re: DTS: clock not found

2014-02-07 Thread Matthias Brugger
Hi Javier, 2014-02-06 Javier Martinez Canillas : > Hello Matthias, > > On Wed, Feb 5, 2014 at 6:02 PM, Matthias Brugger > wrote: >> Hi, >> >> I'm stuck with dts problem. Whenever I try to find a clock for my >> device, the of_get_clk returns an error

DTS: clock not found

2014-02-05 Thread Matthias Brugger
Hi, I'm stuck with dts problem. Whenever I try to find a clock for my device, the of_get_clk returns an error "Kernel panic - not syncing: Can't get timer clock" My DTS looks like this (reduced to relevant parts for easier reading): #include #include #include "skeleton.dtsi" / { [...] s

Re: ARM Linux and ATAGS

2014-01-12 Thread Matthias Brugger
El dia 09/01/2014 8:48, "Mj Embd" va escriure: > > Hi, > > What are atags and are they still used after addition of device tree in linux ? Afaik atags is the mechanism how the kernel gets the boot parameter from the bootloader. In the kernel config you can decide if you will use the boot paramete

Re: Introducing Myself, Looking to Learn

2013-10-28 Thread Matthias Brugger
2013/9/3 Robert P. J. Day : > On Tue, 3 Sep 2013, valdis.kletni...@vt.edu wrote: > >> On Wed, 04 Sep 2013 02:05:42 +0530, Varad Gautam said: >> > Hi Vladis! Thanks for replying. I think I would be fine with >> > writing real code once I figure out what goes where. >> >> Well, assuming you have a ba

First userspace executalbe run at boot up

2013-08-27 Thread Matthias Brugger
Hi all, I'm actually reading the init/main.c source code to understand which is the first user space program the Linux kernel runs. As far as I understood it: 1. tries to execute the file defined by the rdinit= kernel parameter and sets it to "/init" if the parameter is not given 2. tries to exec

Re: pulling in patches mentioned in mails (linux-ker...@vger.kernel.org)

2013-08-04 Thread Matthias Brugger
El 25/07/2013 5:14, "kernel neophyte" va escriure: > > Hi, > > I am sorry if this has been asked before, I tried to look around but did not get an solution and hence the mail. > > In this mail from Mel Gorman: > > https://lkml.org/lkml/2013/7/15/362 > > He mentions a set of patches: > > https://lk

Re: Memory leaks in Samsung's kernel

2013-05-30 Thread Matthias Brugger
El 28/05/2013 19:16, "Michał Akaanonim" va escriure: > > Hi, > I'm developing custom kernel for my Samsung Galaxy Ace 2 phone. > First, I'd like to check if there are any bugs, so I built kernel with kmemleak enabled and I get 10 entries, for example: > > unreferenced object 0xce2a2000 (size 8192)

Re: how do i read a block

2013-05-13 Thread Matthias Brugger
El 13/05/2013 10:07, "shampavman" va escriure: > > Hi all, > > Supposing i create a file of size 10K, it will occupy 2 blocks (4K each). > Now if i want to read only 1 block from it how can i do it? > > read(fd, buf, 4096) ; > would this mean i would read the first block and all its contents? You

Re: [help] kernel oops in function gpio_to_irq

2013-03-30 Thread Matthias Brugger
El 27/03/2013 18:16, "Mylene Josserand" va escriure: > > Hi everyone, > > > I have a problem with gpio functions. > My kernel version is 3.8.2 and my SoC is a imX27 on a "home-made" board. > > First, when I boot, I had only the "Starting kernel..." message. > So I rebuild my kernel with CONFIG_DEB

Re: BFQ: simple elevator

2013-03-25 Thread Matthias Brugger
2013/3/25 Raymond Jennings : > On Sat, Mar 23, 2013 at 9:42 AM, Matthias Brugger > wrote: >> On 03/23/2013 01:05 AM, Raymond Jennings wrote: >> >> On Fri, Mar 22, 2013 at 2:20 PM, wrote: >> >> On Fri, 22 Mar 2013 13:53:45 -0700, Raymond Jennings said: >&

Re: BFQ: simple elevator

2013-03-23 Thread Matthias Brugger
On 03/23/2013 01:05 AM, Raymond Jennings wrote: On Fri, Mar 22, 2013 at 2:20 PM, wrote: On Fri, 22 Mar 2013 13:53:45 -0700, Raymond Jennings said: The first heap would be synchronous requests such as reads and syncs that someone in userspace is blocking on. The second is background I/O l

Re: BFQ: simple elevator

2013-03-23 Thread Matthias Brugger
On 03/20/2013 10:41 PM, Raymond Jennings wrote: > On Wed, Mar 20, 2013 at 2:03 PM, wrote: >> On Thu, 21 Mar 2013 02:24:23 +0700, Mulyadi Santosa said: >> >>> pardon me for any possible sillyness, but what happen if there are >>> incoming I/O operation at very nearby sectors (or perhaps at the sam

Re: Android Kernel Compilation

2013-01-31 Thread Matthias Brugger
2013/1/30 Rahul Gandhi : > I am trying to compile Kernel for my Android device. I am using the NDK > Toolchain (arm-linux-androideabi-4.4.3). When I use the defconfig, the > kernel compiles without any errors but when I flash it onto my device, it > either gets stuck on the HTC logo or continuously

Re: guides to board files -> device-tree and Android -> mainline?

2013-01-26 Thread Matthias Brugger
Hi Paul, 2013/1/26 Paul Wise : > Hi all, > > Are there any guides for developers new to Linux for: > > * converting board files to device-tree > * porting drivers and patches from Android to current mainline? there are several parts of Android, which are not part of the mainline kerne

Re: can I input a gate service to kernel to get kernel data to user ?

2012-12-14 Thread Matthias Brugger
Hi, On 12/14/2012 01:53 AM, horse_rivers wrote: > At 2012-12-13 18:52:53,"Matthias Brugger" wrote: >> On 12/13/2012 04:17 AM, horse_rivers wrote: >>> is there method for doing this work? take kernel data to user? >> >> I think copy_to_user is what

Re: can I input a gate service to kernel to get kernel data to user ?

2012-12-13 Thread Matthias Brugger
On 12/13/2012 04:17 AM, horse_rivers wrote: > is there method for doing this work? take kernel data to user? I think copy_to_user is what you are looking for: http://lxr.free-electrons.com/source/include/asm-generic/uaccess.h#L253 Cheers, Matthias > > > thanks! > > __

Re: Find out function arguments value from stack pointer

2012-12-12 Thread Matthias Brugger
On 12/12/2012 12:24 PM, Manavendra Nath Manav wrote: > On Wed, Dec 12, 2012 at 4:38 PM, Fabio Pozzi wrote: >>> When i call print values at offsets starting from >>> __builtin_frame_address (0) the function arguments start from offset >>> 2. How can I confirm that this behavior is always consisten

Re: Best and fastest way to understand kernel subsystem ?

2012-12-06 Thread Matthias Brugger
On 12/06/2012 10:54 AM, Shraddha Kamat wrote: > What is the best (and the fastest ) way to understand a kernel > subsystem ( for e.g., filesystem , Networking .. etc.) If you are a beginner it might be convenient to look on a small subsystem first. The filesystem is really big and complicated, I

system call numbers

2012-11-22 Thread Matthias Brugger
Hi all, I'm looking into the avr32 architecture implementation, as compiling the kernel gives you several warnings about system calls which are missing. I had a look in the unistd.h file I realized that system call numbers differ widely from other architectures (I had a look at arm and x86). Ar

Re:

2012-10-15 Thread Matthias Brugger
Hi, On 10/15/2012 11:24 AM, Niroj Pokhrel wrote: > Hi, > I'm new to linux and kernel . I'm ongoing with the linux device drivers. > I've followed the the book LDD but i'm lost about how to call my > driver's specific method from the user space. > Eg: if have developed a character device and insert

Re: Writing a new device driver

2012-06-26 Thread Matthias Brugger
Hi Malice, On 06/25/2012 09:42 PM, Malice wrote: > Hi > > I'm planning to write a new device driver on linux kernel . The device i > intend to write will be a device that'll pipe the data coming into it to > another computer that'll be also having the same device . So in short > the device'll be r

Re: Missing Key-codes from input.h file.

2012-06-26 Thread Matthias Brugger
On 06/26/2012 08:47 AM, Dharam Kumar wrote: > On Tue, Jun 26, 2012 at 12:02 PM, anish kumar > wrote: >> On Mon, 2012-06-25 at 23:24 +0530, Dharam Kumar wrote: >>> On Mon, Jun 25, 2012 at 10:47 PM, anish kumar >>> wrote: On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote: > Hi, > I

Re: Kernel 3.4 compile problem

2012-06-19 Thread Matthias Brugger
On 06/19/2012 02:43 PM, Kaan Akşit wrote: > Lieber Matthias, > > Vielen dank für ihre email :) Here is the English version of the output: > >DEPMOD 3.4.3 > DEBUG: return value for "make > INSTALL_MOD_PATH=/var/pisi/kernel-3.4.3-163/install/ DEPMOD=/bin/true > modules_install mod-fw=" is 0 > ..

Re: Kernel 3.4 compile problem

2012-06-19 Thread Matthias Brugger
Merhaba, On 06/19/2012 01:11 PM, Kaan Akşit wrote: > Dear all, > > I am a newbie who try to solve a problem on compiling new kernel on my > computer. Here is the point where I am stuck; I can configure and > compile kernel without any error, but whenever I try to install libc > headers I keep rece

Re: A confusion about invoking my syscall

2012-06-19 Thread Matthias Brugger
On 06/19/2012 06:32 AM, 王哲 wrote: > > > 2012/6/19 Jeff Haran mailto:jha...@bytemobile.com>> > > __ __ > > __ __ > > *From:*kernelnewbies-boun...@kernelnewbies.org > > [mailto:kernelnewbies-boun...@kernelnewbies.org >

Re: no-op error in dmesg

2012-06-19 Thread Matthias Brugger
Hi, On 06/18/2012 08:34 PM, Pritam Bankar wrote: > Hi, > I have one structure called foo. Address of object of foo(say objfoo) is > passed to ioctl call > > status = ioctl(fd, arg, &objfoo); as objfoo is a pointer to foo: struct something foo; struct somethint *objfoo = &foo; &objfoo therefore i

Re: cross compile linux

2012-02-11 Thread Matthias Brugger
On 02/11/2012 10:15 AM, Daniel Baluta wrote: > On Sat, Feb 11, 2012 at 9:05 AM, chromaticwt zac > wrote: >> what is the proper way to cross compile the linux kernel from one arch to >> another? specifically, >> i386 -> ppc. > > You should use a cross-compiler. I recommend you crosstool-ng. > Use

Re: blktrace vs ftrace

2012-02-08 Thread Matthias Brugger
Hi, On 02/03/2012 06:59 AM, Mulyadi Santosa wrote: > > I could only offer this explanation: > blktrace traces events in block level. In this level, I/O is likely > serializedunless you have more than one physical disks. > > in ftrace, you see events right before it hits block level operation.

Re: Changes in block layer for IOScheduler Insertion selection

2012-02-06 Thread Matthias Brugger
hmark. For flash file systems, David Wagner from Free Electrons developed a benchmarksuite. Maybe it would be worse having a look on it. Best regards, Matthias Brugger Thanks in advance.. On Mon, May 30, 2011 at 10:53 AM, mani <mailto:manish...@gmail.com>> wrote: Dear Eduardo

Re: blktrace vs ftrace

2012-02-02 Thread Matthias Brugger
On 02/02/2012 07:15 PM, Mulyadi Santosa wrote: > On Thu, Feb 2, 2012 at 17:20, Matthias Brugger > wrote: >> Hi all, >> >> I'm trying to analize I/O behavior of Qemu on the host. > > what is your complete command to invoke Qemu? qemu -hda scheduler.raw -dri

Re: creation of blktrace completion messages

2012-02-02 Thread Matthias Brugger
On 01/18/2012 02:59 PM, Matthias Brugger wrote: > Hi all, > > where does the kernel create the blktrace completion messages? the mesage is created in block/blk-core.c:blk_update_request which calls trace_block_rq_complete > > Is it done in the interrupt routine or in the block la

blktrace vs ftrace

2012-02-02 Thread Matthias Brugger
Hi all, I'm trying to analize I/O behavior of Qemu on the host. I used blktrace and the blk tracer for ftrace but I see different I/O behavior. I use 4 threads in the VM each reading sequentially a file. Readahead is turned off. With blktrace reads are transmitted in a sequential way, which me

creation of blktrace completion messages

2012-01-18 Thread Matthias Brugger
Hi all, where does the kernel create the blktrace completion messages? Is it done in the interrupt routine or in the block layer. I just found: register_trace_block_rq_complete(blk_add_trace_rq_complete, NULL); and register_trace_block_bio_complete(blk_add_trace_bio_complete, NULL); But I don't

Re: Guidance on writing device drivers

2011-11-18 Thread Matthias Brugger
On 11/10/2011 05:26 AM, Prajosh Premdas wrote: > [...] > On Thu, Nov 10, 2011 at 10:08 AM, rohan puri > wrote: > On Wed, Nov 9, 2011 at 10:40 PM, suraj khurana > mailto:surajkhuran...@gmail.com>> wrote: > > Hi all, > I am a newbie in linux wor

Re: Create a one-to-many tunnel

2011-03-15 Thread Matthias Brugger
Vimal schrieb: > Hi, > > I wish to create an IP in IP tunnel interface that works as follows: > > At the sender: > * The interface checks the dst IP address on the IP packet that it receives. > * It encapsulates the IP packet inside another IP packet with: >Field 1: source address = the inter

Re: Regarding Linux device driver Project

2011-01-23 Thread Matthias Brugger
Hi, ashutosh mishra schrieb: >> hi >> i want to write a driver for DIO-48S PCI Card >> (its automation Project - Aluminium Foil Winding Automated System Using PCI >> Interface) >> i want to ask that what are the..prerequesite...for the Project... >> i hav konwledge of C,89c51 Microcontroller,Arm