]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
ASoC: fsi: Move inline fsi_stream_is_play() before use
authorGeert Uytterhoeven <geert@linux-m68k.org>
Tue, 16 May 2017 17:20:00 +0000 (19:20 +0200)
committerMark Brown <broonie@kernel.org>
Wed, 17 May 2017 09:36:05 +0000 (10:36 +0100)
With gcc 4.1.2:

    sound/soc/sh/fsi.c:304: warning: ‘fsi_stream_is_play’ declared inline after being called
    sound/soc/sh/fsi.c:304: warning: previous declaration of ‘fsi_stream_is_play’ was here

Move fsi_stream_is_play() up to fix this, removing the need for a
forward declaration as well.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sh/fsi.c

index ead520182e2684fb4c8109f913e4148ecb4b2227..7c4bdd82bb955bbbd35d5c78f5bd780da4ef7178 100644 (file)
@@ -301,7 +301,12 @@ struct fsi_master {
        spinlock_t lock;
 };
 
-static int fsi_stream_is_play(struct fsi_priv *fsi, struct fsi_stream *io);
+static inline int fsi_stream_is_play(struct fsi_priv *fsi,
+                                    struct fsi_stream *io)
+{
+       return &fsi->playback == io;
+}
+
 
 /*
  *             basic read write function
@@ -489,12 +494,6 @@ static void fsi_count_fifo_err(struct fsi_priv *fsi)
 /*
  *             fsi_stream_xx() function
  */
-static inline int fsi_stream_is_play(struct fsi_priv *fsi,
-                                    struct fsi_stream *io)
-{
-       return &fsi->playback == io;
-}
-
 static inline struct fsi_stream *fsi_stream_get(struct fsi_priv *fsi,
                                        struct snd_pcm_substream *substream)
 {