Skip to content

Commit b3fa3cf

Browse files
jkrzysztgregkh
authored andcommitted
ASoC: ti: ams-delta: Fix cx81801_receive() argument types
Since types of arguments accepted by tty_ldis_ops::receive_buf() have changed, the driver no longer builds. .../linux/sound/soc/ti/ams-delta.c:403:24: error: initialization of 'void (*)(struct tty_struct *, const u8 *, const u8 *, size_t)' {aka 'void (*)(struct tty_struct *, const unsigned char *, const unsigned char *, unsigned int)'} from incompatible pointer type 'void (*)(struct tty_struct *, const u8 *, const char *, int)' {aka 'void (*)(struct tty_struct *, const unsigned char *, const char *, int)'} [-Werror=incompatible-pointer-types] 403 | .receive_buf = cx81801_receive, Fix it. Fixes: e816144 ("tty: make tty_ldisc_ops::*buf*() hooks operate on size_t") Fixes: 892bc20 ("tty: use u8 for flags") Signed-off-by: Janusz Krzysztofik <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 81a6105 commit b3fa3cf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sound/soc/ti/ams-delta.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -336,8 +336,8 @@ static void cx81801_hangup(struct tty_struct *tty)
336336
}
337337

338338
/* Line discipline .receive_buf() */
339-
static void cx81801_receive(struct tty_struct *tty, const u8 *cp,
340-
const char *fp, int count)
339+
static void cx81801_receive(struct tty_struct *tty, const u8 *cp, const u8 *fp,
340+
size_t count)
341341
{
342342
struct snd_soc_component *component = tty->disc_data;
343343
const unsigned char *c;

0 commit comments

Comments
 (0)