Configuring and using eTSEC and ASF

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Configuring and using eTSEC and ASF

1,374 Views
ridhigarg
Contributor II

Hi,

      I am working on LS1021A-IOT board and I want to use eTSEC and ASF for QOS purpose.

I have checked the SDK and hardware reference manual for LS1021A and found that following configuration options for ASF and eTSEC are available:

eTSEC: Can be configure using "ethtool" command line utility

ASF: Can be configure using various SYSFS interface ASF module provides.

Please find below my queries:

1. I want to configure eTSEC and ASF from my code, but I could not find any document which has details of any set of APIs for eTSEC and ASF configuration purpose.

2. In ASF architecture it is mentioned that ASF snoop packets from Network Driver, so is it referring to GIANFAR Ethernet driver for eTSECs?

Thanks

Tags (1)
7 Replies

984 Views
ridhigarg
Contributor II

Hi,

  Thanks. Ok i got your point but unfortunately we cannot move to any other processor with DPAA enabled.

So using LS1021A-IOT only, is there any way to mark Ethernet traffic as high priority as compared to any other traffic coming on WIFI or LTE interface or any other IP interface?

So that traffic on Ethernet interface is always handled with Highest Priority?

984 Views
bpe
NXP Employee
NXP Employee

ASF modules alone do not accelerate anything. ASF essentially relies on the

availability of hardware acceleration engines and hooks in the driver.

Check with your network interface hardware/driver documentation/support

what is available. If you are to implement it by yourself, look how it

is done in asf_ginfar.h, asf_gianfar.c, gianfar.c.

If your third party network hardware does not implement a header parsing engine,

one possible solution can be to move to a DPAA-enabled processor and

to pass the traffic coming to/from unaccelerated interfaces through

DPAA offline port. This would also require some coding because the

existing ASF does not support offline ports. Achievable acceleration

depends on the amount of time your CPU(s) spend relaying data between

unaccelerated interfaces and DPAA buffers/portals.


Have a great day,
Platon

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

984 Views
ridhigarg
Contributor II

Hi,

    Thanks for your reply. Yes for WIFI module we are also planning to use ath10k firmware but my actual concern is NATTING traffic between WIFI to LTE.

For example considering WiFi module is working as Access Point (AP) and LTE interface is connected to external network (Internet).

So to provide network connectivity to all devices which are connected to my WIFI AP, i need to apply NAT/forwarding of traffic between WIFI and LTE module.

And as i have read, ASF module provides NAT/forwarding functionalities but it provide these functionalities to configure only Ethernet interface traffic.

Can we use ASF for configuring NAT/Forwarding between WIFI and LTE module traffic ?

If not is there any other alternative for this?

0 Kudos

984 Views
pranavmadhu
Contributor IV

hi,
you can use hostapd. Hostapd is a user space daemon for access point and authentication servers. Also you have to integrate DPAA.

0 Kudos

984 Views
ridhigarg
Contributor II

Hi,

  Thanks for your reply. Its really helpful.

Can you please answer following as well:

1. We are planning to integrate WIFI module using PCIe interface and TELIT module using USB interface.

As per ASF design it snoops packets from Network driver, but it is also mentioned as currently it snoops packets only from Ethernet driver (GIANFAR for our case).

So can't we use ASF for appliying IPv4/6firewall & NAT/NAPT forwarding for packets receiving at these interfaces? Or is it possible somehow?

0 Kudos

985 Views
pranavmadhu
Contributor IV

Hi,

You can integrate wifi module to pci, for that you need ath10k firmware(support for wlan), which can be downloaded from github. And you can use this interface as an access point by NAT table forwarding. In our case, we used a 3g netsetter on USB.

0 Kudos

985 Views
bpe
NXP Employee
NXP Employee

>1. I want to configure eTSEC and ASF from my code, but I could not

>find any document which has details of any set of APIs for eTSEC and

>ASF configuration purpose.

>

[Platon] Ethtool uses IOCTLs to control network devices. See

gianfar_ethtool.c for what is available for eTSECs and ethtool.c,

ethtool.h for the system-level interface implementation details.

sysfs entries  are just files, you can read and write them standard

file IO calls.  See files under asfctrl/ to see what is made available

by ASF module.

>2. In ASF architecture it is mentioned that ASF snoop packets from

>Network Driver, so is it referring to GIANFAR Ethernet driver for

>eTSECs?

[Platon] Yes.

Have a great day,
Platon

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos