lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 23 Aug 2011 15:52:47 +0200
From:	Takashi Iwai <tiwai@...e.de>
To:	anish singh <anish198519851985@...il.com>
Cc:	linux-kernel-mail <linux-kernel@...r.kernel.org>,
	kernelnewbies <kernelnewbies@...nelnewbies.org>,
	alsa-devel@...a-project.org,
	"Edgar (gimli) Hucek" <gimli@...k-green.com>,
	Tim Howe <tim.howe@...rus.com>,
	Stephen Warren <swarren@...dia.com>,
	Vince Weaver <vweaver1@...s.utk.edu>,
	Jaroslav Kysela <perex@...ex.cz>,
	Mark Brown <broonie@...nsource.wolfsonmicro.com>,
	Liam Girdwood <lrg@...com>
Subject: Re: Headset driver detection problem during bootup

At Sat, 20 Aug 2011 22:21:10 +0900,
anish singh wrote:
> 
> adding more information and experts on alsa.
> 
> On Fri, Aug 19, 2011 at 9:23 PM, anish singh
> <anish198519851985@...il.com> wrote:
> > I need some suggestions for below situation:
> >
> > Headset if it is inserted before the device is powered up is
> > now detected by forcefully calling the interrupt handler in
> > the probe function of the headset driver.
> Headset is detected in our andorid device by using a detect gpio
>  which is turned on when headset is inserted.If the headset
>  is inserted right from very beginging i.e. before device is even
>  turned on then we forcefully call the handler and thereby in
>  handler we check if gpio is turned on or not and do the rest
> of things.
> 
> > Once the handler is called then we find out if the headset
> > is there or not using gpio and then normal detection happens
> >
> > Is it the right way to detect the device during power-up?
> Does not linux have any other way of doing this which i may
> be missing? How this is handled in the case of ALSA jack i.e.
> the jack drivers which is using alsa framework for detection?
> Android doesn't use ALSA framework for reporting JACK.

Judging from the source code, the likely problem is that the driver
doesn't initialize the switch-state in input device.  The switch-state
is updated only when GPIO IRQ comes up.


Takashi
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ