fs work - request structure

From: KevinL <darius@dont-contact.us>
Date: Fri, 13 Apr 2001 18:16:29 +1000

I'm currently working on cleaning up the fs code, as per previous
conversations. Atm, I have a setup whereby storeCreate calls
buildOpenRequest, followed by submitOpenRequest - both of these functions are
provided by the io code (so, there's a ufs_buildOpenRequest, and an
aufs_buildOpenRequest). The aufs code primarily deals with the ctrlp
structure, and calls the ufs code for everything dealing with the request
structure. In this way, we get good sharing of code.

submitOpenRequest takes a request "object" - in this way, I can cheat by
having ufs and aufs share what is essentially aio_do_open() (which I know is
trivial), and the various request-handling code in cleanup, etc.

What I'm finding, tho, is that aufs keeps it's callback data in ctrl, whereas
ufs keeps it in sio - and unless I can merge those somehow, the code cannot be
nicely shared between them. What I'd like to do, ideally, is move the
callback data out of ctrl into requestp. Are there any reasons I shouldn't do
that?

If that does happen, the ctrlp structure gets less important, and could
theoretically almost vanish - I haven't tracked that down completely yet, but
that's sorta the direction I'm heading. First draft, tho, will have aufs and
ufs looking as similar to their current form as possible, but sharing code,
from there I'll look at cleaning up a lot of the "extras".

I've got as far as having aufs and ufs versions of the create call, and am
currently working on the cleanup and callback handling code - once that's
done, the other store* functions should drop in nicely, then I need to walk
through aufs'es code, to change all references to callback data to the right
place, and to move the various counters for open files, pending opens, etc
into fsdata (so they're on a per-fs basis).

KevinL

-- 
Internet techie, Obsidian Consulting Group
Specialising in proxy issues and traffic measuring/billing.
Received on Fri Apr 13 2001 - 02:16:32 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:13:45 MST