Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 151215
b: refs/heads/master
c: 2b53bc7
h: refs/heads/master
i:
  151213: 81e3484
  151211: c9cb2dd
  151207: edc01b5
  151199: 0c841cb
v: v3
  • Loading branch information
Coly Li authored and Joel Becker committed May 5, 2009
1 parent b59f395 commit 5b7313f
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 19 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: a46fa684fcb7001d79c97f2968696997b3b79064
refs/heads/master: 2b53bc7bff17341d8b5ac12115f5c2363638e628
35 changes: 17 additions & 18 deletions trunk/fs/ocfs2/cluster/masklog.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,34 +48,33 @@
* only emit the appropriage printk() when the caller passes in a constant
* mask, as is almost always the case.
*
* All this bitmask nonsense is hidden from the /proc interface so that Joel
* doesn't have an aneurism. Reading the file gives a straight forward
* indication of which bits are on or off:
* ENTRY off
* EXIT off
* All this bitmask nonsense is managed from the files under
* /sys/fs/o2cb/logmask/. Reading the files gives a straightforward
* indication of which bits are allowed (allow) or denied (off/deny).
* ENTRY deny
* EXIT deny
* TCP off
* MSG off
* SOCKET off
* ERROR off
* NOTICE on
* ERROR allow
* NOTICE allow
*
* Writing changes the state of a given bit and requires a strictly formatted
* single write() call:
*
* write(fd, "ENTRY on", 8);
* write(fd, "allow", 5);
*
* would turn the entry bit on. "1" is also accepted in the place of "on", and
* "off" and "0" behave as expected.
* Echoing allow/deny/off string into the logmask files can flip the bits
* on or off as expected; here is the bash script for example:
*
* Some trivial shell can flip all the bits on or off:
* log_mask="/sys/fs/o2cb/log_mask"
* for node in ENTRY EXIT TCP MSG SOCKET ERROR NOTICE; do
* echo allow >"$log_mask"/"$node"
* done
*
* log_mask="/proc/fs/ocfs2_nodemanager/log_mask"
* cat $log_mask | (
* while read bit status; do
* # $1 is "on" or "off", say
* echo "$bit $1" > $log_mask
* done
* )
* The debugfs.ocfs2 tool can also flip the bits with the -l option:
*
* debugfs.ocfs2 -l TCP allow
*/

/* for task_struct */
Expand Down

0 comments on commit 5b7313f

Please sign in to comment.