Re: where are sample codes of LDD 3 book

2010-11-23 Thread luca ellero
On 23/11/2010 11.38, Carlo Caione wrote: On 23/11/2010 11:24, Bond wrote: Hi,can any one give a link to ftp site where I can get the sample codes of LDD 3rd edition book. A chapter of Block Device Driver talks about it and says that such codes exist online. I want a link to that. C'mon, it's

Re: system call address

2010-10-07 Thread luca ellero
Il 06/10/2010 18.50, Usman S. Ansari wrote: --- On Wed, 10/6/10, luca ellerolro...@gmail.com wrote: I have seen kernel symbols (talking in general, not sys_call_table), appear in /proc/kallsyms in some version of kernel and not in others. Symbol definition is same in both kernel revs. What

Re: system call address

2010-10-05 Thread luca ellero
Il 05/10/2010 1.53, Usman S. Ansari wrote: Not any more, sys_call_table is not exported any more in recent kernel (at least 2.6) I have seen kernel symbols (talking in general, not sys_call_table), appear in /proc/kallsyms in some version of kernel and not in others. Symbol definition is

Re: system call address

2010-10-04 Thread luca ellero
;-) Regards Luca Ellero -- To unsubscribe from this list: send an email with unsubscribe kernelnewbies to ecar...@nl.linux.org Please read the FAQ at http://kernelnewbies.org/FAQ

alloc_bootmem_low

2010-10-01 Thread luca ellero
this kind of code anywhere. Any hints? NOTE: I know that from kernel 2.6.34 there is a lot of work in progress to eliminate bootmem code and substitute it with early_res but suppose for the moment that we didn't specify the config option NO_BOOTMEM. Regards Luca Ellero -- To unsubscribe from

Re: memory consumed by kernel

2010-10-01 Thread luca ellero
Il 01/10/2010 9.51, Arun KS wrote: Hello, kmalloc() memory is reserved or not? No, kmalloc memory is not reserved. The buddy allocator, which is eventually used by kmalloc, use only pages NOT reserved and don't mark the pages reserved when these are allocated. In other words reserved bit is

Re: Regarding GDT

2010-09-30 Thread luca ellero
Hi, Il 29/09/2010 19.28, Sri Ram Vemulpali wrote: Hi All, I have a doubt regarding implementation of segmentation in OS. Since GDT is used to implement the segmentation, in that table you add all segments descriptors dividing the linear address space. In a flat model you

alloc_bootmem_low

2010-09-30 Thread luca ellero
in progress to eliminate bootmem code and substitute it with early_res but suppose for the moment that we didn't specify the config option NO_BOOTMEM. Regards Luca Ellero -- To unsubscribe from this list: send an email with unsubscribe kernelnewbies to ecar...@nl.linux.org Please read the FAQ at http

Re: memory consumed by kernel

2010-09-23 Thread luca ellero
Il 23/09/2010 15.49, Mulyadi Santosa ha scritto: Hi... On Thu, Sep 23, 2010 at 16:13, Tayade, Nilesh nilesh.tay...@netscout.com wrote: -Original Message- From: kernelnewbies-bou...@nl.linux.org [mailto:kernelnewbies- bou...@nl.linux.org] On Behalf Of Arun KS Sent: Thursday, September

Re: spin locks in uniprocessor system

2010-09-15 Thread luca ellero
but still disable IRQs regards Luca Ellero -- To unsubscribe from this list: send an email with unsubscribe kernelnewbies to ecar...@nl.linux.org Please read the FAQ at http://kernelnewbies.org/FAQ

Re: Get UTC from RDTSC

2010-07-16 Thread luca ellero
Mulyadi Santosa ha scritto: Hi On Thu, Jul 15, 2010 at 23:42, Radhesh Kamath rmk.l...@gmail.com wrote: Hi list, Apologies if this is not purely a kernel-related question: I have a kernel module that sends me an RDTSC value to userspace, and I need to get a UTC timestamp based on this. As

Re: I/O and memory barriers

2010-06-08 Thread luca ellero
Pei Lin ha scritto: 2010/6/7 luca ellero lro...@gmail.com: Thanks again for your replay, anyway I'm still confused. See inline comments. Pei Lin wrote: 2010/5/31 luca ellero lro...@gmail.com: Pei Lin wrote: 2010/5/17 luca ellero lro...@gmail.com: Hi

Re: I/O and memory barriers

2010-06-07 Thread luca ellero
Thanks again for your replay, anyway I'm still confused. See inline comments. Pei Lin wrote: 2010/5/31 luca ellero lro...@gmail.com: Pei Lin wrote: 2010/5/17 luca ellero lro...@gmail.com: Hi list, I have some (maybe stupid) questions which I can't answer even after reading

Re: I/O and memory barriers

2010-06-01 Thread luca ellero
Pei Lin wrote: 2010/5/17 luca ellero lro...@gmail.com: Hi list, I have some (maybe stupid) questions which I can't answer even after reading lots of documentation. Suppose I have a PCI device which has some I/O registers mapped to memory (here I mean access are made through memory, not I/O

Re: Using the same serial port for both serial console and kgdb debugging

2010-05-31 Thread luca ellero
to use Ctrl-C remotely you must apply the patch ) On the develop machine: - stty speed 115200 /dev/ttyS0 - gdb vmlinux target remote /dev/ttyS0 you can now use gdb commands: r,c, ... regards Luca Ellero diff -Nur linux-2.6.31.4.original/drivers/char/tty_io.c linux-2.6.31.4

[Fwd: Re: I/O and memory barriers]

2010-05-25 Thread luca ellero
Hi list, I had no response here, so I made some research. If someone is interested, here I reply to myself ;-) It was especially useful reading Intel manual: The Intel Architecture Software Developer Manual (Vol3) - System Programming Guide See inline comments. luca ellero wrote: Hi list, I

I/O and memory barriers

2010-05-17 Thread luca ellero
Hi list, I have some (maybe stupid) questions which I can't answer even after reading lots of documentation. Suppose I have a PCI device which has some I/O registers mapped to memory (here I mean access are made through memory, not I/O space). As far as I know the right way to access them is

Re: sysrq problem

2010-02-23 Thread luca ellero
Hi, nidhi mittal hada wrote: Hi All I want to use magic sysrq key functioning I have enabled in /etc/sysctl.conf kernel.sysrq = 1 but when i press alt + sysrq it asks me to take a screenshot on my Logitech keyboard i have prntscreen / sysrq on same key and i dont have any fn key on it How

Re: automatic driver loading functionality in Linux

2010-01-27 Thread luca ellero
Ozan Türkyılmaz wrote: 26.01.2010 17:42, Greg KH yazmış: On Sun, Jan 24, 2010 at 10:49:24AM +0530, Joel Fernandes wrote: Hi Peter, Thanks for your message. Actually I'm interested in how modprobe autoloads modules based on the modalias files in sysfs. I read this in Greg KH's great book -

Re: Blacklisting in-kernel drivers

2010-01-25 Thread luca ellero
, luca ellero lro...@gmail.com wrote: Greg KH ha scritto: On Wed, Jan 20, 2010 at 01:54:08PM +0100, luca ellero wrote: Hi everybody, I'm writing a driver that use a USB mouse as a minimal keyboard (binding mouse buttons to some useful keys: Enter, Tab, ESC or others

Re: Blacklisting in-kernel drivers

2010-01-23 Thread luca ellero
Greg KH ha scritto: On Wed, Jan 20, 2010 at 01:54:08PM +0100, luca ellero wrote: Hi everybody, I'm writing a driver that use a USB mouse as a minimal keyboard (binding mouse buttons to some useful keys: Enter, Tab, ESC or others). The problem is the USB mouse driver (integrated

Re: Blacklisting in-kernel drivers

2010-01-21 Thread luca ellero
() again to take control of the mouse. From thereon, the program can go into a polling loop to accept all input from the USB devices via libusb_interrupt_transfer() etcAPIs. Not sure if u have the same situation? Thanks. On Wed, Jan 20, 2010 at 8:54 PM, luca ellero lro...@gmail.com wrote

Blacklisting in-kernel drivers

2010-01-20 Thread luca ellero
Hi everybody, I'm writing a driver that use a USB mouse as a minimal keyboard (binding mouse buttons to some useful keys: Enter, Tab, ESC or others). The problem is the USB mouse driver (integrated into the kernel) takes over the mouse device and so my driver is never bind to it. Now, I know

Re: read problem in tty driver

2010-01-18 Thread luca ellero
Jan Pazderník wrote: Hello.I have been working on program based on LDD3 source tiny_tty driver (http://www.cs.fsu.edu/~baker/devices...tty/tiny_tty.c http://www.cs.fsu.edu/%7Ebaker/devices/lxr/http/source/ldd-examples/tty/tiny_tty.c) and I have problem with reading from device in user space.

Re: Introduction to kernel threads

2009-11-30 Thread luca ellero
Kristian Evensen ha scritto: Hello again, Thank you very much for all your help with kernel threads, I have now developed a couple of test modules which use them and feel like I start to understand them. However, there is one thing I have yet to figure out how to solve properly. I am working

Reading I/O ports with kdb

2009-11-03 Thread luca ellero
Hi everybody, I've setup an x86 system with kernel 2.6.31.4 and enabled kdb. I know how to dump memory with md command and CPU registers with rd. I wonder if there is a way to read (and maybe write) I/O ports from within kdb. Any suggestions are welcome Thanks Luca -- To unsubscribe from

Re: pr_debug and if (0) statement

2009-09-03 Thread luca ellero
. [...] Then why not simply use do { } while (0) or similar? [ On Wed, Sep 2, 2009 at 1:24 PM, luca ellero lro...@libero.it wrote: [...] can someone please explain me the meaning/benefits of the if (0

Re: pr_debug and if (0) statement

2009-09-03 Thread luca ellero
Frederic Weisbecker wrote: On Thu, Sep 03, 2009 at 09:25:40AM +0200, luca ellero wrote: Bernd Petrovitsch ha scritto: On Wed, 2009-09-02 at 15:17 +0530, Anuz Pratap Singh Tomar wrote: On Wed, Sep 2, 2009 at 2:30 PM, Bernd Petrovitsch be...@firmix.at wrote: On Wed, 2009-09-02 at 13:31

Re: Drive tester

2009-07-23 Thread luca ellero
Bill Weiler wrote: I wanted to make an Application that could send scripted SCSI and SATA commands to my drives. I have found my Fedora Linux to be too complex to control the drives in this way. I have looked at minimal Linux but I think this would have the same problem. Is there an easier

Re: Debug early kernel stages

2009-07-07 Thread luca ellero
Mulyadi Santosa wrote: Hi... On Mon, Jul 6, 2009 at 8:04 PM, luca ellerolro...@libero.it wrote: Hi all, I'm trying to debug/trace early stages of kernel boot on x86 (just for fun and learning). I mean very first stages when CPU is still in real-mode. Since tools like printk/kdb/kgdb are not

Re: Netlink sockets

2009-03-25 Thread luca ellero
Mauricio Mauad Menegaz Filho wrote: Hi 2009/3/24 luca ellero lro...@libero.it mailto:lro...@libero.it Hi all, I was investigating netlink sockets on the linux kernel and I was wondering how can I list all opened netlink sockets on the system. I've tryed netstat --netlink but my

Netlink sockets

2009-03-24 Thread luca ellero
Hi all, I was investigating netlink sockets on the linux kernel and I was wondering how can I list all opened netlink sockets on the system. I've tryed netstat --netlink but my system (Ubuntu 8.10) seems to not have that option. Thanks in advance Luk -- To unsubscribe from this list: send

Re: Unreliable Guide To Locking

2008-12-19 Thread luca ellero
Michael Blizek ha wrote: Hi! On 09:45 Fri 19 Dec , luca ellero wrote: Michael Blizek wrote: Hi! Hi Michael and thank you for your reply. On 14:35 Thu 18 Dec , luca ellero wrote: 2. Why spin_lock_irqsave is used only between IRQ Handler A and IRQ Handler B? In all other situation

Unreliable Guide To Locking

2008-12-18 Thread luca ellero
in advance Luca Ellero -- To unsubscribe from this list: send an email with unsubscribe kernelnewbies to ecar...@nl.linux.org Please read the FAQ at http://kernelnewbies.org/FAQ

Re: LDD3: tiny_serial and tiny_tty

2008-10-23 Thread luca ellero
, 2008 at 4:01 PM, luca ellero [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: Hi everybody, I'm trying to compile the examples of LDD3 with kernel 2.6.22. http://2.6.22. I get them from: http://www.oreilly.com.cn/codeexample/ldd3/ I have some problems/questions

LDD3: tiny_serial and tiny_tty

2008-10-22 Thread luca ellero
Hi everybody, I'm trying to compile the examples of LDD3 with kernel 2.6.22. I get them from: http://www.oreilly.com.cn/codeexample/ldd3/ I have some problems/questions regarding tiny_tty.c and tiny_serial.c (tty directory concerning chapter 18) 1) Are they tty or uart drivers? What is the

Re: Modules load order

2008-10-17 Thread luca ellero
, luca ellero [EMAIL PROTECTED] wrote: Hi everybody, maybe this is not really related to kernel. Anyway I would like to know in which order udev loads module drivers. I mean, if there is a driver that works for a specific USB device and a more generic USB class driver for the same device, which one

Modules load order

2008-10-16 Thread luca ellero
Hi everybody, maybe this is not really related to kernel. Anyway I would like to know in which order udev loads module drivers. I mean, if there is a driver that works for a specific USB device and a more generic USB class driver for the same device, which one will be loaded. I think that it

Re: Volatile raw spinlock

2008-09-17 Thread luca ellero
Sitsofe Wheeler wrote: Henrik Austad wrote: On Monday 15 September 2008 17:13:08 luca ellero wrote: Why slock is not declared as volatile in the 2.6.25 kernel? the section you refer to (volatile), was introduced in commit fb1c8f93d869b34cacb8b8932e2b83d96a19d720 in sep. 2005. volatile