- From: Frank Mori Hess <fmhess_at_speakeasy.net>
- Date: Wed, 9 Mar 2005 21:14:34 -0500
> > From: Ian Abbott <abbotti_at_mev.co.uk> > > Date: 2005/03/08 Tue AM 08:15:52 CST > > To: comedi_at_comedi.org > > Subject: [PATCH] check_region deprecated (maybe a nicer solution?) > > > > Hi, > > > > Those warnings about check_region being deprecated when compiling the > > comedi drivers for 2.6.x are starting to get to me :-) > > > > The attached patch defines a REQUEST_REGION() macro to act as a > > replacement for the check_region()/request_region() pairs. I stuck it > > in the linux/ioport.h compatibility header (cf. the REMAP_PAGE_RANGE() > > macro in the linux/mm.h compatibility header). > > > > As this is a matter of style, maybe someone has opinions on a nicer > > way to do this, perhaps by defining a comedi_request_region() inline > > function somewhere, or perhaps by avoiding the gcc extention I used. > > > > I haven't changed any drivers yet (except one driver on my local > > system for test purposes). No point doing that until the name of the > > new macro or function is settled. It's fine, but I'd make REQUEST_REGION() a static inline function instead of using _start and _n to add pass-by-value and type checking to a macro. -- Frank
Attachments
- application/pgp-signature attachment: stored
Received on 2005-03-10Z02:14:34