aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2012-02-03 03:51:14 -0500
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-02-03 06:55:38 -0500
commitd78629e2a4457149bd21fdb0cdbbb1c3ec019d96 (patch)
tree069842d5b825ed22817f145f56f31685bedccb5f
parent376cf38a90507f82d22b951b7776557aefe6109c (diff)
ASoC: fsi: rename fsi_dma_soft_xxx() to fsi_pio_xxx()
This is preparation for DMAEngine support Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
-rw-r--r--sound/soc/sh/fsi.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/sound/soc/sh/fsi.c b/sound/soc/sh/fsi.c
index cbb5643794b3..05307acb2bd3 100644
--- a/sound/soc/sh/fsi.c
+++ b/sound/soc/sh/fsi.c
@@ -474,10 +474,10 @@ static void fsi_stream_pop(struct fsi_priv *fsi, int is_play)
474} 474}
475 475
476/* 476/*
477 * dma function 477 * pio function
478 */ 478 */
479 479
480static u8 *fsi_dma_get_area(struct fsi_priv *fsi, int stream) 480static u8 *fsi_pio_get_area(struct fsi_priv *fsi, int stream)
481{ 481{
482 int is_play = fsi_stream_is_play(stream); 482 int is_play = fsi_stream_is_play(stream);
483 struct fsi_stream *io = fsi_stream_get(fsi, is_play); 483 struct fsi_stream *io = fsi_stream_get(fsi, is_play);
@@ -487,47 +487,47 @@ static u8 *fsi_dma_get_area(struct fsi_priv *fsi, int stream)
487 samples_to_bytes(runtime, io->buff_sample_pos); 487 samples_to_bytes(runtime, io->buff_sample_pos);
488} 488}
489 489
490static void fsi_dma_soft_push16(struct fsi_priv *fsi, int num) 490static void fsi_pio_push16(struct fsi_priv *fsi, int num)
491{ 491{
492 u16 *start; 492 u16 *start;
493 int i; 493 int i;
494 494
495 start = (u16 *)fsi_dma_get_area(fsi, SNDRV_PCM_STREAM_PLAYBACK); 495 start = (u16 *)fsi_pio_get_area(fsi, SNDRV_PCM_STREAM_PLAYBACK);
496 496
497 for (i = 0; i < num; i++) 497 for (i = 0; i < num; i++)
498 fsi_reg_write(fsi, DODT, ((u32)*(start + i) << 8)); 498 fsi_reg_write(fsi, DODT, ((u32)*(start + i) << 8));
499} 499}
500 500
501static void fsi_dma_soft_pop16(struct fsi_priv *fsi, int num) 501static void fsi_pio_pop16(struct fsi_priv *fsi, int num)
502{ 502{
503 u16 *start; 503 u16 *start;
504 int i; 504 int i;
505 505
506 start = (u16 *)fsi_dma_get_area(fsi, SNDRV_PCM_STREAM_CAPTURE); 506 start = (u16 *)fsi_pio_get_area(fsi, SNDRV_PCM_STREAM_CAPTURE);
507 507
508 508
509 for (i = 0; i < num; i++) 509 for (i = 0; i < num; i++)
510 *(start + i) = (u16)(fsi_reg_read(fsi, DIDT) >> 8); 510 *(start + i) = (u16)(fsi_reg_read(fsi, DIDT) >> 8);
511} 511}
512 512
513static void fsi_dma_soft_push32(struct fsi_priv *fsi, int num) 513static void fsi_pio_push32(struct fsi_priv *fsi, int num)
514{ 514{
515 u32 *start; 515 u32 *start;
516 int i; 516 int i;
517 517
518 start = (u32 *)fsi_dma_get_area(fsi, SNDRV_PCM_STREAM_PLAYBACK); 518 start = (u32 *)fsi_pio_get_area(fsi, SNDRV_PCM_STREAM_PLAYBACK);
519 519
520 520
521 for (i = 0; i < num; i++) 521 for (i = 0; i < num; i++)
522 fsi_reg_write(fsi, DODT, *(start + i)); 522 fsi_reg_write(fsi, DODT, *(start + i));
523} 523}
524 524
525static void fsi_dma_soft_pop32(struct fsi_priv *fsi, int num) 525static void fsi_pio_pop32(struct fsi_priv *fsi, int num)
526{ 526{
527 u32 *start; 527 u32 *start;
528 int i; 528 int i;
529 529
530 start = (u32 *)fsi_dma_get_area(fsi, SNDRV_PCM_STREAM_CAPTURE); 530 start = (u32 *)fsi_pio_get_area(fsi, SNDRV_PCM_STREAM_CAPTURE);
531 531
532 for (i = 0; i < num; i++) 532 for (i = 0; i < num; i++)
533 *(start + i) = fsi_reg_read(fsi, DIDT); 533 *(start + i) = fsi_reg_read(fsi, DIDT);
@@ -812,8 +812,8 @@ static int fsi_data_pop(struct fsi_priv *fsi)
812 samples = min(sample_residues, sample_space); 812 samples = min(sample_residues, sample_space);
813 813
814 return fsi_fifo_data_ctrl(fsi, io, 814 return fsi_fifo_data_ctrl(fsi, io,
815 fsi_dma_soft_pop16, 815 fsi_pio_pop16,
816 fsi_dma_soft_pop32, 816 fsi_pio_pop32,
817 samples); 817 samples);
818} 818}
819 819
@@ -832,8 +832,8 @@ static int fsi_data_push(struct fsi_priv *fsi)
832 samples = min(sample_residues, sample_space); 832 samples = min(sample_residues, sample_space);
833 833
834 return fsi_fifo_data_ctrl(fsi, io, 834 return fsi_fifo_data_ctrl(fsi, io,
835 fsi_dma_soft_push16, 835 fsi_pio_push16,
836 fsi_dma_soft_push32, 836 fsi_pio_push32,
837 samples); 837 samples);
838} 838}
839 839