[PATCH] blkcg: have bh disable for 32bit UP system reading 64bit stats

2013-11-06 Thread Hong Zhiguo
From: Hong Zhiguo Update of blkg_stat and blkg_rwstat may happen in bh context. While u64_stats_fetch_retry is only preempt_disable on 32bit UP system. This is not enough to avoid preemption by bh and may read strange 64 bit value. Signed-off-by: Hong Zhiguo --- block/blk-cgroup.h | 8

[PATCH v4 2/2] blk-throttle: trim tokens generated for an idle tree

2013-10-20 Thread Hong Zhiguo
From: Hong Zhiguo Why Pointed out by Vivek: Tokens generated during idle period should be trimmed. Otherwise a huge bio may be permited immediately. Overlimit behaviour may be observed during short I/O throughput test. Vivek also pointed out: We should not over-trim for hierarchical groups

[PATCH v4 0/2] blk-throttle: simplify logic by token bucket algorithm

2013-10-20 Thread Hong Zhiguo
From: Hong Zhiguo Based on the discussion with Vivek, Tejun and Jens. Patch 1/2 implements basic token bucket rate limiting for blk-throttle. Patch 2/2 adjusts some behavior for the cases pointed out by Vivek: - A huge bio may be allowed immediately after a long time of idle

[PATCH v4 1/2] blk-throttle: simplify logic by token bucket algorithm

2013-10-20 Thread Hong Zhiguo
me-slicing implementation, and with less fluctuation. It's also tested on hierarchical setup. Signed-off-by: Hong Zhiguo Tested-by: Hong Zhiguo --- block/blk-throttle.c | 285 +-- 1 file changed, 50 insertions(+), 235 deletions(-) diff --git a/block/b

[PATCH v3] blk-throttle: simplify logic by token bucket algorithm

2013-10-17 Thread Hong Zhiguo
From: Hong Zhiguo Token bucket algorithm(http://en.wikipedia.org/wiki/Token_bucket) is very simple and widely used for rate limiting and shaping. It's well suitable for blk-throttle. And it natually works for hierarchical cgroups. So I took it to replace the original time _slicing_|_trim

[PATCH v2] blk-throttle: simplify logic by token bucket algorithm

2013-10-14 Thread Hong Zhiguo
From: Hong Zhiguo Token bucket algorithm(http://en.wikipedia.org/wiki/Token_bucket) is very simple and widely used for rate limiting and shaping. It's well suitable for blk-throttle. And it natually works for hierarchical cgroups. So I took it to replace the original time _slicing_|_trim

[tip:core/locking] lockdep: Remove unnecessary 'hlock_next' variable

2013-04-10 Thread tip-bot for Hong Zhiguo
Commit-ID: bfaf4af8abf92b883c04d137a0c18245cc9d51a2 Gitweb: http://git.kernel.org/tip/bfaf4af8abf92b883c04d137a0c18245cc9d51a2 Author: Hong Zhiguo AuthorDate: Thu, 4 Apr 2013 15:01:21 +0800 Committer: Ingo Molnar CommitDate: Mon, 8 Apr 2013 17:39:34 +0200 lockdep: Remove unnecessary

[PATCH] lockdep: remove unneccesary assignment in loop and the viarable

2013-04-04 Thread Hong Zhiguo
Signed-off-by: Hong Zhiguo --- kernel/lockdep.c |6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/kernel/lockdep.c b/kernel/lockdep.c index 259db20..0f26597 100644 --- a/kernel/lockdep.c +++ b/kernel/lockdep.c @@ -2000,7 +2000,7 @@ static inline int lookup_chain_cache

[PATCH 6/6] connector: replace obsolete NLMSG_* with type safe nlmsg_*

2013-03-27 Thread Hong Zhiguo
Signed-off-by: Hong Zhiguo --- drivers/connector/connector.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/connector/connector.c b/drivers/connector/connector.c index f1b7e24..6ecfa75 100644 --- a/drivers/connector/connector.c +++ b/drivers/connector

[PATCH 5/6] scsi: replace obsolete NLMSG_* with type safe nlmsg_*

2013-03-27 Thread Hong Zhiguo
Signed-off-by: Hong Zhiguo --- drivers/scsi/scsi_netlink.c |4 +-- drivers/scsi/scsi_transport_fc.c| 21 + drivers/scsi/scsi_transport_iscsi.c | 56 +-- 3 files changed, 38 insertions(+), 43 deletions(-) diff --git a/drivers/scsi

[PATCH 1/6] net-next: replace obsolete NLMSG_* with type safe nlmsg_*

2013-03-27 Thread Hong Zhiguo
Signed-off-by: Hong Zhiguo --- net/bridge/netfilter/ebt_ulog.c |4 ++-- net/core/rtnetlink.c |4 ++-- net/decnet/dn_table.c|4 ++-- net/decnet/netfilter/dn_rtmsg.c | 12 ++-- net/ieee802154/netlink.c |4 ++-- net

[PATCH 4/6] gdm72xx: replace obsolete NLMSG_* with type safe nlmsg_*

2013-03-27 Thread Hong Zhiguo
Signed-off-by: Hong Zhiguo --- drivers/staging/gdm72xx/netlink_k.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/staging/gdm72xx/netlink_k.c b/drivers/staging/gdm72xx/netlink_k.c index 52c25ba..c1239aa 100644 --- a/drivers/staging/gdm72xx/netlink_k.c

[PATCH 3/6] selinux: replace obsolete NLMSG_* with type safe nlmsg_*

2013-03-27 Thread Hong Zhiguo
Signed-off-by: Hong Zhiguo --- security/selinux/hooks.c |4 ++-- security/selinux/netlink.c |3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 2fa28c8..0a0609f 100644 --- a/security/selinux/hooks.c +++ b

[PATCH 2/6] audit: replace obsolete NLMSG_* with type safe nlmsg_*

2013-03-27 Thread Hong Zhiguo
Signed-off-by: Hong Zhiguo --- kernel/audit.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/kernel/audit.c b/kernel/audit.c index d596e53..4dbb047 100644 --- a/kernel/audit.c +++ b/kernel/audit.c @@ -58,7 +58,7 @@ #ifdef CONFIG_SECURITY #include #endif