Clarification needed on register_netdevice_notifier behavior.

2012-09-10 Thread Paraneetharan Chandrasekaran
Hi all,

I encountered a behavior of register_netdevice_notifier. Upon the
registration a notifier, it calls the notifier looping through each
net_device and invokes the notifier. If, at some instance, the
notifier fails with error, it rollsback each of net_device it had been
notified earlier. Pls take a look at the function.

I am not sure  whether the rolling back part is done for a reason.
Does this not possibly cause undesirable behaviors in the notifier's
client for the reason that it had been misinformed that all the
net_devices' are unregistered?

--
Regards,
Paraneetharan C

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Need help understanding memory models, cpu modes and address translation

2011-07-13 Thread Paraneetharan Chandrasekaran
The document and osdev are very good and useful. Thanks a lot.

- Paraneetharan C

On 13 July 2011 14:23, amit mehta gmate.a...@gmail.com wrote:

 Tons of resource
 http://wiki.osdev.org/

 On Wed, Jul 13, 2011 at 2:07 PM, Vaibhav Jain vjoss...@gmail.com wrote:
  Hi,
 
  Thanks for the link.I really appreciate but I need something more basic
 and
  something that
  explains these concepts from a broader perspective and not in the context
 of
  a
  particular cpu architecture.Please send me more such links if you come
  across any.
 
  Thanks
  Vaibhav Jain
 
  On Wed, Jul 13, 2011 at 1:14 AM, Daniel Baluta daniel.bal...@gmail.com
  wrote:
 
  Hi,
 
   I am eager to understand the basics of Memory models  (flat, segmented
   etc)
   , CPU modes (real,protected)
   and address translation (physical to logical etc.) and how all of them
   work
   together. I am very confused
   about this and would really appreciate if someone could provide good
   references to these topics.
 
  You may find useful information inside i366 Programmers Manual.
  Anyhow, reading materials is the first step in understanding these
  concepts. You will have to actually  read/write/debug pieces of code
  related to them.
 
  thanks,
  Daniel.
 
  [1] pdos.csail.mit.edu/6.828/2010/readings/i386.pdf
 
 
  ___
  Kernelnewbies mailing list
  Kernelnewbies@kernelnewbies.org
  http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
 
 



 --
 Life is elsewhere. Cross Frontiers. Fly away.

 - Salman Rushdie

 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies




-- 
Regards,
Paraneetharan C
___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: interview question how does application connects to device

2011-07-05 Thread Paraneetharan Chandrasekaran
I think the thread originator is asking about how the application knows
which device file to read or write.
This is done by h/w management system udev. udev creates/manages device
nodes in /dev/ dir and notifes applications based on the udev rules written
(via HAL events or DBUS signals).

Thanks,
Paraneetharan C


On 5 July 2011 12:21, Philipp Ittershagen li...@gate-nine.de wrote:

 On 07/05/2011 06:15 AM, Bond wrote:
  But he was expecting some thing more complex.

 Well, to be honest, I also was expecting something more complex when I
 first looked at kernel programming and creating character devices ;) But
 the file_operations interface is really straight-forward and simple,
 very nice.


 Philipp

 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies




-- 
Regards,
Paraneetharan C
___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Basic HighMeM Question

2011-06-29 Thread Paraneetharan Chandrasekaran
On 29 June 2011 12:08, Mulyadi Santosa mulyadi.sant...@gmail.com wrote:

 Hi :)

 On Wed, Jun 29, 2011 at 13:30, piyush moghe pmker...@gmail.com wrote:
  Thanks Mulyadi and Prabhu for your enlightening description.

 You welcome :)

  What a plight!!! memory has become soo cheap nowadays that I don't have
 less
  than 1GB system and difficult to find someone in my knowledge having less
  than 1 GB memory.

 In embedded world, it's still common scenario so it depends on
 which side we see it :) That's the flexibility Linux kernel tries to
 show...it does well on big memory machine...but it can also run in
 small amount of memory... of course, with the right user space
 applications :) (hint: Linux slitaz, puppy, tiny core...)


  Although does this means that pages in FCOM will never have page fault?

 Everything mapped in kernel space ( I stress the word mapped) is
 designed to stay all the time in RAM in Linux kernel context. So based
 on that AFAIK, we won't get page fault in kernel space. This is
 strictly design choice IMHO.

 and
  if this is true is this the reason why we assign NULL to memory
 descriptor (
  mm_struct ) for kernel threads?

 because kernel threads don't need to have specific address space owned
 to them. They can simply borrow last scheduled process' address
 space. After all, they just operate in kernel space, which is the same
 for all processes, be it kernel threads or normal task.


Thanks Mulyadi for your clarifications!
I am not getting the idea of borrowing last run process's address space. A
kernel thread refers only the addresses in kernel's address space (low-mem
area) which is mapped already, isnt it? How does the address space of last
run task comes into picture?



 --
 regards,

 Mulyadi Santosa
 Freelance Linux trainer and consultant

 blog: the-hydra.blogspot.com
 training: mulyaditraining.blogspot.com

 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies




-- 
Regards,
Paraneetharan C
___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies