Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 261298
b: refs/heads/master
c: 2c7988a
h: refs/heads/master
v: v3
  • Loading branch information
Hans Petter Selasky authored and Mauro Carvalho Chehab committed Jul 27, 2011
1 parent f2e6135 commit 955f657
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5588dc2b025fd8b2188142b8d59efe562bd57d80
refs/heads/master: 2c7988ab0effa9e41bd9c9db5cb33ddda870ca10
7 changes: 5 additions & 2 deletions trunk/drivers/media/video/sr030pc30.c
Original file line number Diff line number Diff line change
Expand Up @@ -726,8 +726,10 @@ static int sr030pc30_s_power(struct v4l2_subdev *sd, int on)
const struct sr030pc30_platform_data *pdata = info->pdata;
int ret;

if (WARN(pdata == NULL, "No platform data!\n"))
return -ENOMEM;
if (pdata == NULL) {
WARN(1, "No platform data!\n");
return -EINVAL;
}

/*
* Put sensor into power sleep mode before switching off
Expand All @@ -746,6 +748,7 @@ static int sr030pc30_s_power(struct v4l2_subdev *sd, int on)
if (on) {
ret = sr030pc30_base_config(sd);
} else {
ret = 0;
info->curr_win = NULL;
info->curr_fmt = NULL;
}
Expand Down

0 comments on commit 955f657

Please sign in to comment.