diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-06-02 15:55:22 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-06-02 15:55:22 +0200 |
commit | bd05dbd3b22612455283610b4e006ee3e421b13d (patch) | |
tree | 06868be09771d6908acd657b1a9f66b0fb209bce /sound/pci/ctxfi/cthw20k1.c | |
parent | 67fbf880631bb4493ad8d23f25562abdf09dc01d (diff) | |
parent | c76157d9286ed598c241c212aa5a3c6e5107bd82 (diff) | |
download | kernel_samsung_aries-bd05dbd3b22612455283610b4e006ee3e421b13d.zip kernel_samsung_aries-bd05dbd3b22612455283610b4e006ee3e421b13d.tar.gz kernel_samsung_aries-bd05dbd3b22612455283610b4e006ee3e421b13d.tar.bz2 |
Merge branch 'topic/ctxfi-fix' into topic/ctxfi
Diffstat (limited to 'sound/pci/ctxfi/cthw20k1.c')
-rw-r--r-- | sound/pci/ctxfi/cthw20k1.c | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/sound/pci/ctxfi/cthw20k1.c b/sound/pci/ctxfi/cthw20k1.c index 44283bd..b7b8e6f 100644 --- a/sound/pci/ctxfi/cthw20k1.c +++ b/sound/pci/ctxfi/cthw20k1.c @@ -1249,19 +1249,15 @@ static int hw_trn_init(struct hw *hw, const struct trn_conf *info) } trnctl = 0x13; /* 32-bit, 4k-size page */ -#if BITS_PER_LONG == 64 - ptp_phys_low = info->vm_pgt_phys & ((1UL<<32)-1); - ptp_phys_high = (info->vm_pgt_phys>>32) & ((1UL<<32)-1); - trnctl |= (1<<2); -#elif BITS_PER_LONG == 32 - ptp_phys_low = info->vm_pgt_phys & (~0UL); - ptp_phys_high = 0; -#else -# error "Unknown BITS_PER_LONG!" -#endif + ptp_phys_low = (u32)info->vm_pgt_phys; + ptp_phys_high = upper_32_bits(info->vm_pgt_phys); + if (sizeof(void *) == 8) /* 64bit address */ + trnctl |= (1 << 2); +#if 0 /* Only 4k h/w pages for simplicitiy */ #if PAGE_SIZE == 8192 trnctl |= (1<<5); #endif +#endif hw_write_20kx(hw, PTPALX, ptp_phys_low); hw_write_20kx(hw, PTPAHX, ptp_phys_high); hw_write_20kx(hw, TRNCTL, trnctl); |