History

ALSA: pcm: Nuke snd_pcm_lib_mmap_vmalloc()

snd_pcm_lib_mmap_vmalloc() was supposed to be implemented with somewhat special for vmalloc handling, but in the end, this turned to just the default handler, i.e. NULL. As the situation has never changed over decades, let's rip it off.

Takashi Iwai committed 8 years ago

Commit fa84cf01 parent ef4db2321 files · +0 −30Browse files

Unified · Split

21 files
  1. drivers/staging/most/sound/sound.c +0 −1
  2. include/sound/pcm.h +0 −2
  3. sound/drivers/aloop.c +0 −1
  4. sound/drivers/vx/vx_pcm.c +0 −2
  5. sound/firewire/bebob/bebob_pcm.c +0 −1
  6. sound/firewire/dice/dice-pcm.c +0 −2
  7. sound/firewire/digi00x/digi00x-pcm.c +0 −1
  8. sound/firewire/fireface/ff-pcm.c +0 −1
  9. sound/firewire/fireworks/fireworks_pcm.c +0 −1
  10. sound/firewire/isight.c +0 −1
  11. sound/firewire/motu/motu-pcm.c +0 −2
  12. sound/firewire/oxfw/oxfw-pcm.c +0 −2
  13. sound/firewire/tascam/tascam-pcm.c +0 −1
  14. sound/mips/sgio2audio.c +0 −3
  15. sound/pcmcia/pdaudiocf/pdaudiocf_pcm.c +0 −1
  16. sound/soc/codecs/rt5514-spi.c +0 −1
  17. sound/usb/6fire/pcm.c +0 −1
  18. sound/usb/caiaq/audio.c +0 −1
  19. sound/usb/hiface/pcm.c +0 −1
  20. sound/usb/misc/ua101.c +0 −2
  21. sound/usb/pcm.c +0 −2
drivers/staging/most/sound/sound.c+0−1
@@ -457,7 +457,6 @@ static const struct snd_pcm_ops pcm_ops = { · 456 unmodified lines
457457 .trigger = pcm_trigger,
458458 .pointer = pcm_pointer,
459459 .page = snd_pcm_lib_get_vmalloc_page,
460− .mmap = snd_pcm_lib_mmap_vmalloc,
461460 };
462461
463462 static int split_arg_list(char *buf, char **card_name, u16 *ch_num,
include/sound/pcm.h+0−2
@@ -1342,8 +1342,6 @@ int snd_pcm_lib_mmap_iomem(struct snd_pcm_substream *substream, struct vm_area_s · 1341 unmodified lines
13421342 #define snd_pcm_lib_mmap_iomem NULL
13431343 #endif
13441344
1345−#define snd_pcm_lib_mmap_vmalloc NULL
1346−
13471345 /**
13481346 * snd_pcm_limit_isa_dma_size - Get the max size fitting with ISA DMA transfer
13491347 * @dma: DMA number
sound/drivers/aloop.c+0−1
@@ -778,7 +778,6 @@ static const struct snd_pcm_ops loopback_pcm_ops = { · 777 unmodified lines
778778 .trigger = loopback_trigger,
779779 .pointer = loopback_pointer,
780780 .page = snd_pcm_lib_get_vmalloc_page,
781− .mmap = snd_pcm_lib_mmap_vmalloc,
782781 };
783782
784783 static int loopback_pcm_new(struct loopback *loopback,
sound/drivers/vx/vx_pcm.c+0−2
@@ -883,7 +883,6 @@ static const struct snd_pcm_ops vx_pcm_playback_ops = { · 882 unmodified lines
883883 .trigger = vx_pcm_trigger,
884884 .pointer = vx_pcm_playback_pointer,
885885 .page = snd_pcm_lib_get_vmalloc_page,
886− .mmap = snd_pcm_lib_mmap_vmalloc,
887886 };
888887
889888
@@ -1105,7 +1104,6 @@ static const struct snd_pcm_ops vx_pcm_capture_ops = { · 215 unmodified lines
11051104 .trigger = vx_pcm_trigger,
11061105 .pointer = vx_pcm_capture_pointer,
11071106 .page = snd_pcm_lib_get_vmalloc_page,
1108− .mmap = snd_pcm_lib_mmap_vmalloc,
11091107 };
11101108
11111109
sound/firewire/bebob/bebob_pcm.c+0−1
@@ -373,7 +373,6 @@ int snd_bebob_create_pcm_devices(struct snd_bebob *bebob) · 372 unmodified lines
373373 .pointer = pcm_playback_pointer,
374374 .ack = pcm_playback_ack,
375375 .page = snd_pcm_lib_get_vmalloc_page,
376− .mmap = snd_pcm_lib_mmap_vmalloc,
377376 };
378377 struct snd_pcm *pcm;
379378 int err;
sound/firewire/dice/dice-pcm.c+0−2
@@ -412,7 +412,6 @@ int snd_dice_create_pcm(struct snd_dice *dice) · 411 unmodified lines
412412 .pointer = capture_pointer,
413413 .ack = capture_ack,
414414 .page = snd_pcm_lib_get_vmalloc_page,
415− .mmap = snd_pcm_lib_mmap_vmalloc,
416415 };
417416 static const struct snd_pcm_ops playback_ops = {
418417 .open = pcm_open,
@@ -425,7 +424,6 @@ int snd_dice_create_pcm(struct snd_dice *dice) · 6 unmodified lines
425424 .pointer = playback_pointer,
426425 .ack = playback_ack,
427426 .page = snd_pcm_lib_get_vmalloc_page,
428− .mmap = snd_pcm_lib_mmap_vmalloc,
429427 };
430428 struct snd_pcm *pcm;
431429 unsigned int capture, playback;
sound/firewire/digi00x/digi00x-pcm.c+0−1
@@ -352,7 +352,6 @@ int snd_dg00x_create_pcm_devices(struct snd_dg00x *dg00x) · 351 unmodified lines
352352 .pointer = pcm_playback_pointer,
353353 .ack = pcm_playback_ack,
354354 .page = snd_pcm_lib_get_vmalloc_page,
355− .mmap = snd_pcm_lib_mmap_vmalloc,
356355 };
357356 struct snd_pcm *pcm;
358357 int err;
sound/firewire/fireface/ff-pcm.c+0−1
@@ -383,7 +383,6 @@ int snd_ff_create_pcm_devices(struct snd_ff *ff) · 382 unmodified lines
383383 .pointer = pcm_playback_pointer,
384384 .ack = pcm_playback_ack,
385385 .page = snd_pcm_lib_get_vmalloc_page,
386− .mmap = snd_pcm_lib_mmap_vmalloc,
387386 };
388387 struct snd_pcm *pcm;
389388 int err;
sound/firewire/fireworks/fireworks_pcm.c+0−1
@@ -397,7 +397,6 @@ int snd_efw_create_pcm_devices(struct snd_efw *efw) · 396 unmodified lines
397397 .pointer = pcm_playback_pointer,
398398 .ack = pcm_playback_ack,
399399 .page = snd_pcm_lib_get_vmalloc_page,
400− .mmap = snd_pcm_lib_mmap_vmalloc,
401400 };
402401 struct snd_pcm *pcm;
403402 int err;
sound/firewire/isight.c+0−1
@@ -454,7 +454,6 @@ static int isight_create_pcm(struct isight *isight) · 453 unmodified lines
454454 .trigger = isight_trigger,
455455 .pointer = isight_pointer,
456456 .page = snd_pcm_lib_get_vmalloc_page,
457− .mmap = snd_pcm_lib_mmap_vmalloc,
458457 };
459458 struct snd_pcm *pcm;
460459 int err;
sound/firewire/motu/motu-pcm.c+0−2
@@ -363,7 +363,6 @@ int snd_motu_create_pcm_devices(struct snd_motu *motu) · 362 unmodified lines
363363 .pointer = capture_pointer,
364364 .ack = capture_ack,
365365 .page = snd_pcm_lib_get_vmalloc_page,
366− .mmap = snd_pcm_lib_mmap_vmalloc,
367366 };
368367 static const struct snd_pcm_ops playback_ops = {
369368 .open = pcm_open,
@@ -376,7 +375,6 @@ int snd_motu_create_pcm_devices(struct snd_motu *motu) · 6 unmodified lines
376375 .pointer = playback_pointer,
377376 .ack = playback_ack,
378377 .page = snd_pcm_lib_get_vmalloc_page,
379− .mmap = snd_pcm_lib_mmap_vmalloc,
380378 };
381379 struct snd_pcm *pcm;
382380 int err;
sound/firewire/oxfw/oxfw-pcm.c+0−2
@@ -389,7 +389,6 @@ int snd_oxfw_create_pcm(struct snd_oxfw *oxfw) · 388 unmodified lines
389389 .pointer = pcm_capture_pointer,
390390 .ack = pcm_capture_ack,
391391 .page = snd_pcm_lib_get_vmalloc_page,
392− .mmap = snd_pcm_lib_mmap_vmalloc,
393392 };
394393 static const struct snd_pcm_ops playback_ops = {
395394 .open = pcm_open,
@@ -402,7 +401,6 @@ int snd_oxfw_create_pcm(struct snd_oxfw *oxfw) · 6 unmodified lines
402401 .pointer = pcm_playback_pointer,
403402 .ack = pcm_playback_ack,
404403 .page = snd_pcm_lib_get_vmalloc_page,
405− .mmap = snd_pcm_lib_mmap_vmalloc,
406404 };
407405 struct snd_pcm *pcm;
408406 unsigned int cap = 0;
sound/firewire/tascam/tascam-pcm.c+0−1
@@ -279,7 +279,6 @@ int snd_tscm_create_pcm_devices(struct snd_tscm *tscm) · 278 unmodified lines
279279 .pointer = pcm_playback_pointer,
280280 .ack = pcm_playback_ack,
281281 .page = snd_pcm_lib_get_vmalloc_page,
282− .mmap = snd_pcm_lib_mmap_vmalloc,
283282 };
284283 struct snd_pcm *pcm;
285284 int err;
sound/mips/sgio2audio.c+0−3
@@ -685,7 +685,6 @@ static const struct snd_pcm_ops snd_sgio2audio_playback1_ops = { · 684 unmodified lines
685685 .trigger = snd_sgio2audio_pcm_trigger,
686686 .pointer = snd_sgio2audio_pcm_pointer,
687687 .page = snd_pcm_lib_get_vmalloc_page,
688− .mmap = snd_pcm_lib_mmap_vmalloc,
689688 };
690689
691690 static const struct snd_pcm_ops snd_sgio2audio_playback2_ops = {
@@ -698,7 +697,6 @@ static const struct snd_pcm_ops snd_sgio2audio_playback2_ops = { · 6 unmodified lines
698697 .trigger = snd_sgio2audio_pcm_trigger,
699698 .pointer = snd_sgio2audio_pcm_pointer,
700699 .page = snd_pcm_lib_get_vmalloc_page,
701− .mmap = snd_pcm_lib_mmap_vmalloc,
702700 };
703701
704702 static const struct snd_pcm_ops snd_sgio2audio_capture_ops = {
@@ -711,7 +709,6 @@ static const struct snd_pcm_ops snd_sgio2audio_capture_ops = { · 6 unmodified lines
711709 .trigger = snd_sgio2audio_pcm_trigger,
712710 .pointer = snd_sgio2audio_pcm_pointer,
713711 .page = snd_pcm_lib_get_vmalloc_page,
714− .mmap = snd_pcm_lib_mmap_vmalloc,
715712 };
716713
717714 /*
sound/pcmcia/pdaudiocf/pdaudiocf_pcm.c+0−1
@@ -276,7 +276,6 @@ static const struct snd_pcm_ops pdacf_pcm_capture_ops = { · 275 unmodified lines
276276 .trigger = pdacf_pcm_trigger,
277277 .pointer = pdacf_pcm_capture_pointer,
278278 .page = snd_pcm_lib_get_vmalloc_page,
279− .mmap = snd_pcm_lib_mmap_vmalloc,
280279 };
281280
282281
sound/soc/codecs/rt5514-spi.c+0−1
@@ -268,7 +268,6 @@ static const struct snd_pcm_ops rt5514_spi_pcm_ops = { · 267 unmodified lines
268268 .hw_params = rt5514_spi_hw_params,
269269 .hw_free = rt5514_spi_hw_free,
270270 .pointer = rt5514_spi_pcm_pointer,
271− .mmap = snd_pcm_lib_mmap_vmalloc,
272271 .page = snd_pcm_lib_get_vmalloc_page,
273272 };
274273
sound/usb/6fire/pcm.c+0−1
@@ -565,7 +565,6 @@ static const struct snd_pcm_ops pcm_ops = { · 564 unmodified lines
565565 .trigger = usb6fire_pcm_trigger,
566566 .pointer = usb6fire_pcm_pointer,
567567 .page = snd_pcm_lib_get_vmalloc_page,
568− .mmap = snd_pcm_lib_mmap_vmalloc,
569568 };
570569
571570 static void usb6fire_pcm_init_urb(struct pcm_urb *urb,
sound/usb/caiaq/audio.c+0−1
@@ -348,7 +348,6 @@ static const struct snd_pcm_ops snd_usb_caiaq_ops = { · 347 unmodified lines
348348 .trigger = snd_usb_caiaq_pcm_trigger,
349349 .pointer = snd_usb_caiaq_pcm_pointer,
350350 .page = snd_pcm_lib_get_vmalloc_page,
351− .mmap = snd_pcm_lib_mmap_vmalloc,
352351 };
353352
354353 static void check_for_elapsed_periods(struct snd_usb_caiaqdev *cdev,
sound/usb/hiface/pcm.c+0−1
@@ -523,7 +523,6 @@ static const struct snd_pcm_ops pcm_ops = { · 522 unmodified lines
523523 .trigger = hiface_pcm_trigger,
524524 .pointer = hiface_pcm_pointer,
525525 .page = snd_pcm_lib_get_vmalloc_page,
526− .mmap = snd_pcm_lib_mmap_vmalloc,
527526 };
528527
529528 static int hiface_pcm_init_urb(struct pcm_urb *urb,
sound/usb/misc/ua101.c+0−2
@@ -900,7 +900,6 @@ static const struct snd_pcm_ops capture_pcm_ops = { · 899 unmodified lines
900900 .trigger = capture_pcm_trigger,
901901 .pointer = capture_pcm_pointer,
902902 .page = snd_pcm_lib_get_vmalloc_page,
903− .mmap = snd_pcm_lib_mmap_vmalloc,
904903 };
905904
906905 static const struct snd_pcm_ops playback_pcm_ops = {
@@ -913,7 +912,6 @@ static const struct snd_pcm_ops playback_pcm_ops = { · 6 unmodified lines
913912 .trigger = playback_pcm_trigger,
914913 .pointer = playback_pcm_pointer,
915914 .page = snd_pcm_lib_get_vmalloc_page,
916− .mmap = snd_pcm_lib_mmap_vmalloc,
917915 };
918916
919917 static const struct uac_format_type_i_discrete_descriptor *
sound/usb/pcm.c+0−2
@@ -1694,7 +1694,6 @@ static const struct snd_pcm_ops snd_usb_playback_ops = { · 1693 unmodified lines
16941694 .trigger = snd_usb_substream_playback_trigger,
16951695 .pointer = snd_usb_pcm_pointer,
16961696 .page = snd_pcm_lib_get_vmalloc_page,
1697− .mmap = snd_pcm_lib_mmap_vmalloc,
16981697 };
16991698
17001699 static const struct snd_pcm_ops snd_usb_capture_ops = {
@@ -1707,7 +1706,6 @@ static const struct snd_pcm_ops snd_usb_capture_ops = { · 6 unmodified lines
17071706 .trigger = snd_usb_substream_capture_trigger,
17081707 .pointer = snd_usb_pcm_pointer,
17091708 .page = snd_pcm_lib_get_vmalloc_page,
1710− .mmap = snd_pcm_lib_mmap_vmalloc,
17111709 };
17121710
17131711 static const struct snd_pcm_ops snd_usb_playback_dev_ops = {