aboutsummaryrefslogtreecommitdiffstats
path: root/sound/oss/dmasound
diff options
context:
space:
mode:
Diffstat (limited to 'sound/oss/dmasound')
-rw-r--r--sound/oss/dmasound/dmasound_paula.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sound/oss/dmasound/dmasound_paula.c b/sound/oss/dmasound/dmasound_paula.c
index f163868e7526..541781507e63 100644
--- a/sound/oss/dmasound/dmasound_paula.c
+++ b/sound/oss/dmasound/dmasound_paula.c
@@ -245,6 +245,7 @@ static ssize_t funcname(const u_char *userPtr, size_t userCount, \
245 u_char frame[], ssize_t *frameUsed, \ 245 u_char frame[], ssize_t *frameUsed, \
246 ssize_t frameLeft) \ 246 ssize_t frameLeft) \
247{ \ 247{ \
248 const u_short *ptr = (const u_short *)userPtr; \
248 ssize_t count, used; \ 249 ssize_t count, used; \
249 u_short data; \ 250 u_short data; \
250 \ 251 \
@@ -254,7 +255,7 @@ static ssize_t funcname(const u_char *userPtr, size_t userCount, \
254 count = min_t(size_t, userCount, frameLeft)>>1 & ~1; \ 255 count = min_t(size_t, userCount, frameLeft)>>1 & ~1; \
255 used = count*2; \ 256 used = count*2; \
256 while (count > 0) { \ 257 while (count > 0) { \
257 if (get_user(data, ((u_short *)userPtr)++)) \ 258 if (get_user(data, ptr++)) \
258 return -EFAULT; \ 259 return -EFAULT; \
259 data = convsample(data); \ 260 data = convsample(data); \
260 *high++ = data>>8; \ 261 *high++ = data>>8; \
@@ -269,12 +270,12 @@ static ssize_t funcname(const u_char *userPtr, size_t userCount, \
269 count = min_t(size_t, userCount, frameLeft)>>2 & ~1; \ 270 count = min_t(size_t, userCount, frameLeft)>>2 & ~1; \
270 used = count*4; \ 271 used = count*4; \
271 while (count > 0) { \ 272 while (count > 0) { \
272 if (get_user(data, ((u_short *)userPtr)++)) \ 273 if (get_user(data, ptr++)) \
273 return -EFAULT; \ 274 return -EFAULT; \
274 data = convsample(data); \ 275 data = convsample(data); \
275 *lefth++ = data>>8; \ 276 *lefth++ = data>>8; \
276 *leftl++ = (data>>2) & 0x3f; \ 277 *leftl++ = (data>>2) & 0x3f; \
277 if (get_user(data, ((u_short *)userPtr)++)) \ 278 if (get_user(data, ptr++)) \
278 return -EFAULT; \ 279 return -EFAULT; \
279 data = convsample(data); \ 280 data = convsample(data); \
280 *righth++ = data>>8; \ 281 *righth++ = data>>8; \