[PATCH] addon-input: SW_LINEOUT_INSERT and SW_MICROPHONE_INSERT event reporting

Guillem Jover guillem.jover at nokia.com
Mon Oct 27 16:22:13 PDT 2008


Hi,

On Sat, 2008-10-25 at 01:06:27 -0400, ext Matthew Ranostay wrote:
> Added support for SW_LINEOUT_INSERT and SW_MICROPHONE_INSERT with a type
> "lineout_insert" and "microphone_insert" in button.type for addon-input.

> +			case SW_MICROPHONE_INSERT:
> +				name = "microphone_insert";
> +				break;
> +			case SW_LINEOUT_INSERT:
> +				name = "lineout_insert";
> +				break;

There's some problems with this patch. The microphone switch is quite
new but at least on Linus' tree but the other one is only on Takashi's
tree, so this will make HAL fail to build.

And then there's the problem with userland trying to make sense of
those events, if for each jack insertion we trigger several HAL
signals, userland will have to wait with a timeout for other possible
signals after the first one, making them a bit unreliable. Please see
the proposal I sent to the list some weeks ago:

  <http://lists.freedesktop.org/archives/hal/2008-October/012375.html>

Anyway, I'll send the patches I've around tomorrow.

regards,
guillem


More information about the hal mailing list