From: Takashi Iwai Subject: Re: [PATCH - [hdspm] RayDAT/AIO 1/2] ALSA: Add support for RME RayDAT and AIO Date: Thu, 27 Jan 2011 09:04:57 +0100 Message-ID: References: <1296066735-11280-1-git-send-email-adi@drcomp.erfurt.thur.de> <1296066735-11280-2-git-send-email-adi@drcomp.erfurt.thur.de> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 13853103810 for ; Thu, 27 Jan 2011 09:05:00 +0100 (CET) In-Reply-To: <1296066735-11280-2-git-send-email-adi@drcomp.erfurt.thur.de> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: Adrian Knoth Cc: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org At Wed, 26 Jan 2011 19:32:14 +0100, Adrian Knoth wrote: > > diff --git a/include/sound/hdspm.h b/include/sound/hdspm.h > index 81990b2..c3f1819 100644 > --- a/include/sound/hdspm.h > +++ b/include/sound/hdspm.h > @@ -131,4 +225,175 @@ typedef struct hdspm_version hdspm_version_t; > typedef struct hdspm_channelfader snd_hdspm_channelfader_t; > typedef struct hdspm_mixer hdspm_mixer_t; > > -#endif /* __SOUND_HDSPM_H */ > +/* These tables map the ALSA channels 1..N to the channels that we > + need to use in order to find the relevant channel buffer. RME > + refers to this kind of mapping as between "the ADAT channel and > + the DMA channel." We index it using the logical audio channel, > + and the value is the DMA channel (i.e. channel buffer number) > + where the data for that channel can be read/written from/to. > +*/ > + > +char channel_map_unity_ss[HDSPM_MAX_CHANNELS] = { Err, no, array definitions should be never in a header file. It doesn't matter whether it's static or not. The definition should be in *.c file where it's used. So, simply move these array definitions to hdspm.c. thanks, Takashi