devres: device resource management
Implement device resource management, in short, devres. A device
driver can allocate arbirary size of devres data which is associated
with a release function. On driver detach, release function is
invoked on the devres data, then, devres data is freed.
devreses are typed by associated release functions. Some devreses are
better represented by single instance of the type while others need
multiple instances sharing the same release function. Both usages are
supported.
devreses can be grouped using devres group such that a device driver
can easily release acquired resources halfway through initialization
or selectively release resources (e.g. resources for port 1 out of 4
ports).
This patch adds devres core including documentation and the following
managed interfaces.
* alloc/free : devm_kzalloc(), devm_kzfree()
* IO region : devm_request_region(), devm_release_region()
* IRQ : devm_request_irq(), devm_free_irq()
* DMA : dmam_alloc_coherent(), dmam_free_coherent(),
dmam_declare_coherent_memory(), dmam_pool_create(),
dmam_pool_destroy()
* PCI : pcim_enable_device(), pcim_pin_device(), pci_is_managed()
* iomap : devm_ioport_map(), devm_ioport_unmap(), devm_ioremap(),
devm_ioremap_nocache(), devm_iounmap(), pcim_iomap_table(),
pcim_iomap(), pcim_iounmap()
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-20 14:00:26 +07:00
|
|
|
Devres - Managed Device Resource
|
|
|
|
================================
|
|
|
|
|
|
|
|
Tejun Heo <teheo@suse.de>
|
|
|
|
|
|
|
|
First draft 10 January 2007
|
|
|
|
|
|
|
|
|
|
|
|
1. Intro : Huh? Devres?
|
|
|
|
2. Devres : Devres in a nutshell
|
|
|
|
3. Devres Group : Group devres'es and release them together
|
|
|
|
4. Details : Life time rules, calling context, ...
|
|
|
|
5. Overhead : How much do we have to pay for this?
|
|
|
|
6. List of managed interfaces : Currently implemented managed interfaces
|
|
|
|
|
|
|
|
|
|
|
|
1. Intro
|
|
|
|
--------
|
|
|
|
|
|
|
|
devres came up while trying to convert libata to use iomap. Each
|
|
|
|
iomapped address should be kept and unmapped on driver detach. For
|
|
|
|
example, a plain SFF ATA controller (that is, good old PCI IDE) in
|
|
|
|
native mode makes use of 5 PCI BARs and all of them should be
|
|
|
|
maintained.
|
|
|
|
|
|
|
|
As with many other device drivers, libata low level drivers have
|
|
|
|
sufficient bugs in ->remove and ->probe failure path. Well, yes,
|
|
|
|
that's probably because libata low level driver developers are lazy
|
|
|
|
bunch, but aren't all low level driver developers? After spending a
|
|
|
|
day fiddling with braindamaged hardware with no document or
|
|
|
|
braindamaged document, if it's finally working, well, it's working.
|
|
|
|
|
|
|
|
For one reason or another, low level drivers don't receive as much
|
|
|
|
attention or testing as core code, and bugs on driver detach or
|
2007-10-20 06:34:40 +07:00
|
|
|
initialization failure don't happen often enough to be noticeable.
|
devres: device resource management
Implement device resource management, in short, devres. A device
driver can allocate arbirary size of devres data which is associated
with a release function. On driver detach, release function is
invoked on the devres data, then, devres data is freed.
devreses are typed by associated release functions. Some devreses are
better represented by single instance of the type while others need
multiple instances sharing the same release function. Both usages are
supported.
devreses can be grouped using devres group such that a device driver
can easily release acquired resources halfway through initialization
or selectively release resources (e.g. resources for port 1 out of 4
ports).
This patch adds devres core including documentation and the following
managed interfaces.
* alloc/free : devm_kzalloc(), devm_kzfree()
* IO region : devm_request_region(), devm_release_region()
* IRQ : devm_request_irq(), devm_free_irq()
* DMA : dmam_alloc_coherent(), dmam_free_coherent(),
dmam_declare_coherent_memory(), dmam_pool_create(),
dmam_pool_destroy()
* PCI : pcim_enable_device(), pcim_pin_device(), pci_is_managed()
* iomap : devm_ioport_map(), devm_ioport_unmap(), devm_ioremap(),
devm_ioremap_nocache(), devm_iounmap(), pcim_iomap_table(),
pcim_iomap(), pcim_iounmap()
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-20 14:00:26 +07:00
|
|
|
Init failure path is worse because it's much less travelled while
|
|
|
|
needs to handle multiple entry points.
|
|
|
|
|
|
|
|
So, many low level drivers end up leaking resources on driver detach
|
|
|
|
and having half broken failure path implementation in ->probe() which
|
|
|
|
would leak resources or even cause oops when failure occurs. iomap
|
|
|
|
adds more to this mix. So do msi and msix.
|
|
|
|
|
|
|
|
|
|
|
|
2. Devres
|
|
|
|
---------
|
|
|
|
|
|
|
|
devres is basically linked list of arbitrarily sized memory areas
|
|
|
|
associated with a struct device. Each devres entry is associated with
|
|
|
|
a release function. A devres can be released in several ways. No
|
|
|
|
matter what, all devres entries are released on driver detach. On
|
|
|
|
release, the associated release function is invoked and then the
|
|
|
|
devres entry is freed.
|
|
|
|
|
|
|
|
Managed interface is created for resources commonly used by device
|
|
|
|
drivers using devres. For example, coherent DMA memory is acquired
|
|
|
|
using dma_alloc_coherent(). The managed version is called
|
|
|
|
dmam_alloc_coherent(). It is identical to dma_alloc_coherent() except
|
|
|
|
for the DMA memory allocated using it is managed and will be
|
|
|
|
automatically released on driver detach. Implementation looks like
|
|
|
|
the following.
|
|
|
|
|
|
|
|
struct dma_devres {
|
|
|
|
size_t size;
|
|
|
|
void *vaddr;
|
|
|
|
dma_addr_t dma_handle;
|
|
|
|
};
|
|
|
|
|
|
|
|
static void dmam_coherent_release(struct device *dev, void *res)
|
|
|
|
{
|
|
|
|
struct dma_devres *this = res;
|
|
|
|
|
|
|
|
dma_free_coherent(dev, this->size, this->vaddr, this->dma_handle);
|
|
|
|
}
|
|
|
|
|
|
|
|
dmam_alloc_coherent(dev, size, dma_handle, gfp)
|
|
|
|
{
|
|
|
|
struct dma_devres *dr;
|
|
|
|
void *vaddr;
|
|
|
|
|
|
|
|
dr = devres_alloc(dmam_coherent_release, sizeof(*dr), gfp);
|
|
|
|
...
|
|
|
|
|
|
|
|
/* alloc DMA memory as usual */
|
|
|
|
vaddr = dma_alloc_coherent(...);
|
|
|
|
...
|
|
|
|
|
|
|
|
/* record size, vaddr, dma_handle in dr */
|
|
|
|
dr->vaddr = vaddr;
|
|
|
|
...
|
|
|
|
|
|
|
|
devres_add(dev, dr);
|
|
|
|
|
|
|
|
return vaddr;
|
|
|
|
}
|
|
|
|
|
|
|
|
If a driver uses dmam_alloc_coherent(), the area is guaranteed to be
|
|
|
|
freed whether initialization fails half-way or the device gets
|
|
|
|
detached. If most resources are acquired using managed interface, a
|
|
|
|
driver can have much simpler init and exit code. Init path basically
|
|
|
|
looks like the following.
|
|
|
|
|
|
|
|
my_init_one()
|
|
|
|
{
|
|
|
|
struct mydev *d;
|
|
|
|
|
|
|
|
d = devm_kzalloc(dev, sizeof(*d), GFP_KERNEL);
|
|
|
|
if (!d)
|
|
|
|
return -ENOMEM;
|
|
|
|
|
|
|
|
d->ring = dmam_alloc_coherent(...);
|
|
|
|
if (!d->ring)
|
|
|
|
return -ENOMEM;
|
|
|
|
|
|
|
|
if (check something)
|
|
|
|
return -EINVAL;
|
|
|
|
...
|
|
|
|
|
|
|
|
return register_to_upper_layer(d);
|
|
|
|
}
|
|
|
|
|
|
|
|
And exit path,
|
|
|
|
|
|
|
|
my_remove_one()
|
|
|
|
{
|
|
|
|
unregister_from_upper_layer(d);
|
|
|
|
shutdown_my_hardware();
|
|
|
|
}
|
|
|
|
|
|
|
|
As shown above, low level drivers can be simplified a lot by using
|
|
|
|
devres. Complexity is shifted from less maintained low level drivers
|
|
|
|
to better maintained higher layer. Also, as init failure path is
|
|
|
|
shared with exit path, both can get more testing.
|
|
|
|
|
|
|
|
|
|
|
|
3. Devres group
|
|
|
|
---------------
|
|
|
|
|
|
|
|
Devres entries can be grouped using devres group. When a group is
|
|
|
|
released, all contained normal devres entries and properly nested
|
|
|
|
groups are released. One usage is to rollback series of acquired
|
|
|
|
resources on failure. For example,
|
|
|
|
|
|
|
|
if (!devres_open_group(dev, NULL, GFP_KERNEL))
|
|
|
|
return -ENOMEM;
|
|
|
|
|
|
|
|
acquire A;
|
|
|
|
if (failed)
|
|
|
|
goto err;
|
|
|
|
|
|
|
|
acquire B;
|
|
|
|
if (failed)
|
|
|
|
goto err;
|
|
|
|
...
|
|
|
|
|
|
|
|
devres_remove_group(dev, NULL);
|
|
|
|
return 0;
|
|
|
|
|
|
|
|
err:
|
|
|
|
devres_release_group(dev, NULL);
|
|
|
|
return err_code;
|
|
|
|
|
2007-10-20 06:34:40 +07:00
|
|
|
As resource acquisition failure usually means probe failure, constructs
|
devres: device resource management
Implement device resource management, in short, devres. A device
driver can allocate arbirary size of devres data which is associated
with a release function. On driver detach, release function is
invoked on the devres data, then, devres data is freed.
devreses are typed by associated release functions. Some devreses are
better represented by single instance of the type while others need
multiple instances sharing the same release function. Both usages are
supported.
devreses can be grouped using devres group such that a device driver
can easily release acquired resources halfway through initialization
or selectively release resources (e.g. resources for port 1 out of 4
ports).
This patch adds devres core including documentation and the following
managed interfaces.
* alloc/free : devm_kzalloc(), devm_kzfree()
* IO region : devm_request_region(), devm_release_region()
* IRQ : devm_request_irq(), devm_free_irq()
* DMA : dmam_alloc_coherent(), dmam_free_coherent(),
dmam_declare_coherent_memory(), dmam_pool_create(),
dmam_pool_destroy()
* PCI : pcim_enable_device(), pcim_pin_device(), pci_is_managed()
* iomap : devm_ioport_map(), devm_ioport_unmap(), devm_ioremap(),
devm_ioremap_nocache(), devm_iounmap(), pcim_iomap_table(),
pcim_iomap(), pcim_iounmap()
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-20 14:00:26 +07:00
|
|
|
like above are usually useful in midlayer driver (e.g. libata core
|
|
|
|
layer) where interface function shouldn't have side effect on failure.
|
|
|
|
For LLDs, just returning error code suffices in most cases.
|
|
|
|
|
|
|
|
Each group is identified by void *id. It can either be explicitly
|
|
|
|
specified by @id argument to devres_open_group() or automatically
|
|
|
|
created by passing NULL as @id as in the above example. In both
|
|
|
|
cases, devres_open_group() returns the group's id. The returned id
|
|
|
|
can be passed to other devres functions to select the target group.
|
|
|
|
If NULL is given to those functions, the latest open group is
|
|
|
|
selected.
|
|
|
|
|
|
|
|
For example, you can do something like the following.
|
|
|
|
|
|
|
|
int my_midlayer_create_something()
|
|
|
|
{
|
|
|
|
if (!devres_open_group(dev, my_midlayer_create_something, GFP_KERNEL))
|
|
|
|
return -ENOMEM;
|
|
|
|
|
|
|
|
...
|
|
|
|
|
2007-05-01 16:00:19 +07:00
|
|
|
devres_close_group(dev, my_midlayer_create_something);
|
devres: device resource management
Implement device resource management, in short, devres. A device
driver can allocate arbirary size of devres data which is associated
with a release function. On driver detach, release function is
invoked on the devres data, then, devres data is freed.
devreses are typed by associated release functions. Some devreses are
better represented by single instance of the type while others need
multiple instances sharing the same release function. Both usages are
supported.
devreses can be grouped using devres group such that a device driver
can easily release acquired resources halfway through initialization
or selectively release resources (e.g. resources for port 1 out of 4
ports).
This patch adds devres core including documentation and the following
managed interfaces.
* alloc/free : devm_kzalloc(), devm_kzfree()
* IO region : devm_request_region(), devm_release_region()
* IRQ : devm_request_irq(), devm_free_irq()
* DMA : dmam_alloc_coherent(), dmam_free_coherent(),
dmam_declare_coherent_memory(), dmam_pool_create(),
dmam_pool_destroy()
* PCI : pcim_enable_device(), pcim_pin_device(), pci_is_managed()
* iomap : devm_ioport_map(), devm_ioport_unmap(), devm_ioremap(),
devm_ioremap_nocache(), devm_iounmap(), pcim_iomap_table(),
pcim_iomap(), pcim_iounmap()
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-20 14:00:26 +07:00
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
void my_midlayer_destroy_something()
|
|
|
|
{
|
2009-04-27 20:06:31 +07:00
|
|
|
devres_release_group(dev, my_midlayer_create_something);
|
devres: device resource management
Implement device resource management, in short, devres. A device
driver can allocate arbirary size of devres data which is associated
with a release function. On driver detach, release function is
invoked on the devres data, then, devres data is freed.
devreses are typed by associated release functions. Some devreses are
better represented by single instance of the type while others need
multiple instances sharing the same release function. Both usages are
supported.
devreses can be grouped using devres group such that a device driver
can easily release acquired resources halfway through initialization
or selectively release resources (e.g. resources for port 1 out of 4
ports).
This patch adds devres core including documentation and the following
managed interfaces.
* alloc/free : devm_kzalloc(), devm_kzfree()
* IO region : devm_request_region(), devm_release_region()
* IRQ : devm_request_irq(), devm_free_irq()
* DMA : dmam_alloc_coherent(), dmam_free_coherent(),
dmam_declare_coherent_memory(), dmam_pool_create(),
dmam_pool_destroy()
* PCI : pcim_enable_device(), pcim_pin_device(), pci_is_managed()
* iomap : devm_ioport_map(), devm_ioport_unmap(), devm_ioremap(),
devm_ioremap_nocache(), devm_iounmap(), pcim_iomap_table(),
pcim_iomap(), pcim_iounmap()
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-20 14:00:26 +07:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
4. Details
|
|
|
|
----------
|
|
|
|
|
|
|
|
Lifetime of a devres entry begins on devres allocation and finishes
|
|
|
|
when it is released or destroyed (removed and freed) - no reference
|
|
|
|
counting.
|
|
|
|
|
|
|
|
devres core guarantees atomicity to all basic devres operations and
|
|
|
|
has support for single-instance devres types (atomic
|
|
|
|
lookup-and-add-if-not-found). Other than that, synchronizing
|
|
|
|
concurrent accesses to allocated devres data is caller's
|
|
|
|
responsibility. This is usually non-issue because bus ops and
|
|
|
|
resource allocations already do the job.
|
|
|
|
|
|
|
|
For an example of single-instance devres type, read pcim_iomap_table()
|
2007-07-18 12:09:34 +07:00
|
|
|
in lib/devres.c.
|
devres: device resource management
Implement device resource management, in short, devres. A device
driver can allocate arbirary size of devres data which is associated
with a release function. On driver detach, release function is
invoked on the devres data, then, devres data is freed.
devreses are typed by associated release functions. Some devreses are
better represented by single instance of the type while others need
multiple instances sharing the same release function. Both usages are
supported.
devreses can be grouped using devres group such that a device driver
can easily release acquired resources halfway through initialization
or selectively release resources (e.g. resources for port 1 out of 4
ports).
This patch adds devres core including documentation and the following
managed interfaces.
* alloc/free : devm_kzalloc(), devm_kzfree()
* IO region : devm_request_region(), devm_release_region()
* IRQ : devm_request_irq(), devm_free_irq()
* DMA : dmam_alloc_coherent(), dmam_free_coherent(),
dmam_declare_coherent_memory(), dmam_pool_create(),
dmam_pool_destroy()
* PCI : pcim_enable_device(), pcim_pin_device(), pci_is_managed()
* iomap : devm_ioport_map(), devm_ioport_unmap(), devm_ioremap(),
devm_ioremap_nocache(), devm_iounmap(), pcim_iomap_table(),
pcim_iomap(), pcim_iounmap()
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-20 14:00:26 +07:00
|
|
|
|
|
|
|
All devres interface functions can be called without context if the
|
|
|
|
right gfp mask is given.
|
|
|
|
|
|
|
|
|
|
|
|
5. Overhead
|
|
|
|
-----------
|
|
|
|
|
|
|
|
Each devres bookkeeping info is allocated together with requested data
|
|
|
|
area. With debug option turned off, bookkeeping info occupies 16
|
|
|
|
bytes on 32bit machines and 24 bytes on 64bit (three pointers rounded
|
|
|
|
up to ull alignment). If singly linked list is used, it can be
|
|
|
|
reduced to two pointers (8 bytes on 32bit, 16 bytes on 64bit).
|
|
|
|
|
|
|
|
Each devres group occupies 8 pointers. It can be reduced to 6 if
|
|
|
|
singly linked list is used.
|
|
|
|
|
|
|
|
Memory space overhead on ahci controller with two ports is between 300
|
|
|
|
and 400 bytes on 32bit machine after naive conversion (we can
|
|
|
|
certainly invest a bit more effort into libata core layer).
|
|
|
|
|
|
|
|
|
|
|
|
6. List of managed interfaces
|
|
|
|
-----------------------------
|
|
|
|
|
2012-01-15 19:31:46 +07:00
|
|
|
MEM
|
|
|
|
devm_kzalloc()
|
|
|
|
devm_kfree()
|
2014-04-29 06:51:00 +07:00
|
|
|
devm_kmemdup()
|
2014-05-16 15:26:35 +07:00
|
|
|
devm_get_free_pages()
|
|
|
|
devm_free_pages()
|
2012-01-15 19:31:46 +07:00
|
|
|
|
2013-07-23 15:39:00 +07:00
|
|
|
IIO
|
|
|
|
devm_iio_device_alloc()
|
|
|
|
devm_iio_device_free()
|
2013-08-16 20:11:00 +07:00
|
|
|
devm_iio_trigger_alloc()
|
|
|
|
devm_iio_trigger_free()
|
2013-10-29 18:39:00 +07:00
|
|
|
devm_iio_device_register()
|
|
|
|
devm_iio_device_unregister()
|
2013-07-23 15:39:00 +07:00
|
|
|
|
devres: device resource management
Implement device resource management, in short, devres. A device
driver can allocate arbirary size of devres data which is associated
with a release function. On driver detach, release function is
invoked on the devres data, then, devres data is freed.
devreses are typed by associated release functions. Some devreses are
better represented by single instance of the type while others need
multiple instances sharing the same release function. Both usages are
supported.
devreses can be grouped using devres group such that a device driver
can easily release acquired resources halfway through initialization
or selectively release resources (e.g. resources for port 1 out of 4
ports).
This patch adds devres core including documentation and the following
managed interfaces.
* alloc/free : devm_kzalloc(), devm_kzfree()
* IO region : devm_request_region(), devm_release_region()
* IRQ : devm_request_irq(), devm_free_irq()
* DMA : dmam_alloc_coherent(), dmam_free_coherent(),
dmam_declare_coherent_memory(), dmam_pool_create(),
dmam_pool_destroy()
* PCI : pcim_enable_device(), pcim_pin_device(), pci_is_managed()
* iomap : devm_ioport_map(), devm_ioport_unmap(), devm_ioremap(),
devm_ioremap_nocache(), devm_iounmap(), pcim_iomap_table(),
pcim_iomap(), pcim_iounmap()
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-20 14:00:26 +07:00
|
|
|
IO region
|
|
|
|
devm_request_region()
|
|
|
|
devm_request_mem_region()
|
|
|
|
devm_release_region()
|
|
|
|
devm_release_mem_region()
|
|
|
|
|
|
|
|
IRQ
|
|
|
|
devm_request_irq()
|
|
|
|
devm_free_irq()
|
|
|
|
|
|
|
|
DMA
|
|
|
|
dmam_alloc_coherent()
|
|
|
|
dmam_free_coherent()
|
|
|
|
dmam_alloc_noncoherent()
|
|
|
|
dmam_free_noncoherent()
|
|
|
|
dmam_declare_coherent_memory()
|
|
|
|
dmam_pool_create()
|
|
|
|
dmam_pool_destroy()
|
|
|
|
|
|
|
|
PCI
|
|
|
|
pcim_enable_device() : after success, all PCI ops become managed
|
|
|
|
pcim_pin_device() : keep PCI device enabled after release
|
|
|
|
|
|
|
|
IOMAP
|
|
|
|
devm_ioport_map()
|
|
|
|
devm_ioport_unmap()
|
|
|
|
devm_ioremap()
|
|
|
|
devm_ioremap_nocache()
|
|
|
|
devm_iounmap()
|
2013-01-21 17:08:54 +07:00
|
|
|
devm_ioremap_resource() : checks resource, requests memory region, ioremaps
|
|
|
|
devm_request_and_ioremap() : obsoleted by devm_ioremap_resource()
|
devres: device resource management
Implement device resource management, in short, devres. A device
driver can allocate arbirary size of devres data which is associated
with a release function. On driver detach, release function is
invoked on the devres data, then, devres data is freed.
devreses are typed by associated release functions. Some devreses are
better represented by single instance of the type while others need
multiple instances sharing the same release function. Both usages are
supported.
devreses can be grouped using devres group such that a device driver
can easily release acquired resources halfway through initialization
or selectively release resources (e.g. resources for port 1 out of 4
ports).
This patch adds devres core including documentation and the following
managed interfaces.
* alloc/free : devm_kzalloc(), devm_kzfree()
* IO region : devm_request_region(), devm_release_region()
* IRQ : devm_request_irq(), devm_free_irq()
* DMA : dmam_alloc_coherent(), dmam_free_coherent(),
dmam_declare_coherent_memory(), dmam_pool_create(),
dmam_pool_destroy()
* PCI : pcim_enable_device(), pcim_pin_device(), pci_is_managed()
* iomap : devm_ioport_map(), devm_ioport_unmap(), devm_ioremap(),
devm_ioremap_nocache(), devm_iounmap(), pcim_iomap_table(),
pcim_iomap(), pcim_iounmap()
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-20 14:00:26 +07:00
|
|
|
pcim_iomap()
|
|
|
|
pcim_iounmap()
|
|
|
|
pcim_iomap_table() : array of mapped addresses indexed by BAR
|
|
|
|
pcim_iomap_regions() : do request_region() and iomap() on multiple BARs
|
2012-01-17 10:39:58 +07:00
|
|
|
|
|
|
|
REGULATOR
|
|
|
|
devm_regulator_get()
|
2012-01-31 13:44:01 +07:00
|
|
|
devm_regulator_put()
|
|
|
|
devm_regulator_bulk_get()
|
2013-08-31 17:58:26 +07:00
|
|
|
devm_regulator_register()
|
2012-04-05 17:42:09 +07:00
|
|
|
|
|
|
|
CLOCK
|
|
|
|
devm_clk_get()
|
|
|
|
devm_clk_put()
|
2012-05-22 06:58:23 +07:00
|
|
|
|
2012-04-16 23:51:00 +07:00
|
|
|
PINCTRL
|
|
|
|
devm_pinctrl_get()
|
|
|
|
devm_pinctrl_put()
|
2012-08-01 17:20:58 +07:00
|
|
|
|
|
|
|
PWM
|
|
|
|
devm_pwm_get()
|
|
|
|
devm_pwm_put()
|
2012-12-14 01:14:54 +07:00
|
|
|
|
|
|
|
PHY
|
|
|
|
devm_usb_get_phy()
|
|
|
|
devm_usb_put_phy()
|
2013-08-21 18:27:05 +07:00
|
|
|
|
|
|
|
SLAVE DMA ENGINE
|
|
|
|
devm_acpi_dma_controller_register()
|
2013-09-01 00:50:52 +07:00
|
|
|
|
|
|
|
SPI
|
|
|
|
devm_spi_register_master()
|
2014-04-25 22:10:05 +07:00
|
|
|
|
|
|
|
GPIO
|
|
|
|
devm_gpiod_get()
|
|
|
|
devm_gpiod_get_index()
|
2014-04-25 22:10:06 +07:00
|
|
|
devm_gpiod_get_optional()
|
|
|
|
devm_gpiod_get_index_optional()
|
2014-04-25 22:10:05 +07:00
|
|
|
devm_gpiod_put()
|
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next
Pull networking updates from David Miller:
1) Seccomp BPF filters can now be JIT'd, from Alexei Starovoitov.
2) Multiqueue support in xen-netback and xen-netfront, from Andrew J
Benniston.
3) Allow tweaking of aggregation settings in cdc_ncm driver, from Bjørn
Mork.
4) BPF now has a "random" opcode, from Chema Gonzalez.
5) Add more BPF documentation and improve test framework, from Daniel
Borkmann.
6) Support TCP fastopen over ipv6, from Daniel Lee.
7) Add software TSO helper functions and use them to support software
TSO in mvneta and mv643xx_eth drivers. From Ezequiel Garcia.
8) Support software TSO in fec driver too, from Nimrod Andy.
9) Add Broadcom SYSTEMPORT driver, from Florian Fainelli.
10) Handle broadcasts more gracefully over macvlan when there are large
numbers of interfaces configured, from Herbert Xu.
11) Allow more control over fwmark used for non-socket based responses,
from Lorenzo Colitti.
12) Do TCP congestion window limiting based upon measurements, from Neal
Cardwell.
13) Support busy polling in SCTP, from Neal Horman.
14) Allow RSS key to be configured via ethtool, from Venkata Duvvuru.
15) Bridge promisc mode handling improvements from Vlad Yasevich.
16) Don't use inetpeer entries to implement ID generation any more, it
performs poorly, from Eric Dumazet.
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1522 commits)
rtnetlink: fix userspace API breakage for iproute2 < v3.9.0
tcp: fixing TLP's FIN recovery
net: fec: Add software TSO support
net: fec: Add Scatter/gather support
net: fec: Increase buffer descriptor entry number
net: fec: Factorize feature setting
net: fec: Enable IP header hardware checksum
net: fec: Factorize the .xmit transmit function
bridge: fix compile error when compiling without IPv6 support
bridge: fix smatch warning / potential null pointer dereference
via-rhine: fix full-duplex with autoneg disable
bnx2x: Enlarge the dorq threshold for VFs
bnx2x: Check for UNDI in uncommon branch
bnx2x: Fix 1G-baseT link
bnx2x: Fix link for KR with swapped polarity lane
sctp: Fix sk_ack_backlog wrap-around problem
net/core: Add VF link state control policy
net/fsl: xgmac_mdio is dependent on OF_MDIO
net/fsl: Make xgmac_mdio read error message useful
net_sched: drr: warn when qdisc is not work conserving
...
2014-06-13 04:27:40 +07:00
|
|
|
|
2014-04-30 19:23:33 +07:00
|
|
|
MDIO
|
|
|
|
devm_mdiobus_alloc()
|
|
|
|
devm_mdiobus_alloc_size()
|
|
|
|
devm_mdiobus_free()
|