Changeset 19709


Ignore:
Timestamp:
2010-02-18T22:34:49+01:00 (6 years ago)
Author:
nbd
Message:

fix a compile error in block2mtd when compiled as module

Location:
trunk/target/linux/generic-2.6
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/generic-2.6/patches-2.6.30/065-rootfs_split.patch

    r16944 r19709  
    442442                        bdev = open_by_devnum(devt, FMODE_WRITE | FMODE_READ); 
    443443                } 
    444 @@ -263,17 +276,97 @@ static struct block2mtd_dev *add_device( 
     444@@ -263,17 +276,98 @@ static struct block2mtd_dev *add_device( 
    445445 #endif 
    446446  
     
    506506+       if (!bdev || !bdev->bd_disk) 
    507507+               err = -EINVAL; 
    508 +       else { 
     508+#ifndef CONFIG_MTD_BLOCK2MTD_MODULE 
     509+       else 
    509510+               err = rescan_partitions(bdev->bd_disk, bdev); 
    510 +       } 
     511+#endif 
    511512+       if (bdev) 
    512513+               close_bdev_exclusive(bdev, FMODE_READ|FMODE_WRITE); 
     
    543544        if (!mtdname) 
    544545                mtdname = devname; 
    545 @@ -297,6 +390,7 @@ static struct block2mtd_dev *add_device( 
     546@@ -297,6 +391,7 @@ static struct block2mtd_dev *add_device( 
    546547        dev->mtd.read = block2mtd_read; 
    547548        dev->mtd.priv = dev; 
  • trunk/target/linux/generic-2.6/patches-2.6.31/065-rootfs_split.patch

    r18007 r19709  
    435435                        bdev = open_by_devnum(devt, FMODE_WRITE | FMODE_READ); 
    436436                } 
    437 @@ -263,17 +276,97 @@ static struct block2mtd_dev *add_device( 
     437@@ -263,17 +276,98 @@ static struct block2mtd_dev *add_device( 
    438438 #endif 
    439439  
     
    499499+       if (!bdev || !bdev->bd_disk) 
    500500+               err = -EINVAL; 
    501 +       else { 
     501+#ifndef CONFIG_MTD_BLOCK2MTD_MODULE 
     502+       else 
    502503+               err = rescan_partitions(bdev->bd_disk, bdev); 
    503 +       } 
     504+#endif 
    504505+       if (bdev) 
    505506+               close_bdev_exclusive(bdev, FMODE_READ|FMODE_WRITE); 
     
    536537        if (!mtdname) 
    537538                mtdname = devname; 
    538 @@ -297,6 +390,7 @@ static struct block2mtd_dev *add_device( 
     539@@ -297,6 +391,7 @@ static struct block2mtd_dev *add_device( 
    539540        dev->mtd.read = block2mtd_read; 
    540541        dev->mtd.priv = dev; 
  • trunk/target/linux/generic-2.6/patches-2.6.32/065-rootfs_split.patch

    r18283 r19709  
    435435                        bdev = open_by_devnum(devt, FMODE_WRITE | FMODE_READ); 
    436436                } 
    437 @@ -263,17 +276,97 @@ static struct block2mtd_dev *add_device( 
     437@@ -263,17 +276,98 @@ static struct block2mtd_dev *add_device( 
    438438 #endif 
    439439  
     
    499499+       if (!bdev || !bdev->bd_disk) 
    500500+               err = -EINVAL; 
    501 +       else { 
     501+#ifndef CONFIG_MTD_BLOCK2MTD_MODULE 
     502+       else 
    502503+               err = rescan_partitions(bdev->bd_disk, bdev); 
    503 +       } 
     504+#endif 
    504505+       if (bdev) 
    505506+               close_bdev_exclusive(bdev, FMODE_READ|FMODE_WRITE); 
     
    536537        if (!mtdname) 
    537538                mtdname = devname; 
    538 @@ -297,6 +390,7 @@ static struct block2mtd_dev *add_device( 
     539@@ -297,6 +391,7 @@ static struct block2mtd_dev *add_device( 
    539540        dev->mtd.read = block2mtd_read; 
    540541        dev->mtd.priv = dev; 
Note: See TracChangeset for help on using the changeset viewer.