Hi, On Mon, Jun 2, 2008 at 7:11 PM, Jan Kara <jack@suse.cz> wrote:This is really too hideous in my opinion and looks like a candidate for its own static inline function. Or you can try to rewrite the boolean expression on multiple lines using continue, something like: - for (cnt = 0, dirty = 0; cnt < MAXQUOTAS; cnt++) - if ((type == cnt || type == -1) && sb_has_quota_enabled( - && info_any_dirty(&sb_dqopt(sb)->info[cnt])) - dirty = 1; + for (cnt = 0, dirty = 0; cnt < MAXQUOTAS; cnt++) { + if (type != cnt && type != -1) + continue; + if (!sb_has_quota_enabled(sb, cnt)) + continue; + if (!info_any_dirty(&sb_dqopt(sb)->info[cnt])) + continue; + dirty = 1; + } (This uses the original macro, I know. How about moving that from the header to a new inline function just above this function?) What do you think? Vegard PS: This is a really good clean-up effort. Good work! -- "The animistic metaphor of the bug that maliciously sneaked in while the programmer was not looking is intellectually dishonest as it disguises that the error is the programmer's own creation." -- E. W. Dijkstra, EWD1036 --
| Linus Torvalds | Linux 2.6.27-rc8 |
| Greg KH | [GIT PATCH] driver core patches against 2.6.24 |
| Linus Torvalds | Linux 2.6.20-rc6 |
| Mike Snitzer | Re: Distributed storage. |
git: | |
| Gerrit Renker | [PATCH 03/37] dccp: List management for new feature negotiation |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| David Miller | [GIT]: Networking |
| Herbert Xu | Re: Kernel oops with 2.6.26, padlock and ipsec: probably problem with fpu state ch... |
