Re: Re: Move softcursor out of fbdev to fbcon
flat view
From: Jon Smirl <hidden>
Date: 2005-07-27 19:06:23
On 7/27/05, Antonino A. Daplas [off-list ref] wrote:
Jon Smirl wrote:quoted
On 7/27/05, Antonino A. Daplas [off-list ref] wrote:quoted
The changelog says it all. This is a modification of Jon's patch, but I have moved softcursor.c to the console directory. Also I removed the "select FB_SOFTCURSOR" from video/Kconfig and made the compilation of softcursor unconditional, if framebuffer console is enabled. I don't think the fb_cursor hook is usable by other programs, so we should just restrict this hook for fbcon use only. For userspace cursor support, we need a new one. But instead of one function, I believe it's better to provide several. Ie, something like below: fbcursor_show() fbcursor_move() fbcursor_loadimage() fbcursor_loadpalette() fbcursor_start() fbcursor_stop()What does start/stop do?Wrong choice of words, this is just an example. But start() should tell the driver that the cursor is going to be used, and perhaps do some locking (so another app does not try to grab the device). It can also return the capabilities of the cursor: maximum dimensions, color depth of image, caps such as alpha, transparency, etc. stop() will release the cursor.
In the sysfs model I'd do something like this. Most attributes are read/write. cursor_visible -- 0/1 hide/show cursor_location -- x,y cursor_image -- image bitmap cursor_palette -- pallete data cursor_capabilities -- read only An owner could have a lot of problems, what if the owning apps dies? There is no open file handle in the sysfs model. I would just assume that ownership is handled in the upper layers. Sysfs is still an experiment to see if it really can handle everything the IOCTLs do. -- Jon Smirl jonsmirl@gmail.com ------------------------------------------------------- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf