All of lore.kernel.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: alsa-devel@alsa-project.org
Subject: [alsa-devel] [PATCH 4/5] ALSA: uapi: Fix typos and header inclusion in asound.h
Date: Fri, 20 Dec 2019 16:34:14 +0100	[thread overview]
Message-ID: <20191220153415.2740-5-tiwai@suse.de> (raw)
In-Reply-To: <20191220153415.2740-1-tiwai@suse.de>

The recent changes in uapi/asoundlib.h caused some build errors in
alsa-lib side because of a typo and the new included files.
Basically asound.h is supposed to be usable also on non-Linux systems,
so we've tried to avoid the Linux-specific include files.

This patch is an attempt to recover from those changes.

Fixes: 3ddee7f88aaf ("ALSA: Avoid using timespec for struct snd_pcm_status")
Fixes: 80fe7430c708 ("ALSA: add new 32-bit layout for snd_pcm_mmap_status/control")
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
 include/uapi/sound/asound.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/uapi/sound/asound.h b/include/uapi/sound/asound.h
index e6a958b8aff1..e7943302359e 100644
--- a/include/uapi/sound/asound.h
+++ b/include/uapi/sound/asound.h
@@ -26,7 +26,9 @@
 
 #if defined(__KERNEL__) || defined(__linux__)
 #include <linux/types.h>
+#include <asm/byteorder.h>
 #else
+#include <endian.h>
 #include <sys/ioctl.h>
 #endif
 
@@ -35,8 +37,6 @@
 #include <time.h>
 #endif
 
-#include <asm/byteorder.h>
-
 /*
  *  protocol version
  */
@@ -471,7 +471,7 @@ enum {
 
 #ifndef __KERNEL__
 /* explicit padding avoids incompatibility between i386 and x86-64 */
-typedef struct { unsigned char pad[sizeof(time_t) - sizeof(int)] __time_pad;
+typedef struct { unsigned char pad[sizeof(time_t) - sizeof(int)]; } __time_pad;
 
 struct snd_pcm_status {
 	snd_pcm_state_t state;		/* stream state */
-- 
2.16.4

_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
https://mailman.alsa-project.org/mailman/listinfo/alsa-devel

  parent reply	other threads:[~2019-12-20 15:37 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-20 15:34 [alsa-devel] [PATCH 0/5] ALSA: Fix uapi headers Takashi Iwai
2019-12-20 15:34 ` [alsa-devel] [PATCH 1/5] ALSA: emu10k1: Make uapi/emu10k1.h compilable again Takashi Iwai
2019-12-20 15:34 ` [alsa-devel] [PATCH 2/5] ALSA: hdsp: Make uapi/hdsp.h " Takashi Iwai
2019-12-20 15:34 ` [alsa-devel] [PATCH 3/5] ALSA: hdspm: Drop linux/types.h inclusion in uapi header Takashi Iwai
2019-12-20 15:34 ` Takashi Iwai [this message]
2019-12-20 15:34 ` [alsa-devel] [PATCH 5/5] ALSA: uapi: Drop asound.h inclusion from asoc.h Takashi Iwai
2020-03-30 16:53   ` Dmitry V. Levin
2020-03-30 19:11     ` Takashi Iwai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191220153415.2740-5-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=alsa-devel@alsa-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.