Return-Path: Date: Sat, 9 Aug 2014 16:50:24 +0200 From: Pavel Machek Subject: Re: [PATCH 1/3] fpga manager framework core Message-ID: <20140809145024.GA6764@pollux.denx.de> References: <1406932118-13885-1-git-send-email-atull@opensource.altera.com> <1406932118-13885-2-git-send-email-atull@opensource.altera.com> <20140802001848.GB11170@amd.pavel.ucw.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: To: Alan Tull Cc: Pavel Machek , atull@opensource.altera.com, Greg Kroah-Hartman , Jason Gunthorpe , "H. Peter Anvin" , Michal Simek , Michal Simek , linux-kernel , "devicetree@vger.kernel.org" , Pantelis Antoniou , Rob Herring , Grant Likely , Mark Brown , Philip Balister , Alessandro Rubini , Steffen Trumtrar , Jason Cooper , Kyle Teske , Nicolas Pitre , Felipe Balbi , Mauro Carvalho Chehab , David Brown , Rob Landley , "David S. Miller" , Cesar Eduardo Barros , Samuel Ortiz , Andrew Morton , Linus Walleij , dinguyen@opensource.altera.com, yvanderv@opensource.altera.com List-ID: On Tue 2014-08-05 15:05:40, Alan Tull wrote: > On Fri, Aug 1, 2014 at 7:18 PM, Pavel Machek wrote: > > Hi! > > > >> + nr = ida_simple_get(&fpga_mgr_ida, start, FPGA_MAX_MINORS, GFP_KERNEL); > >> + > > > > Actually, are you sure ida framework is a good idea here? AFAICT, you > > only use it to keep track of used minors. > > pavel > > > > Yes, the ida is to keep track of minors. I think that was the intent > of introducing ida into the kernel (looking at git logs of idr.c). > SImilar to idr, but uses less memory. I see some other frameworks > using it for this purpose, such as the rtc class. I can change this > if this is something the kernel wants to move away from. What issues > are you seeing here and what would you suggest? Well, it looked to me like a job for bitfield, since we don't plan that many minors... Pavel