summaryrefslogtreecommitdiff
path: root/media-tv/wis-go7007/files/snd.patch
blob: 26c864671c2dc4a3b422af11b3606c8d9b8dd75e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
diff -ur wis-go7007-linux-0.9.8.old/kernel/snd-go7007.c wis-go7007-linux-0.9.8/kernel/snd-go7007.c
--- wis-go7007-linux-0.9.8.old/kernel/snd-go7007.c	2007-07-16 19:54:38.736387914 +0100
+++ wis-go7007-linux-0.9.8/kernel/snd-go7007.c	2007-07-16 19:56:18.309084853 +0100
@@ -58,9 +58,9 @@
 MODULE_PARM_DESC(index, "Enable for the go7007 audio driver");
 
 struct go7007_snd {
-	snd_card_t *card;
-	snd_pcm_t *pcm;
-	snd_pcm_substream_t *substream;
+	struct snd_card *card;
+	struct snd_pcm *pcm;
+	struct snd_pcm_substream *substream;
 	spinlock_t lock;
 	int w_idx;
 	int hw_ptr;
@@ -68,7 +68,7 @@
 	int capturing;
 };
 
-static snd_pcm_hardware_t go7007_snd_capture_hw = {
+static struct snd_pcm_hardware go7007_snd_capture_hw = {
 	.info			= (SNDRV_PCM_INFO_MMAP |
 					SNDRV_PCM_INFO_INTERLEAVED |
 					SNDRV_PCM_INFO_BLOCK_TRANSFER |
@@ -89,7 +89,7 @@
 static void parse_audio_stream_data(struct go7007 *go, u8 *buf, int length)
 {
 	struct go7007_snd *gosnd = go->snd_context;
-	snd_pcm_runtime_t *runtime = gosnd->substream->runtime;
+	struct snd_pcm_runtime *runtime = gosnd->substream->runtime;
 	int frames = bytes_to_frames(runtime, length);
 
 	spin_lock(&gosnd->lock);
@@ -119,8 +119,8 @@
 		snd_pcm_period_elapsed(gosnd->substream);
 }
 
-static int go7007_snd_hw_params(snd_pcm_substream_t *substream,
-				snd_pcm_hw_params_t *hw_params)
+static int go7007_snd_hw_params(struct snd_pcm_substream *substream,
+				struct snd_pcm_hw_params *hw_params)
 {
 	struct go7007 *go = snd_pcm_substream_chip(substream);
 	unsigned int bytes;
@@ -137,7 +137,7 @@
 	return 0;
 }
 
-static int go7007_snd_hw_free(snd_pcm_substream_t *substream)
+static int go7007_snd_hw_free(struct snd_pcm_substream *substream)
 {
 	struct go7007 *go = snd_pcm_substream_chip(substream);
 
@@ -148,7 +148,7 @@
 	return 0;
 }
 
-static int go7007_snd_capture_open(snd_pcm_substream_t *substream)
+static int go7007_snd_capture_open(struct snd_pcm_substream *substream)
 {
 	struct go7007 *go = snd_pcm_substream_chip(substream);
 	struct go7007_snd *gosnd = go->snd_context;
@@ -166,7 +166,7 @@
 	return r;
 }
 
-static int go7007_snd_capture_close(snd_pcm_substream_t *substream)
+static int go7007_snd_capture_close(struct snd_pcm_substream *substream)
 {
 	struct go7007 *go = snd_pcm_substream_chip(substream);
 	struct go7007_snd *gosnd = go->snd_context;
@@ -175,12 +175,12 @@
 	return 0;
 }
 
-static int go7007_snd_pcm_prepare(snd_pcm_substream_t *substream)
+static int go7007_snd_pcm_prepare(struct snd_pcm_substream *substream)
 {
 	return 0;
 }
 
-static int go7007_snd_pcm_trigger(snd_pcm_substream_t *substream, int cmd)
+static int go7007_snd_pcm_trigger(struct snd_pcm_substream *substream, int cmd)
 {
 	struct go7007 *go = snd_pcm_substream_chip(substream);
 	struct go7007_snd *gosnd = go->snd_context;
@@ -200,7 +200,7 @@
 	}
 }
 
-static snd_pcm_uframes_t go7007_snd_pcm_pointer(snd_pcm_substream_t *substream)
+static snd_pcm_uframes_t go7007_snd_pcm_pointer(struct snd_pcm_substream *substream)
 {
 	struct go7007 *go = snd_pcm_substream_chip(substream);
 	struct go7007_snd *gosnd = go->snd_context;
@@ -208,13 +208,13 @@
 	return gosnd->hw_ptr;
 }
 
-static struct page *go7007_snd_pcm_page(snd_pcm_substream_t *substream,
+static struct page *go7007_snd_pcm_page(struct snd_pcm_substream *substream,
 					unsigned long offset)
 {
 	return vmalloc_to_page(substream->runtime->dma_area + offset);
 }
 
-static snd_pcm_ops_t go7007_snd_capture_ops = {
+static struct snd_pcm_ops go7007_snd_capture_ops = {
 	.open		= go7007_snd_capture_open,
 	.close		= go7007_snd_capture_close,
 	.ioctl		= snd_pcm_lib_ioctl,
@@ -226,7 +226,7 @@
 	.page		= go7007_snd_pcm_page,
 };
 
-static int go7007_snd_free(snd_device_t *device)
+static int go7007_snd_free(struct snd_device *device)
 {
 	struct go7007 *go = device->device_data;
 
@@ -237,7 +237,7 @@
 	return 0;
 }
 
-static snd_device_ops_t go7007_snd_device_ops = {
+static struct snd_device_ops go7007_snd_device_ops = {
 	.dev_free	= go7007_snd_free,
 };