Atsushi Nemoto wrote: > On Tue, 7 Aug 2007 10:18:04 +0400, "Dajie Tan" <jiankemeng@xxxxxxxxx> wrote: > >> static inline unsigned long virt_to_phys(volatile const void *address) >> { >> - return (unsigned long)address - PAGE_OFFSET + PHYS_OFFSET; >> + return ((unsigned long)address & 0x1fffffff) + PHYS_OFFSET; >> } >> > > This makes virt_to_phys() a bit slower, and more importantly, breaks > 64-bit kernel. > I have tried this way, and disassemble result show 32-bit kernel add only one instruction. But I don't really insist on this patch, for it doesn't resolve some driver code requirement. > --- > Atsushi Nemoto > _______________________________________________ > Alsa-devel mailing list > Alsa-devel@xxxxxxxxxxxxxxxx > http://mailman.alsa-project.org/mailman/listinfo/alsa-devel > > > _______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxx http://mailman.alsa-project.org/mailman/listinfo/alsa-devel