From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751206Ab0KVHC0 (ORCPT ); Mon, 22 Nov 2010 02:02:26 -0500 Received: from cantor.suse.de ([195.135.220.2]:58375 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750856Ab0KVHCZ (ORCPT ); Mon, 22 Nov 2010 02:02:25 -0500 Date: Mon, 22 Nov 2010 08:02:24 +0100 Message-ID: From: Takashi Iwai To: Florian Fainelli Cc: alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, Jaroslav Kysela Subject: Re: [PATCH] sound/mixart: avoid redefining {readl,write}_{le,be} accessors In-Reply-To: <201011121829.11914.florian@openwrt.org> References: <201011091829.08664.florian@openwrt.org> <201011121829.11914.florian@openwrt.org> User-Agent: Wanderlust/2.15.6 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.7 Emacs/23.1 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) 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 At Fri, 12 Nov 2010 18:29:11 +0100, Florian Fainelli wrote: > > On Tuesday 09 November 2010 18:29:08 Florian Fainelli wrote: > > From: Florian Fainelli > > Takashi, do you have any comments on this patch? Sorry for the late reply. Yes, I already applied it weeks ago, but the reply mail wasn't sent out but stuck in my output queue by some reason during my vacation. Anyway, thanks for the patch. I think it's OK in the way you did for the time being. Ideally, read*_be() should be defined on all platforms, though. Takashi > > Thanks! > > > > > If the platform already provides a definition for these accessors > > do not redefine them. The warning was caught on MIPS. > > > > Signed-off-by: Florian Fainelli > > --- > > diff --git a/sound/pci/mixart/mixart_hwdep.h > > b/sound/pci/mixart/mixart_hwdep.h index a46f508..812e288 100644 > > --- a/sound/pci/mixart/mixart_hwdep.h > > +++ b/sound/pci/mixart/mixart_hwdep.h > > @@ -25,11 +25,21 @@ > > > > #include > > > > +#ifndef readl_be > > #define readl_be(x) be32_to_cpu(__raw_readl(x)) > > +#endif > > + > > +#ifndef writel_be > > #define writel_be(data,addr) __raw_writel(cpu_to_be32(data),addr) > > +#endif > > > > +#ifndef readl_le > > #define readl_le(x) le32_to_cpu(__raw_readl(x)) > > +#endif > > + > > +#ifndef writel_le > > #define writel_le(data,addr) __raw_writel(cpu_to_le32(data),addr) > > +#endif > > > > #define MIXART_MEM(mgr,x) ((mgr)->mem[0].virt + (x)) > > #define MIXART_REG(mgr,x) ((mgr)->mem[1].virt + (x)) >