--- ../../alsa-kernel/core/info.c	Sun Oct 17 22:28:15 2004
+++ info.c	Sun Oct 17 22:28:54 2004
@@ -1,3 +1,4 @@
+#include "info.inc"
 /*
  *  Information interface for ALSA driver
  *  Copyright (c) by Jaroslav Kysela <perex@suse.cz>
@@ -20,6 +21,7 @@
  */
 
 #include <sound/driver.h>
+#include <linux/version.h>
 #include <linux/init.h>
 #include <linux/vmalloc.h>
 #include <linux/time.h>
@@ -120,6 +122,7 @@
 snd_info_entry_t *snd_oss_root = NULL;
 #endif
 
+#ifndef LINUX_2_2
 static inline void snd_info_entry_prepare(struct proc_dir_entry *de)
 {
 	de->owner = THIS_MODULE;
@@ -131,6 +134,7 @@
 	if (de)
 		remove_proc_entry(de->name, parent);
 }
+#endif
 
 static loff_t snd_info_entry_llseek(struct file *file, loff_t offset, int orig)
 {
@@ -140,7 +144,9 @@
 
 	data = file->private_data;
 	entry = data->entry;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 3)
 	lock_kernel();
+#endif
 	switch (entry->content) {
 	case SNDRV_INFO_CONTENT_TEXT:
 		switch (orig) {
@@ -169,7 +175,9 @@
 	}
 	ret = -ENXIO;
 out:
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 3)
 	unlock_kernel();
+#endif
 	return ret;
 }
 
@@ -499,7 +507,9 @@
 
 static struct file_operations snd_info_entry_operations =
 {
+#ifndef LINUX_2_2
 	.owner =	THIS_MODULE,
+#endif
 	.llseek =	snd_info_entry_llseek,
 	.read =		snd_info_entry_read,
 	.write =	snd_info_entry_write,
@@ -510,6 +520,13 @@
 	.release =	snd_info_entry_release,
 };
 
+#ifdef LINUX_2_2
+static struct inode_operations snd_info_entry_inode_operations =
+{
+	&snd_info_entry_operations,     /* default sound info directory file-ops */
+};
+#endif
+
 /**
  * snd_create_proc_entry - create a procfs entry
  * @name: the name of the proc file
@@ -918,9 +935,16 @@
 		up(&info_mutex);
 		return -ENOMEM;
 	}
+#ifndef LINUX_2_2
 	p->owner = entry->module;
-	if (!S_ISDIR(entry->mode))
+#endif
+	if (!S_ISDIR(entry->mode)) {
+#ifndef LINUX_2_2
 		p->proc_fops = &snd_info_entry_operations;
+#else
+		p->ops = &snd_info_entry_inode_operations;
+#endif
+	}
 	p->size = entry->size;
 	p->data = entry;
 	entry->p = p;
@@ -958,9 +982,19 @@
 
 static void snd_info_version_read(snd_info_entry_t *entry, snd_info_buffer_t * buffer)
 {
+	static char *kernel_version = UTS_RELEASE;
+
 	snd_iprintf(buffer,
 		    "Advanced Linux Sound Architecture Driver Version "
 		    CONFIG_SND_VERSION CONFIG_SND_DATE ".\n"
+		    "Compiled on " __DATE__ " for kernel %s"
+#ifdef CONFIG_SMP
+		    " (SMP)"
+#endif
+#ifdef MODVERSIONS
+		    " with versioned symbols"
+#endif
+		    ".\n", kernel_version
 		   );
 }
 
