From: Marcel Holtmann <marcel@holtmann.org>
To: Pavan Savoy <pavan_savoy@yahoo.co.in>
Cc: Greg KH <gregkh@suse.de>, PavanSavoy <pavan_savoy@ti.com>,
"alan@lxorguk.ukuu.org.uk" <alan@lxorguk.ukuu.org.uk>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 4/6] drivers:misc: sources for Init manager module
Date: Wed, 24 Mar 2010 10:15:50 -0700 [thread overview]
Message-ID: <1269450950.11714.126.camel@localhost.localdomain> (raw)
In-Reply-To: <132027.10140.qm@web94905.mail.in2.yahoo.com>
Hi Pavan,
> > > > > I wanted to somehow put this in staging
> > because then
> > > > it would probably have a thorough architectural
> > review
> > > > process.
> > > > > Some details about this driver -
> > > > >
> > > > > 1. This driver will be used by
> > Bluetooth-BlueZ/FM-V4L2
> > > > and GPS (probably character device driver) using
> > the
> > > > EXPORTED symbols (-register/_unregister).
> > > > >
> > > > > 2. Much like the hciattach daemon which
> > maintains
> > > > N_HCI bluetooth line discipline, this driver will
> > also have
> > > > a User-Space N_TI_WL Init manager (UIM)
> > maintaining
> > > > the Line discipline.
> > > >
> > > > can you explain why you think this is needed and
> > we can not
> > > > interface
> > > > this directly. If it is a serial port, what
> > protocol does
> > > > it talk?
> > >
> > > Illustration: The BT driver on top of this ST driver,
> > would create a hci0 interface, when someone does an DEVUP on
> > that interface, the BT driver would then do a st-register -
> > which in-turn would ask the hciattach-like daemon to install
> > the line discipline for it via the sysfs entry.
> > > The same concept goes for FM-V4L2 and GPS character
> > driver.
> > >
> > > The core of the problem is we cannot
> > ask/install/ldisc_put for a line discipline from kernel
> > space.
> >
> > so let us get the facts straight here. The device in
> > question is using a
> > serial port to connect to the host and then multiplexing
> > BT, FM and GPS
> > over it. My question again, what protocol does it talk.
>
> Ok, On TTY/4-wire UART, BT talks standard HCI, and HCI-LL for power management as in hci_ll.c/hciattach_ti.c which is already upstream.
>
> And in a very similar way, FM talks over what is known as "channel 8" and GPS over "channel 9", Although these are not standard.
>
> So, basically data going/coming to/out of chip is
> 1,2,3,4 - HCI
> 30,31,32,33 for HCI-LL
> 8 - FM
> 9 - GPS.
>
> So consider this an extension of hci_ll/hci_ldisc but only more features to accomodate the FM and GPS.
So why are we not making the hci_ll into a generic driver that can
register besides Bluetooth also FM and GPS.
Then we can attach that driver to the TTY via line discipline on boot
and let the LL part handle the power management.
Registration of Bluetooth device, FM and GPS nodes are done via RFKILL
that the LL driver exports.
> > Also why not just install the line discipline and then
> > control the
> > subdevices via RFKILL?
>
> The chip side PM would be fine, and is being done so, st_kim.c creates the rfkill entries, and controls them locally, also allows applications to control them.
> But ldisc can't be install upon boot, because UART clks would be used up for no reason at all.
> (say on a mobile phone, how many times in a day - do we actually use BT/FM or GPS - so UART needs to be most often idle, and ldisc should be installed only upon requirement)
I think the driver should make sure it doesn't use the UART clocks if in
deep sleep. This has nothing to do with installing the line discipline
on boot via a userspace tool.
You do the power management for the hci_ll driver already today. So why
can't we do the same in this driver?
Another way to view this is that the LL driver has to create a virtual
bus for Bluetooth, FM and GPS devices. However RFKILL might be a bit
more suitable and simpler.
Regards
Marcel
next prev parent reply other threads:[~2010-03-24 17:16 UTC|newest]
Thread overview: 48+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-22 21:19 [re-worked] New ldisc for WiLink7.0 pavan_savoy
2010-03-22 21:19 ` [PATCH 1/6] serial: TTY: new ldisc for TI BT/FM/GPS chips pavan_savoy
2010-03-22 21:19 ` [PATCH 2/6] drivers:misc: Kconfig, Makefile for TI's ST ldisc pavan_savoy
2010-03-22 21:19 ` [PATCH 3/6] drivers:misc: sources for ST core pavan_savoy
2010-03-22 21:19 ` [PATCH 4/6] drivers:misc: sources for Init manager module pavan_savoy
2010-03-22 21:19 ` [PATCH 5/6] drivers:misc: sources for HCI LL PM protocol pavan_savoy
2010-03-22 21:19 ` [PATCH 6/6] drivers:misc: sources for ST header file pavan_savoy
2010-03-22 21:36 ` [PATCH 4/6] drivers:misc: sources for Init manager module Greg KH
2010-03-22 22:03 ` Savoy, Pavan
2010-03-24 2:23 ` Greg KH
2010-03-24 8:04 ` Marcel Holtmann
2010-03-24 14:54 ` Pavan Savoy
2010-03-24 15:52 ` Greg KH
2010-03-24 16:11 ` Marcel Holtmann
2010-03-24 16:22 ` Pavan Savoy
2010-03-24 16:38 ` Marcel Holtmann
2010-03-24 16:39 ` Randy Dunlap
2010-03-24 16:54 ` Pavan Savoy
2010-03-24 17:03 ` Alan Cox
2010-03-24 17:09 ` Pavan Savoy
2010-03-24 17:26 ` Alan Cox
2010-03-24 17:32 ` Pavan Savoy
2010-03-24 17:39 ` Alan Cox
2010-03-24 18:46 ` Pavan Savoy
2010-03-24 20:54 ` Marcel Holtmann
2010-03-24 21:03 ` Pavan Savoy
2010-03-24 17:15 ` Marcel Holtmann [this message]
2010-03-24 17:42 ` Pavan Savoy
2010-03-24 20:59 ` Marcel Holtmann
2010-03-24 16:58 ` Alan Cox
2010-03-24 16:56 ` Pavan Savoy
2010-03-24 16:26 ` Greg KH
2010-03-24 16:35 ` Pavan Savoy
2010-03-24 16:52 ` Greg KH
2010-03-24 17:05 ` Pavan Savoy
2010-03-24 17:20 ` Alan Cox
2010-03-22 21:34 ` [PATCH 3/6] drivers:misc: sources for ST core Greg KH
2010-03-23 15:24 ` Alan Cox
2010-03-22 21:34 ` [PATCH 2/6] drivers:misc: Kconfig, Makefile for TI's ST ldisc Greg KH
2010-03-22 21:35 ` Greg KH
2010-03-23 0:07 ` Tilman Schmidt
2010-03-23 15:18 ` Alan Cox
2010-03-24 2:19 ` Greg KH
2010-03-22 21:45 ` Randy Dunlap
2010-03-22 22:37 ` Savoy, Pavan
2010-03-22 22:49 ` Randy Dunlap
2010-03-23 15:20 ` [PATCH 1/6] serial: TTY: new ldisc for TI BT/FM/GPS chips Alan Cox
[not found] <1269466536.11714.144.camel@localhost.localdomain>
2010-03-24 21:46 ` [PATCH 4/6] drivers:misc: sources for Init manager module Pavan Savoy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1269450950.11714.126.camel@localhost.localdomain \
--to=marcel@holtmann.org \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=gregkh@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=pavan_savoy@ti.com \
--cc=pavan_savoy@yahoo.co.in \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome