From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759158AbXHTJrJ (ORCPT ); Mon, 20 Aug 2007 05:47:09 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754416AbXHTJq5 (ORCPT ); Mon, 20 Aug 2007 05:46:57 -0400 Received: from mail.suse.de ([195.135.220.2]:57260 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753207AbXHTJq4 (ORCPT ); Mon, 20 Aug 2007 05:46:56 -0400 Date: Mon, 20 Aug 2007 11:46:54 +0200 Message-ID: From: Takashi Iwai To: Andi Kleen Cc: Linus Torvalds , Muli Ben-Yehuda , James Bottomley , Andrew Morton , patches@x86-64.org, Linux Kernel Mailing List , Alan Cox Subject: Re: [PATCH] [1/4] x86_64: Fail dma_alloc_coherent on dma less devices In-Reply-To: <200708182103.25461.ak@suse.de> References: <20070815240.194452000@suse.de> <20070815004034.4AB7814DC8@wotan.suse.de> <200708182103.25461.ak@suse.de> User-Agent: Wanderlust/2.15.5 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (=?ISO-8859-4?Q?Sanj=F2?=) APEL/10.6 MULE XEmacs/21.5 (beta28) (fuki) (+CVS-20070802) (i386-suse-linux) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org At Sat, 18 Aug 2007 21:03:25 +0200, Andi Kleen wrote: > > > Considering that the oops comes from this: > > > > /* Kludge to make it bug-to-bug compatible with i386. i386 > > uses the normal dma_mask for alloc_coherent. */ > > dma_mask &= *dev->dma_mask; > > > > > and that that code is *old*, and comes from when this file was called > > arch/x86_64/kernel/pci-gart.c, and the comment doesn't seem to even be > > It might be outdated or it might now. The kludge was needed for Alsa because old > i386 ignored the consistent mask and they didn't always set it correctly, but that > should be obsolete now? I'm not quite sure because sound devices > are not always well tested on large memory systems which are the only > ones who show this problem. Takashi, do you know if all alsa drivers > set consistent mask correctly now? Yes, ALSA driver set both masks from the very beginning :) There are some OSS drivers still calling only pci_set_dma_mask(). Through a quick look, maybe only trident.c needs a fix because it uses a mask < 32bit for ALI devices. Others use 32bit DMA mask. Takashi