Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 15271
b: refs/heads/master
c: fd30fc3
h: refs/heads/master
i:
  15269: 96ea305
  15267: d4f3122
  15263: a36770f
v: v3
  • Loading branch information
Tom Zanussi authored and Linus Torvalds committed Dec 21, 2005
1 parent 79c976c commit 8302b8b
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 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: bb44f116a14c4c932f15c79acfafd46bcb43ca9a
refs/heads/master: fd30fc3256824f03c2ff9317269d66f72f7042ca
8 changes: 6 additions & 2 deletions trunk/fs/relayfs/relay.c
Original file line number Diff line number Diff line change
Expand Up @@ -333,8 +333,7 @@ size_t relay_switch_subbuf(struct rchan_buf *buf, size_t length)
return length;

toobig:
printk(KERN_WARNING "relayfs: event too large (%Zd)\n", length);
WARN_ON(1);
buf->chan->last_toobig = length;
return 0;
}

Expand Down Expand Up @@ -399,6 +398,11 @@ void relay_close(struct rchan *chan)
relay_close_buf(chan->buf[i]);
}

if (chan->last_toobig)
printk(KERN_WARNING "relayfs: one or more items not logged "
"[item size (%Zd) > sub-buffer size (%Zd)]\n",
chan->last_toobig, chan->subbuf_size);

kref_put(&chan->kref, relay_destroy_channel);
}

Expand Down
5 changes: 3 additions & 2 deletions trunk/include/linux/relayfs_fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
#include <linux/kref.h>

/*
* Tracks changes to rchan_buf struct
* Tracks changes to rchan/rchan_buf structs
*/
#define RELAYFS_CHANNEL_VERSION 5
#define RELAYFS_CHANNEL_VERSION 6

/*
* Per-cpu relay channel buffer
Expand Down Expand Up @@ -60,6 +60,7 @@ struct rchan
struct rchan_callbacks *cb; /* client callbacks */
struct kref kref; /* channel refcount */
void *private_data; /* for user-defined data */
size_t last_toobig; /* tried to log event > subbuf size */
struct rchan_buf *buf[NR_CPUS]; /* per-cpu channel buffers */
};

Expand Down

0 comments on commit 8302b8b

Please sign in to comment.