Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 304357
b: refs/heads/master
c: 234bb3c
h: refs/heads/master
i:
  304355: a91b19e
v: v3
  • Loading branch information
Ian Abbott authored and Greg Kroah-Hartman committed Apr 13, 2012
1 parent 90d83b2 commit 7166b77
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4d7df821277e82ebe2fc9c9af07c928a83f572b8
refs/heads/master: 234bb3c60f1f1489630750aba4adf40154e0bd70
20 changes: 20 additions & 0 deletions trunk/drivers/staging/comedi/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,26 @@ config COMEDI_DEBUG
This is an option for use by developers; most people should
say N here. This enables comedi core and driver debugging.

config COMEDI_DEFAULT_BUF_SIZE_KB
int "Comedi default initial asynchronous buffer size in KiB"
default "2048"
depends on COMEDI != n
---help---
This is the default asynchronous buffer size which is used for
commands running in the background in kernel space. This
defaults to 2048 KiB of memory so that a 16 channel card
running at 10 kHz has of 2-4 seconds of buffer.

config COMEDI_DEFAULT_BUF_MAXSIZE_KB
int "Comedi default maximum asynchronous buffer size in KiB"
default "20480"
depends on COMEDI != n
---help---
This is the default maximum asynchronous buffer size which can
be requested by a userspace program without root privileges.
This is set to 20480 KiB so that a fast I/O card with 16
channels running at 100 kHz has 2-4 seconds of buffer.

menuconfig COMEDI_MISC_DRIVERS
tristate "Comedi misc drivers"
depends on COMEDI
Expand Down
12 changes: 5 additions & 7 deletions trunk/drivers/staging/comedi/comedi_fops.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,6 @@ MODULE_AUTHOR("http://www.comedi.org");
MODULE_DESCRIPTION("Comedi core module");
MODULE_LICENSE("GPL");

#define DEFAULT_BUF_MAXSIZE_KB 64
#define DEFAULT_BUF_SIZE_KB 64

#ifdef CONFIG_COMEDI_DEBUG
int comedi_debug;
EXPORT_SYMBOL(comedi_debug);
Expand All @@ -78,17 +75,18 @@ MODULE_PARM_DESC(comedi_num_legacy_minors,
"number of comedi minor devices to reserve for non-auto-configured devices (default 0)"
);

unsigned int comedi_default_buf_size_kb = DEFAULT_BUF_SIZE_KB;
unsigned int comedi_default_buf_size_kb = CONFIG_COMEDI_DEFAULT_BUF_SIZE_KB;
module_param(comedi_default_buf_size_kb, uint, S_IRUGO | S_IWUSR);
MODULE_PARM_DESC(comedi_default_buf_size_kb,
"default asynchronous buffer size in KiB (default "
__MODULE_STRING(DEFAULT_BUF_SIZE_KB) ")");
__MODULE_STRING(CONFIG_COMEDI_DEFAULT_BUF_SIZE_KB) ")");

unsigned int comedi_default_buf_maxsize_kb = DEFAULT_BUF_MAXSIZE_KB;
unsigned int comedi_default_buf_maxsize_kb
= CONFIG_COMEDI_DEFAULT_BUF_MAXSIZE_KB;
module_param(comedi_default_buf_maxsize_kb, uint, S_IRUGO | S_IWUSR);
MODULE_PARM_DESC(comedi_default_buf_maxsize_kb,
"default maximum size of asynchronous buffer in KiB (default "
__MODULE_STRING(DEFAULT_BUF_MAXSIZE_KB) ")");
__MODULE_STRING(CONFIG_COMEDI_DEFAULT_BUF_MAXSIZE_KB) ")");

static DEFINE_SPINLOCK(comedi_file_info_table_lock);
static struct comedi_device_file_info
Expand Down

0 comments on commit 7166b77

Please sign in to comment.