From: "Komal Shah" <komal_shah802003@yahoo.com>
To: linux-omap-open-source@linux.omap.com
Subject: [PATCH] OMAP: c55x dummy code as dspfs plugin
Date: Tue, 12 Sep 2006 15:05:26 +0530 [thread overview]
Message-ID: <1158053726.18758.270711882@webmail.messagingengine.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 249 bytes --]
After applying the patch, please update arch/arm/mach-omap2/Makefile
to make it compile.
Signed-off-by: Komal Shah <komal_shah802003@yahoo.com>
---Komal Shah
http://komalshah.blogspot.com
--
http://www.fastmail.fm - Send your email first class
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: dsp.patch --]
[-- Type: text/x-patch; name="dsp.patch", Size: 2175 bytes --]
diff --git a/arch/arm/mach-omap2/dsp.c b/arch/arm/mach-omap2/dsp.c
new file mode 100644
index 0000000..ffba320
--- /dev/null
+++ b/arch/arm/mach-omap2/dsp.c
@@ -0,0 +1,87 @@
+/*
+ * arch/arm/mach-omap2/dsp.c
+ *
+ * Support DSP (C55x) for OMAP2420 using dspfs.
+ *
+ * Author: Komal Shah (komal_shah802003@yahoo.com)
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/err.h>
+#include <linux/dspfs.h>
+#include <linux/mm.h>
+#include <linux/kernel.h>
+#include <linux/fs.h>
+
+struct dentry *dentry;
+
+static int omap_dsp_init(void* arg)
+{
+ printk(KERN_NOTICE "DSP: Initializing\n");
+
+ return 0;
+}
+
+static void omap_dsp_exit(void* arg)
+{
+ printk(KERN_NOTICE "DSP: Exiting\n");
+}
+
+static ssize_t omap_dsp_dir_write(struct file *file, const char __user *buf,
+ size_t count, loff_t *ppos)
+{
+ return generic_file_write(file, buf, count, ppos);
+}
+
+static struct file_operations omap_dsp_codecs_dir_fops = {
+ .open = dcache_dir_open,
+ .release = dcache_dir_close,
+ .llseek = dcache_dir_lseek,
+ .read = generic_read_dir,
+ .write = omap_dsp_dir_write,
+ .readdir = dcache_readdir,
+};
+
+static struct file_operations omap_dsp_percodec_fops = {
+ .read = generic_file_read,
+ .write = generic_file_write,
+};
+
+static struct tree_descr omap_dsp_percodec_files[] = {
+ {"frmdata_0", &omap_dsp_percodec_fops, S_IWUSR | S_IRUGO},
+ {"frmdata_1", &omap_dsp_percodec_fops, S_IWUSR | S_IRUGO},
+ {"" },
+};
+
+static struct dsp_info omap_dsp = {
+ .name = "c55x",
+ .parent = NULL,
+ .init = omap_dsp_init,
+ .exit = omap_dsp_exit,
+ .fops = &omap_dsp_codecs_dir_fops,
+ .percodec_files = omap_dsp_percodec_files,
+};
+
+static int __init omap_dsp_fs_init(void)
+{
+ dentry = dsp_register(&omap_dsp);
+
+ if (IS_ERR(dentry))
+ return PTR_ERR(dentry);
+
+ return 0;
+}
+
+static void __exit omap_dsp_fs_exit(void)
+{
+ dsp_unregister(dentry);
+}
+
+module_init(omap_dsp_fs_init);
+module_exit(omap_dsp_fs_exit);
+
+MODULE_LICENSE("GPL");
[-- Attachment #3: Type: text/plain, Size: 0 bytes --]
reply other threads:[~2006-09-12 9:35 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1158053726.18758.270711882@webmail.messagingengine.com \
--to=komal_shah802003@yahoo.com \
--cc=linux-omap-open-source@linux.omap.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox