Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 190987 | Differences between
and this patch

Collapse All | Expand All

(-)work.orig/vmblock-only/linux/filesystem.c (+10 lines)
Lines 116-121 Link Here
116
      return -ENAMETOOLONG;
116
      return -ENAMETOOLONG;
117
   }
117
   }
118
118
119
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 23)
120
   /* Initialize our inode slab allocator */
121
   VMBlockInodeCache = kmem_cache_create("VMBlockInodeCache",
122
                                         sizeof (VMBlockInodeInfo),
123
                                         0,
124
                                         SLAB_HWCACHE_ALIGN,
125
                                         InodeCacheCtor);
126
#else
119
   /* Initialize our inode slab allocator */
127
   /* Initialize our inode slab allocator */
120
   VMBlockInodeCache = kmem_cache_create("VMBlockInodeCache",
128
   VMBlockInodeCache = kmem_cache_create("VMBlockInodeCache",
121
                                         sizeof (VMBlockInodeInfo),
129
                                         sizeof (VMBlockInodeInfo),
Lines 123-128 Link Here
123
                                         SLAB_HWCACHE_ALIGN,
131
                                         SLAB_HWCACHE_ALIGN,
124
                                         InodeCacheCtor,
132
                                         InodeCacheCtor,
125
                                         NULL);
133
                                         NULL);
134
#endif
135
126
   if (!VMBlockInodeCache) {
136
   if (!VMBlockInodeCache) {
127
      Warning("VMBlockInitFileSystem: could not initialize inode cache\n");
137
      Warning("VMBlockInitFileSystem: could not initialize inode cache\n");
128
      return -ENOMEM;
138
      return -ENOMEM;
(-)work.orig/vmblock-only/linux/os.h (+5 lines)
Lines 75-82 Link Here
75
#define os_read_unlock(lock)            read_unlock(lock)
75
#define os_read_unlock(lock)            read_unlock(lock)
76
#define os_write_unlock(lock)           write_unlock(lock)
76
#define os_write_unlock(lock)           write_unlock(lock)
77
77
78
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 23)
79
#define os_kmem_cache_create(name, size, align, flags, ctor, dtor, data) \
80
   kmem_cache_create(name, size, align, flags, ctor)
81
#else
78
#define os_kmem_cache_create(name, size, align, flags, ctor, dtor, data) \
82
#define os_kmem_cache_create(name, size, align, flags, ctor, dtor, data) \
79
   kmem_cache_create(name, size, align, flags, ctor, dtor)
83
   kmem_cache_create(name, size, align, flags, ctor, dtor)
84
#endif
80
#define os_kmem_cache_destroy(cache)    kmem_cache_destroy(cache)
85
#define os_kmem_cache_destroy(cache)    kmem_cache_destroy(cache)
81
#define os_kmem_cache_alloc(cache)      kmem_cache_alloc(cache, GFP_KERNEL)
86
#define os_kmem_cache_alloc(cache)      kmem_cache_alloc(cache, GFP_KERNEL)
82
#define os_kmem_cache_free(cache, elem) kmem_cache_free(cache, elem)
87
#define os_kmem_cache_free(cache, elem) kmem_cache_free(cache, elem)
(-)work.orig/vmmon-only/linux/driver.c (-1 / +3 lines)
Lines 1711-1717 Link Here
1711
	  current->fsuid == current->uid &&
1711
	  current->fsuid == current->uid &&
1712
          current->egid == current->gid &&
1712
          current->egid == current->gid &&
1713
	  current->fsgid == current->gid) {
1713
	  current->fsgid == current->gid) {
1714
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 4, 7)
1714
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 23)
1715
/*	 set_dumpable(current->mm, 1); */ /* this is a GPL-only symbol */
1716
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2, 4, 7)
1715
	 current->mm->dumpable = 1;
1717
	 current->mm->dumpable = 1;
1716
#else
1718
#else
1717
	 current->dumpable = 1;
1719
	 current->dumpable = 1;
(-)work.orig/vmnet-only/driver.c (-1 / +5 lines)
Lines 525-538 Link Here
525
void
525
void
526
cleanup_module(void)
526
cleanup_module(void)
527
{
527
{
528
   unregister_ioctl32_handlers();
529
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 23)
530
   unregister_chrdev(VNET_MAJOR_NUMBER, "vmnet");
531
#else
528
   int retval;
532
   int retval;
529
533
530
   unregister_ioctl32_handlers();
531
   retval =  unregister_chrdev(VNET_MAJOR_NUMBER, "vmnet");
534
   retval =  unregister_chrdev(VNET_MAJOR_NUMBER, "vmnet");
532
   if (retval != 0 ) {
535
   if (retval != 0 ) {
533
      LOG(0, (KERN_WARNING "/dev/vmnet: could not unregister major device %d\n", 
536
      LOG(0, (KERN_WARNING "/dev/vmnet: could not unregister major device %d\n", 
534
	      VNET_MAJOR_NUMBER));
537
	      VNET_MAJOR_NUMBER));
535
   }
538
   }
539
#endif
536
   VNetProtoUnregister();
540
   VNetProtoUnregister();
537
   VNetProc_Cleanup();
541
   VNetProc_Cleanup();
538
#ifdef CONFIG_NETFILTER
542
#ifdef CONFIG_NETFILTER

Return to bug 190987