ChangeSet 1.2082, 2005/03/12 09:16:29-08:00, [EMAIL PROTECTED]
[PATCH] Remove ASSERT macro from PA-RISC PCI-DMA implementation
Remove no-longer-needed ASSERTs
Signed-off-by: Grant Grundler <[EMAIL PROTECTED]>
Signed-off-by: Matthew Wilcox <[EMAIL PROTECTED]>
Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
pci-dma.c | 22 +---------------------
1 files changed, 1 insertion(+), 21 deletions(-)
diff -Nru a/arch/parisc/kernel/pci-dma.c b/arch/parisc/kernel/pci-dma.c
--- a/arch/parisc/kernel/pci-dma.c 2005-03-12 21:44:01 -08:00
+++ b/arch/parisc/kernel/pci-dma.c 2005-03-12 21:44:01 -08:00
@@ -32,18 +32,6 @@
#include <asm/pgalloc.h>
#include <asm/uaccess.h>
-#ifdef DEBUG_PCI
-#undef ASSERT
-#define ASSERT(expr) \
- if(!(expr)) { \
- printk("\n%s:%d: Assertion " #expr " failed!\n", \
- __FILE__, __LINE__); \
- panic(#expr); \
- }
-#else
-#define ASSERT(expr)
-#endif
-
static struct proc_dir_entry * proc_gsc_root = NULL;
static int pcxl_proc_info(char *buffer, char **start, off_t offset, int
length);
@@ -259,10 +247,6 @@
u_long mask, flags;
unsigned int pages_needed = size >> PAGE_SHIFT;
- ASSERT(pages_needed);
- ASSERT((pages_needed * PAGE_SIZE) < DMA_CHUNK_SIZE);
- ASSERT(pages_needed < (BITS_PER_LONG - PAGE_SHIFT));
-
mask = (u_long) -1L;
mask >>= BITS_PER_LONG - pages_needed;
@@ -306,7 +290,7 @@
#define PCXL_FREE_MAPPINGS(idx, m, size) \
u##size *res_ptr = (u##size *)&(pcxl_res_map[(idx) + (((size >>
3) - 1) & (~((size >> 3) - 1)))]); \
- ASSERT((*res_ptr & m) == m); \
+ /* BUG_ON((*res_ptr & m) != m); */ \
*res_ptr &= ~m;
/*
@@ -318,10 +302,6 @@
u_long mask, flags;
unsigned int res_idx = (vaddr - pcxl_dma_start) >> (PAGE_SHIFT + 3);
unsigned int pages_mapped = size >> PAGE_SHIFT;
-
- ASSERT(pages_mapped);
- ASSERT((pages_mapped * PAGE_SIZE) < DMA_CHUNK_SIZE);
- ASSERT(pages_mapped < (BITS_PER_LONG - PAGE_SHIFT));
mask = (u_long) -1L;
mask >>= BITS_PER_LONG - pages_mapped;
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html