From mboxrd@z Thu Jan 1 00:00:00 1970 From: Artem Bityutskiy Subject: [PATCHv5 00/16] kill unnecessary SB sync wake-ups + cleanups Date: Sun, 6 Jun 2010 17:50:13 +0300 Message-ID: <1275835829-1478-1-git-send-email-dedekind1@gmail.com> Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=ISO-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Andrew Morton , LKML , linux-fsdevel@vger.kernel.org To: Al Viro Return-path: Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org Hi, here is the v5 of the SB sync wakups killing patches, the v4 submission= can be found here: http://marc.info/?l=3Dlinux-fsdevel&m=3D127479544728442&w=3D= 2 Changes since v4: - use 'sb_mark_dirty()', 'sb_mark_clean()' and 'sb_is_dirty()' names as per Andrew's request - use lighter locking scheme requested by Al and Andrew and provided by Nick Piggin - various clean-ups as a result of validation of 's_dirt' usage in FSes as was requested by Al. To be frank, my energy ended at some point, a= nd I did not really validate reiserfs, sysv, UDF and UFS. The former is = very sub-standard, and the latter are ancient code and I dared not touchin= g it. The structure of the patch series ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1. The first patch introduces s_dirt wrappers and makes all FSes use th= em. Previously I submitted per-FS patches, but now I've folded them all = into one. 2. Patch 3 implements the whole logic which prevents unnecessary wake-u= ps. Then go various clean-ups which I have to do to get upstreamed :-) Note= , the changes described below do not go in exactly this order in the patch se= ries. 3. I've cleaned up AFFS and tested it. 4. Removed unneeded (IMO) code from BFS and tested. 5. Due to races between ->write_super and entities which modify the SB,= it is possible to end up with a modified SB, but nevertheless marked as= clean. So I added some more memory barriers and fixed AFFS, exofs, ext2, ex= t4, and HFS. Tested only AFFS. 6. Ancient FSes disrespect the wait flag in ->sync_fs(). They also do n= ot wait for the buffers in ->put_super(), which is wrong AFAIU, because= we are being unmounted, so we have to make sure the stuff was submitted to the HW. I fix this in AFFS, HFS, and HFSPLUS. It looks like sysv, UFS and UDF also do not wait for the buffers in ->put_super, but I did not dare modifying them... I already made too ma= n modifications in the code I do not know well enough. Please, review the cleanups - I tested only AFFS and BFS (the rest is o= nly compile-tested), and I am not really sure the 'wait for buffers' change= s are correct. --=20 Best Regards, Artem Bityutskiy (=D0=90=D1=80=D1=82=D1=91=D0=BC =D0=91=D0=B8=D1=82=D1=8E= =D1=86=D0=BA=D0=B8=D0=B9)