Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 123477
b: refs/heads/master
c: 37ca5eb
h: refs/heads/master
i:
  123475: c51aa49
v: v3
  • Loading branch information
Robert Richter committed Dec 10, 2008
1 parent c2be6f3 commit e9a0768
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 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: fd7826d56bde11ab142d2431093773ad2b3f0a59
refs/heads/master: 37ca5eb341711d7aeb9f296873b9d46eb6af33ec
15 changes: 12 additions & 3 deletions trunk/drivers/oprofile/oprofile_files.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,13 @@
#include "oprofile_stats.h"
#include "oprof.h"

unsigned long fs_buffer_size = 131072;
unsigned long fs_cpu_buffer_size = 8192;
unsigned long fs_buffer_watershed = 32768; /* FIXME: tune */
#define FS_BUFFER_SIZE_DEFAULT 131072
#define FS_CPU_BUFFER_SIZE_DEFAULT 8192
#define FS_BUFFER_WATERSHED_DEFAULT 32768 /* FIXME: tune */

unsigned long fs_buffer_size;
unsigned long fs_cpu_buffer_size;
unsigned long fs_buffer_watershed;

static ssize_t depth_read(struct file *file, char __user *buf, size_t count, loff_t *offset)
{
Expand Down Expand Up @@ -120,6 +124,11 @@ static const struct file_operations dump_fops = {

void oprofile_create_files(struct super_block *sb, struct dentry *root)
{
/* reinitialize default values */
fs_buffer_size = FS_BUFFER_SIZE_DEFAULT;
fs_cpu_buffer_size = FS_CPU_BUFFER_SIZE_DEFAULT;
fs_buffer_watershed = FS_BUFFER_WATERSHED_DEFAULT;

oprofilefs_create_file(sb, root, "enable", &enable_fops);
oprofilefs_create_file_perm(sb, root, "dump", &dump_fops, 0666);
oprofilefs_create_file(sb, root, "buffer", &event_buffer_fops);
Expand Down

0 comments on commit e9a0768

Please sign in to comment.