lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Message-ID: <20130320134226.GF13294@quack.suse.cz> Date: Wed, 20 Mar 2013 14:42:26 +0100 From: Jan Kara <jack@...e.cz> To: Theodore Ts'o <tytso@....edu> Cc: Jan Kara <jack@...e.cz>, Ext4 Developers List <linux-ext4@...r.kernel.org> Subject: Re: [PATCH] ext4: fix ext4_evict_inode() racing against workqueue processing code On Wed 20-03-13 09:37:51, Ted Tso wrote: > On Wed, Mar 20, 2013 at 02:22:23PM +0100, Jan Kara wrote: > > > + if (work_pending(&EXT4_I(inode)->i_unwritten_work)) > > > + flush_work(&EXT4_I(inode)->i_unwritten_work); > > > } > > Won't it be more logical to use cancel_work_sync() here? > > Hmm.... yes, probably, but then ext4_ioend_wait() can only be safely > used by ext4_evict_inode(). I'll make the change, but I'll also make > a comment to this effect. (No one else is using it now, but if there > was ever a need to use it while the inode was in use, using > cancel_work_sync() would be highly dagernous/racy. That being said, I > can't really think of a good use case other than evict_inode path, so > it seems fine to make this change.) Yeah, we can possibly rename the function or maybe even just inline it in ext4_evict_inode? Honza -- Jan Kara <jack@...e.cz> SUSE Labs, CR -- To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists