From mboxrd@z Thu Jan 1 00:00:00 1970 From: freeman.zhang1992@gmail.com (freeman) Date: Thu, 20 Feb 2014 09:32:11 +0800 Subject: [Help] How to Replace File Operations in File System? In-Reply-To: References: <52FC29B3.10201@gmail.com> <52FC69C7.7010705@gmail.com> <52FCC870.3010303@gmail.com> <5302E2DC.1040308@gmail.com> Message-ID: <53055B1B.5000500@gmail.com> To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org Hi Rishi, With pleasure! You can check it on https://github.com/freemandealer/droidcry on your convenience. 2014-02-19 23:17, Rishi Agrawal : > Good that you solved it your self, still if you can send me the idea > on which you are working - I may also learn something. > > > On Tue, Feb 18, 2014 at 10:04 AM, freeman > wrote: > > > > Hi > > > > The operations will not change back until your object gets > destroyed, > > whatever be the type of the object. > > > > Caching will not cause any issue here. > > > > Maybe if you can send the code we can have a look at it. > > > > > > -- > > Regards, > > Rishi Agrawal > Hi Rishi, > > It's very nice of you willing to help check my code! > I'm now very excited ? problem solved! > > I spent half a day beautifying my code yesterday (so that it won't > annoy > you > that much), and find there is a problem: > > Every time there is a read/write system call, I saved the lower > file ops > and > address space ops. In their replacement(upper operations), I invoked > lower ones. > There's a possibility that it might saved the upper operations as > lower > ones if I > open them twice in a short time. At this point, upper operation invoke > itself! > So I check the operations before truly save and replace them and, > it works! > > Thanks to you and all the amazing people in this amazing list that > helped me, > now I get both wrapfs and my own non-filesystem module functional > for my > future work on transparent encryption, and most importantly, I've > learned and > enjoyed a lot! > > Regards > Freeman Zhang > > > > > -- > Regards, > Rishi Agrawal Regards Freeman Zhang -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140220/93c9c63e/attachment.html