Conversation
b61501b to
c8fa26b
Compare
These callbacks will be used platform specific code for VT backend specific functions, so we get rid of complicated #ifdef-zoos and demuxing. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Factor out the logic for acquiring a VT into separate function instead of wild goto's. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Instead of returning the fd, assign it into xf86Info.consoleFd directly from within the console probe functions (they're already assigning other fields anyways) and turn the return value into bool (just report success). Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Moving the console post-open steps (eg. acquire_vt()) into the indivual console driver's open proc, so we don't need the extra switch() and related #ifdef zoo anymore. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
* move console type specific close logic into separate functions * install them into xf86_console_proc_close on init Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
factor it out into per console-driver functions. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Yet another step on factoring out console type specific code so separate drivers. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Yet another step on factoring out console type specific code so separate drivers. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
factor it out into per console-driver functions. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Factor it out to separate per-console-driver functions. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Prefer stdbool over our own historical Bool. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replace ugly ifdef-zoo and frequent switching over current console backend type, splitting it all off into separate console drivers and use function pointers where we can directly call into the currently active console driver.
At this stage just doing it for BSD (the only platform that needs several ones). Later iterations will also do it for the other platforms, so we can consolidate the corresponding DDX entry points and move all console drivers to one common place.
The individual platforms then will just have a little bit of glue/setup code left, for probing from the list of their supported console drivers. Adding new console drivers will be pretty easy now.