linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: swarren@wwwdotorg.org (Stephen Warren)
To: linux-arm-kernel@lists.infradead.org
Subject: Where to power on the wifi device before loading the driver.
Date: Fri, 15 Jun 2012 09:49:10 -0600	[thread overview]
Message-ID: <4FDB5976.20809@wwwdotorg.org> (raw)
In-Reply-To: <6B4D417B830BC44B8026029FD256F7F1C377BFFE8D@HKMAIL01.nvidia.com>

On 06/15/2012 12:09 AM, Wei Ni wrote:
> On Thu, Jun 14, 2012 at 23:54:22, Stephen Warren wrote:
>>>>> The core of the issue is that:
>>>
>>>>> * Tegra30 support is via device tree. * We have an SDIO bus, and 
>>>>> the WiFi device attached to that bus is enumerable. * Since the 
>>>>> WiFi device is enumerable, no node exists in the DT to represent 
>>>>> it. * However, the driver for the WiFi device needs certain 
>>>>> information, such as the reset GPIO ID and perhaps power GPIO.
>>>
>>>> PCI devices are also enumerable and yet they can be matched up with 
>>>> nodes in the device tree. Perhaps something similar could be added 
>>>> for the SDIO bus?
>>>
>>> This seems to make the most sense - pushing this through the 
>>> regulator API is just a bodge.
>>
>> Yes, that seems reasonable.
>>
>> Presumably the power GPIO should be a fixed regulator though, since it 
>> is a power control not just a plain old GPIO? That said, the current driver apparently deals with this as a GPIO already.
>>
>> The reset GPIO can separately/directly controlled by the WiFi driver though.
> 
> I talked with Franky, this power sequence is generally for 4329, so it mean this sequence can be put into the wifi driver.
> We can use the virtual platform device both for OOB and non OOB.
> I will send out patches later.

Can you please expand on what a "virtual platform device" is; device
tree typically represents real hardware rather than anything "virtual".

Now if this means adding a child node under the SDIO controller to
represent the attached device, and storing any settings required by that
device in that child node, that's probably a reasonable basic approach.

BTW, which GPIO is the power GPIO; is it WF_EN on the schematic? That
seems reasonable to represent as a GPIO rather than a regulator since it
connects directly into the WiFi device as a GPIO, and its use within the
WiFi device can indeed be governed purely internally to the WiFi
driver/HW. However, if this is some GPIO that controls the power to e.g.
VBAT3V3_IN_WF, VDDIO_WF, or other power supply to the WiFi card, then
it'd be better represented as a regulator, since the control point is
outside the WiFi device.

  reply	other threads:[~2012-06-15 15:49 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-13 10:40 Where to power on the wifi device before loading the driver Wei Ni
2012-06-13 17:33 ` Franky Lin
2012-06-14  4:17   ` Wei Ni
2012-06-14 16:45     ` Franky Lin
2012-06-13 21:17 ` Stephen Warren
2012-06-14  6:31   ` Thierry Reding
2012-06-14 12:12     ` Mark Brown
2012-06-14 15:54       ` Stephen Warren
2012-06-15  6:09         ` Wei Ni
2012-06-15 15:49           ` Stephen Warren [this message]
2012-06-18  6:20             ` Wei Ni
2012-06-18  7:40               ` Rakesh Kumar
2012-06-18  8:03                 ` Laxman Dewangan
2012-06-18 15:01                   ` Stephen Warren
2012-06-19  9:13                     ` Wei Ni
2012-06-19  1:23               ` Philip Rakity
2012-06-19  4:25                 ` Wei Ni
2012-06-19  9:17                   ` Mark Brown
2012-06-19  9:44                     ` Wei Ni
2012-06-20  0:01                       ` Stephen Warren
2012-06-20 10:47                         ` Mark Brown
2012-06-20 11:28                         ` Wei Ni
2012-06-20 16:51                           ` Stephen Warren
2012-06-26  8:56                         ` Dong Aisheng
2012-06-26 16:53                           ` Stephen Warren
2012-06-26 21:26                             ` Rob Herring
2012-06-26 22:38                               ` Stephen Warren
2012-06-27  2:19                               ` Dong Aisheng
2012-06-27  2:16                             ` Dong Aisheng
2012-06-15 16:24           ` Franky Lin
2012-06-18  6:00             ` Wei Ni
2012-06-14 11:27   ` Wei Ni
2012-06-14 11:44     ` Wei Ni

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=4FDB5976.20809@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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;
as well as URLs for NNTP newsgroup(s).