From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Koss Subject: Re: fragmentation && blocks "realloc" Date: Sat, 21 Jan 2006 12:42:40 +0300 Message-ID: References: <1137764093.15107.33.camel@imp.csi.cam.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: kernelnewbies@nl.linux.org, linux-fsdevel@vger.kernel.org Return-path: To: Anton Altaparmakov In-Reply-To: Content-Disposition: inline Sender: kernelnewbies-bounce@nl.linux.org Errors-to: kernelnewbies-bounce@nl.linux.org List-help: List-unsubscribe: List-software: Ecartis version 1.0.0 List-subscribe: List-owner: List-post: List-archive: List-Id: linux-fsdevel.vger.kernel.org >It will all just work >fine. (Unless you have omitted to say things about your fs that are >important. Why don't you show all your code rather than just those >snippets and then proper advice can be given...) fs is just a simple analog of ufs/ext2/minix/sysv. It is block oriented, and I suppose that working with pages, instead of blocks make it more complicated, then it should to be. >You do not want the invalidate_inode_buffers() call. It makes no sense Great, we reached the point. Yes, my file system based on usage sb_bread/brelse. As ordinary file system my file system implements readpage and writepage, it is similar to static int sysv_writepage(struct page *page, struct writeback_control *wbc) { =09return block_write_full_page(page,get_block,wbc); } static int sysv_readpage(struct file *file, struct page *page) { =09return block_read_full_page(page,get_block); } get_block make such thing map_bh(...) So, when we "realloc" blocks, what happen with these "old" mapped (or used in some other way) blocks? How can I prevent usage "old" blocks instead of "new" blocks? Or if I mark old and new blocks as dirty all will be right? -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/