From cd5915013429e7f2263a7f53ead5f36f9563300a Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Tue, 9 Oct 2007 22:15:27 -0300 Subject: V4L: zc0301, remove bad usage of ERESTARTSYS From: Jiri Slaby zc0301, remove bad usage of ERESTARTSYS down_read_trylock can't be interrupted and so ERESTARTSYS would reach userspace, which is not permitted. Change it to EAGAIN Signed-off-by: Jiri Slaby Acked-by: Luca Risolia Signed-off-by: Mauro Carvalho Chehab --- linux/drivers/media/video/zc0301/zc0301_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'linux/drivers/media') diff --git a/linux/drivers/media/video/zc0301/zc0301_core.c b/linux/drivers/media/video/zc0301/zc0301_core.c index 519fc927c..de6c86be0 100644 --- a/linux/drivers/media/video/zc0301/zc0301_core.c +++ b/linux/drivers/media/video/zc0301/zc0301_core.c @@ -659,7 +659,7 @@ static int zc0301_open(struct inode* inode, struct file* filp) int err = 0; if (!down_read_trylock(&zc0301_dev_lock)) - return -ERESTARTSYS; + return -EAGAIN; cam = video_get_drvdata(video_devdata(filp)); -- cgit v1.2.3