From: Takashi Iwai Subject: Re: [PATCH 1/5] [RFC]intel_hdmi_audio:include header Date: Wed, 24 Nov 2010 10:20:41 +0100 Message-ID: References: <1290433186-31628-1-git-send-email-ramesh.babu@intel.com> 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 mx1.suse.de (cantor.suse.de [195.135.220.2]) by alsa0.perex.cz (Postfix) with ESMTP id 8A276103809 for ; Wed, 24 Nov 2010 10:20:41 +0100 (CET) In-Reply-To: <1290433186-31628-1-git-send-email-ramesh.babu@intel.com> 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: ramesh.babu@intel.com Cc: alsa-devel@alsa-project.org, Sailaja Bandarupalli List-Id: alsa-devel@alsa-project.org In addition to Mark's comments... At Mon, 22 Nov 2010 19:09:42 +0530, ramesh.babu@intel.com wrote: > > +#include > +#include Usually this header isn't needed in the global header file. > +#include "../../../drivers/staging/mrst/drv/mdfld_hdmi_audio_if.h" > +#include "../../../drivers/staging/mrst/drv/psb_intel_hdmi.h" This is bad... If these files are really used over several subsystems, they should be put somewhere in a better public place. > +/** > + * union aud_cfg - Audio configuration offset - 69000 > + * > + * @cfg_regx: individual register bits > + * @cfg_regval: full register value > + * > + * */ > +union aud_cfg { > + struct { > + u32 aud_en:1; > + u32 layout:1; > + u32 fmt:2; > + u32 num_ch:2; > + u32 rsvd0:1; > + u32 set:1; > + u32 flat:1; > + u32 val_bit:1; > + u32 user_bit:1; > + u32 underrun:1; > + u32 rsvd1:20; > + } cfg_regx; > + u32 cfg_regval; > +}; In general, better to avoid bit fields if it's used for the data transfer. The bit-fields are never portable. thanks, Takashi