--- ../alsa-kernel/core/misc.c	2010-01-14 09:24:33.415809949 +0100
+++ misc.c	2010-01-14 09:30:42.691557398 +0100
@@ -1,3 +1,9 @@
+#define __NO_VERSION__
+#include "adriver.h"
+#ifndef KERN_DEFAULT
+#define KERN_DEFAULT	""
+#endif
+
 /*
  *  Misc and compatibility things
  *  Copyright (c) by Jaroslav Kysela <perex@perex.cz>
@@ -42,7 +48,7 @@
 {
 	if (res) {
 		release_resource(res);
-		kfree(res);
+		kfree_nocheck(res);
 	}
 }
 
@@ -143,9 +149,42 @@
 const struct snd_pci_quirk *
 snd_pci_quirk_lookup(struct pci_dev *pci, const struct snd_pci_quirk *list)
 {
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 3, 0)
 	return snd_pci_quirk_lookup_id(pci->subsystem_vendor,
 				       pci->subsystem_device,
 				       list);
+#else
+	unsigned short subsystem_vendor, subsystem_device;
+	pci_read_config_word(pci, PCI_SUBSYSTEM_VENDOR_ID, &subsystem_vendor);
+	pci_read_config_word(pci, PCI_SUBSYSTEM_ID, &subsystem_device);
+	return snd_pci_quirk_lookup_id(subsystem_vendor,
+				       subsystem_device,
+				       list);
+#endif
 }
 EXPORT_SYMBOL(snd_pci_quirk_lookup);
 #endif
+
+/* just for compatibility reason */
+void snd_verbose_printk(const char *file, int line, const char *format, ...)
+{
+	va_list args;
+	va_start(args, format);
+	if (print_snd_pfx(0, file, line, format))
+		format += 3; /* skip the printk level-prefix */
+	vprintk(format, args);
+	va_end(args);
+}
+EXPORT_SYMBOL(snd_verbose_printk);
+
+void snd_verbose_printd(const char *file, int line, const char *format, ...)
+{
+	va_list args;
+	va_start(args, format);
+	if (print_snd_pfx(1, file, line, format))
+		format += 3; /* skip the printk level-prefix */
+	vprintk(format, args);
+	va_end(args);
+
+}
+EXPORT_SYMBOL(snd_verbose_printd);
