Re: few questions on 'struct net_device'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello, Rajat!
You wrote to "Roman Mashak" <mrv@xxxxxxxxxxxxx> on Wed, 31 Jan 2007 11:00:12 +0530:

RJ> The actual request for resources is delayed till the device open time
RJ> because no one would actually be using those resources prior to opening
RJ> the device. If we allocate the resources at initialization time only,
RJ> we would be wasting precious resources without needing them, despite
RJ> the same resources could have been used by some other device in use,
RJ> while our device has yet not been "opened".

I guess it's true for non-PCI devices only, isn't it? Because firmware arranges all necessary resources and stores them in the registers of PCI devices, prior the kernel run.

Or the above described approach is chosen, as it's consistent and provides hardware abstraction, regardless of the bus you're running the devices on.

RJ> Also consider that once we request the irq, our ISR will be called at
RJ> every irq seen at that line whether it was generated by our device or
RJ> not. Even if it was generated by our device, we could have safely
RJ> chosen to ignore it.

RJ> Hence linux delays the actual allocation of resources as much as
RJ> possible.

---
Best regards, Roman Mashak


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux