aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/ctxfi/ctvmem.h
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2009-06-02 09:04:29 -0400
committerTakashi Iwai <tiwai@suse.de>2009-06-02 09:54:46 -0400
commitcd391e206f486955e216a61bd9ebcb0e142122e9 (patch)
treeecbf2facf4199093d44bae7e16767566353758d8 /sound/pci/ctxfi/ctvmem.h
parentd2b9b96c516d4d61663d92ab4ad4f15ca0134ef2 (diff)
ALSA: ctxfi - Remove PAGE_SIZE limitation
Remove the limitation of PAGE_SIZE to be 4k by defining the own page size and macros for 4k. 8kb page size could be natively supported, but it's disabled right now for simplicity. Also, clean up using upper_32_bits() macro. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/ctxfi/ctvmem.h')
-rw-r--r--sound/pci/ctxfi/ctvmem.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/sound/pci/ctxfi/ctvmem.h b/sound/pci/ctxfi/ctvmem.h
index 618952efa5b3..17d2d37a9ea7 100644
--- a/sound/pci/ctxfi/ctvmem.h
+++ b/sound/pci/ctxfi/ctvmem.h
@@ -23,6 +23,14 @@
23#include <linux/mutex.h> 23#include <linux/mutex.h>
24#include <linux/list.h> 24#include <linux/list.h>
25 25
26/* The chip can handle the page table of 4k pages
27 * (emu20k1 can handle even 8k pages, but we don't use it right now)
28 */
29#define CT_PAGE_SIZE 4096
30#define CT_PAGE_SHIFT 12
31#define CT_PAGE_MASK (~(PAGE_SIZE - 1))
32#define CT_PAGE_ALIGN(addr) ALIGN(addr, CT_PAGE_SIZE)
33
26struct ct_vm_block { 34struct ct_vm_block {
27 unsigned int addr; /* starting logical addr of this block */ 35 unsigned int addr; /* starting logical addr of this block */
28 unsigned int size; /* size of this device virtual mem block */ 36 unsigned int size; /* size of this device virtual mem block */