Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 282910
b: refs/heads/master
c: 27c151a
h: refs/heads/master
v: v3
  • Loading branch information
Artem Bityutskiy authored and David Woodhouse committed Jan 9, 2012
1 parent 6c25dba commit c9bb90f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 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: b6de3d6cb63427178c4f1df88b81d1ceee637e6f
refs/heads/master: 27c151a5e52efaa46d0938984f2ef591bdcb6d5b
4 changes: 0 additions & 4 deletions trunk/drivers/mtd/mtdchar.c
Original file line number Diff line number Diff line change
Expand Up @@ -310,10 +310,6 @@ static ssize_t mtdchar_write(struct file *file, const char __user *buf, size_t c
ret = -EROFS;
break;
case MTD_FILE_MODE_OTP_USER:
if (!mtd->write_user_prot_reg) {
ret = -EOPNOTSUPP;
break;
}
ret = mtd_write_user_prot_reg(mtd, *ppos, len,
&retlen, kbuf);
break;
Expand Down
2 changes: 2 additions & 0 deletions trunk/include/linux/mtd/mtd.h
Original file line number Diff line number Diff line change
Expand Up @@ -381,6 +381,8 @@ static inline int mtd_write_user_prot_reg(struct mtd_info *mtd, loff_t to,
u_char *buf)
{
*retlen = 0;
if (!mtd->write_user_prot_reg)
return -EOPNOTSUPP;
return mtd->write_user_prot_reg(mtd, to, len, retlen, buf);
}

Expand Down

0 comments on commit c9bb90f

Please sign in to comment.