diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2019-03-28 10:41:38 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2019-03-29 07:44:12 -0400 |
commit | b4a7113f84128ed0acbc5ff886bd5cf4d87ab733 (patch) | |
tree | 5b5984b0d7e4eda050da57a4f30ed70df7c4594c | |
parent | 9c2ccc324b3a6cbc865ab8b3e1a09e93d3c8ade9 (diff) |
media: wl128x: Fix some error handling in fmc_prepare()
The st_register() returns have changed over time, but these days it
never returns -1. We should just be checking for any negative error
codes.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
-rw-r--r-- | drivers/media/radio/wl128x/fmdrv_common.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/radio/wl128x/fmdrv_common.c b/drivers/media/radio/wl128x/fmdrv_common.c index a1fcb80a2191..053d51a5890a 100644 --- a/drivers/media/radio/wl128x/fmdrv_common.c +++ b/drivers/media/radio/wl128x/fmdrv_common.c @@ -1524,7 +1524,7 @@ int fmc_prepare(struct fmdev *fmdev) } ret = 0; - } else if (ret == -1) { + } else if (ret < 0) { fmerr("st_register failed %d\n", ret); return -EAGAIN; } |