From: Takashi Iwai Subject: Re: [PATCH 30/98] hdspm.h: use __u8, __u32 and __u64 from linux/types.h Date: Sun, 31 May 2015 09:11:54 +0200 Message-ID: References: <1433000370-19509-1-git-send-email-mikko.rapeli@iki.fi> <1433000370-19509-31-git-send-email-mikko.rapeli@iki.fi> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: In-Reply-To: <1433000370-19509-31-git-send-email-mikko.rapeli-X3B1VOXEql0@public.gmane.org> Sender: linux-api-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Mikko Rapeli Cc: linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Jaroslav Kysela , alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw@public.gmane.org, linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: alsa-devel@alsa-project.org At Sat, 30 May 2015 17:38:22 +0200, Mikko Rapeli wrote: >=20 > Fixes userspace compilation errors like: >=20 > sound/hdspm.h:43:2: error: unknown type name =E2=80=98uint32_t=E2=80=99 Hmm, how do you get this error at all? The header includes stdint.h for user-space. thanks, Takashi >=20 > Signed-off-by: Mikko Rapeli > --- > include/uapi/sound/hdspm.h | 40 ++++++++++++++++++------------------= ---- > 1 file changed, 18 insertions(+), 22 deletions(-) >=20 > diff --git a/include/uapi/sound/hdspm.h b/include/uapi/sound/hdspm.h > index 5737332..c4db6f5 100644 > --- a/include/uapi/sound/hdspm.h > +++ b/include/uapi/sound/hdspm.h > @@ -20,11 +20,7 @@ > * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. > */ > =20 > -#ifdef __KERNEL__ > #include > -#else > -#include > -#endif > =20 > /* Maximum channels is 64 even on 56Mode you have 64playbacks to mat= rix */ > #define HDSPM_MAX_CHANNELS 64 > @@ -46,15 +42,15 @@ enum hdspm_speed { > /* -------------------- IOCTL Peak/RMS Meters -------------------- *= / > =20 > struct hdspm_peak_rms { > - uint32_t input_peaks[64]; > - uint32_t playback_peaks[64]; > - uint32_t output_peaks[64]; > + __u32 input_peaks[64]; > + __u32 playback_peaks[64]; > + __u32 output_peaks[64]; > =20 > - uint64_t input_rms[64]; > - uint64_t playback_rms[64]; > - uint64_t output_rms[64]; > + __u64 input_rms[64]; > + __u64 playback_rms[64]; > + __u64 output_rms[64]; > =20 > - uint8_t speed; /* enum {ss, ds, qs} */ > + __u8 speed; /* enum {ss, ds, qs} */ > int status2; > }; > =20 > @@ -155,21 +151,21 @@ enum hdspm_syncsource { > }; > =20 > struct hdspm_status { > - uint8_t card_type; /* enum hdspm_io_type */ > + __u8 card_type; /* enum hdspm_io_type */ > enum hdspm_syncsource autosync_source; > =20 > - uint64_t card_clock; > - uint32_t master_period; > + __u64 card_clock; > + __u32 master_period; > =20 > union { > struct { > - uint8_t sync_wc; /* enum hdspm_sync */ > - uint8_t sync_madi; /* enum hdspm_sync */ > - uint8_t sync_tco; /* enum hdspm_sync */ > - uint8_t sync_in; /* enum hdspm_sync */ > - uint8_t madi_input; /* enum hdspm_madi_input */ > - uint8_t channel_format; /* enum hdspm_madi_channel_format */ > - uint8_t frame_format; /* enum hdspm_madi_frame_format */ > + __u8 sync_wc; /* enum hdspm_sync */ > + __u8 sync_madi; /* enum hdspm_sync */ > + __u8 sync_tco; /* enum hdspm_sync */ > + __u8 sync_in; /* enum hdspm_sync */ > + __u8 madi_input; /* enum hdspm_madi_input */ > + __u8 channel_format; /* enum hdspm_madi_channel_format */ > + __u8 frame_format; /* enum hdspm_madi_frame_format */ > } madi; > } card_specific; > }; > @@ -184,7 +180,7 @@ struct hdspm_status { > #define HDSPM_ADDON_TCO 1 > =20 > struct hdspm_version { > - uint8_t card_type; /* enum hdspm_io_type */ > + __u8 card_type; /* enum hdspm_io_type */ > char cardname[20]; > unsigned int serial; > unsigned short firmware_rev; > --=20 > 2.1.4 >=20