Re: [f2fs-dev] [PATCH v1 01/12] f2fs: cache: implement metadata cache

Wenjie Qi <[email protected]>
Newsgroups net.sourceforge.lists.linux-f2fs-devel,org.kernel.vger.linux-kernel
Message-ID <[email protected]>
Hi Chao,

> static void f2fs_zone_write_end_io(struct bio *bio)
> {
> 	bio->bi_private = io->bi_private;
> 	complete(&io->zone_wait);
> 	if (io->fio.is_cache)
> 		f2fs_cache_write_end_io(bio);
> 	else
> 		f2fs_write_end_io(bio);
> }

`io->fio` is updated when the next BIO is prepared.  Once
`complete(&io->zone_wait)` wakes the waiting writer, that preparation can
run before this callback reads `io->fio.is_cache`.

Is there another serialization condition that keeps `io->fio.is_cache`
unchanged between `complete()` and this read?


_______________________________________________
Linux-f2fs-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.