X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fieee1394%2Fcsr1212.h;h=17ddd72dee4e60c8f3ac4e99ff4a57be2f8d7531;hb=refs%2Fheads%2Fvserver;hp=e7f1d30c660b1d6bab739c50ecbc793765cbf169;hpb=5273a3df6485dc2ad6aa7ddd441b9a21970f003b;p=linux-2.6.git diff --git a/drivers/ieee1394/csr1212.h b/drivers/ieee1394/csr1212.h index e7f1d30c6..17ddd72de 100644 --- a/drivers/ieee1394/csr1212.h +++ b/drivers/ieee1394/csr1212.h @@ -37,10 +37,11 @@ #include #include #include -#include +#include +#include -#define CSR1212_MALLOC(size) kmalloc((size), in_interrupt() ? GFP_ATOMIC : GFP_KERNEL) -#define CSR1212_FREE(ptr) kfree(ptr) +#define CSR1212_MALLOC(size) vmalloc((size)) +#define CSR1212_FREE(ptr) vfree(ptr) #define CSR1212_BE16_TO_CPU(quad) be16_to_cpu(quad) #define CSR1212_CPU_TO_BE16(quad) cpu_to_be16(quad) #define CSR1212_BE32_TO_CPU(quad) be32_to_cpu(quad) @@ -191,6 +192,7 @@ #define CSR1212_EXTENDED_ROM_SIZE (0x10000 * sizeof(u_int32_t)) +#define CSR1212_INVALID_ADDR_SPACE -1 /* Config ROM image structures */ struct csr1212_bus_info_block_img { @@ -645,7 +647,7 @@ static inline struct csr1212_csr_rom_cache *csr1212_rom_cache_malloc(u_int32_t o { struct csr1212_csr_rom_cache *cache; - cache = CSR1212_MALLOC(sizeof(struct csr1212_csr_rom_cache) + size); + cache = CSR1212_MALLOC(sizeof(*cache) + size); if (!cache) return NULL;