summaryrefslogtreecommitdiff
path: root/sound/soc/ti/ams-delta.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/ti/ams-delta.c')
-rw-r--r--sound/soc/ti/ams-delta.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/sound/soc/ti/ams-delta.c b/sound/soc/ti/ams-delta.c
index aba0017e870b..ecd24d412a9b 100644
--- a/sound/soc/ti/ams-delta.c
+++ b/sound/soc/ti/ams-delta.c
@@ -337,8 +337,8 @@ static int cx81801_hangup(struct tty_struct *tty)
}
/* Line discipline .receive_buf() */
-static void cx81801_receive(struct tty_struct *tty,
- const unsigned char *cp, char *fp, int count)
+static void cx81801_receive(struct tty_struct *tty, const unsigned char *cp,
+ const char *fp, int count)
{
struct snd_soc_component *component = tty->disc_data;
const unsigned char *c;
@@ -396,6 +396,7 @@ static void cx81801_wakeup(struct tty_struct *tty)
static struct tty_ldisc_ops cx81801_ops = {
.name = "cx81801",
+ .num = N_V253,
.owner = THIS_MODULE,
.open = cx81801_open,
.close = cx81801_close,
@@ -503,7 +504,7 @@ static int ams_delta_cx20442_init(struct snd_soc_pcm_runtime *rtd)
}
/* Register optional line discipline for over the modem control */
- ret = tty_register_ldisc(N_V253, &cx81801_ops);
+ ret = tty_register_ldisc(&cx81801_ops);
if (ret) {
dev_warn(card->dev,
"Failed to register line discipline, "
@@ -582,9 +583,7 @@ static int ams_delta_remove(struct platform_device *pdev)
{
struct snd_soc_card *card = platform_get_drvdata(pdev);
- if (tty_unregister_ldisc(N_V253) != 0)
- dev_warn(&pdev->dev,
- "failed to unregister V253 line discipline\n");
+ tty_unregister_ldisc(&cx81801_ops);
snd_soc_unregister_card(card);
card->dev = NULL;