User: | Jiri Slaby |
Error type: | Leaving function in locked state |
Error type description: | Some lock is not unlocked on all paths of a function, so it is leaked |
File location: | fs/jfs/jfs_logmgr.c |
Line in file: | 2101 |
Project: | Linux Kernel |
Project version: | 2.6.28 |
Tools: |
Undetermined 1
|
Entered: | 2012-03-04 17:07:06 UTC |
2071 /* insert at tail of wqueue */ 2072 if (tail == NULL) { 2073 log->wqueue = bp; 2074 bp->l_wqnext = bp; 2075 } else { 2076 log->wqueue = bp; 2077 bp->l_wqnext = tail->l_wqnext; 2078 tail->l_wqnext = bp; 2079 } 2080 2081 tail = bp; 2082 } 2083 2084 /* is buffer at head of wqueue and for write ? */ 2085 if ((bp != tail->l_wqnext) || !(flag & lbmWRITE)) { 2086 LCACHE_UNLOCK(flags); /* unlock+enable */ 2087 return; 2088 } 2089 2090 LCACHE_UNLOCK(flags); /* unlock+enable */ 2091 2092 if (cant_block) 2093 lbmRedrive(bp); 2094 else if (flag & lbmSYNC) 2095 lbmStartIO(bp); 2096 else { 2097 LOGGC_UNLOCK(log); 2098 lbmStartIO(bp); 2099 LOGGC_LOCK(log); 2100 } 2101} 2102 2103 2104/* 2105 * lbmDirectWrite() 2106 * 2107 * initiate pageout bypassing write queue for sidestream 2108 * (e.g., log superblock) write; 2109 */ 2110static void lbmDirectWrite(struct jfs_log * log, struct lbuf * bp, int flag) 2111{