Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Functions
msi_bitmap.c File Reference
#include <linux/slab.h>
#include <linux/kernel.h>
#include <linux/bitmap.h>
#include <asm/msi_bitmap.h>
#include <asm/setup.h>

Go to the source code of this file.

Functions

int msi_bitmap_alloc_hwirqs (struct msi_bitmap *bmp, int num)
 
void msi_bitmap_free_hwirqs (struct msi_bitmap *bmp, unsigned int offset, unsigned int num)
 
void msi_bitmap_reserve_hwirq (struct msi_bitmap *bmp, unsigned int hwirq)
 
int msi_bitmap_reserve_dt_hwirqs (struct msi_bitmap *bmp)
 
int msi_bitmap_alloc (struct msi_bitmap *bmp, unsigned int irq_count, struct device_node *of_node)
 
void msi_bitmap_free (struct msi_bitmap *bmp)
 

Function Documentation

int msi_bitmap_alloc ( struct msi_bitmap bmp,
unsigned int  irq_count,
struct device_node of_node 
)

Definition at line 109 of file msi_bitmap.c.

int msi_bitmap_alloc_hwirqs ( struct msi_bitmap bmp,
int  num 
)

Definition at line 17 of file msi_bitmap.c.

void msi_bitmap_free ( struct msi_bitmap bmp)

Definition at line 134 of file msi_bitmap.c.

void msi_bitmap_free_hwirqs ( struct msi_bitmap bmp,
unsigned int  offset,
unsigned int  num 
)

Definition at line 36 of file msi_bitmap.c.

int msi_bitmap_reserve_dt_hwirqs ( struct msi_bitmap bmp)

msi_bitmap_reserve_dt_hwirqs - Reserve irqs specified in the device tree. : pointer to the MSI bitmap.

Looks in the device tree to see if there is a property specifying which irqs can be used for MSI. If found those irqs reserved in the device tree are reserved in the bitmap.

Returns 0 for success, < 0 if there was an error, and > 0 if no property was found in the device tree.

Definition at line 72 of file msi_bitmap.c.

void msi_bitmap_reserve_hwirq ( struct msi_bitmap bmp,
unsigned int  hwirq 
)

Definition at line 50 of file msi_bitmap.c.