[alsa-devel] Accessing already probed snd_card in kernel space

Shreshtha shreshthakumar at gmail.com
Fri Apr 15 11:00:40 CEST 2011

Sorry, I couldn't get your point of sending notification to userspace.

just describing my understanding, if we are in same page -
For example if user touches a phone button, android gets the notification
from touch driver and in its reaction it displays the button on screen and
also uses sysfs interface (one way of implementation) to make vibrator
vibrate (haptic feedback).
sysfs open/enable handled by timed_output vibrator driver, which internally
can enable/drive some vibrator via GPIO or Audio block etc.
Here my case is Audio block and directly accessing Audio block registers is
not suggested.
So ALSA API inside the kernel which comes to mind. But now I am not sure if
that is even possible and recommended.

So proper way I see is to remove sysfs interface and implement the glue
layer of android and kernel using ALSA lib API to configure the mixer.


On Fri, Apr 15, 2011 at 2:06 PM, Lu Guanqun <guanqun.lu at intel.com> wrote:

> On Fri, Apr 15, 2011 at 04:27:08PM +0800, Shreshtha wrote:
> >
> >
> > > So only way remains is to access the sound card from user space using
> > > lib APIs and replace current usage of sysfs for haptic feedback. Please
> > > suggest if it is right direction.
> >
> > Is the sysfs API a _required_ Android API, or would Android allow you
> > to write a user space driver?
> >
> > [Shreshtha]  I found this one way of implementation seen on other
> devices. There can be other, and now I feel I require one.
> You might use input subsystem to notify the userspace, just like jack's
> implementation in sound subsystem.
> >
> > Regards,
> > Clemens
> >
> >
> >
> > --
> > shreshthakumar at gmail.com<mailto:shreshthakumar at gmail.com>
> --
> guanqun

shreshthakumar at gmail.com

More information about the Alsa-devel mailing list