Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754724AbYH1Mom (ORCPT ); Thu, 28 Aug 2008 08:44:42 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752170AbYH1Moe (ORCPT ); Thu, 28 Aug 2008 08:44:34 -0400 Received: from cantor2.suse.de ([195.135.220.15]:59228 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752064AbYH1Mod (ORCPT ); Thu, 28 Aug 2008 08:44:33 -0400 Date: Thu, 28 Aug 2008 14:44:32 +0200 Message-ID: From: Takashi Iwai To: Bryan Wu Cc: perex@perex.cz, liam.girdwood@wolfsonmicro.com, broonie@opensource.wolfsonmicro.com, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, Cliff Cai Subject: Re: [PATCH 4/4] ALSA: add dummy function to support shared mmap in nommu Blackfin arch In-Reply-To: <1219829968-6431-5-git-send-email-cooloney@kernel.org> References: <1219829968-6431-1-git-send-email-cooloney@kernel.org> <1219829968-6431-5-git-send-email-cooloney@kernel.org> User-Agent: Wanderlust/2.12.0 (Your Wildest Dreams) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (=?ISO-8859-4?Q?Sanj=F2?=) APEL/10.6 Emacs/22.2 (x86_64-suse-linux-gnu) MULE/5.0 (SAKAKI) 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 List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1735 Lines: 58 At Wed, 27 Aug 2008 17:39:28 +0800, Bryan Wu wrote: > > From: Cliff Cai > > Signed-off-by: Cliff Cai > Signed-off-by: Bryan Wu > --- > sound/core/pcm_native.c | 8 ++++++++ > 1 files changed, 8 insertions(+), 0 deletions(-) > > diff --git a/sound/core/pcm_native.c b/sound/core/pcm_native.c > index c49b9d9..cb202a1 100644 > --- a/sound/core/pcm_native.c > +++ b/sound/core/pcm_native.c > @@ -3391,6 +3391,12 @@ out: > } > #endif /* CONFIG_SND_SUPPORT_OLD_API */ > > +unsigned long dummy_get_unmapped_area(struct file *file, unsigned long addr, > + unsigned long len, unsigned long pgoff, unsigned long flags) > +{ > + return 0; > +} Always zero is confirmed to work for other architectures, too? > /* > * Register section > */ > @@ -3407,6 +3413,7 @@ const struct file_operations snd_pcm_f_ops[2] = { > .compat_ioctl = snd_pcm_ioctl_compat, > .mmap = snd_pcm_mmap, > .fasync = snd_pcm_fasync, > + .get_unmapped_area = dummy_get_unmapped_area, > }, > { > .owner = THIS_MODULE, > @@ -3419,5 +3426,6 @@ const struct file_operations snd_pcm_f_ops[2] = { > .compat_ioctl = snd_pcm_ioctl_compat, > .mmap = snd_pcm_mmap, > .fasync = snd_pcm_fasync, > + .get_unmapped_area = dummy_get_unmapped_area, > } > }; I don't think adding this dummy get_unmapped_area unconditionally for every driver is good. This overrides the default mm->get_unmaped_area. Takashi -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/