Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 195871
b: refs/heads/master
c: 4d3a853
h: refs/heads/master
i:
  195869: 7774845
  195867: 7a062a4
  195863: a91f612
  195855: a9a08c5
  195839: bf32a9c
v: v3
  • Loading branch information
Ben Hutchings authored and David Woodhouse committed Feb 25, 2010
1 parent 03e1012 commit d1b65b3
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: b520e412faaaad35641aeedd6059179f9f1b393c
refs/heads/master: 4d3a8534bdbcf4843fc8ad05c9a81a964fc65237
7 changes: 5 additions & 2 deletions trunk/drivers/mtd/mtd_blkdevs.c
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,12 @@ int add_mtd_blktrans_dev(struct mtd_blktrans_dev *new)
if (new->devnum == -1)
new->devnum = last_devnum+1;

if ((new->devnum << tr->part_bits) > 256) {
/* Check that the device and any partitions will get valid
* minor numbers and that the disk naming code below can cope
* with this number. */
if (new->devnum > (MINORMASK >> tr->part_bits) ||
(tr->part_bits && new->devnum >= 27 * 26))
return -EBUSY;
}

list_add_tail(&new->list, &tr->devs);
added:
Expand Down

0 comments on commit d1b65b3

Please sign in to comment.