Jeremy Fitzhardinge <jeremy@goop.org> writes:I could do that do that, but the intermediate step (one driver, not the other) is somewhat problematic: the backend in dom0 needs both drivers, and will refuse to complete device initialization unless they're both present. Framebuffer: fbif.h xen-fbfront.c Keyboard/mouse: kbdif.h xen-kbdfront.h I added the config dependency because having one without the other doesn't make sense, as explained above. Still want it split into two separate patches? [...] [...] [...] It's designed that way. dev->info is initialized so that xenkbd_remove() does nothing. Then stuff is stored into dev->info only when it's sufficiently initialized for xenkbd_remove() to clean it up. Yes. xenkbd_probe() initializes info->kbd and info->ptr to null, and changes that to the device only after input_register_device() succeeds. If something goes wrong between input_allocate_device() and input_register_device(), xenkbd_probe() frees the device with input_free_device(). This is how input_register_device() wants to be used according to its function comment: /** * input_register_device - register device with input core * @dev: device to be registered * * This function registers device with input core. The device must be * allocated with input_allocate_device() and all it's capabilities * set up before registering. * If function fails the device must be freed with input_free_device(). * Once device has been successfully registered it can be unregistered * with input_unregister_device(); input_free_device() should not be * called in this case. */ There's another bug here: must not call input_unregister_device() when the device is still null. Man, I remember checking cleanup multiple times when this stuff went into Xen (i.e. quite some time ago), and I still missed this one. Going to check cleanup *again*. [...] Thanks! --
| Tarkan Erimer | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| Greg Kroah-Hartman | [PATCH 001/196] Chinese: Add the known_regression URI to the HOWTO |
| Benjamin Herrenschmidt | Re: [PATCH] Remove process freezer from suspend to RAM pathway |
| Bart Van Assche | Re: Integration of SCST in the mainstream Linux kernel |
git: | |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| Arjan van de Ven | Re: [GIT]: Networking |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| Natalie Protasevich | [BUG] New Kernel Bugs |
