Skip to content

Commit

Permalink
ALSA: pcm: Unexport snd_pcm_sgbuf_ops_page
Browse files Browse the repository at this point in the history
The helper is no longer referred after the recent code refactoring.
Drop the export for saving some bits and future misuse.

Acked-by: Mark Brown <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Takashi Iwai <[email protected]>
  • Loading branch information
tiwai committed Nov 9, 2019
1 parent e610748 commit fc7af6b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 10 deletions.
8 changes: 0 additions & 8 deletions include/sound/pcm.h
Original file line number Diff line number Diff line change
Expand Up @@ -1236,14 +1236,6 @@ static inline int snd_pcm_lib_alloc_vmalloc_32_buffer
*/
#define snd_pcm_substream_sgbuf(substream) \
snd_pcm_get_dma_buf(substream)->private_data

struct page *snd_pcm_sgbuf_ops_page(struct snd_pcm_substream *substream,
unsigned long offset);
#else /* !SND_DMA_SGBUF */
/*
* fake using a continuous buffer
*/
#define snd_pcm_sgbuf_ops_page NULL
#endif /* SND_DMA_SGBUF */

/**
Expand Down
5 changes: 5 additions & 0 deletions sound/core/pcm_local.h
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,9 @@ static inline void snd_pcm_timer_done(struct snd_pcm_substream *substream) {}
void __snd_pcm_xrun(struct snd_pcm_substream *substream);
void snd_pcm_group_init(struct snd_pcm_group *group);

#ifdef CONFIG_SND_DMA_SGBUF
struct page *snd_pcm_sgbuf_ops_page(struct snd_pcm_substream *substream,
unsigned long offset);
#endif

#endif /* __SOUND_CORE_PCM_LOCAL_H */
3 changes: 1 addition & 2 deletions sound/core/pcm_memory.c
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ void snd_pcm_lib_preallocate_pages_for_all(struct snd_pcm *pcm,
EXPORT_SYMBOL(snd_pcm_lib_preallocate_pages_for_all);

#ifdef CONFIG_SND_DMA_SGBUF
/**
/*
* snd_pcm_sgbuf_ops_page - get the page struct at the given offset
* @substream: the pcm substream instance
* @offset: the buffer offset
Expand All @@ -273,7 +273,6 @@ struct page *snd_pcm_sgbuf_ops_page(struct snd_pcm_substream *substream, unsigne
return NULL;
return sgbuf->page_table[idx];
}
EXPORT_SYMBOL(snd_pcm_sgbuf_ops_page);
#endif /* CONFIG_SND_DMA_SGBUF */

/**
Expand Down

0 comments on commit fc7af6b

Please sign in to comment.