"Fossies" - the Fresh Open Source Software Archive

Member "aoe-aoe6-86/conf/2-patches/old-new.diff" (4 Jul 2015, 1425 Bytes) of archive /linux/misc/aoe-aoe6-86.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Diff source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 diff -upr old/linux/drivers/block/aoe/aoechr.c new/linux/drivers/block/aoe/aoechr.c
    2 --- old/linux/drivers/block/aoe/aoechr.c    2009-01-22 11:52:25.000000000 -0500
    3 +++ new/linux/drivers/block/aoe/aoechr.c    2009-01-22 09:32:45.000000000 -0500
    4 @@ -44,7 +44,7 @@ static int emsgs_head_idx, emsgs_tail_id
    5  static struct semaphore emsgs_sema;
    6  static spinlock_t emsgs_lock;
    7  static int nblocked_emsgs_readers;
    8 -static struct class_simple *aoe_class;
    9 +static struct class *aoe_class;
   10  static struct aoe_chardev chardevs[] = {
   11     { MINOR_ERR, "err" },
   12     { MINOR_DISCOVER, "discover" },
   13 @@ -277,13 +277,13 @@ aoechr_init(void)
   14         printk(KERN_ERR "aoe: can't register char device\n");
   15         return n;
   16     }
   17 -   aoe_class = class_simple_create(THIS_MODULE, "aoe");
   18 +   aoe_class = class_create(THIS_MODULE, "aoe");
   19     if (IS_ERR(aoe_class)) {
   20         unregister_chrdev(AOE_MAJOR, "aoechr");
   21         return PTR_ERR(aoe_class);
   22     }
   23     for (i = 0; i < ARRAY_SIZE(chardevs); ++i)
   24 -       class_simple_device_add(aoe_class,
   25 +       device_create(aoe_class, NULL,
   26                 MKDEV(AOE_MAJOR, chardevs[i].minor),
   27                 NULL, chardevs[i].name);
   28  
   29 @@ -296,8 +296,8 @@ aoechr_exit(void)
   30     int i;
   31  
   32     for (i = 0; i < ARRAY_SIZE(chardevs); ++i)
   33 -       class_simple_device_remove(MKDEV(AOE_MAJOR, chardevs[i].minor));
   34 -   class_simple_destroy(aoe_class);
   35 +       device_destroy(aoe_class, MKDEV(AOE_MAJOR, chardevs[i].minor));
   36 +   class_destroy(aoe_class);
   37     unregister_chrdev(AOE_MAJOR, "aoechr");
   38  }
   39