home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!cbmvax!jesup
- From: jesup@cbmvax.commodore.com (Randell Jesup)
- Newsgroups: comp.sys.amiga.programmer
- Subject: Re: Getting a valid FileSysStartupMsg pointers.
- Message-ID: <37848@cbmvax.commodore.com>
- Date: 14 Dec 92 04:04:25 GMT
- References: <1992Dec13.030020.13319@mail.cornell.edu>
- Reply-To: jesup@cbmvax.commodore.com (Randell Jesup)
- Organization: Commodore, West Chester, PA
- Lines: 30
-
- chris@alchemy.tn.cornell.edu writes:
- >However, apparently dol_StartUp does NOT always point to a valid
- >FileSystemStartupMsg (hereafter abbreviated FSSM) even though IsFileSystem()
- >returns true. I have particularly found this to be the case on devices
- >which are not physical disks such as RAM disks or remotely mounted
- >network devices.
-
- This is an ugly area. Unfortunately, early in the Amiga days (or
- perhaps back in tripos), someone though strings would be neat to hold
- parameters for handler startups. So they implemented BSTRs as an alternative
- to FSSMs. They also thought that passing small integers would make it slightly
- easier on whoever was writing the port-handler (SER/PAR/PRT). So they also
- added support to pass an integer. So, startup can hold 3 things: an integer,
- an BPTR to a BSTR, or a pointer to an FSSM (actually I think it's a BPTR).
- Ugly, eh?
-
- A heuristic approach: first, filter out values <64 (64*4 = the size of
- the 680x0 vector table, no pointer can be here). Next, see if TypeOfMem
- on startup<<2 says it's real memory. Next, see if the various FSSM pointers
- (or BPTRs) point to real memory (TypeOfMem again). That should catch almost
- all cases. (UGLY!!!!).
-
- Isn't compatibility grand?
-
- --
- To be or not to be = 0xff
- -
- Randell Jesup, Jack-of-quite-a-few-trades, Commodore Engineering.
- {uunet|rutgers}!cbmvax!jesup, jesup@cbmvax.cbm.commodore.com BIX: rjesup
- Disclaimer: Nothing I say is anything other than my personal opinion.
-