Project Home
Project Home
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Starting Wilink 8 driver on i.Mx6 Processor: (10 Items)
   
Starting Wilink 8 driver on i.Mx6 Processor  
Hello,

The latest drop of TI Wilink8 drivers provides  the following syntax to start drivers with DMA enabled. 

# Start io-pkt using the devnp-ti18xx_imx6x.so driver on SDIO port 2 - DMA 26 & 27
  io-pkt-v4-hc -dti18xx_imx6x sdio=2,dmatx=26,dmarx=27

How are the numbers 26 and 27 chosen. i.MX6 reference manual does not hard wire DMA channel numbers to SDIO port 2? 

Thanks,
Sesh
Re: Starting Wilink 8 driver on i.Mx6 Processor  
Hi Sesh,

The DMA event numbers are from the i.MX6 Reference Manual the numbers are
hard wired, see attached screenshot from the i.MX6 D/Q Reference Manual.

Mark

Attachment: Image mx6_sdma_events.png 169.99 KB
Re: Starting Wilink 8 driver on i.Mx6 Processor  
Here is an example from use file

# use -a /lib/dll/devnp-ti18xx_imx6x.so 
%C Driver for TI18xx Wireless controllers

Supported devices:
  TI18xx

Syntax:
  io-pkt-v4-hc -d ti18xx_imx6x [option[,option ...]] ... &

Options
  firmdir=dir           Directory for firmware
  bindir=dir            Directory for configuration bin files. (tiwlan.bin,roleAp.bin,roleSta.bin,roleP2pCl.bin)
  nvram                 Set nvram option
  sdio=[0|1|2]          Select SDIO port to use
  dmatx=N               DMA channel for transmit
  dmarx=N               DMA channel for receive
  irq=N                 IRQ to be used
  gpio=N                GPIO to be used for enable
  thr_prio=N            Priority to run driver thread.
  irq_gpio=N            IRQ to be used for OOB interrupt
  irq_cfg_dflt=[1]      Select default BSP GPIO configuration for the OOB irq (disabled by default)

Examples:
  # Start io-pkt using the devnp-ti18xx_imx6x.so driver on SDIO port 1:
  io-pkt-v4-hc -dti18xx_imx6x sdio=1
  # Start io-pkt using the devnp-ti18xx_imx6x.so driver on SDIO port 2 - DMA 26 & 27
  io-pkt-v4-hc -dti18xx_imx6x sdio=2,dmatx=26,dmarx=27

According to this example SDIO2 is associated with DMA events 26,27. This is not true as these events are associated 
with UART1 (Tx) & UART 2 (Rx). Usage of the word channel further confuses this as channel had a different meaning for 
DMA in i.MX6 reference. 
For eg: we use SDIO3 what will be my parameters for dmatx/rx?
Re: Starting Wilink 8 driver on i.Mx6 Processor  
Hi Sesh,

That looks like a typo in the use file. The SDMA event numbers from the
reference manual should definitely be used. There's a document describing
how to use WiLink8 on the mx6 Q Sabre Smart board here -
http://community.qnx.com/sf/wiki/do/viewPage/projects.bsp/wiki/FreescaleImx
6QSabreSmart that may also be helpful.


Mark

Re: Starting Wilink 8 driver on i.Mx6 Processor  
Hi Mark,

Thanks for the response. The link you sent is not working. I get the following error


"The page you requested cannot be found.
If you feel you have received this message in error, please contact the TeamForge administrator."

Regards,
Sesh
Re: Starting Wilink 8 driver on i.Mx6 Processor  
Hi Sesh,

Do you have access to http://community.qnx.com/sf/projects/bsp/? You may
need to join the BSP project.

Mark

Re: Starting Wilink 8 driver on i.Mx6 Processor  
I checked Sabresmart manual from forums site. This BSP is based of old MCP 8.4 TI release. No DMA support was available 
in this driver. I confirmed this by checking MCP 8.4 code base received from QNX. Sample command from "IMX6 Sabre Smart 
WIFI AND BT.pdf"

mount -T io-pkt -o sdio=2,gpio=103,irq_gpio=102 /lib/dll/devnp-ti18xx_imx6x.so

I have MCP 8.5 release ( Released in March 2015 ). I do not have the source code here but received some documentation 
from QNX showing the DMA tx and rx parameters. My preference is to have DMA enabled in Wilink 8 driver.
Re: Starting Wilink 8 driver on i.Mx6 Processor  
Hi Sesh,

Sorry for the confusion here. I took a look at the code again and the
i.MX6 variant of the WiLink8 driver doesn't actually use the "dmatx" and
"dmarx" parameters. These parameters are used by Host Controllers that use
shared DMA systems (e.g. EDMA on TI SOCs). Both the "dmatx" and "dmarx"
parameters can be ignored when using the i.MX6 varaint of the WiLink8
driver. SDIO DMA will be enabled by default on i.MX6 but since the i.MX6's
uSDHC host controller's DMA engine is not shared it's not necessary to
specify DMA event numbers.

One other note if you are upgrading from an older revision of the WiLink8
driver there was a change made July 8/2015 (i.e. WiLink8 PSPs >= build
#697). If using the newer WiLink8 driver your BSP's startup main.c file
MUST specify the SOC name, e.g. "I.MX6" (or "i.MX6"), "AM335X", "OMAP5",
etc. in _CS_MACHINE:
add_typed_string(_CS_MACHINE, "i.MX6Q Sabre-Smart Board");

This is because the updated WiLink8 driver reads _CS_MACHINE to determine
which SOC is being used as it needs this info for initialization to work.
Otherwise you'll get an error like this: "Unable to id SoC from machine
conf str to configure OOB irq based on startup GPIO mapping."


Mark

Re: Starting Wilink 8 driver on i.Mx6 Processor  
Hi Mark,

Thanks for the detailed mail. This answers all my questions.My latest wilink8 release is installed as patch from 

http://community.qnx.com/sf/wiki/do/viewPage/projects.customer_ast_services/wiki/All_SRA0599

The driver gets installed to C:/qnx660\target/qnx6/armle-v7/lib/dll/devnp-ti18xx_imx6x.so and is specifically built for 
i.MX6. We use it on our custom board and have not run into any issues.  

Regards,
Sesh
Re: Starting Wilink 8 driver on i.Mx6 Processor  
OK, great!

Mark