Re: [Patch] Fix compilation for sound/oss/vwsnd.c

From: Eric Sesterhenn
Date: Thu Mar 23 2006 - 17:06:15 EST


sorry,

fixed patch below between all the switching i forgot to remove
the declaration in li_create()

Signed-off-by: Eric Sesterhenn <snakebyte@xxxxxx>


--- linux-2.6.16-git6/sound/oss/vwsnd.c 2006-03-23 23:07:15.000000000 +0100
+++ linux-2.6.16-git6.new/sound/oss/vwsnd.c 2006-03-23 23:07:32.000000000 +0100
@@ -247,27 +247,6 @@ typedef struct lithium {
} lithium_t;

/*
- * li_create initializes the lithium_t structure and sets up vm mappings
- * to access the registers.
- * Returns 0 on success, -errno on failure.
- */
-
-static int __init li_create(lithium_t *lith, unsigned long baseaddr)
-{
- static void li_destroy(lithium_t *);
-
- spin_lock_init(&lith->lock);
- lith->page0 = ioremap_nocache(baseaddr + LI_PAGE0_OFFSET, PAGE_SIZE);
- lith->page1 = ioremap_nocache(baseaddr + LI_PAGE1_OFFSET, PAGE_SIZE);
- lith->page2 = ioremap_nocache(baseaddr + LI_PAGE2_OFFSET, PAGE_SIZE);
- if (!lith->page0 || !lith->page1 || !lith->page2) {
- li_destroy(lith);
- return -ENOMEM;
- }
- return 0;
-}
-
-/*
* li_destroy destroys the lithium_t structure and vm mappings.
*/

@@ -288,6 +267,25 @@ static void li_destroy(lithium_t *lith)
}

/*
+ * li_create initializes the lithium_t structure and sets up vm mappings
+ * to access the registers.
+ * Returns 0 on success, -errno on failure.
+ */
+
+static int __init li_create(lithium_t *lith, unsigned long baseaddr)
+{
+ spin_lock_init(&lith->lock);
+ lith->page0 = ioremap_nocache(baseaddr + LI_PAGE0_OFFSET, PAGE_SIZE);
+ lith->page1 = ioremap_nocache(baseaddr + LI_PAGE1_OFFSET, PAGE_SIZE);
+ lith->page2 = ioremap_nocache(baseaddr + LI_PAGE2_OFFSET, PAGE_SIZE);
+ if (!lith->page0 || !lith->page1 || !lith->page2) {
+ li_destroy(lith);
+ return -ENOMEM;
+ }
+ return 0;
+}
+
+/*
* basic register accessors - read/write long/byte
*/



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/