From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <199604021913.LAA14172@hyper.stanford.edu> Date: Tue, 2 Apr 1996 11:13:28 -0800 (PST) From: David Hinds Subject: Re: Patches for PCMCIA on UDB In-Reply-To: > > +#ifdef USE_MEM_ACCESS_ROUTINES > > + *ptr = _readb(sys); > > +#else > > *ptr = *sys; > > +#endif > > } > > } > > } /* read_cis_mem */ > > The above kind of horror it too ugly to survive. I don't care _too_ much, > as pcmcia isn't in the kernel, but I'd rather not even be distantly > associated with anything like this. > > Remember: #ifdef is _ugly_, and should be avoided at all costs. > > Use "readb()" (without the underscore), and it should work on all > platforms. No ifdefs, no direct pointer accesses. The alpha isn't the > only architecture that needs something like this (PPC has the PCI address > space shifted up in memory space etc). I've already made this change (readb/writeb for all platforms, no conditional code) for the next release. I put it in before I got the other Alpha patches, though, so the others will be in 2.8.11. -- Dave Hinds