Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 141042
b: refs/heads/master
c: bdd6df6
h: refs/heads/master
v: v3
  • Loading branch information
Eduard - Gabriel Munteanu authored and Ingo Molnar committed Mar 31, 2009
1 parent 46f0a4d commit 6f4147b
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2a4efa42450762cbfa5c5712aa4cc9f06924c9fd
refs/heads/master: bdd6df6af98ce7e70702edfb5fd5dbbd8d1b0453
13 changes: 13 additions & 0 deletions trunk/kernel/trace/trace_output.c
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,19 @@ int trace_seq_putmem_hex(struct trace_seq *s, void *mem, size_t len)
return trace_seq_putmem(s, hex, j);
}

void *trace_seq_reserve(struct trace_seq *s, size_t len)
{
void *ret;

if (len > ((PAGE_SIZE - 1) - s->len))
return NULL;

ret = s->buffer + s->len;
s->len += len;

return ret;
}

int trace_seq_path(struct trace_seq *s, struct path *path)
{
unsigned char *p;
Expand Down
1 change: 1 addition & 0 deletions trunk/kernel/trace/trace_output.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ int trace_seq_puts(struct trace_seq *s, const char *str);
int trace_seq_putc(struct trace_seq *s, unsigned char c);
int trace_seq_putmem(struct trace_seq *s, void *mem, size_t len);
int trace_seq_putmem_hex(struct trace_seq *s, void *mem, size_t len);
void *trace_seq_reserve(struct trace_seq *s, size_t len);
int trace_seq_path(struct trace_seq *s, struct path *path);
int seq_print_userip_objs(const struct userstack_entry *entry,
struct trace_seq *s, unsigned long sym_flags);
Expand Down

0 comments on commit 6f4147b

Please sign in to comment.